public PropertyChangedCommand(IStatefulObject model, ValueChangedEventArgs e) { if (model.DataState == DataState.Initializing) return; snapshot = new Snapshot() { Model = model as StatefulObject, OldState = model.DataState, NewState = DataState.Modified, OldValue = e.OldValue, NewValue = e.NewValue, PropertyName = e.PropertyName }; }
/// <summary> /// Indicates that this object is currently passing through the specific workflow /// </summary> /// <param name="self"></param> /// <param name="workflow"></param> /// <returns></returns> public static bool IsAliveInWorkflow <T>(this IStatefulObject self, IStatefulWorkflow <T> workflow) where T : class, IStatefulObject { return(self.GetStateId(workflow.WorkflowId) != null); }
/// <summary> /// Indicates that this object is currently passing through the specific workflow /// </summary> /// <param name="self"></param> /// <param name="workflowId"></param> /// <returns></returns> public static bool IsAliveInWorkflow(this IStatefulObject self, object workflowId) { return(self.GetStateId(workflowId) != null); }
public ClassStateOne(IStatefulObject statefulObject) { _statefulObject = statefulObject; }
public ClassStateTwo(IStatefulObject stateful) { _statefulObject = stateful; }
public DefaultState(IStatefulObject statefulObject) { _statefulObject = statefulObject; }