22 #ifndef NDN_MGMT_NFD_CONTROL_PARAMETERS_HPP 23 #define NDN_MGMT_NFD_CONTROL_PARAMETERS_HPP 70 "BaseCongestionMarkingInterval",
71 "DefaultCongestionThreshold",
87 using tlv::Error::Error;
95 template<encoding::Tag TAG>
175 BOOST_ASSERT(this->
hasUri());
213 m_localUri = localUri;
303 m_capacity = capacity;
423 m_strategy = strategy;
442 const time::milliseconds&
446 return m_expirationPeriod;
453 m_expirationPeriod = expirationPeriod;
476 return m_facePersistency;
483 m_facePersistency = persistency;
506 return m_baseCongestionMarkingInterval;
513 m_baseCongestionMarkingInterval = interval;
538 return m_defaultCongestionThreshold;
547 m_defaultCongestionThreshold = threshold;
573 BOOST_ASSERT(this->
hasMtu());
598 const std::vector<bool>&
626 setFlagBit(
size_t bit,
bool value,
bool wantMask =
true);
637 std::vector<bool> m_hasFields;
642 std::string m_localUri;
650 time::milliseconds m_expirationPeriod;
652 time::nanoseconds m_baseCongestionMarkingInterval;
653 uint64_t m_defaultCongestionThreshold;
657 mutable Block m_wire;
668 #endif // NDN_MGMT_NFD_CONTROL_PARAMETERS_HPP
uint64_t getFlags() const
ControlParameters & setFaceId(uint64_t faceId)
void wireDecode(const Block &wire) final
Copyright (c) 2011-2015 Regents of the University of California.
ControlParameters & unsetStrategy()
represents parameters in a ControlCommand request or response
time::nanoseconds getBaseCongestionMarkingInterval() const
ControlParameters & unsetBaseCongestionMarkingInterval()
ControlParameters & setMtu(uint64_t mtu)
set MTU (measured in bytes)
ControlParameters & setFlags(uint64_t flags)
ControlParameters & unsetFaceId()
ControlParameters & unsetMask()
Represents a TLV element of NDN packet format.
ControlParameters & unsetCost()
ControlParameters & unsetFlags()
bool hasBaseCongestionMarkingInterval() const
ControlParameters & setUri(const std::string &uri)
ControlParameters & unsetOrigin()
ControlParameters & setStrategy(const Name &strategy)
ControlParameters & setExpirationPeriod(const time::milliseconds &expirationPeriod)
ControlParameters & unsetFlagBit(size_t bit)
disable a bit in Mask
uint64_t getCapacity() const
FacePersistency getFacePersistency() const
const Name & getName() const
uint64_t getMtu() const
get MTU (measured in bytes)
uint64_t getCount() const
Block wireEncode() const final
Copyright (c) 2011-2015 Regents of the University of California.
ControlParameters & setBaseCongestionMarkingInterval(time::nanoseconds interval)
const std::string & getLocalUri() const
ControlParameters & unsetExpirationPeriod()
ControlParameters & unsetFacePersistency()
uint64_t getDefaultCongestionThreshold() const
get default congestion threshold (measured in bytes)
bool hasExpirationPeriod() const
ControlParameters & unsetLocalUri()
RouteOrigin getOrigin() const
std::ostream & operator<<(std::ostream &os, FaceScope faceScope)
void reset()
Reset wire buffer of the element.
Represents an absolute name.
const std::string CONTROL_PARAMETER_FIELD[CONTROL_PARAMETER_UBOUND]
bool hasFlagBit(size_t bit) const
const std::vector< bool > & getPresentFields() const
uint64_t getFaceId() const
base class for a struct that contains ControlCommand parameters
const std::string & getUri() const
ControlParameters & unsetCapacity()
ControlParameters & setCost(uint64_t cost)
bool hasFacePersistency() const
const time::milliseconds & getExpirationPeriod() const
NDN_CXX_DECLARE_WIRE_ENCODE_INSTANTIATIONS(ChannelStatus)
ControlParameters & setName(const Name &name)
ControlParameters & setFacePersistency(FacePersistency persistency)
ControlParameters & unsetCount()
ControlParameters & setOrigin(RouteOrigin origin)
ControlParameters & setDefaultCongestionThreshold(uint64_t threshold)
set default congestion threshold (measured in bytes)
bool hasDefaultCongestionThreshold() const
ControlParameters & setCapacity(uint64_t capacity)
bool getFlagBit(size_t bit) const
ControlParameters & unsetName()
ControlParameters & unsetUri()
ControlParameters & setCount(uint64_t count)
const Name & getStrategy() const
ControlParameters & setMask(uint64_t mask)
ControlParameters & setFlagBit(size_t bit, bool value, bool wantMask=true)
set a bit in Flags
ControlParameters & unsetDefaultCongestionThreshold()
represents an error in TLV encoding or decoding
ControlParameters & setLocalUri(const std::string &localUri)
ControlParameters & unsetMtu()