Пример #1
0
        internal void Initialize(DIndentEngine engine, IndentState parent = null)
        {
            Parent = parent;
            Engine = engine;

            InitializeState();
        }
Пример #2
0
        /// <summary>
        ///     Creates a new indentation state that is a copy of the given
        ///     prototype.
        /// </summary>
        /// <param name="prototype">
        ///     The prototype state.
        /// </param>
        /// <param name="engine">
        ///     The engine of the new state.
        /// </param>
        protected IndentState(IndentState prototype, DIndentEngine engine)
        {
            Engine = engine;
            Parent = prototype.Parent != null?prototype.Parent.Clone(engine) : null;

            ThisLineIndent = prototype.ThisLineIndent.Clone();
            NextLineIndent = prototype.NextLineIndent.Clone();
        }
Пример #3
0
        public IStateMachineIndentEngine Clone()
        {
            var eng = new DIndentEngine();

            return(eng);
        }
Пример #4
0
 public abstract IndentState Clone(DIndentEngine engine);
Пример #5
0
		public IStateMachineIndentEngine Clone ()
		{
			var eng = new DIndentEngine ();

			return eng;
		}