#include <IOPool/Streamer/interface/Utilities.h>
Public Member Functions | |
std::auto_ptr< SendJobHeader > | decodeJobHeader (InitMsg const &msg) |
JobHeaderDecoder () | |
~JobHeaderDecoder () | |
Private Attributes | |
RootBuffer | buf_ |
TClass * | desc_ |
Definition at line 34 of file Utilities.h.
edm::JobHeaderDecoder::JobHeaderDecoder | ( | ) |
edm::JobHeaderDecoder::~JobHeaderDecoder | ( | ) |
std::auto_ptr< SendJobHeader > edm::JobHeaderDecoder::decodeJobHeader | ( | InitMsg const & | msg | ) |
Definition at line 61 of file Utilities.cc.
References edm::InitMsg::data(), desc_, lat::endl(), Exception, FDEBUG, edm::MsgCode::getCode(), edm::InitMsg::getDataSize(), and edm::MsgCode::INIT.
00062 { 00063 FDEBUG(6) << "StreamInput: decodeRegistry" << std::endl; 00064 00065 if(msg.getCode()!=MsgCode::INIT) 00066 throw cms::Exception("HeaderDecode","EventStreamerInput") 00067 << "received wrong message type: expected INIT, got " 00068 << msg.getCode() << "\n"; 00069 00070 // This "SetBuffer" stuff does not appear to work or I don't understand 00071 // what needs to be done to actually make it go. (JBK) 00072 //buf_.SetBuffer((char*)msg.data(),msg.getDataSize(),kFALSE); 00073 RootBuffer xbuf(TBuffer::kRead,msg.getDataSize(),(char*)msg.data(),kFALSE); 00074 RootDebug tracer(10,10); 00075 std::auto_ptr<SendJobHeader> sd((SendJobHeader*)xbuf.ReadObjectAny(desc_)); 00076 00077 if(sd.get()==0) { 00078 throw cms::Exception("HeaderDecode","DecodeProductList") 00079 << "Could not read the initial product registry list\n"; 00080 } 00081 00082 return sd; 00083 }
RootBuffer edm::JobHeaderDecoder::buf_ [private] |
Definition at line 44 of file Utilities.h.
TClass* edm::JobHeaderDecoder::desc_ [private] |