[Ndn-lib] writing a code to create an Interest packet
zeinabzali at gmail.com
Mon Aug 1 04:46:29 PDT 2016
Thank you very much. That was a big help :)
On Mon, Aug 1, 2016 at 2:13 PM, Thompson, Jeff <jefft0 at remap.ucla.edu>
> Hello Zeinab,
> The TlvEncoder is an internal utility. It is not meant to be called
> directly by applications. You can encode an Interest using the wireEncode
> method as shown on the API page:
> Here is an example program to encode an Interest:
> If you need to add an ImplicitSha256DigestComponent to the name, see:
> Thank you,
> - Jeff T
> From: Ndn-lib <ndn-lib-bounces at lists.cs.ucla.edu> on behalf of Zeinab
> Zali <zeinabzali at gmail.com>
> Date: Monday, August 1, 2016 at 1:47:00
> To: NDN Lib <ndn-lib at lists.cs.ucla.edu>
> Subject: [Ndn-lib] writing a code to create an Interest packet
> Hi all,
> I am confused with TlvEncoder and Bytebuffers. I want to write a simple
> java code to create a UDP packet that contained an Interest. I tried to use
> writeBlobTlv of class TlvEncoder in jndn package. But I don't understand if
> I should create the outer Tlv or the inner one. For example to create a
> name Tlv, should I create a TlvEncoder object for nameComponent and then
> another one for ImplicitSha256DigestComponent, and then a Name component?
> Would you please give me a simple example to create a Tlv with its sub Tlvs?
> Thanks a lot.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Ndn-lib