-TextStream = function(text) {
- if (typeof(text) == "undefined") text = "";
- text = ""+text;
- this.text = text;
- this.cursor = 0;
-}
-
-Roo.apply( TextStream.prototype, {
-
- look : function(n) {
- if (typeof n == "undefined") n = 0;
-
- if (this.cursor+n < 0 || this.cursor+n >= this.text.length) {
- var result = new String("");
- result.eof = true;
- return result;
- }
- return this.text.charAt(this.cursor+n);