org.robokind.api.common.services
Interface ServiceConfigurationLoader<ServiceConfig,Param>

Type Parameters:
ServiceConfig - Service Configuration Class returned by this loader
Param - Parameter Class passed in to this loader

public interface ServiceConfigurationLoader<ServiceConfig,Param>

An ServiceConfigurationLoader loads a ServiceConfig with a specific version. The ServiceConfig is used to connect to some Service such as: Servos, Microphone, Text-to-Speech, Face Tracking, etc...

Author:
Matthew Stevenson

Field Summary
static String PROP_CONFIG_FORMAT_VERSION
          Property String for the Configuration Format VersionProperty
static String PROP_PARAMETER_CLASS
          Property String for the Parameter Class used by the ServiceConfigurationLoader.
static String PROP_SERVICE_CONFIG_CLASS
          Property String for the Class of the ServiceConfig being loaded.
 
Method Summary
 Class<ServiceConfig> getConfigurationClass()
          Returns the Class of the ServiceConfig to be loaded.
 VersionProperty getConfigurationFormat()
          Specifies the Service Configuration Format version which can be loaded.
 Class<Param> getParameterClass()
          Returns the Class of the Parameter required to load a ServiceConfig.
 ServiceConfig loadConfiguration(Param param)
          Loads a ServiceConfig of the specified type from the given parameters.
 

Field Detail

PROP_CONFIG_FORMAT_VERSION

static final String PROP_CONFIG_FORMAT_VERSION
Property String for the Configuration Format VersionProperty

See Also:
Constant Field Values

PROP_SERVICE_CONFIG_CLASS

static final String PROP_SERVICE_CONFIG_CLASS
Property String for the Class of the ServiceConfig being loaded.

See Also:
Constant Field Values

PROP_PARAMETER_CLASS

static final String PROP_PARAMETER_CLASS
Property String for the Parameter Class used by the ServiceConfigurationLoader.

See Also:
Constant Field Values
Method Detail

getConfigurationFormat

VersionProperty getConfigurationFormat()
Specifies the Service Configuration Format version which can be loaded.

Returns:
VersionProperty specifying the Service Configuration Format to load

loadConfiguration

ServiceConfig loadConfiguration(Param param)
Loads a ServiceConfig of the specified type from the given parameters.

Parameters:
param - parameters needed to load the ServiceConfig
Returns:
ServiceConfig of the specified type from the given parameters

getConfigurationClass

Class<ServiceConfig> getConfigurationClass()
Returns the Class of the ServiceConfig to be loaded.

Returns:
Class of the ServiceConfig to be loaded

getParameterClass

Class<Param> getParameterClass()
Returns the Class of the Parameter required to load a ServiceConfig.

Returns:
Class of the Parameter required to load a ServiceConfig


Copyright © 2011. All Rights Reserved.