10 #ifndef YARP_OS_PORTWRITERBUFFER_H
11 #define YARP_OS_PORTWRITERBUFFER_H
21 #ifndef DOXYGEN_SHOULD_SKIP_THIS
24 class PortWriterBufferAdaptor :
public PortWriterWrapper
27 PortWriterBufferManager& creator;
31 PortWriterBufferAdaptor(PortWriterBufferManager& creator,
38 bool write(ConnectionWriter& connection)
const override
40 return writer.write(connection);
43 void onCompletion()
const override
45 writer.onCompletion();
46 creator.onCompletion(tracker);
49 void onCommencement()
const override
51 writer.onCommencement();
54 PortWriter* getInternal()
override
60 #endif // DOXYGEN_SHOULD_SKIP_THIS
104 PortWriterBufferAdaptor<T>* content = (PortWriterBufferAdaptor<T>*)
getContent();
105 return content->writer;
133 void write(
bool forceStrict =
false)
146 virtual PortWriterWrapper*
create(PortWriterBufferManager& man,
147 void* tracker)
override
149 return new PortWriterBufferAdaptor<T>(man, tracker);
156 #endif // YARP_OS_PORTWRITERBUFFER_H