Interface ConfigurationMapper<T>

All Known Implementing Classes:
AbstractAwsProfileMapper, AbstractProfileConfigMapper, BoxProfileMapper, S3ProfileMapper, WebDavProfileMapper

public interface ConfigurationMapper<T>
Interface for classes that map configuration data to Java bean classes.
Author:
avasquez
  • Method Summary

    Modifier and Type
    Method
    Description
    processConfig(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> config)
    Reads a single profile from the given configuration
    readConfig(ConfigurationProvider provider, String module, String path, String encoding, String configId)
    Reads the configuration from the specified input stream, extracts the specific sub-configuration identified by configId and maps the configuration to a Java bean.
  • Method Details

    • readConfig

      T readConfig(ConfigurationProvider provider, String module, String path, String encoding, String configId) throws ConfigurationException, ConfigurationProfileNotFoundException
      Reads the configuration from the specified input stream, extracts the specific sub-configuration identified by configId and maps the configuration to a Java bean.
      Parameters:
      provider - the provider to read the configuration file
      encoding - the charset encoding of the configuration file
      configId - the ID of the specific sub-configuration to map
      Returns:
      the configuration object
      Throws:
      ConfigurationException - if an error occurs
      ConfigurationProfileNotFoundException - if profile is not found
    • processConfig

      T processConfig(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> config) throws ConfigurationException
      Reads a single profile from the given configuration
      Parameters:
      config - the profile configuration
      Returns:
      the configuration object
      Throws:
      ConfigurationException - if an error occurs