public class StateContainer<O,S extends IStateHolder<S>>
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
StateContainer.Builder<O,S extends IStateHolder<S>> |
static interface |
StateContainer.IFactory<O,S extends IStateHolder<S>,A extends StateHolder<O,S>> |
Modifier and Type | Field and Description |
---|---|
private static java.util.regex.Pattern |
NAME_PATTERN |
private O |
owner |
private com.google.common.collect.ImmutableSortedMap<java.lang.String,IProperty<?>> |
properties |
private com.google.common.collect.ImmutableList<S> |
validStates |
Modifier | Constructor and Description |
---|---|
protected |
StateContainer(O object,
StateContainer.IFactory<O,S,A> factory,
java.util.Map<java.lang.String,IProperty<?>> propertiesIn) |
Modifier and Type | Method and Description |
---|---|
S |
getBaseState() |
O |
getOwner() |
java.util.Collection<IProperty<?>> |
getProperties() |
IProperty<?> |
getProperty(java.lang.String propertyName) |
com.google.common.collect.ImmutableList<S> |
getValidStates() |
java.lang.String |
toString() |
private static final java.util.regex.Pattern NAME_PATTERN
private final O owner
private final com.google.common.collect.ImmutableSortedMap<java.lang.String,IProperty<?>> properties
private final com.google.common.collect.ImmutableList<S extends IStateHolder<S>> validStates
protected StateContainer(O object, StateContainer.IFactory<O,S,A> factory, java.util.Map<java.lang.String,IProperty<?>> propertiesIn)
public com.google.common.collect.ImmutableList<S> getValidStates()
public S getBaseState()
public O getOwner()
public java.util.Collection<IProperty<?>> getProperties()
public java.lang.String toString()
toString
in class java.lang.Object
@Nullable public IProperty<?> getProperty(java.lang.String propertyName)