Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members
|
Serialize a variant to or from INI formatted file. More...
#include <FXINIFile.h>
Public Member Functions | |
FXINIFile () | |
Create INI file i/o object. | |
FXINIFile (const FXString &filename, Direction d=Load, FXuval sz=8192) | |
Create INI file i/o object and open it. | |
FXbool | open (const FXString &filename, Direction d=Load, FXuval sz=8192) |
Open INI file from given handle for direction d. | |
virtual FXival | fill (FXival count) |
Read at least count bytes into buffer; return bytes available, or -1 for error. | |
virtual FXival | flush (FXival count) |
Write at least count bytes from buffer; return space available, or -1 for error. | |
FXbool | close () |
Close INI file and delete buffers. | |
virtual | ~FXINIFile () |
Close INI file. | |
Public Member Functions inherited from FX::FXINI | |
FXINI () | |
Initialize INI parser. | |
FXINI (FXchar *buffer, FXuval sz=8192, Direction d=Load) | |
Initialize INI parser with buffer of size and direction. More... | |
FXbool | open (FXchar *buffer, FXuval sz=8192, Direction d=Load) |
Open INI parse buffer with given size and direction. More... | |
FXint | getLine () const |
Return current line number. | |
FXint | getColumn () const |
Return current column number. | |
FXlong | getOffset () const |
Return offset from begin of file. | |
Error | load (FXVariant &variant) |
Load a variant from stream. More... | |
Error | save (const FXVariant &variant) |
Save a variant to stream. More... | |
void | setNumericPrecision (FXuchar p) |
Floating point output precision control. More... | |
FXuchar | getNumericPrecision () const |
void | setNumericFormat (FXuchar f) |
Floating point output format control. More... | |
FXuchar | getNumericFormat () const |
void | setEscapeMode (FXuchar e) |
Change string escape mode; 0=don't escape unicode in strings; 1=escape unicode as , 2=escape UTF8 multi-byte characters as or . More... | |
FXuchar | getEscapeMode () const |
FXbool | close () |
Close INI parser. More... | |
virtual | ~FXINI () |
Close INI parser and clean up. | |
Public Member Functions inherited from FX::FXParseBuffer | |
FXParseBuffer () | |
Initialize parse buffer to empty. | |
FXParseBuffer (FXchar *buffer, FXuval sz=4096, Direction d=Load) | |
Initialize parse buffer with given size and direction. More... | |
FXbool | open (FXchar *buffer=nullptr, FXuval sz=4096, Direction d=Load) |
Open parse buffer with given size and direction. | |
Direction | direction () const |
Return current direction. | |
FXuval | size () const |
Return current buffer size. | |
FXbool | close () |
Close parse buffer. | |
virtual | ~FXParseBuffer () |
Clean up and close buffer. | |
Additional Inherited Members | |
Public Types inherited from FX::FXINI | |
enum | Error { ErrOK, ErrSave, ErrLoad, ErrToken, ErrColon, ErrComma, ErrBracket, ErrBrace, ErrQuotes, ErrQuote, ErrNumber, ErrEnd } |
Public Types inherited from FX::FXParseBuffer | |
enum | Direction { Stop = 0, Save = 1, Load = 2 } |
Static Public Member Functions inherited from FX::FXINI | |
static const FXchar * | getError (Error err) |
Returns error code for given error. | |
Protected Member Functions inherited from FX::FXParseBuffer | |
FXbool | need (FXival count) |
FXbool | emit (FXchar ch, FXint count) |
FXbool | emit (const FXchar *str, FXint count) |
Protected Attributes inherited from FX::FXINI | |
FXlong | offset |
FXint | token |
FXint | column |
FXint | indent |
FXint | line |
FXuchar | state |
FXuchar | prec |
FXuchar | fmt |
FXuchar | esc |
Protected Attributes inherited from FX::FXParseBuffer | |
FXchar * | begptr |
FXchar * | endptr |
FXchar * | wptr |
FXchar * | rptr |
FXchar * | sptr |
Direction | dir |
Serialize a variant to or from INI formatted file.
Copyright © 1997-2022 Jeroen van der Zijp |