public IState GetState(StateTypeEnum state) { IState istate = null; if (!m_States.TryGetValue(state, out istate)) return null; return istate; }
public void SetState(StateTypeEnum state) { IState istate = null; lock (this) { if (!m_States.TryGetValue(state, out istate)) { ArgumentException ex = new ArgumentException("Could not find the state of type " + state.ToString()); Logger.LogError(ex.Message); throw ex; } } SetState(istate); }
public StatefullAttribute(StateTypeEnum stateType) { StateType = stateType; }