Esempio n. 1
0
 public StringReader(string sourceCode)
 {
     _charBuffer = sourceCode.ToCharArray();
     _currentPosition = new TextPosition
     {
         CharIndex = 0,
         LineNo = 1,
         ColNo = 1
     };
 }
Esempio n. 2
0
 public string Substr(TextPosition start, TextPosition end)
 {
     return new string(_charBuffer, start.CharIndex, end.CharIndex - start.CharIndex);
 }