示例#1
0
        private string ReadUntil(char c)
        {
            string text = "";

            while (true)
            {
                char next = this._buffer.Next;
                bool flag = next == c;
                if (flag)
                {
                    break;
                }
                text += next.ToString();
            }
            FileBuffer expr_25  = this._buffer;
            int        position = expr_25.Position;

            expr_25.Position = position - 1;
            bool flag2 = text[0] == '"';

            if (flag2)
            {
                text = text.Remove(0, 1);
            }
            bool flag3 = text[text.Length - 1] == '"';

            if (flag3)
            {
                text = text.Remove(text.Length - 1, 1);
            }
            return(text);
        }
示例#2
0
        private string NextToken()
        {
            string text = "";
            bool   flag = false;

            while (true)
            {
                char next  = this._buffer.Next;
                bool flag2 = XMLFragmentParser._punctuation.Contains(next);
                if (flag2)
                {
                    bool flag3 = text != "";
                    if (flag3)
                    {
                        break;
                    }
                    flag = true;
                }
                else
                {
                    bool flag4 = char.IsWhiteSpace(next);
                    if (flag4)
                    {
                        bool flag5 = text != "";
                        if (flag5)
                        {
                            goto Block_4;
                        }
                        continue;
                    }
                }
                text += next.ToString();
                bool flag6 = flag;
                if (flag6)
                {
                    goto Block_5;
                }
            }
            FileBuffer expr_43  = this._buffer;
            int        position = expr_43.Position;

            expr_43.Position = position - 1;
Block_4:
Block_5:
            text = this.TrimControl(text);
            bool flag7 = text[0] == '"';

            if (flag7)
            {
                text = text.Remove(0, 1);
            }
            bool flag8 = text[text.Length - 1] == '"';

            if (flag8)
            {
                text = text.Remove(text.Length - 1, 1);
            }
            return(text);
        }
示例#3
0
 public void Load(Stream stream)
 {
     this._buffer = new FileBuffer(stream);
 }