コード例 #1
0
        public override void ExitSan_move(Generated.TakPGNParser.San_moveContext context)
        {
            var          notationText = context.SYMBOL().GetText();
            MoveNotation notation;

            if (!MoveNotation.TryParse(notationText, out notation))
            {
                throw new ApplicationException("Unrecognized move notation: " + notationText);
            }
            _currentGame.MoveNotations.Add(notation);
            base.ExitSan_move(context);
        }
コード例 #2
0
 /// <summary>
 /// Exit a parse tree produced by <see cref="TakPGNParser.san_move"/>.
 /// <para>The default implementation does nothing.</para>
 /// </summary>
 /// <param name="context">The parse tree.</param>
 public virtual void ExitSan_move([NotNull] TakPGNParser.San_moveContext context)
 {
 }