7 #ifndef NDN_META_INFO_HPP
8 #define NDN_META_INFO_HPP
28 , m_freshnessPeriod(-1)
67 const time::milliseconds&
70 return m_freshnessPeriod;
77 m_freshnessPeriod = freshnessPeriod;
84 return m_finalBlockId;
91 m_finalBlockId = finalBlockId;
105 return !(*
this == other);
110 time::milliseconds m_freshnessPeriod;
113 mutable Block m_wire;
125 size_t totalLength = 0;
128 if (!m_finalBlockId.
empty())
134 if (m_freshnessPeriod >= time::milliseconds::zero())
137 m_freshnessPeriod.count());
146 totalLength += blk.prependVarNumber(totalLength);
163 m_wire = buffer.block();
193 m_freshnessPeriod = time::milliseconds::min();
203 m_finalBlockId.
reset();
207 m_finalBlockId.
reset();
214 os <<
"ContentType: " << info.
getType();
222 os <<
", FinalBlockId: ";
230 #endif // NDN_META_INFO_HPP
size_t prependNestedBlock(EncodingImpl< P > &encoder, uint32_t type, const U &nestedBlock)
element_const_iterator find(uint32_t type) const
const element_container & elements() const
Get all subelements.
Class representing wire element of the NDN packet.
uint64_t readNonNegativeInteger(const Block &block)
Block blockFromValue() const
element_container::const_iterator element_const_iterator
void toUri(std::ostream &result) const
void reset()
Reset wire buffer of the element.
void parse() const
Parse wire buffer into subblocks.
Component holds a read-only name component value.
bool hasWire() const
Check if the Block has fully encoded wire.
size_t prependNonNegativeIntegerBlock(EncodingImpl< P > &encoder, uint32_t type, uint64_t number)
helper methods
std::ostream & operator<<(std::ostream &os, const Data &data)
Class representing wire element of the NDN packet.