82 if (!stream)
return *
this;
83 (*stream.get()) << obj;
93 if (stream) stream->flush();
98 std::unique_ptr<std::ostream> stream;
102 if (desc ==
nullptr)
return;
103 init(desc->
msg,
sizeof(desc->
msg) /
sizeof(desc->
msg[0]));
106 void init(
char* ptr,
size_t len) {
107 if (
nullptr != ptr && len > 0) {
109 setp(ptr, ptr + len - 1);
111 stream.reset(
new std::ostream(
this));
113 if (
nullptr != ptr && len > 0) {
115 (*stream.get()) << ptr;
Inference Engine Plugin API namespace.
A description buffer wrapping StatusCode and ResponseDesc.
Definition: description_buffer.hpp:24
DescriptionBuffer(StatusCode err, ResponseDesc *desc)
Creeates a description buffer with parameters.
Definition: description_buffer.hpp:31
DescriptionBuffer(ResponseDesc *desc)
Constructs with ResponseDesc.
Definition: description_buffer.hpp:47
DescriptionBuffer(StatusCode err)
Constructs with StatusCode.
Definition: description_buffer.hpp:40
DescriptionBuffer(char *pBuffer, size_t len)
Constructs with parameters.
Definition: description_buffer.hpp:57
DescriptionBuffer & operator<<(const T &obj)
Writes to ResponseDesc stream.
Definition: description_buffer.hpp:81
DescriptionBuffer(StatusCode err, char *pBuffer, size_t len)
Constructs with parameters.
Definition: description_buffer.hpp:68