Open GoogleCodeExporter opened 9 years ago
I guess the question is what you consider as the current location in the
"Stream" for the purposes of parsing. Maybe we should add a StringStream
object (or similar) that would let you treat a String as a Stream?
Original comment by dmel...@gmail.com
on 9 May 2012 at 1:03
Current location in Stream should be the last byte I read or parsed. Again, I
take TextFinder as my model, since it works well, and makes sense in terms of
how it operates.
For String, though, it could be simpler. What I'm thinking of would be
something that parses a string and pulls out the first legit number. Classic
use case would be something that reads values from a comma-separated value
string. given:
String foo = "23.5, 456, 123\r\n"
I want to do:
float first = foo.parseFloat();
float second = foo.parseFloat();
float third = foo.parseFloat(); //or parseInt
and get numeric values.
Original comment by tom.i...@gmail.com
on 9 May 2012 at 11:01
Original issue reported on code.google.com by
tom.i...@gmail.com
on 20 Apr 2012 at 12:57