NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.0: NDN, CCN, CCNx, content centric networks
API Documentation
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
ndnSIM
ndnSIM documentation
All Attributes
All GlobalValues
All LogComponents
All TraceSources
Todo List
Deprecated List
Modules
Namespaces
Classes
Files
File List
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
field-info.hpp
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
22
#ifndef NDN_CXX_LP_DETAIL_FIELD_INFO_HPP
23
#define NDN_CXX_LP_DETAIL_FIELD_INFO_HPP
24
25
#include "../../common.hpp"
26
27
#include "../fields.hpp"
28
29
namespace
ndn
{
30
namespace
lp {
31
namespace
detail {
32
33
class
FieldInfo
34
{
35
public
:
36
FieldInfo
();
37
38
explicit
39
FieldInfo
(uint64_t tlv);
40
41
public
:
45
uint64_t
tlvType
;
46
50
bool
isRecognized
;
51
55
bool
canIgnore
;
56
60
bool
isRepeatable
;
61
65
int
locationSortOrder
;
66
};
67
68
template
<
typename
TAG>
69
inline
int
70
getLocationSortOrder
();
71
72
template
<>
73
inline
int
74
getLocationSortOrder<field_location_tags::Header>()
75
{
76
return
1;
77
}
78
79
template
<>
80
inline
int
81
getLocationSortOrder<field_location_tags::Fragment>()
82
{
83
return
2;
84
}
85
86
inline
bool
87
compareFieldSortOrder
(
const
FieldInfo
& first,
const
FieldInfo
& second)
88
{
89
return
(first.
locationSortOrder
< second.
locationSortOrder
) ||
90
(first.
locationSortOrder
== second.
locationSortOrder
&& first.
tlvType
< second.
tlvType
);
91
}
92
93
}
// namespace detail
94
}
// namespace lp
95
}
// namespace ndn
96
97
#endif // NDN_CXX_LP_DETAIL_FIELD_INFO_HPP
ndn::lp::detail::FieldInfo::canIgnore
bool canIgnore
can this unknown field be ignored
Definition:
field-info.hpp:55
ndn
Copyright (c) 2011-2015 Regents of the University of California.
Definition:
ndn-strategy-choice-helper.hpp:34
ndn::lp::detail::getLocationSortOrder
int getLocationSortOrder()
ndn::lp::detail::FieldInfo::isRepeatable
bool isRepeatable
is the field repeatable
Definition:
field-info.hpp:60
ndn::lp::detail::FieldInfo::isRecognized
bool isRecognized
is this field known
Definition:
field-info.hpp:50
ndn::lp::detail::FieldInfo
Definition:
field-info.hpp:33
ndn::lp::detail::compareFieldSortOrder
bool compareFieldSortOrder(const FieldInfo &first, const FieldInfo &second)
Definition:
field-info.hpp:87
ndn::lp::detail::FieldInfo::locationSortOrder
int locationSortOrder
sort order of field_location_tag
Definition:
field-info.hpp:65
ndn::lp::detail::FieldInfo::FieldInfo
FieldInfo()
Definition:
field-info.cpp:49
ndn::lp::detail::FieldInfo::tlvType
uint64_t tlvType
TLV-TYPE of the field; 0 if field does not exist.
Definition:
field-info.hpp:45
ndnSIM
ndn-cxx
src
lp
detail
field-info.hpp
Generated on Tue Feb 23 2016 22:18:43 for ndnSIM by
1.8.11