Class VelocityContext
java.lang.Object
com.nomagic.magicreport.engine.velocity.VelocityContext
- All Implemented Interfaces:
IContext,Serializable
Implementation of the
IContext interface for use. This implementation uses a
org.apache.velocity.VelocityContext for data storage.
org.apache.velocity.VelocityContext is not synchronized. If you need to share a Context between
threads with simultaneous access for some reason, please create your own and extend the interface Context- Since:
- Jun 11, 2007 10:50:15 PM
- Version:
- 1.0 Jun 11, 2007
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionFinds all the keys of the entry in this context.String[]Finds all the keys of the entry in this context as array.org.apache.velocity.VelocityContextCreate a velocity context from template context.Gets the value corresponding to the provided key from the context.Adds a name/value pair to the context.Removes the value associated with the specified key from the context.voidRemoves all items from this context.
-
Constructor Details
-
VelocityContext
public VelocityContext()Creates a new instance (with no inner context).
-
-
Method Details
-
get
Gets the value corresponding to the provided key from the context. -
remove
Removes the value associated with the specified key from the context. -
put
Adds a name/value pair to the context. -
removeAll
public void removeAll()Removes all items from this context. -
contextKeys
Finds all the keys of the entry in this context.- Specified by:
contextKeysin interfaceIContext- Returns:
- an Iterator of all the key of the entry in this context.
-
contextKeysArray
Finds all the keys of the entry in this context as array.- Specified by:
contextKeysArrayin interfaceIContext- Returns:
- an array of all the key of the entry in this context.
-
createContext
public org.apache.velocity.VelocityContext createContext()Create a velocity context from template context.- Returns:
- a velocity context
-