|
reSIProcate/stack
9694
|
Represents the "Request-Line" element in the RFC 3261 grammar. More...
#include <RequestLine.hxx>


Public Member Functions | |
| RequestLine () | |
| RequestLine (MethodTypes method, const Data &sipVersion=Symbols::DefaultSipVersion) | |
| RequestLine (const HeaderFieldValue &hfv) | |
| RequestLine (const char *buf, int len) | |
| RequestLine (const RequestLine &) | |
| RequestLine & | operator= (const RequestLine &) |
| virtual | ~RequestLine () |
| const Uri & | uri () const |
| Uri & | uri () |
| MethodTypes | getMethod () const |
| MethodTypes & | method () |
| MethodTypes | method () const |
| Data & | unknownMethodName () |
| const Data & | unknownMethodName () const |
| const Data & | getSipVersion () const |
| virtual void | parse (ParseBuffer &pb) |
| virtual StartLine * | clone () const |
| virtual StartLine * | clone (void *location) const |
| virtual EncodeStream & | encodeParsed (EncodeStream &str) const |
| virtual const Data & | errorContext () const |
Private Attributes | |
| Uri | mUri |
| MethodTypes | mMethod |
| Data | mUnknownMethodName |
| Data | mSipVersion |
Represents the "Request-Line" element in the RFC 3261 grammar.
Definition at line 17 of file RequestLine.hxx.
| RequestLine::RequestLine | ( | ) |
Definition at line 21 of file RequestLine.cxx.
Referenced by clone().
: StartLine(), mMethod(UNKNOWN), mUnknownMethodName(Data::Share,getMethodName(UNKNOWN)), mSipVersion(Data::Share,Symbols::DefaultSipVersion) {}
| RequestLine::RequestLine | ( | MethodTypes | method, |
| const Data & | sipVersion = Symbols::DefaultSipVersion |
||
| ) |
Definition at line 28 of file RequestLine.cxx.
: mMethod(method), mUnknownMethodName(), mSipVersion(sipVersion) {}
| RequestLine::RequestLine | ( | const HeaderFieldValue & | hfv | ) |
Definition at line 35 of file RequestLine.cxx.
: StartLine(hfv), mMethod(UNKNOWN), mUnknownMethodName(Data::Share,getMethodName(UNKNOWN)), mSipVersion(Data::Share,Symbols::DefaultSipVersion) {}
| RequestLine::RequestLine | ( | const char * | buf, |
| int | len | ||
| ) |
Definition at line 42 of file RequestLine.cxx.
: StartLine(buf, len), mMethod(UNKNOWN), mUnknownMethodName(Data::Share,getMethodName(UNKNOWN)), mSipVersion(Data::Share,Symbols::DefaultSipVersion) {}
| RequestLine::RequestLine | ( | const RequestLine & | rhs | ) |
Definition at line 49 of file RequestLine.cxx.
: StartLine(rhs), mUri(rhs.mUri), mMethod(rhs.mMethod), mUnknownMethodName(rhs.mUnknownMethodName), mSipVersion(rhs.mSipVersion) {}
| RequestLine::~RequestLine | ( | ) | [virtual] |
Definition at line 71 of file RequestLine.cxx.
{}
| StartLine * RequestLine::clone | ( | ) | const [virtual] |
Implements resip::StartLine.
Definition at line 75 of file RequestLine.cxx.
References RequestLine().
{
return new RequestLine(*this);
}

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

| EncodeStream & RequestLine::encodeParsed | ( | EncodeStream & | str | ) | const [virtual] |
Implements resip::StartLine.
Definition at line 159 of file RequestLine.cxx.
References resip::Uri::encodeParsed(), mMethod, mSipVersion, mUnknownMethodName, mUri, and resip::Symbols::SPACE.
Referenced by resip::SipMessage::getCanonicalIdentityString().
{
str << (mMethod != UNKNOWN ? getMethodName(mMethod) : mUnknownMethodName) << Symbols::SPACE;
mUri.encodeParsed(str);
str << Symbols::SPACE << mSipVersion;
return str;
}

| const Data & RequestLine::errorContext | ( | ) | const [virtual] |
Implements resip::StartLine.
Definition at line 168 of file RequestLine.cxx.
{
static const Data reqLine("Request Line");
return reqLine;
}
| MethodTypes RequestLine::getMethod | ( | ) | const |
Definition at line 101 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mMethod.
Referenced by resip::Helper::advancedAuthenticateRequest(), resip::Helper::authenticateRequest(), resip::Helper::authenticateRequestWithA1(), resip::SipMessage::encodeBrief(), main(), resip::DeprecatedDialog::makeCancel(), resip::Helper::makeCancel(), resip::Helper::makeChallengeResponseAuth(), resip::Helper::makeChallengeResponseAuthWithA1(), resip::Helper::makeFailureAck(), resip::DeprecatedDialog::makeResponse(), resip::SipMessage::method(), performTest(), resip::TuIM::processMessageRequest(), resip::TuIM::processNotifyRequest(), resip::TuIM::processRegisterRequest(), resip::TuIM::processRequest(), resip::TuIM::processSubscribeRequest(), processTimeouts(), resip::DeprecatedDialog::targetRefreshRequest(), Server::thread(), and Loadgen::InviteServer::waitForRequest().
{
checkParsed();
return mMethod;
}

| const Data & RequestLine::getSipVersion | ( | ) | const |
Definition at line 136 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mSipVersion.
Referenced by main(), resip::Helper::makeCancel(), and resip::Helper::makeFailureAck().
{
checkParsed();
return mSipVersion;
}

