public class ParameterMap extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
protected Hashtable<String,String> |
codeMap |
protected Hashtable<String,Hashtable<String,Object>> |
typeMap |
Constructor and Description |
---|
ParameterMap() |
Modifier and Type | Method and Description |
---|---|
void |
clear(Class<? extends ParameterObject> paramType) |
void |
clear(DBRowSet rowset) |
void |
clear(String type) |
protected String |
encodeAndStore(String typeName,
String objectKey,
Object item,
boolean useCache)
encodes the objectKey and stores the item in the parameter map
|
String |
encodeString(String valueAsString) |
String |
encodeStringWithCache(String valueAsString) |
<T extends ParameterObject> |
get(Class<T> paramType,
String id)
Puts an object into the paramter map that implements the ParameterObject interface
|
Object |
get(String type,
String id)
Gets an object from the parameter map for a given type and id
|
Object[] |
getKey(DBRowSet rowset,
String id) |
Object[] |
getKey(PageDefinition page,
DBRowSet rowset,
String id)
returns an record key for a given page
|
protected String |
getRowSetTypeName(DBRowSet rowset)
gets a unique name for a given rowset
|
String |
put(DBRowSet rowset,
Object[] key) |
String |
put(PageDefinition targetPage,
DBRowSet rowset,
Object[] key)
Generates an idParam which is only valid for the given page.
|
String |
put(ParameterObject paramObject)
Puts an object into the paramter map that implements the ParameterObject interface
|
String |
put(String type,
String key,
boolean useCache) |
protected void |
putValue(String typeName,
String encodedId,
Object item)
puts an object into the parameter map
|
protected String getRowSetTypeName(DBRowSet rowset)
rowset
- protected void putValue(String typeName, String encodedId, Object item)
typeName
- id
- value
- protected String encodeAndStore(String typeName, String objectKey, Object item, boolean useCache)
typeName
- id
- value
- public String put(ParameterObject paramObject)
paramObject
- public String put(PageDefinition targetPage, DBRowSet rowset, Object[] key)
targetPage
- rowset
- key
- public Object get(String type, String id)
type
- the object type (typically the class name)id
- the encoded idParampublic void clear(String type)
public <T extends ParameterObject> T get(Class<T> paramType, String id)
paramType
- id
- public void clear(Class<? extends ParameterObject> paramType)
public void clear(DBRowSet rowset)
public Object[] getKey(PageDefinition page, DBRowSet rowset, String id)
page
- rowset
- id
- Copyright © 2008–2022 Apache Software Foundation. All rights reserved.