Class FileConverter
- java.lang.Object
-
- org.codehaus.plexus.component.configurator.converters.AbstractConfigurationConverter
-
- org.codehaus.plexus.component.configurator.converters.basic.AbstractBasicConverter
-
- org.codehaus.plexus.component.configurator.converters.basic.FileConverter
-
- All Implemented Interfaces:
ConfigurationConverter
public class FileConverter extends AbstractBasicConverter
- Author:
- Brett Porter
-
-
Constructor Summary
Constructors Constructor Description FileConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancanConvert(Class type)ObjectfromConfiguration(ConverterLookup converterLookup, PlexusConfiguration configuration, Class type, Class baseType, ClassLoader classLoader, ExpressionEvaluator expressionEvaluator, ConfigurationListener listener)ObjectfromString(String str)-
Methods inherited from class org.codehaus.plexus.component.configurator.converters.basic.AbstractBasicConverter
fromExpression
-
Methods inherited from class org.codehaus.plexus.component.configurator.converters.AbstractConfigurationConverter
fromConfiguration, fromExpression, fromXML, getClassForImplementationHint, instantiateObject, instantiateObject, loadClass, toXML
-
-
-
-
Method Detail
-
canConvert
public boolean canConvert(Class type)
-
fromString
public Object fromString(String str)
- Specified by:
fromStringin classAbstractBasicConverter
-
fromConfiguration
public Object fromConfiguration(ConverterLookup converterLookup, PlexusConfiguration configuration, Class type, Class baseType, ClassLoader classLoader, ExpressionEvaluator expressionEvaluator, ConfigurationListener listener) throws ComponentConfigurationException
- Specified by:
fromConfigurationin interfaceConfigurationConverter- Overrides:
fromConfigurationin classAbstractBasicConverter- Parameters:
converterLookup- Repository of available convertersconfiguration-PlexusConfigurationtype- the type of object to readbaseType- the type of object the the source isclassLoader- ClassLoader which should be used for loading classesexpressionEvaluator- the expression evaluator to use for expressionslistener-ConfigurationListener.- Returns:
- the object
- Throws:
ComponentConfigurationException- in case of an error. TODO: a better way, instead of baseType, would be to pass in a factory for new classes that could be based from the given package
-
-