void NxsToken::GetNextToken (  ) 

Reads characters from in until a complete token has been read and stored in token.

GetNextToken performs a number of useful operations in the process of retrieving tokens: ~ o any underscore characters encountered are stored as blank spaces (unless the labile flag bit preserveUnderscores is set) o if the first character of the next token is an isolated single quote, then the entire quoted NxsString is saved as the next token o paired single quotes are automatically converted to single quotes before being stored o comments are handled automatically (normal comments are treated as whitespace and output comments are passed to the function OutputComment which does nothing in the NxsToken class but can be overridden in a derived class to handle these in an appropriate fashion) o leading whitespace (including comments) is automatically skipped o if the end of the file is reached on reading this token, the atEOF flag is set and may be queried using the AtEOF member function o punctuation characters are always returned as individual tokens (see the Maddison, Swofford, and Maddison paper for the definition of punctuation characters) unless the flag ignorePunctuation is set in labileFlags, in which case the normal punctuation symbols are treated just like any other darkspace character. ~ The behavior of GetNextToken may be altered by using labile flags. For example, the labile flag saveCommandComments can be set using the member function SetLabileFlagBit. This will cause comments of the form [&X] to be saved as tokens (without the square brackets), but only for the aquisition of the next token. Labile flags are cleared after each application.


Definition at line 879 of file nxstoken.cpp.

 All Classes Functions Variables Enumerations Enumerator Friends
Generated on Mon Mar 29 16:37:13 2010 for NCL by  doxygen 1.6.3