Class ServiceDescriptorTools

java.lang.Object
chemaxon.marvin.services.ServiceDescriptorTools

@PublicAPI public class ServiceDescriptorTools extends Object
Helper class for accessing ServiceDescriptorReader, ServiceDescriptorWriter and ServiceDialogProvider implementations and various configuration data for services.
Since:
5.6
  • Field Details

    • SERVICE_CONFIGURATION_PATH_PROPERTY_KEY

      public static final String SERVICE_CONFIGURATION_PATH_PROPERTY_KEY
      Java System Property key to globally override default configuration path. Accepts absolute file path or URL in String format.
      Since:
      5.12
      See Also:
    • SERVICE_DIALOG_PROVIDER_CLASS_NAME_PROPERTY_KEY

      public static final String SERVICE_DIALOG_PROVIDER_CLASS_NAME_PROPERTY_KEY
      Java System Property key to globally override default Service Dialog Provider class with custom implementation.
      Since:
      6.0
      See Also:
    • DEFAULT_SERVICE_DESCRIPTOR_READER_CLASSNAME

      public static final String DEFAULT_SERVICE_DESCRIPTOR_READER_CLASSNAME
      the Marvin Default service descriptor reader class
      See Also:
    • DEFAULT_SERVICE_DESCRIPTOR_WRITER_CLASSNAME

      public static final String DEFAULT_SERVICE_DESCRIPTOR_WRITER_CLASSNAME
      the Marvin Default service descriptor writer class
      See Also:
    • DEFAULT_SERVICE_DIALOG_PROVIDER_CLASSNAME

      public static final String DEFAULT_SERVICE_DIALOG_PROVIDER_CLASSNAME
      the Marvin Default service dialog provider class
      See Also:
    • DEFAULT_SERVICE_DESCRIPTOR_EDITOR_PROVIDER_CLASSNAME

      public static final String DEFAULT_SERVICE_DESCRIPTOR_EDITOR_PROVIDER_CLASSNAME
      the Marvin Default service descriptor editor provider class
      See Also:
    • DEFAULT_SERVICE_CONFIGURATION_PATH

      public static final String DEFAULT_SERVICE_CONFIGURATION_PATH
      Path to default services configuration xml
      See Also:
    • DEFAULT_USER_SERVICE_CONFIGURATION_FILENAME

      public static final String DEFAULT_USER_SERVICE_CONFIGURATION_FILENAME
      name of default user service configuration file
      See Also:
  • Constructor Details

    • ServiceDescriptorTools

      public ServiceDescriptorTools()
  • Method Details

    • getDefaultServiceDescriptorReader

      public static ServiceDescriptorReader getDefaultServiceDescriptorReader()
      Returns the default ServiceDescriptorReader instance
      Returns:
      the default ServiceDescriptorReader instance, or null if no service descriptor reader is available
    • getDefaultServiceDescriptorWriter

      public static ServiceDescriptorWriter getDefaultServiceDescriptorWriter()
      Returns the default ServiceDescriptorWriter instance
      Returns:
      the default ServiceDescriptorWriter instance, or null if no service descriptor writer is available
    • getDefaultServiceDialogProvider

      public static ServiceDialogProvider getDefaultServiceDialogProvider()
      Returns the default ServiceDialogProvider instance
      Returns:
      the default ServiceDialogProvider instance, or null if no service dialog provider is available
    • getDefaultServiceDescriptorEditorProvider

      public static ServiceDescriptorEditorProvider getDefaultServiceDescriptorEditorProvider()
      Returns the default ServiceDescriptorEditorProvider instance
      Returns:
      the default ServiceDescriptorEditorProvider instance, or null if no service descriptor editor provider is available
    • getServiceDescriptorConfigurationAsStream

      public static InputStream getServiceDescriptorConfigurationAsStream()
      Returns an InputStream with service configuration.
      Returns:
      an InputStream with service configuration or null if not possible to get a configuration
    • getServiceDescriptorConfigurationAsStream

      public static InputStream getServiceDescriptorConfigurationAsStream(chemaxon.marvin.services.ServicesConfigURLProvider settings)
      Returns an InputStream with service configuration.
      Parameters:
      settings - the user settings
      Returns:
      an InputStream with service configuration or null if not possible to get a configuration
    • getServiceDescriptorConfigurationAsStream

      public static InputStream getServiceDescriptorConfigurationAsStream(String configPath)
      Returns the service descriptor configuration stream from path, or null.
      Parameters:
      configPath - the path or URL to service descriptor configuration. Empty String or null falls back to default configuration file.
      Returns:
      the service descriptor configuration stream from path, or null
      Since:
      5.10
    • getServiceDescriptorReader

      public static ServiceDescriptorReader getServiceDescriptorReader(String descriptorReaderClassName)
      Returns the ServiceDescriptorReader instance if available, or null
      Parameters:
      descriptorReaderClassName - the class name of the service descriptor writer
      Returns:
      the ServiceDescriptorReader instance if available, or null
    • getServiceDescriptorWriter

      public static ServiceDescriptorWriter getServiceDescriptorWriter(String descriptorWriterClassName)
      Returns the ServiceDescriptorWriter instance if available, or null
      Parameters:
      descriptorWriterClassName - the class name of the service descriptor writer
      Returns:
      the ServiceDescriptorWriter instance if available, or null
    • getServiceDialogProvider

      public static ServiceDialogProvider getServiceDialogProvider(String serviceDialogProviderClassName)
      Returns the ServiceDialogProvider instance if available, or null
      Parameters:
      serviceDialogProviderClassName - the class name of the service dialog provider
      Returns:
      the ServiceDialogProvider instance if available, or null
    • getServiceDescriptorEditorProvider

      public static ServiceDescriptorEditorProvider getServiceDescriptorEditorProvider(String serviceDescriptorEditorProviderClassName)
      Returns the ServiceDescriptorEditorProvider instance if available, or null
      Parameters:
      serviceDescriptorEditorProviderClassName - the class name of the service descriptor editor provider
      Returns:
      the ServiceDescriptorEditorProvider instance if available, or null