public interface InformationContainer
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
KEY_BUILT_IN_FUN_ACCESSIBLE_RESOURCES |
Modifier and Type | Method and Description |
---|---|
java.util.List<java.io.Serializable> |
getAllInfo()
Gets all information stored in the container.
|
java.io.Serializable |
getInfo(java.lang.String key)
Gets the information from container.
|
void |
putInfo(java.lang.String key,
java.io.Serializable obj,
InfoLifeCycleType lifeCycleType,
java.lang.Object... lifeCycle)
Pub information into the container.
|
boolean |
removeInfo(java.lang.String key)
Removes the information object from container.
|
static final java.lang.String KEY_BUILT_IN_FUN_ACCESSIBLE_RESOURCES
void putInfo(java.lang.String key, java.io.Serializable obj, InfoLifeCycleType lifeCycleType, java.lang.Object... lifeCycle)
key
- The information keyobj
- The information valuelifeCycleType
- The information life cycle type, one of LONG_TIME, SPECIFIED_TIME, ONCE_TIME.lifeCycle
- The information life cycle, only need when lifeCycleType value is SPECIFIED_TIME.
The lifeCycle can be int, long and Date, for int and long, the unit is millisecond. When the
lifeCycle was specified by int or long millisecond, the obj will be removed from information
container after it put into container specified millisecond. When the lifeCycle was specified
by Date, the obj will be removed at the Date specified.java.io.Serializable getInfo(java.lang.String key)
key
- The information key.boolean removeInfo(java.lang.String key)
key
- The information key.java.util.List<java.io.Serializable> getAllInfo()