Package com.powsybl.commons.config
Class MapModuleConfig
- java.lang.Object
-
- com.powsybl.commons.config.AbstractModuleConfig
-
- com.powsybl.commons.config.AbstractMapModuleConfig
-
- com.powsybl.commons.config.MapModuleConfig
-
- All Implemented Interfaces:
ModuleConfig
- Direct Known Subclasses:
EnvironmentMapModuleConfig
public class MapModuleConfig extends AbstractMapModuleConfig
AModuleConfig
backed by a simple key/valueMap
.- Author:
- Geoffroy Jamgotchian
-
-
Constructor Summary
Constructors Constructor Description MapModuleConfig(FileSystem fs)
MapModuleConfig(Map<Object,Object> properties)
MapModuleConfig(Map<Object,Object> properties, FileSystem fs)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Set<String>
getPropertyNames()
protected Object
getValue(String propertyName)
Returns the value of the property with the specified name, ornull
if it does not exist.boolean
hasProperty(String name)
<T> void
setClassProperty(String name, Class<T> subClass)
void
setPathProperty(String name, Path path)
void
setStringListProperty(String name, List<String> value)
void
setStringProperty(String name, String value)
-
Methods inherited from class com.powsybl.commons.config.AbstractMapModuleConfig
getOptionalBooleanProperty, getOptionalDateTimeProperty, getOptionalDoubleProperty, getOptionalFloatProperty, getOptionalIntProperty, getOptionalLongProperty, getOptionalPathListProperty, getOptionalPathProperty, getOptionalStringListProperty, getOptionalStringProperty
-
Methods inherited from class com.powsybl.commons.config.AbstractModuleConfig
getBooleanProperty, getBooleanProperty, getClassProperty, getClassProperty, getDateTimeProperty, getDoubleProperty, getDoubleProperty, getEnumProperty, getEnumProperty, getEnumSetProperty, getEnumSetProperty, getFloatProperty, getFloatProperty, getIntervalProperty, getIntProperty, getIntProperty, getLongProperty, getLongProperty, getOptionalClassProperty, getOptionalEnumProperty, getOptionalEnumSetProperty, getOptionalIntervalProperty, getPathListProperty, getPathProperty, getPathProperty, getStringListProperty, getStringListProperty, getStringProperty, getStringProperty
-
-
-
-
Constructor Detail
-
MapModuleConfig
public MapModuleConfig(FileSystem fs)
-
MapModuleConfig
public MapModuleConfig(Map<Object,Object> properties, FileSystem fs)
-
-
Method Detail
-
getValue
protected Object getValue(String propertyName)
Description copied from class:AbstractMapModuleConfig
Returns the value of the property with the specified name, ornull
if it does not exist. The returned object may be aString
or directly a more specialized type (Date
orFloat
for instance).- Specified by:
getValue
in classAbstractMapModuleConfig
- Parameters:
propertyName
- The name of the property to be looked up- Returns:
- The value of the specified property it it exists,
null
otherwise.
-
hasProperty
public boolean hasProperty(String name)
-
-