CifParser Class Reference

Public class that respresents a CIF parser. More...

#include <CifParserBase.h>

Inherits CifScanner.

Inheritance diagram for CifParser:

Inheritance graph
[legend]
Collaboration diagram for CifParser:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 CifParser (CifFile *cifFileP, bool verbose=false)
 CifParser (CifFile *cifFileP, CifFileReadDef readDef, bool verbose=false)
void Parse (const string &fileName, string &diagnostics)
virtual ~CifParser ()
void Error (const char *)
void Clear ()
void Reset ()
int ProcessLoopDeclaration (void)
int ProcessItemNameList (void)
int ProcessValueList (void)
int ProcessItemValuePair (void)
void ProcessAssignments (void)
void ProcessLoop (void)
void ProcessItemName (void)
void ProcessItemValue (void)
void ProcessLsItemValue (void)
void ProcessUnknownValue (void)
void ProcessMissingValue (void)
void ProcessDataBlockName (void)

Private Member Functions

void _ComplexWriteTable ()

Private Attributes

string _uString
string _mString
CifFile * _fobj
CifFileReadDef _readDef
ISTable * _tbl
int _afterLoop
int _nTablesInBlock
int _curItemNo
int _curValueNo
int _numDataBlocks
int _fieldListAlloc
int _curRow
string _curCol
vector< string > _fieldList
string _pBufValue
vector< string > * _rowBuf
string _tBufKeyword
string _curCategoryName
string _curDataBlockName
string _prevDataBlockName
string errorLog
int _err
int _warn

Detailed Description

Public class that respresents a CIF parser.

This class represents a CIF parser. This class utilizes flex/bison for syntax/semantic processing and stores the parsed data (data blocks and tables) in a CifFile object.


Constructor & Destructor Documentation

CifParser::CifParser ( CifFile *  cifFileP,
bool  verbose = false 
)

Constructs a CIF parser.

Parameters:
[in] cifFileP - pointer to the CifFile object that the CIF parser is to use to store the parsed data
[in] verbose - optional parameter that indicates whether parsing logging should be turned on (if true) or off (if false). If verbose is not spefified, logging is turned off.
Returns:
Not applicable
Precondition:
cifFileP must not be NULL
Postcondition:
None
Exceptions:
EmptyValueException - if cifFileP is NULL

CifParser::CifParser ( CifFile *  cifFileP,
CifFileReadDef  readDef,
bool  verbose = false 
)

Method, not currently part of users public API, and will soon be re-examined.

CifParser::~CifParser (  )  [virtual]

Destructs a CIF parser by releasing all the used resources.

Parameters:
 Not applicable
Returns:
Not applicable
Precondition:
None
Postcondition:
None
Exceptions:
 None


Member Function Documentation

void CifParser::Parse ( const string &  fileName,
string &  diagnostics 
)

Parses the CIF file.

Parameters:
[in] fileName - relative or absolute name of the CIF file that is to be parsed.
[out] diagnostics - parsing result. If empty, parsing completed with no warnings or errors. If non-empty, there were parsing warnings and/or parsing errors.
Returns:
None
Precondition:
None
Postcondition:
None
Exceptions:
 None

void CifParser::Error ( const char *   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::Clear (  ) 

Method, not currently part of users public API, and will soon be re-examined.

Reimplemented from CifScanner.

void CifParser::Reset (  ) 

Method, not currently part of users public API, and will soon be re-examined.

Reimplemented from CifScanner.

int CifParser::ProcessLoopDeclaration ( void   ) 

Utility method, not part of users public API, and will soon be removed.

int CifParser::ProcessItemNameList ( void   ) 

Utility method, not part of users public API, and will soon be removed.

int CifParser::ProcessValueList ( void   ) 

Utility method, not part of users public API, and will soon be removed.

int CifParser::ProcessItemValuePair ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessAssignments ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessLoop ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessItemName ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessItemValue ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessLsItemValue ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessUnknownValue ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessMissingValue ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::ProcessDataBlockName ( void   ) 

Utility method, not part of users public API, and will soon be removed.

void CifParser::_ComplexWriteTable (  )  [private]


Member Data Documentation

string CifParser::_uString [private]

string CifParser::_mString [private]

CifFile* CifParser::_fobj [private]

CifFileReadDef CifParser::_readDef [private]

ISTable* CifParser::_tbl [private]

int CifParser::_afterLoop [private]

int CifParser::_nTablesInBlock [private]

int CifParser::_curItemNo [private]

int CifParser::_curValueNo [private]

int CifParser::_numDataBlocks [private]

int CifParser::_fieldListAlloc [private]

int CifParser::_curRow [private]

string CifParser::_curCol [private]

vector<string> CifParser::_fieldList [private]

string CifParser::_pBufValue [private]

vector<string>* CifParser::_rowBuf [private]

string CifParser::_tBufKeyword [private]

string CifParser::_curCategoryName [private]

string CifParser::_curDataBlockName [private]

string CifParser::_prevDataBlockName [private]

string CifParser::errorLog [private]

int CifParser::_err [private]

int CifParser::_warn [private]


The documentation for this class was generated from the following files:
Generated on Tue Apr 24 09:25:40 2007 for cifparse-obj-v7.0 by  doxygen 1.5.1