|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.scopes.impl.StateImpl
public class StateImpl
Simple implementation for a state.
| Constructor Summary | |
|---|---|
StateImpl()
Constructor. |
|
| Method Summary | |
|---|---|
java.lang.Object |
getAttribute(java.lang.String attributeName)
Returns an attribute, searching in all contexts, until it finds one. |
java.lang.Object |
getAttribute(java.lang.String contextName,
java.lang.String attributeName)
Returns an attribute in a context. |
java.util.Set<java.lang.String> |
getAttributeNames()
Returns all attribute names in all contexts. |
java.util.Set<java.lang.String> |
getAttributeNames(java.lang.String contextName)
Returns the attribute names for a particular context. |
Context |
getContext(java.lang.String contextName)
Returns a context object. |
java.util.Set<java.lang.String> |
getContextNames()
Returns the names of the used contexts. |
void |
removeAttribute(java.lang.String attributeName)
Removes an attribute in every context. |
void |
removeAttribute(java.lang.String contextName,
java.lang.String attributeName)
Removes an attribute from a context. |
void |
setAttribute(java.lang.String attributeName,
java.lang.Object object)
Sets an attribute, searching if it exists. |
void |
setAttribute(java.lang.String contextName,
java.lang.String attributeName,
java.lang.Object object)
|
void |
setContext(java.lang.String contextName,
Context context)
Sets a context, giving its context name. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StateImpl()
| Method Detail |
|---|
public java.util.Set<java.lang.String> getContextNames()
State
getContextNames in interface State
public void setContext(java.lang.String contextName,
Context context)
contextName - The context name.context - The context object.public Context getContext(java.lang.String contextName)
State
getContext in interface StatecontextName - The context name.
public java.lang.Object getAttribute(java.lang.String contextName,
java.lang.String attributeName)
State
getAttribute in interface StatecontextName - The name of the context.attributeName - The name of the attribute.
public java.util.Set<java.lang.String> getAttributeNames(java.lang.String contextName)
State
getAttributeNames in interface StatecontextName - The name of the context.
public void setAttribute(java.lang.String contextName,
java.lang.String attributeName,
java.lang.Object object)
setAttribute in interface State
public void removeAttribute(java.lang.String contextName,
java.lang.String attributeName)
State
removeAttribute in interface StatecontextName - The name of the context.attributeName - The attribute to remove.public java.lang.Object getAttribute(java.lang.String attributeName)
State
getAttribute in interface StateattributeName - The attribute name to search.
public java.util.Set<java.lang.String> getAttributeNames()
State
getAttributeNames in interface State
public void setAttribute(java.lang.String attributeName,
java.lang.Object object)
State
setAttribute in interface StateattributeName - The name of the attribute to overwrite.object - The new attributepublic void removeAttribute(java.lang.String attributeName)
State
removeAttribute in interface StateattributeName - The attribute to remove.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||