123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142 |
- #pragma once
- #ifdef __GNUC__
- #pragma GCC diagnostic push
- #pragma GCC diagnostic ignored "-Wunused-parameter"
- #endif
- #ifndef LLVM_BINARYFORMAT_MSGPACKWRITER_H
- #define LLVM_BINARYFORMAT_MSGPACKWRITER_H
- #include "llvm/Support/EndianStream.h"
- #include "llvm/Support/MemoryBufferRef.h"
- namespace llvm {
- class raw_ostream;
- namespace msgpack {
- class Writer {
- public:
-
-
-
-
-
-
-
-
- Writer(raw_ostream &OS, bool Compatible = false);
- Writer(const Writer &) = delete;
- Writer &operator=(const Writer &) = delete;
-
-
-
- void writeNil();
-
-
-
- void write(bool b);
-
-
-
-
-
- void write(int64_t i);
-
-
-
- void write(uint64_t u);
-
-
-
- void write(double d);
-
-
-
- void write(StringRef s);
-
-
-
-
-
- void write(MemoryBufferRef Buffer);
-
-
-
-
-
-
-
-
-
- void writeArraySize(uint32_t Size);
-
-
-
-
-
-
-
-
-
-
- void writeMapSize(uint32_t Size);
-
-
-
- void writeExt(int8_t Type, MemoryBufferRef Buffer);
- private:
- support::endian::Writer EW;
- bool Compatible;
- };
- }
- }
- #endif
- #ifdef __GNUC__
- #pragma GCC diagnostic pop
- #endif
|