45 char *rawbuf =
new char[
sizeof(
UInt_t)];
58 rawbuf =
new char[
sizeof(
ULong_t)];
66 std::unique_ptr<TBufferFile> objBuf;
67 if (classBufSize != 0) {
68 char *classBuf =
new char[classBufSize];
69 s->
RecvRaw(classBuf, classBufSize);
73 return std::make_pair(code, std::move(objBuf));
The concrete implementation of TBuffer for writing/reading to/from a ROOT file or socket...
MPCodeBufPair MPRecv(TSocket *s)
Receive message from a socket.
int MPSend(TSocket *s, unsigned code)
Send a message with the specified code on the specified socket.
Error while reading from the socket.
virtual void ReadUInt(UInt_t &i)
virtual void WriteULong(ULong_t l)
virtual Int_t SendRaw(const void *buffer, Int_t length, ESendRecvOptions opt=kDefault)
Send a raw buffer of specified length.
virtual void WriteUInt(UInt_t i)
std::pair< unsigned, std::unique_ptr< TBufferFile >> MPCodeBufPair
An std::pair that wraps the code and optional object contained in a message.
virtual Int_t RecvRaw(void *buffer, Int_t length, ESendRecvOptions opt=kDefault)
Receive a raw buffer of specified length bytes.
virtual void ReadULong(ULong_t &l)
void SetBuffer(void *buf, UInt_t bufsiz=0, Bool_t adopt=kTRUE, ReAllocCharFun_t reallocfunc=0)
Sets a new buffer in an existing TBuffer object.