123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- #region --------------- Copyright Dresser Wayne Pignone -------------
- /*
- * $Log: /Wrk/WayneLibraries/Wrk/StateEngine/TransitionInfo.cs $
- *
- * 2 08-03-10 16:16 Mattias.larsson
- * Fixed summaries.
- *
- * 1 08-03-10 15:00 Mattias.larsson
- * Created.
- */
- #endregion
- using System;
- namespace Wayne.Lib.StateEngine
- {
- /// <summary>
- /// A class wrapping information about a transition.
- /// </summary>
- public class TransitionInfo
- {
- #region Fields
- private string fromStateFactoryName;
- private string transitionName;
- private string toStateFactoryName;
- private HistoryType historyType;
- #endregion
- #region Construction
- /// <summary>
- /// Constructor.
- /// </summary>
- /// <param name="fromStateFactoryName"></param>
- /// <param name="transitionName"></param>
- /// <param name="toStateFactoryName"></param>
- /// <param name="historyType"></param>
- public TransitionInfo(string fromStateFactoryName, string transitionName,
- string toStateFactoryName, HistoryType historyType)
- {
- this.fromStateFactoryName = fromStateFactoryName;
- this.transitionName = transitionName;
- this.toStateFactoryName = toStateFactoryName;
- this.historyType = historyType;
- }
- #endregion
- #region Properties
- /// <summary>
- /// The factory name of the "From" state.
- /// </summary>
- public string FromStateFactoryName
- {
- get { return fromStateFactoryName; }
- }
- /// <summary>
- /// The name of the transition.
- /// </summary>
- public string TransitionName
- {
- get { return transitionName; }
- }
- /// <summary>
- /// The factory name of the "To" state.
- /// </summary>
- public string ToStateFactoryName
- {
- get { return toStateFactoryName; }
- }
- /// <summary>
- /// The History Type.
- /// </summary>
- public HistoryType HistoryType
- {
- get { return historyType; }
- }
- #endregion
- #region Methods
- /// <summary>
- /// To string.
- /// </summary>
- /// <returns></returns>
- public override string ToString()
- {
- return string.Format("{0} >>{1}>> {2}", fromStateFactoryName, transitionName, toStateFactoryName);
- }
- #endregion
- }
- }
|