|
reSIProcate/stack
9694
|
Represents the "token" element in the RFC 3261 grammar. More...
#include <PrivacyCategory.hxx>


Public Types | |
| enum | { commaHandling = CommasAllowedOutputCommas } |
Public Member Functions | |
| PrivacyCategory () | |
| PrivacyCategory (const Data &d) | |
| PrivacyCategory (const HeaderFieldValue &hfv, Headers::Type type, PoolBase *pool=0) | |
| PrivacyCategory (const PrivacyCategory &orig, PoolBase *pool=0) | |
| PrivacyCategory & | operator= (const PrivacyCategory &) |
| const std::vector< Data > & | value () const |
| std::vector< Data > & | value () |
| virtual void | parse (ParseBuffer &pb) |
| virtual ParserCategory * | clone () const |
| virtual ParserCategory * | clone (void *location) const |
| virtual ParserCategory * | clone (PoolBase *pool) const |
| virtual EncodeStream & | encodeParsed (EncodeStream &str) const |
Private Attributes | |
| std::vector< Data > | mValue |
Represents the "token" element in the RFC 3261 grammar.
Definition at line 17 of file PrivacyCategory.hxx.
| anonymous enum |
Definition at line 20 of file PrivacyCategory.hxx.
| resip::PrivacyCategory::PrivacyCategory | ( | ) |
Definition at line 7 of file PrivacyCategory.cxx.
Referenced by clone().
: ParserCategory(), mValue() {}
| resip::PrivacyCategory::PrivacyCategory | ( | const Data & | d | ) | [explicit] |
Definition at line 13 of file PrivacyCategory.cxx.
References resip::Data::data(), resip::Data::size(), and resip::Headers::UNKNOWN.
: ParserCategory(), mValue() { HeaderFieldValue hfv(d.data(), d.size()); PrivacyCategory tmp(hfv, Headers::UNKNOWN); tmp.checkParsed(); *this = tmp; }

| resip::PrivacyCategory::PrivacyCategory | ( | const HeaderFieldValue & | hfv, |
| Headers::Type | type, | ||
| PoolBase * | pool = 0 |
||
| ) |
Definition at line 23 of file PrivacyCategory.cxx.
: ParserCategory(hfv, type, pool), mValue() {}
| resip::PrivacyCategory::PrivacyCategory | ( | const PrivacyCategory & | orig, |
| PoolBase * | pool = 0 |
||
| ) |
Definition at line 30 of file PrivacyCategory.cxx.
: ParserCategory(rhs, pool), mValue(rhs.mValue) {}
| ParserCategory * resip::PrivacyCategory::clone | ( | ) | const [virtual] |
Implements resip::ParserCategory.
Definition at line 88 of file PrivacyCategory.cxx.
References PrivacyCategory().
{
return new PrivacyCategory(*this);
}

| ParserCategory * resip::PrivacyCategory::clone | ( | void * | location | ) | const [virtual] |
Implements resip::ParserCategory.
Definition at line 94 of file PrivacyCategory.cxx.
References PrivacyCategory().
{
return new (location) PrivacyCategory(*this);
}

| ParserCategory * resip::PrivacyCategory::clone | ( | PoolBase * | pool | ) | const [virtual] |
Implements resip::ParserCategory.
Definition at line 100 of file PrivacyCategory.cxx.
References PrivacyCategory().
{
return new (pool) PrivacyCategory(*this, pool);
}

| EncodeStream & resip::PrivacyCategory::encodeParsed | ( | EncodeStream & | str | ) | const [virtual] |
Implements resip::LazyParser.
Definition at line 106 of file PrivacyCategory.cxx.
References mValue.
| PrivacyCategory & resip::PrivacyCategory::operator= | ( | const PrivacyCategory & | rhs | ) |
Definition at line 37 of file PrivacyCategory.cxx.
References mValue.
{
if (this != &rhs)
{
ParserCategory::operator=(rhs);
mValue = rhs.mValue;
}
return *this;
}
| void resip::PrivacyCategory::parse | ( | ParseBuffer & | pb | ) | [virtual] |
Implements resip::LazyParser.
Definition at line 62 of file PrivacyCategory.cxx.
References resip::ParseBuffer::data(), resip::ParseBuffer::eof(), mValue, resip::ParseBuffer::position(), resip::ParseBuffer::skipChar(), resip::ParseBuffer::skipToOneOf(), resip::ParseBuffer::skipWhitespace(), and resip::ParseBuffer::Whitespace.
{
while(!pb.eof())
{
pb.skipWhitespace();
if(!pb.eof())
{
const char* start=pb.position();
pb.skipToOneOf(";",ParseBuffer::Whitespace);
if(pb.position()==start)
{
throw ParseException("Empty privacy token!",
"PrivacyCategory::parse()",
__FILE__, __LINE__);
}
mValue.push_back(pb.data(start));
pb.skipWhitespace();
}
if(!pb.eof())
{
pb.skipChar(';');
}
}
}

| const std::vector< Data > & resip::PrivacyCategory::value | ( | ) | const |
Definition at line 48 of file PrivacyCategory.cxx.
References resip::LazyParser::checkParsed(), and mValue.
{
checkParsed();
return mValue;
}

| std::vector< Data > & resip::PrivacyCategory::value | ( | ) |
Definition at line 55 of file PrivacyCategory.cxx.
References resip::LazyParser::checkParsed(), and mValue.
{
checkParsed();
return mValue;
}

std::vector<Data> resip::PrivacyCategory::mValue [private] |
Definition at line 40 of file PrivacyCategory.hxx.
Referenced by encodeParsed(), operator=(), parse(), and value().
1.7.5.1