reSIProcate/stack  9694
Classes | Defines | Functions | Variables
Uri.cxx File Reference
#include <set>
#include "resip/stack/Embedded.hxx"
#include "resip/stack/Helper.hxx"
#include "resip/stack/NameAddr.hxx"
#include "resip/stack/SipMessage.hxx"
#include "resip/stack/Symbols.hxx"
#include "resip/stack/UnknownParameter.hxx"
#include "resip/stack/Uri.hxx"
#include "rutil/DataStream.hxx"
#include "rutil/DnsUtil.hxx"
#include "rutil/Logger.hxx"
#include "rutil/ParseBuffer.hxx"
Include dependency graph for Uri.cxx:

Go to the source code of this file.

Classes

class  OrderUnknownParameters
 used as a comparator for sorting purposes More...

Defines

#define RESIPROCATE_SUBSYSTEM   Subsystem::SIP
#define HANDLE_CHARACTER_ESCAPING
#define defineParam(_enum, _name, _type, _RFC_ref_ignored)

Functions

static bool initAllTables ()
 defineParam (ob,"ob", ExistsParameter,"RFC 5626")
 defineParam (gr,"gr", ExistsOrDataParameter,"RFC 5627")
 defineParam (comp,"comp", DataParameter,"RFC 3486")
 defineParam (duration,"duration", UInt32Parameter,"RFC 4240")
 defineParam (lr,"lr", ExistsParameter,"RFC 3261")
 defineParam (maddr,"maddr", DataParameter,"RFC 3261")
 defineParam (method,"method", DataParameter,"RFC 3261")
 defineParam (transport,"transport", DataParameter,"RFC 3261")
 defineParam (ttl,"ttl", UInt32Parameter,"RFC 3261")
 defineParam (user,"user", DataParameter,"RFC 3261, 4967")
 defineParam (extension,"ext", DataParameter,"RFC 3966")
 defineParam (sigcompId,"sigcomp-id", QuotedDataParameter,"RFC 5049")
 defineParam (rinstance,"rinstance", DataParameter,"proprietary (resip)")
 defineParam (addTransport,"addTransport", ExistsParameter,"RESIP INTERNAL")
 HashValueImp (resip::Uri, resip::Data::from(data).hash())

Variables

static const Data parseContext ("Uri constructor")
static const Data bodyData ("Body")

Define Documentation

#define defineParam (   _enum,
  _name,
  _type,
  _RFC_ref_ignored 
)
Value:
_enum##_Param::DType&                                                                                           \
Uri::param(const _enum##_Param& paramType)                                                           \
{                                                                                                               \
   checkParsed();                                                                                               \
   _enum##_Param::Type* p =                                                                                     \
      static_cast<_enum##_Param::Type*>(getParameterByEnum(paramType.getTypeNum()));                            \
   if (!p)                                                                                                      \
   {                                                                                                            \
      p = new _enum##_Param::Type(paramType.getTypeNum());                                                      \
      mParameters.push_back(p);                                                                                 \
   }                                                                                                            \
   return p->value();                                                                                           \
}                                                                                                               \
                                                                                                                \
const _enum##_Param::DType&                                                                                     \
Uri::param(const _enum##_Param& paramType) const                                                     \
{                                                                                                               \
   checkParsed();                                                                                               \
   _enum##_Param::Type* p =                                                                                     \
      static_cast<_enum##_Param::Type*>(getParameterByEnum(paramType.getTypeNum()));                            \
   if (!p)                                                                                                      \
   {                                                                                                            \
      InfoLog(<< "Missing parameter " _name " " << ParameterTypes::ParameterNames[paramType.getTypeNum()]);     \
      DebugLog(<< *this);                                                                                       \
      throw Exception("Missing parameter " _name, __FILE__, __LINE__);                                          \
   }                                                                                                            \
   return p->value();                                                                                           \
}

Definition at line 1279 of file Uri.cxx.

#define HANDLE_CHARACTER_ESCAPING

Definition at line 23 of file Uri.cxx.

#define RESIPROCATE_SUBSYSTEM   Subsystem::SIP

Definition at line 22 of file Uri.cxx.


Function Documentation

defineParam ( ob  ,
"ob"  ,
ExistsParameter  ,
"RFC 5626"   
)
defineParam ( gr  ,
"gr"  ,
ExistsOrDataParameter  ,
"RFC 5627"   
)
defineParam ( comp  ,
"comp"  ,
DataParameter  ,
"RFC 3486"   
)
defineParam ( duration  ,
"duration"  ,
UInt32Parameter  ,
"RFC 4240"   
)
defineParam ( lr  ,
"lr"  ,
ExistsParameter  ,
"RFC 3261"   
)
defineParam ( maddr  ,
"maddr"  ,
DataParameter  ,
"RFC 3261"   
)
defineParam ( method  ,
"method"  ,
DataParameter  ,
"RFC 3261"   
)
defineParam ( transport  ,
"transport"  ,
DataParameter  ,
"RFC 3261"   
)
defineParam ( ttl  ,
"ttl"  ,
UInt32Parameter  ,
"RFC 3261"   
)
defineParam ( user  ,
"user"  ,
DataParameter  ,
"RFC  3261,
4967"   
)
defineParam ( extension  ,
"ext"  ,
DataParameter  ,
"RFC 3966"   
)
defineParam ( sigcompId  ,
"sigcomp-id"  ,
QuotedDataParameter  ,
"RFC 5049"   
)
defineParam ( rinstance  ,
"rinstance"  ,
DataParameter  ,
"proprietary (resip)"   
)
defineParam ( addTransport  ,
"addTransport"  ,
ExistsParameter  ,
"RESIP INTERNAL"   
)
HashValueImp ( resip::Uri  ,
resip::Data::  fromdata).hash( 
)
static bool initAllTables ( ) [static]

Definition at line 25 of file Uri.cxx.

References resip::Uri::getGlobalNumberTable(), resip::Uri::getLocalNumberTable(), resip::Uri::getPasswordEncodingTable(), and resip::Uri::getUserEncodingTable().

{
   Uri::getUserEncodingTable();
   Uri::getPasswordEncodingTable();
   Uri::getLocalNumberTable();
   Uri::getGlobalNumberTable();
   return true;
}

Here is the call graph for this function:


Variable Documentation

const Data bodyData("Body") [static]
const Data parseContext("Uri constructor") [static]