#include <RawFileUtil.h>
◆ DataSeparatorRecord() [1/3]
| DataSeparatorRecord::DataSeparatorRecord |
( |
| ) |
|
◆ DataSeparatorRecord() [2/3]
| DataSeparatorRecord::DataSeparatorRecord |
( |
| ) |
|
◆ DataSeparatorRecord() [3/3]
| DataSeparatorRecord::DataSeparatorRecord |
( |
| ) |
|
◆ dump() [1/3]
| void DataSeparatorRecord::dump |
( |
std::ostream & | os = std::cout | ) |
const |
Definition at line 351 of file RawFileUtil.cxx.
351 {
352 os << "[RawFile] DataSeparatorRecord:" << std::endl
353 << std::hex << "[RawFile] \tmarker : 0x" << m_record.marker << std::endl
354 << "[RawFile] \trecord_size : 0x" << m_record.record_size << std::endl
355 << "[RawFile] \tdata_block_number : 0x" << m_record.data_block_number << std::endl
356 << "[RawFile] \tdata_block_size : 0x" << m_record.data_block_size << std::dec
357 << std::endl;
358}
◆ dump() [2/3]
| void DataSeparatorRecord::dump |
( |
std::ostream & | os = std::cout | ) |
const |
◆ dump() [3/3]
| void DataSeparatorRecord::dump |
( |
std::ostream & | os = std::cout | ) |
const |
◆ getRecord() [1/3]
◆ getRecord() [2/3]
◆ getRecord() [3/3]
◆ setDataBlockNumber() [1/3]
| void DataSeparatorRecord::setDataBlockNumber |
( |
uint32_t | dn | ) |
|
|
inline |
◆ setDataBlockNumber() [2/3]
| void DataSeparatorRecord::setDataBlockNumber |
( |
uint32_t | dn | ) |
|
|
inline |
◆ setDataBlockNumber() [3/3]
| void DataSeparatorRecord::setDataBlockNumber |
( |
uint32_t | dn | ) |
|
|
inline |
◆ setDataBlockSize() [1/3]
| void DataSeparatorRecord::setDataBlockSize |
( |
uint32_t | ds | ) |
|
|
inline |
◆ setDataBlockSize() [2/3]
| void DataSeparatorRecord::setDataBlockSize |
( |
uint32_t | ds | ) |
|
|
inline |
◆ setDataBlockSize() [3/3]
| void DataSeparatorRecord::setDataBlockSize |
( |
uint32_t | ds | ) |
|
|
inline |
◆ operator<< [1/3]
Definition at line 239 of file RawFileUtil.cxx.
239 {
240
241 if ( os.write( (char*)( &record.m_record ), sizeof( data_separator_record ) ).fail() )
242 {
243 std::cerr << "[RawFile] Error occurred while writing file" << std::endl;
244 throw FailedToWrite( "DataSeparatorRecord" );
245 }
246
247 return os;
248}
◆ operator<< [2/3]
Definition at line 239 of file RawFileUtil.cxx.
239 {
240
241 if ( os.write( (char*)( &record.m_record ), sizeof( data_separator_record ) ).fail() )
242 {
243 std::cerr << "[RawFile] Error occurred while writing file" << std::endl;
244 throw FailedToWrite( "DataSeparatorRecord" );
245 }
246
247 return os;
248}
◆ operator<< [3/3]
Definition at line 239 of file RawFileUtil.cxx.
239 {
240
241 if ( os.write( (char*)( &record.m_record ), sizeof( data_separator_record ) ).fail() )
242 {
243 std::cerr << "[RawFile] Error occurred while writing file" << std::endl;
244 throw FailedToWrite( "DataSeparatorRecord" );
245 }
246
247 return os;
248}
◆ operator>> [1/3]
Definition at line 108 of file RawFileUtil.cxx.
108 {
109
110 if ( is.read( (char*)( &record.m_record ), sizeof( data_separator_record ) ).fail() )
111 {
112
113 throw BadInputStream( "DataSeparatorRecord" );
114
115 }
116
117
118 if ( record.m_record.
marker != 0x1234cccc )
119 {
120 if ( record.m_record.
marker == 0x1234dddd )
121 {
throw ReachEndOfFile( is.
currentFile().c_str() ); }
122
123 throw WrongMarker( 0x1234cccc, record.m_record.
marker );
124 }
125
127 {
128
129 throw UnexpectedRecordSize(
"DataSeparatorRecord", 4, record.m_record.
record_size );
130 }
131
132 return is;
133}
std::string currentFile() const
◆ operator>> [2/3]
Definition at line 108 of file RawFileUtil.cxx.
108 {
109
110 if ( is.read( (char*)( &record.m_record ), sizeof( data_separator_record ) ).fail() )
111 {
112
113 throw BadInputStream( "DataSeparatorRecord" );
114
115 }
116
117
118 if ( record.m_record.
marker != 0x1234cccc )
119 {
120 if ( record.m_record.
marker == 0x1234dddd )
121 {
throw ReachEndOfFile( is.
currentFile().c_str() ); }
122
123 throw WrongMarker( 0x1234cccc, record.m_record.
marker );
124 }
125
127 {
128
129 throw UnexpectedRecordSize(
"DataSeparatorRecord", 4, record.m_record.
record_size );
130 }
131
132 return is;
133}
◆ operator>> [3/3]
Definition at line 108 of file RawFileUtil.cxx.
108 {
109
110 if ( is.read( (char*)( &record.m_record ), sizeof( data_separator_record ) ).fail() )
111 {
112
113 throw BadInputStream( "DataSeparatorRecord" );
114
115 }
116
117
118 if ( record.m_record.
marker != 0x1234cccc )
119 {
120 if ( record.m_record.
marker == 0x1234dddd )
121 {
throw ReachEndOfFile( is.
currentFile().c_str() ); }
122
123 throw WrongMarker( 0x1234cccc, record.m_record.
marker );
124 }
125
127 {
128
129 throw UnexpectedRecordSize(
"DataSeparatorRecord", 4, record.m_record.
record_size );
130 }
131
132 return is;
133}
The documentation for this class was generated from the following files: