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

Class representing single field of iCalendar object. Field can have assigned value and list of parameters. Fields itself does not know its name. More...

#include <PIMCalendarItem.hpp>

Public Member Functions

 ItemField ()
 default constructor More...
 
 ItemField (const std::string &value)
 create field with given value More...
 
 ~ItemField ()
 
bool parse (std::string rawFieldString, bool forceParams=false)
 Parses given field from raw string. More...
 
void setValue (const std::string &value)
 Sets value of field. More...
 
bool operator< (const ItemField &other) const
 comparison operator, required so fields can be stored in std::map More...
 
std::string toString () const
 Returns string representation of field. More...
 
std::string getValue () const
 Returns value of field. More...
 
std::map< std::string,
std::set< std::string > > 
getParams () const
 Returns all parameters of field. More...
 

Detailed Description

Class representing single field of iCalendar object. Field can have assigned value and list of parameters. Fields itself does not know its name.

Constructor & Destructor Documentation

OpenAB::ItemField::ItemField ( )

default constructor

OpenAB::ItemField::ItemField ( const std::string &  value)

create field with given value

OpenAB::ItemField::~ItemField ( )

Member Function Documentation

std::map< std::string, std::set< std::string > > OpenAB::ItemField::getParams ( ) const

Returns all parameters of field.

Returns
all parameters of field, keys in returned map are params names
std::string OpenAB::ItemField::getValue ( ) const

Returns value of field.

Returns
value of field
bool OpenAB::ItemField::operator< ( const ItemField other) const

comparison operator, required so fields can be stored in std::map

bool OpenAB::ItemField::parse ( std::string  rawFieldString,
bool  forceParams = false 
)

Parses given field from raw string.

Parameters
[in]rawFieldStringstring from which field should be parsed
[in]forceParamsset to true if field does not have any value, but can have parameters list (eg. RRULE of VTIMEZONE)
void OpenAB::ItemField::setValue ( const std::string &  value)

Sets value of field.

Parameters
[in]valuevalue to be set
std::string OpenAB::ItemField::toString ( ) const

Returns string representation of field.

Returns
string representation of field

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