ndn::name Namespace Reference

Classes

class  Component
 Represents a name component. More...
 

Enumerations

enum  : uint8_t {
  SEGMENT_MARKER = 0x00,
  SEGMENT_OFFSET_MARKER = 0xFB,
  VERSION_MARKER = 0xFD,
  TIMESTAMP_MARKER = 0xFC,
  SEQUENCE_NUMBER_MARKER = 0xFE
}
 Markers in Naming Conventions rev1. More...
 
enum  Convention {
  Convention::MARKER = 1 << 0,
  Convention::TYPED = 1 << 1,
  Convention::EITHER = MARKER | TYPED
}
 Identify a style of NDN Naming Conventions. More...
 

Functions

static bool canDecodeMarkerConvention ()
 
static bool canDecodeTypedConvention ()
 
template size_t Component::wireEncode<::ndn::encoding::EncoderTag > (::ndn::EncodingBuffer &) const
 
template size_t Component::wireEncode<::ndn::encoding::EstimatorTag > (::ndn::EncodingEstimator &) const
 
Convention getConventionDecoding ()
 Return which Naming Conventions style(s) to accept while decoding. More...
 
Convention getConventionEncoding ()
 Return which Naming Conventions style to use while encoding. More...
 
std::ostream & operator<< (std::ostream &os, const Component &component)
 
static Component parseUriEscapedValue (uint32_t type, const char *input, size_t len)
 
void setConventionDecoding (Convention convention)
 Set which Naming Conventions style(s) to accept while decoding. More...
 
void setConventionEncoding (Convention convention)
 Set which Naming Conventions style to use while encoding. More...
 

Variables

static Convention g_conventionDecoding = Convention::EITHER
 
static Convention g_conventionEncoding = Convention::MARKER
 

Enumeration Type Documentation

anonymous enum : uint8_t

Markers in Naming Conventions rev1.

Enumerator
SEGMENT_MARKER 
SEGMENT_OFFSET_MARKER 
VERSION_MARKER 
TIMESTAMP_MARKER 
SEQUENCE_NUMBER_MARKER 

Definition at line 43 of file name-component.hpp.

enum ndn::name::Convention
strong

Identify a style of NDN Naming Conventions.

Enumerator
MARKER 

component markers (revision 1)

TYPED 

typed name components (revision 2)

EITHER 

Definition at line 35 of file name-component.hpp.

Function Documentation

static bool ndn::name::canDecodeMarkerConvention ( )
static

Definition at line 78 of file name-component.cpp.

static bool ndn::name::canDecodeTypedConvention ( )
static

Definition at line 84 of file name-component.cpp.

template size_t ndn::name::Component::wireEncode<::ndn::encoding::EncoderTag > ( ::ndn::EncodingBuffer &  ) const
template size_t ndn::name::Component::wireEncode<::ndn::encoding::EstimatorTag > ( ::ndn::EncodingEstimator &  ) const
Convention ndn::name::getConventionDecoding ( )

Return which Naming Conventions style(s) to accept while decoding.

The current library default is Convention::EITHER, but this will change in the future.

Definition at line 66 of file name-component.cpp.

Convention ndn::name::getConventionEncoding ( )

Return which Naming Conventions style to use while encoding.

The current library default is Convention::MARKER, but this will change in the future.

Definition at line 47 of file name-component.cpp.

std::ostream& ndn::name::operator<< ( std::ostream &  os,
const Component component 
)
inline

Definition at line 679 of file name-component.hpp.

static Component ndn::name::parseUriEscapedValue ( uint32_t  type,
const char *  input,
size_t  len 
)
static

Definition at line 133 of file name-component.cpp.

void ndn::name::setConventionDecoding ( Convention  convention)

Set which Naming Conventions style(s) to accept while decoding.

Parameters
conventionConvention::MARKER or Convention::TYPED accepts the specified style only; Convention::EITHER accepts either.

Definition at line 72 of file name-component.cpp.

void ndn::name::setConventionEncoding ( Convention  convention)

Set which Naming Conventions style to use while encoding.

Parameters
conventioneither Convention::MARKER or Convention::TYPED.

Definition at line 53 of file name-component.cpp.

Variable Documentation

Convention ndn::name::g_conventionDecoding = Convention::EITHER
static

Definition at line 44 of file name-component.cpp.

Convention ndn::name::g_conventionEncoding = Convention::MARKER
static

Definition at line 43 of file name-component.cpp.