/** * Decode the input using a particular wire format and update this * EncryptedContent. * @param input The input byte array to be decoded. * @param wireFormat (optional) A WireFormat object used to decode the input. * If omitted, use WireFormat::getDefaultWireFormat(). */ void wireDecode (const std::vector<uint8_t>& input, WireFormat& wireFormat = *WireFormat::getDefaultWireFormat()) { wireDecode(&input[0], input.size(), wireFormat); }
void wireDecode (const Blob& input, WireFormat& wireFormat = *WireFormat::getDefaultWireFormat()) { wireDecode(input.buf(), input.size(), wireFormat); }
/** * Decode the input using a particular wire format and update this Data. If wireFormat is the default wire format, also * set the defaultWireEncoding field to a copy of the input. (To not copy the input, see wireDecode(Blob).) * @param input The input byte array to be decoded. * @param inputLength The length of input. * @param wireFormat A WireFormat object used to decode the input. If omitted, use WireFormat getDefaultWireFormat(). */ void wireDecode (const uint8_t* input, size_t inputLength, WireFormat& wireFormat = *WireFormat::getDefaultWireFormat()) { wireDecode(Blob(input, inputLength), wireFormat); }
uint32_t PacketHeader<Pkt>::Deserialize(ns3::Buffer::Iterator start) { auto packet = make_shared<Pkt>(); io::stream<Ns3BufferIteratorSource> is(start); packet->wireDecode(::ndn::Block::fromStream(is)); m_packet = packet; return packet->wireEncode().size(); }
bool Response::fromData(const Name& zone, const Data& data) { label::MatchResult re; if (!matchName(data, zone, re)) return false; m_rrLabel = re.rrLabel; m_rrType = re.rrType; m_version = re.version; m_zone = zone; size_t len = zone.size(); m_queryType = data.getName().get(len); MetaInfo info = data.getMetaInfo(); m_freshnessPeriod = time::duration_cast<time::seconds>(info.getFreshnessPeriod()); m_contentType = NdnsContentType(data.getContentType()); wireDecode(data.getContent()); return true; }
LsdbStatus::LsdbStatus(const ndn::Block& block) { wireDecode(block); }
MetaInfo::MetaInfo(const Block& block) { wireDecode(block); }
RoutingTable::RoutingTable(const ndn::Block& block) { wireDecode(block); }
ControlParameters::ControlParameters(const Block& block) : m_hasFields(CONTROL_PARAMETER_UBOUND) { wireDecode(block); }
Data::Data(const Block& wire) { wireDecode(wire); }
explicit SimpleNotification(const Block& block) { wireDecode(block); }
CachePolicy::CachePolicy(const Block& block) { wireDecode(block); }
Packet::Packet(const Block& wire) { wireDecode(wire); }
AdjacencyLsa::AdjacencyLsa(const ndn::Block& block) { wireDecode(block); }
NackHeader::NackHeader(const Block& block) { wireDecode(block); }
Interest::Interest(const Block& wire) { wireDecode(wire); }
/** * Decode the input and update this Schedule. * @param input The input byte array to be decoded as an immutable Blob. */ void wireDecode(const Blob& input) { wireDecode(input.buf(), input.size()); }
/** * Decode the input and update this Schedule. * @param input The input byte array to be decoded. */ void wireDecode(const std::vector<uint8_t>& input) { wireDecode(&input[0], input.size()); }
AdditionalDescription::AdditionalDescription(const Block& block) { wireDecode(block); }
CoordinateLsa::CoordinateLsa(const ndn::Block& block) { wireDecode(block); }
LsaInfo::LsaInfo(const ndn::Block& block) { wireDecode(block); }
Exclude::Exclude(const Block& wire) { wireDecode(wire); }
RibEntry::RibEntry(const Block& block) { wireDecode(block); }
KeyLocator::KeyLocator(const Block& wire) { wireDecode(wire); }
Schedule::Schedule(const Block& block) { wireDecode(block); }
Route::Route(const Block& block) { wireDecode(block); }
DefaultParam::DefaultParam(const Block& wire) { wireDecode(wire); }