java.lang.Object
com.pervasive.datarush.graphs.EngineProperty<T>
- Type Parameters:
T- the type of the engine property
Defined configuration properties for the DataRush engine.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> EngineProperty<T>defineProperty(String propertyName, String description, Class<T> propertyClass, T defaultValue) Creates a new engine propertystatic List<EngineProperty<?>>discoverProperties(Class<?> clazz) Finds allpublic static final EnginePropertydeclarations of the given class and its inner classes.static EngineProperty<?>discoverProperty(Class<?> clazz, String name) Looks up engine properties by their property file keys.final booleanGets the default value for the property.final StringGets a description of the property.final StringGets the property key for use in properties files.Returns the class of values of this propertyfinal inthashCode()parseValue(String value) Parses the given value from its text representation to the type of the propertytoString()
-
Method Details
-
defineProperty
public static <T> EngineProperty<T> defineProperty(String propertyName, String description, Class<T> propertyClass, T defaultValue) Creates a new engine property- Type Parameters:
T- the type of property- Parameters:
propertyName- the name of the propertydescription- the description of the propertypropertyClass- the type of the propertydefaultValue- the default value of the property- Returns:
- a new engine property
-
hashCode
public final int hashCode() -
equals
-
parseValue
public T parseValue(String value) throws com.pervasive.datarush.graphs.physical.InvalidPropertyValueException Parses the given value from its text representation to the type of the property- Parameters:
value- the next value- Returns:
- the property value
- Throws:
com.pervasive.datarush.graphs.physical.InvalidPropertyValueException- if a parse error occurs
-
getProperty
Gets the property key for use in properties files.- Returns:
- the property's key name
-
getDescription
Gets a description of the property.- Returns:
- the property's description
-
getDefaultValue
Gets the default value for the property.- Returns:
- the property's default
-
toString
-
getPropertyClass
Returns the class of values of this property- Returns:
- the class of values of this property
-
discoverProperties
Finds allpublic static final EnginePropertydeclarations of the given class and its inner classes.- Parameters:
clazz- the class, usuallyEngineConfig- Returns:
- all property declarations in the given class and inner classes
-
discoverProperty
Looks up engine properties by their property file keys.- Parameters:
clazz- the class containing property declarationsname- the key from the property file- Returns:
- the associated engine property.
nullif no such property can be found.
-