blob: 8458f9436a99c005630cbfc26e7f973b35219c25 [file] [log] [blame]
Jeff Thompson47eecfc2013-07-07 22:56:46 -07001/**
2 * @author: Jeff Thompson
3 * See COPYING for copyright and distribution information.
Jeff Thompson9c41dfe2013-06-27 12:10:25 -07004 */
5
Jeff Thompson9c41dfe2013-06-27 12:10:25 -07006#ifndef NDN_WIREFORMAT_HPP
7#define NDN_WIREFORMAT_HPP
8
9#include <vector>
10
11namespace ndn {
12
13class Name;
14class Interest;
Jeff Thompson5cae5e52013-07-10 19:41:20 -070015class ContentObject;
Jeff Thompson9c41dfe2013-06-27 12:10:25 -070016
17class WireFormat {
18public:
Jeff Thompsond345a5b2013-07-08 16:18:23 -070019 virtual void encodeName(const Name &name, std::vector<unsigned char> &output);
Jeff Thompson42380712013-06-28 10:59:33 -070020 virtual void decodeName(Name &name, const unsigned char *input, unsigned int inputLength);
Jeff Thompson9c41dfe2013-06-27 12:10:25 -070021
Jeff Thompsond345a5b2013-07-08 16:18:23 -070022 virtual void encodeInterest(const Interest &interest, std::vector<unsigned char> &output);
Jeff Thompson42380712013-06-28 10:59:33 -070023 virtual void decodeInterest(Interest &interest, const unsigned char *input, unsigned int inputLength);
Jeff Thompson9c41dfe2013-06-27 12:10:25 -070024
Jeff Thompson5cae5e52013-07-10 19:41:20 -070025 virtual void encodeContentObject(const ContentObject &contentObject, std::vector<unsigned char> &output);
26 virtual void decodeContentObject(ContentObject &contentObject, const unsigned char *input, unsigned int inputLength);
Jeff Thompson9c41dfe2013-06-27 12:10:25 -070027};
28
29}
30
31#endif
32