1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- using System;
- using System.Collections.Generic;
- using Wayne.Lib;
- using Wayne.Lib.StateEngine;
- using System.Threading;
- namespace Wayne.Lib.StateEngine.Generic
- {
-
-
-
-
-
-
-
-
-
-
-
-
-
- public abstract class AsyncWorkState<TMain, TData> : AsyncWorkState<TMain> where TData : StateData
- {
- #region Fields
- private IStateWithData stateWithData;
- #endregion
- #region Construction
-
-
-
-
- protected AsyncWorkState(object doneTransitionType)
- : base(doneTransitionType)
- {
- }
- #endregion
- #region Properties
-
-
-
- protected TData Data
- {
- get
- {
- if (stateWithData == null)
- {
- stateWithData = StateData.GetParentCompositeStateWithStateData<TData>(this);
- }
- return stateWithData.StateData as TData;
- }
- }
- #endregion
- }
- }
|