CifParserBase.h
Go to the documentation of this file.
//$$FILE$$
//$$VERSION$$
//$$DATE$$
//$$LICENSE$$
#ifndef CIF_PARSER_BASE_H
#define CIF_PARSER_BASE_H
#include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <rcsb/ISTable.h>
#include <rcsb/CifFile.h>
#include <rcsb/CifScannerBase.h>
#include <rcsb/CifParserInt.h>
#include <rcsb/CifFileReadDef.h>
#define DATA_TAG "data_"
class CifParser : public CifScanner
{
public:
CifParser(CifFile* cifFileP, bool verbose = false);
CifParser(CifFile* cifFileP, CifFileReadDef readDef,
bool verbose = false);
void Parse(const string& fileName, string& diagnostics,
const std::string& parseLogFileName = std::string());
void ParseString(const string& cifString, 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:
CifFile *_fobj;
CifFileReadDef _readDef;
ISTable *_tbl;
int _afterLoop;
int _nTablesInBlock;
int _curItemNo, _curValueNo, _numDataBlocks, _fieldListAlloc, _curRow;
vector<string> _fieldList;
string _pBufValue;
string _tBufKeyword;
string _curCategoryName;
string _curDataBlockName;
string _prevDataBlockName;
void _ComplexWriteTable();
int _err, _warn;
};
#endif /* CIF_PARSER_BASE_H */
CifFile.h
Header file for CifFile class.
CifFileReadDef.h
Header file for CifFileReadDef class.
CifParserInt.h
Header file for bison interfacing to CifParser class.
CifScannerBase.h
Header file for CifScanner class.
ISTable.h
Header file for ISTable class.
CifFile
Public class that represents a CIF file, composed of blocks with tables.
Definition CifFile.h:48
CifFileReadDef
Private class that represents a CIF parser controller.
Definition CifFileReadDef.h:39
CifParser
Public class that respresents a CIF parser.
Definition CifParserBase.h:42
CifParser::ProcessValueList
int ProcessValueList(void)
CifParser::ProcessLoopDeclaration
int ProcessLoopDeclaration(void)
CifParser::CifParser
CifParser(CifFile *cifFileP, bool verbose=false)
CifParser::Parse
void Parse(const string &fileName, string &diagnostics, const std::string &parseLogFileName=std::string())
CifParser::ProcessItemValuePair
int ProcessItemValuePair(void)
CifParser::Clear
void Clear()
CifParser::ProcessAssignments
void ProcessAssignments(void)
CifParser::CifParser
CifParser(CifFile *cifFileP, CifFileReadDef readDef, bool verbose=false)
CifParser::Reset
void Reset()
CifParser::ProcessItemValue
void ProcessItemValue(void)
CifParser::ProcessLsItemValue
void ProcessLsItemValue(void)
CifParser::ProcessLoop
void ProcessLoop(void)
CifParser::~CifParser
virtual ~CifParser()
CifParser::ProcessItemNameList
int ProcessItemNameList(void)
CifParser::ProcessItemName
void ProcessItemName(void)
CifParser::ProcessMissingValue
void ProcessMissingValue(void)
CifParser::Error
void Error(const char *)
CifParser::ProcessUnknownValue
void ProcessUnknownValue(void)
CifParser::ParseString
void ParseString(const string &cifString, string &diagnostics)
CifParser::ProcessDataBlockName
void ProcessDataBlockName(void)
CifScanner
Private class that represents a CIF scanner.
Definition CifScannerBase.h:49
ISTable
Public class that respresents a two-dimensional table of strings.
Definition ISTable.h:54