public interface Context extends BaseContext
Modifier and Type | Method and Description |
---|---|
void |
clearSubContext()
删除所有子上下文
|
Context |
createSubContext(String contextName)
创建子上下文
|
<T> T |
getInSubContext(String contextName,
String name)
从指定子环境获取变量
|
Map<String,Object> |
getItemMap()
返回当前上下文(不包含子上下文)中所有内容
|
Context |
getParent()
返回父上下文对象
|
Context |
getSubContext(String contextName)
返回子环境
|
Map<String,Context> |
getSubContextMap()
返回所有子上下文组装成的map
|
Map<String,Object> |
getTotalItemMap()
Deprecated.
|
<T> T |
put(String contextName,
String name,
T object)
添加到子环境
|
Context |
putSubContext(String contextName,
Context context)
添加子环境
|
<T> T |
remove(String contextName,
String name)
从子上下文中删除name的参数信息
|
Context |
removeSubContext(String contextName)
删除子上下文
|
void |
setParent(Context parent)
设置父上下文对象
|
Context createSubContext(String contextName)
contextName
- 上下文名称<T> T remove(String contextName, String name)
contextName
- 子环境名称name
- 上下文变量名称<T> T getInSubContext(String contextName, String name)
contextName
- 子环境name
- 上下文变量名称<T> T put(String contextName, String name, T object)
contextName
- 子环境name
- 上下文变量名称object
- 要放入的数据Context getParent()
void setParent(Context parent)
parent
- 父上下文对象Context putSubContext(String contextName, Context context)
contextName
- 子环境context
- Context getSubContext(String contextName)
contextName
- 子环境void clearSubContext()
Map<String,Object> getItemMap()
getItemMap
in interface BaseContext
@Deprecated Map<String,Object> getTotalItemMap()
Copyright © 2006–2018 TinyGroup. All rights reserved.