| MethodTypes & RequestLine::method | ( | ) |
Definition at line 108 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mMethod.
Referenced by resip::SipMessage::compute2543TransactionHash(), resip::DeprecatedDialog::createDialogAsUAC(), resip::KeepAliveMessage::KeepAliveMessage(), main(), resip::DeprecatedDialog::makeCancel(), resip::Helper::makeCancel(), resip::Helper::makeFailureAck(), resip::Helper::makeMessage(), resip::Helper::makePublish(), resip::Helper::makeRegister(), resip::Helper::makeRequest(), resip::DeprecatedDialog::makeRequestInternal(), resip::Helper::makeResponse(), resip::Helper::makeSubscribe(), resip::MessageFilterRule::matches(), resip::SipMessage::mergeUri(), resip::SipMessage::method(), performTest(), resip::StatisticsManager::received(), and resip::Helper::validateMessage().
{
checkParsed();
return mMethod;
}

| MethodTypes RequestLine::method | ( | ) | const |
Definition at line 115 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mMethod.
{
checkParsed();
return mMethod;
}

| RequestLine & RequestLine::operator= | ( | const RequestLine & | rhs | ) |
Definition at line 58 of file RequestLine.cxx.
References mMethod, mSipVersion, mUnknownMethodName, and mUri.
{
if (this != &rhs)
{
StartLine::operator=(rhs);
mUri = rhs.mUri;
mMethod = rhs.mMethod;
mUnknownMethodName = rhs.mUnknownMethodName;
mSipVersion = rhs.mSipVersion;
}
return *this;
}
| void RequestLine::parse | ( | ParseBuffer & | pb | ) | [virtual] |
Implements resip::StartLine.
Definition at line 143 of file RequestLine.cxx.
References resip::ParseBuffer::data(), mMethod, mSipVersion, mUnknownMethodName, mUri, resip::Uri::parse(), resip::ParseBuffer::position(), resip::ParseBuffer::skipNonWhitespace(), and resip::ParseBuffer::skipWhitespace().
{
const char* start;
start = pb.skipWhitespace();
pb.skipNonWhitespace();
mMethod = getMethodType(start, int(pb.position() - start));
// for backward compatibility, set the method name even if the method is known
pb.data(mUnknownMethodName, start);
pb.skipWhitespace();
mUri.parse(pb);
start = pb.skipWhitespace();
pb.skipNonWhitespace();
pb.data(mSipVersion, start);
}

| Data & RequestLine::unknownMethodName | ( | ) |
Definition at line 122 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mUnknownMethodName.
Referenced by resip::SipMessage::encodeBrief(), and resip::SipMessage::methodStr().
{
checkParsed();
return mUnknownMethodName;
}

| const Data & RequestLine::unknownMethodName | ( | ) | const |
Definition at line 129 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mUnknownMethodName.
{
checkParsed();
return mUnknownMethodName;
}

| const Uri & RequestLine::uri | ( | ) | const |
Definition at line 87 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mUri.
Referenced by resip::SipMessage::compute2543TransactionHash(), resip::TransportSelector::dnsResolve(), resip::SipMessage::encodeBrief(), resip::Helper::extractFromPkcs7(), resip::SipMessage::getCanonicalIdentityString(), main(), resip::Helper::makeCancel(), resip::Helper::makeChallengeResponseAuth(), resip::Helper::makeChallengeResponseAuthWithA1(), resip::Helper::makeFailureAck(), resip::DeprecatedDialog::makeInitialInvite(), resip::DeprecatedDialog::makeInitialMessage(), resip::DeprecatedDialog::makeInitialPublish(), resip::DeprecatedDialog::makeInitialRegister(), resip::DeprecatedDialog::makeInitialSubscribe(), resip::Helper::makeMessage(), resip::BasicNonceHelper::makeNonce(), resip::Helper::makePublish(), resip::Helper::makeRegister(), resip::Helper::makeRequest(), resip::DeprecatedDialog::makeRequestInternal(), resip::Helper::makeSubscribe(), resip::Helper::massageRoute(), resip::MessageFilterRule::matches(), resip::SipMessage::mergeUri(), resip::TransactionState::processClientInvite(), resip::TransactionState::processClientNonInvite(), resip::TuIM::processMessageRequest(), resip::TuIM::processNotifyRequest(), resip::TuIM::processPageResponse(), resip::TuIM::processRegisterResponse(), resip::Helper::processStrictRoute(), resip::TuIM::processSubscribeRequest(), resip::TuIM::processSubscribeResponse(), resip::StatelessMessage::rewriteRequest(), resip::TransactionState::rewriteRequest(), Loadgen::Transceiver::send(), resip::TuIM::setOutbound(), resip::TransportSelector::transmit(), and resip::DeprecatedDialog::updateRequest().
{
checkParsed();
return mUri;
}

| Uri & RequestLine::uri | ( | ) |
Definition at line 94 of file RequestLine.cxx.
References resip::LazyParser::checkParsed(), and mUri.
{
checkParsed();
return mUri;
}

MethodTypes resip::RequestLine::mMethod [private] |
Definition at line 48 of file RequestLine.hxx.
Referenced by encodeParsed(), getMethod(), method(), operator=(), and parse().
Data resip::RequestLine::mSipVersion [private] |
Definition at line 50 of file RequestLine.hxx.
Referenced by encodeParsed(), getSipVersion(), operator=(), and parse().
Data resip::RequestLine::mUnknownMethodName [private] |
Definition at line 49 of file RequestLine.hxx.
Referenced by encodeParsed(), operator=(), parse(), and unknownMethodName().
Uri resip::RequestLine::mUri [private] |
Definition at line 47 of file RequestLine.hxx.
Referenced by encodeParsed(), operator=(), parse(), and uri().
1.7.5.1