#include <JCAMPFile.h>
Inheritance diagram for JCAMPFile:

Public Types | |
|
typedef std::pair< String, JCAMPValue > | KeyValuePair |
| a key-value pair | |
| typedef StringHashMap< JCAMPValue > | EntryMap |
| A hash map containing the JCAMP entries. | |
| typedef StringHashMap< String > | HeaderMap |
| A hash map containing the header entries. | |
| enum | ContentType { STRING, NUMERIC, ARRAY } |
Public Member Functions | |
Constructors and Destructors | |
| JCAMPFile (const String &name, OpenMode open_mode=std::ios::in) throw (Exception::FileNotFound) | |
| JCAMPFile (const JCAMPFile &file) throw (Exception::FileNotFound) | |
| Copy constructor. | |
| virtual | ~JCAMPFile () throw () |
| Destructor. | |
Accessors | |
| void | read () throw (Exception::ParseError) |
| Read the file. | |
| bool | write () throw (File::CannotWrite) |
| Write the file. | |
| HeaderMap & | getHeader () throw () |
| const HeaderMap & | getHeader () const throw () |
| EntryMap & | getEntries () throw () |
| const EntryMap & | getEntries () const throw () |
| const JCAMPValue & | operator[] (const String &name) const |
| double | getDoubleValue (const String &name) const throw (Exception::InvalidFormat) |
| Index | getIntValue (const String &name) const throw (Exception::InvalidFormat) |
| bool | hasEntry (const String &name) const throw () |
| bool | hasHeader (const String &name) const throw () |
| const JCAMPFile & | operator= (const JCAMPFile &file) throw () |
Equality operators | |
| bool | operator== (const JCAMPFile &f) const throw () |
| Equality operator. | |
| bool | operator!= (const JCAMPFile &f) const throw () |
| Inequality operator. | |
Protected Attributes | |
| HeaderMap | header_ |
| Entries from the header section. | |
| EntryMap | entries_ |
| Entries from the key-value section. | |
This class parses JCAMP files, which are often used to store parameter files in spectroscopy (NMR, IR, MS), e.g. in Bruker instruments.