1 #ifndef __DataFormats_L1THGCal_HGCFETriggerDigi_h__ 2 #define __DataFormats_L1THGCal_HGCFETriggerDigi_h__ 50 template <
typename IDTYPE>
54 template <
typename IDTYPE>
62 template <
typename CODEC,
typename DATA>
66 <<
"HGC Codec and data already set with codec: " << std::hex <<
codec_ <<
std::dec;
68 codec_ = codec.getCodecType();
69 data_ = codec.encode(data);
72 template <
typename CODEC,
typename DATA>
74 if (
codec_ != codec.getCodecType()) {
76 <<
"Wrong HGC codec: " << std::hex << codec.getCodecType()
77 <<
" given to data encoded with HGC codec type: " <<
codec_ <<
std::dec;
83 template <
typename CODEC>
84 void print(
const CODEC& codec, std::ostream& out)
const;
92 template <
typename CODEC>
94 if (
codec_ != codec.getCodecType()) {
96 <<
"Wrong HGC codec: " << codec.getCodecType() <<
" given to data encoded with HGC codec type: " <<
codec_;
99 out << std::endl <<
" decoded from: " << std::endl;
void decode(const CODEC &codec, DATA &data) const
unsigned char getWhichCodec() const
std::vector< bool > data_payload
void encode(const CODEC &codec, const DATA &data)
void setDetId(const IDTYPE &id)
unsigned char hgcal_bad_codec(0xff)
void print(std::ostream &out) const
char data[epos_bytes_allocation]