Пример #1
0
 protected void DumpCore(StringBuilder sb)
 {
     sb.AppendFormat(
         "\tnull   {3}\r\n" +
         "\tfirst  {0}\r\n" +
         "\tlast   {1}\r\n" +
         "\tfollow {2}\r\n",
         RegexpBuilder.DumpSet(FirstPos),
         RegexpBuilder.DumpSet(LastPos),
         RegexpBuilder.DumpSet(FollowPos),
         Nullable);
 }
Пример #2
0
            public override string ToString()
            {
                StringBuilder sb = new StringBuilder();

                sb.AppendFormat("s{0} posn {1}", Index, RegexpBuilder.DumpSet(Positions));
                if (Accepts)
                {
                    sb.Append(" (acc)");
                }
                sb.Append(" next:");
                for (int i = 0; i != NextState.Length; ++i)
                {
                    if (NextState[i] != null)
                    {
                        sb.AppendFormat(" {0:X2}->s{1}", i, NextState[i].Index);
                    }
                }
                return(sb.ToString());
            }