Jon Berndt wrote:

OK, I fixed the problem. Here's what I do now in FGXMLParse (my 
XMLVisitor-derived class):

startElement():

Here I simply set the working string to the null string.

data():

Here I append the string that is passed in to the current working string,

 working_string += string(s, length);

endElement():

Here is where more work is done. When execution gets to here, the working string could be
composed of several lines (with embedded spaces and newlines). I work through this string,
finding each line until there are no more lines.



That sounds like the right approach to me (and I'm an expert because I took a compilers class 15 years ago and we used the "Dragon book".) :-)


Curt.

--
Curtis Olson        http://www.flightgear.org/~curt
HumanFIRST Program  http://www.humanfirst.umn.edu/
FlightGear Project  http://www.flightgear.org
Unique text:        2f585eeea02e2c79d7b1d8c4963bae2d


_______________________________________________ Flightgear-devel mailing list Flightgear-devel@flightgear.org http://mail.flightgear.org/mailman/listinfo/flightgear-devel 2f585eeea02e2c79d7b1d8c4963bae2d

Reply via email to