Changes between Version 1 and Version 2 of FdoTextReaderEnhancements


Ignore:
Timestamp:
Oct 18, 2007, 1:57:44 PM (17 years ago)
Author:
gregboone
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • FdoTextReaderEnhancements

    v1 v2  
    9393''Exceptions'':
    9494
    95 Read() throws an FdoException if a left delimiter is encountered but end-of-stream is reached before the right delimiter is found.
     95Read() throws an !FdoException if a left delimiter is encountered but end-of-stream is reached before the right delimiter is found.
    9696
    9797''Example 1'':
     
    114114(**) – the 2nd ("{"} leftDelimiter is encountered before "'", so read is done until the 2nd right delimiter ("}") is reached[[br]]
    115115
     116''Example 2'':
     117
     118If a stream contains comma separated values where:
     119
     120• values are separated by commas and any number of spaces[[br]]
     121• values with embedded separators are enclosed in either single or double quotes[[br]]
     122• other values are optionally delimited[[br]]
     123
     124e.g:
     125
     126"abc def", ,  123.45, 'ghi', jkl, "", 9876
     127
     128then each value can be read by a call to:
     129
     130{{{
     131Read(outString, "'\"", "", " ",",")
     132}}}
     133
     134multiple calls to the above Read() on the above stream will read the following for each call:
     135
     136"abc def"[[br]]
     137""[[br]]
     138"123.45"[[br]]
     139"ghi"[[br]]
     140"jkl"[[br]]
     141""[[br]]
     142"9876"[[br]]
     143
     144''Example 3'':
     145
     146!ReadLine is actually just a convenience function. It is equivalent to:
     147
     148{{{
     149Read(outString, "", "", "", "\n" )
     150}}}
     151
     152
     153