#region --------------- Copyright Dresser Wayne Pignone ------------- /* * $Log: /Wrk/WayneLibraries/Wrk/StateEngine/AnyState.cs $ * * 3 08-03-25 14:25 Mattias.larsson * Added 'new' to FactoryName. * * 2 08-03-25 14:14 Mattias.larsson * Added static members FactoryName and GetInstanceName(). */ #endregion using System; namespace Wayne.Lib.StateEngine { /// /// This is used to define the sourcestate as any state, a wildcard, /// if we want to create a general transition from a unspecified state in a machine. /// public sealed class AnyState : State { #region Static Fields private static string factoryName; #endregion #region Static Properties /// /// The factory name of the AnyState. /// public new static string FactoryName { get { if (factoryName == null) factoryName = typeof(AnyState).FullName; return factoryName; } } #endregion #region Static Methods /// /// Gets the name of this instance in a given configuration, using the supplied parent state instance name. /// /// /// public static string GetInstanceName(string parentStateInstanceName) { return string.Concat(parentStateInstanceName, ".", typeof(AnyState).Name); } #endregion } }