Package zendesk.support.suas
Class State
- java.lang.Object
-
- zendesk.support.suas.State
-
- All Implemented Interfaces:
- java.io.Serializable
public class State extends java.lang.Object implements java.io.SerializableAn implementation of state that's used in aSuasStore.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description State()Create a new and empty state.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description booleanequals(java.lang.Object o)<E> EgetState(java.lang.Class<E> clazz)Get a state for aClassjava.lang.ObjectgetState(java.lang.String stateKey)Get a state for a state key<E> EgetState(java.lang.String stateKey, java.lang.Class<E> clazz)Get a state for the a state key of the type<E>inthashCode()java.lang.StringtoString()
-
-
-
Method Detail
-
getState
public java.lang.Object getState(java.lang.String stateKey)
Get a state for a state key- Parameters:
stateKey- state key- Returns:
- not typed state
-
getState
public <E> E getState(java.lang.Class<E> clazz)
Get a state for aClassIf available in the state returns a the state with type
<E>- Parameters:
clazz- type of the state- Returns:
- the state with the correct type or
null
-
getState
public <E> E getState(java.lang.String stateKey, java.lang.Class<E> clazz)Get a state for the a state key of the type<E>If available in the state returns a the state with type
<E>- Parameters:
stateKey- key for the stateclazz- type of the state- Returns:
- the state with the correct type or
null
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-