接口 RuntimeProperty<T>
-
- 所有已知实现类:
AbstractRuntimeProperty,BooleanProperty,EnumProperty,IntegerProperty,LongProperty,MemorySizeProperty,StringProperty
public interface RuntimeProperty<T>
-
-
嵌套类概要
嵌套类 修饰符和类型 接口 说明 static interfaceRuntimeProperty.RuntimePropertyListener
-
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 voidaddListener(RuntimeProperty.RuntimePropertyListener l)Add listener for this property changes.TgetInitialValue()Get initial value (default or defined in connection string/Properties)PropertyDefinition<T>getPropertyDefinition()StringgetStringValue()Get internal value representation as String.TgetValue()Get internal value representation as Object.voidinitializeFrom(Properties extractFrom, ExceptionInterceptor exceptionInterceptor)Explicitly set value of this RuntimeProperty according to the self-titled property value contained in extractFrom.voidinitializeFrom(Reference ref, ExceptionInterceptor exceptionInterceptor)booleanisExplicitlySet()voidremoveListener(RuntimeProperty.RuntimePropertyListener l)voidresetValue()Reset to initial value (default or defined in connection string/Properties)voidsetValue(T value)Set the object value of a property directly.voidsetValue(T value, ExceptionInterceptor exceptionInterceptor)Set the object value of a property directly.
-
-
-
方法详细资料
-
getPropertyDefinition
PropertyDefinition<T> getPropertyDefinition()
-
initializeFrom
void initializeFrom(Properties extractFrom, ExceptionInterceptor exceptionInterceptor)
Explicitly set value of this RuntimeProperty according to the self-titled property value contained in extractFrom. This method is called during PropertySet initialization thus ignores the RUNTIME_NOT_MODIFIABLE flag.This value will also be the initial one, i.e.
resetValue()will reset to this value, not the default one.If extractFrom does not contain such property then this RuntimeProperty remains unchanged.
- 参数:
extractFrom-Propertiesobject containing key-value pairs usually passed from connection string.exceptionInterceptor- exceptionInterceptor
-
initializeFrom
void initializeFrom(Reference ref, ExceptionInterceptor exceptionInterceptor)
-
resetValue
void resetValue()
Reset to initial value (default or defined in connection string/Properties)
-
isExplicitlySet
boolean isExplicitlySet()
-
addListener
void addListener(RuntimeProperty.RuntimePropertyListener l)
Add listener for this property changes.
-
removeListener
void removeListener(RuntimeProperty.RuntimePropertyListener l)
-
getValue
T getValue()
Get internal value representation as Object.- 返回:
- value
-
getInitialValue
T getInitialValue()
Get initial value (default or defined in connection string/Properties)- 返回:
- value
-
getStringValue
String getStringValue()
Get internal value representation as String.- 返回:
- value
-
setValue
void setValue(T value)
Set the object value of a property directly. Validation against allowable values will be performed.- 参数:
value- value
-
setValue
void setValue(T value, ExceptionInterceptor exceptionInterceptor)
Set the object value of a property directly. Validation against allowable values will be performed.- 参数:
value- valueexceptionInterceptor- exception interceptor
-
-