OpenAB  1.0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
OpenAB::KeyValueItem Class Reference

Class representing item containing fields in form of key value pairs, that can contain additional parameters for each field. Each item can also contain nested items. More...

#include <PIMCalendarItem.hpp>

Inheritance diagram for OpenAB::KeyValueItem:
Collaboration diagram for OpenAB::KeyValueItem:

Public Member Functions

 KeyValueItem ()
 default constructor More...
 
virtual ~KeyValueItem ()
 
bool parse (const std::string &rawData)
 parses item from raw data string More...
 
std::map< std::string,
std::vector< ItemField > > & 
getFields ()
 Returns all fields of item. More...
 

Protected Member Functions

virtual bool processField ()
 Handler that processed contents of given fields. Can be override in child classes. More...
 

Protected Attributes

std::string currentLine
 
std::string currentFieldName
 
std::string currentFieldValue
 
std::string currentFieldValueOriginal
 
std::map< std::string,
std::vector< ItemField > > 
fields
 
std::map< std::string,
std::vector< SmartPtr
< KeyValueItem > > > 
subcomponents
 

Detailed Description

Class representing item containing fields in form of key value pairs, that can contain additional parameters for each field. Each item can also contain nested items.

Constructor & Destructor Documentation

OpenAB::KeyValueItem::KeyValueItem ( )

default constructor

OpenAB::KeyValueItem::~KeyValueItem ( )
virtual

Member Function Documentation

std::map<std::string, std::vector<ItemField> >& OpenAB::KeyValueItem::getFields ( )
inline

Returns all fields of item.

Returns
all fields of item.
bool OpenAB::KeyValueItem::parse ( const std::string &  rawData)

parses item from raw data string

Parameters
[in]rawDatastring to be parsed
Returns
true if string was parsed successfully, false otherwise
bool OpenAB::KeyValueItem::processField ( )
protectedvirtual

Handler that processed contents of given fields. Can be override in child classes.

Reimplemented in OpenAB::VStandardTimeZoneKeyValueItem, and OpenAB::VDayLightTimeZoneKeyValueItem.

Member Data Documentation

std::string OpenAB::KeyValueItem::currentFieldName
protected
std::string OpenAB::KeyValueItem::currentFieldValue
protected
std::string OpenAB::KeyValueItem::currentFieldValueOriginal
protected
std::string OpenAB::KeyValueItem::currentLine
protected
std::map<std::string, std::vector<ItemField> > OpenAB::KeyValueItem::fields
protected
std::map<std::string, std::vector< SmartPtr<KeyValueItem> > > OpenAB::KeyValueItem::subcomponents
protected

The documentation for this class was generated from the following files: