22 #include <boost/io/ios_state.hpp> 37 boost::prior(
data().end(), 4),
38 crc32_t() ).checksum();
43 boost::io::ios_all_saver ias(os);
44 os <<
"MPE Section:\n" 46 <<
senf::fieldName(
"table_id") <<
"0x" << unsigned(p->table_id()) <<
"\n" 47 <<
senf::fieldName(
"section syntax indicator") << p->section_syntax_indicator() <<
"\n" 48 <<
senf::fieldName(
"private indicator") << p->private_indicator() <<
"\n" 52 <<
senf::fieldName(
"MAC address 6") <<
"0x" << unsigned(p->mac_addr_6()) <<
"\n" 53 <<
senf::fieldName(
"MAC address 5") <<
"0x" << unsigned(p->mac_addr_5()) <<
"\n" 54 <<
senf::fieldName(
"payload scrambling ctrl") <<
"0x" << p->payload_scrmbl_ctrl() <<
"\n" 56 <<
senf::fieldName(
"LLC/SNAP flag") <<
"0x" << p->llc_snap_flag() <<
"\n" 57 <<
senf::fieldName(
"current next indicator") <<
"0x" << p->curr_next_indicator() <<
"\n" 58 <<
senf::fieldName(
"section number") <<
"0x" << unsigned(p->section_num()) <<
"\n" 59 <<
senf::fieldName(
"last section number") <<
"0x" << unsigned(p->last_section_num()) <<
"\n" 61 <<
senf::fieldName(
" delta_t") <<
"0x" << unsigned(p->real_time_parameters().delta_t()) <<
"\n" 62 <<
senf::fieldName(
" table boundary") <<
"0x" << unsigned(p->real_time_parameters().table_boundary()) <<
"\n" 63 <<
senf::fieldName(
" frame boundary") <<
"0x" << unsigned(p->real_time_parameters().frame_boundary()) <<
"\n" 64 <<
senf::fieldName(
" address") <<
"0x" << unsigned(p->real_time_parameters().address()) <<
"\n" 71 return parser::fixed_bytes + 32/8;
76 return parser::fixed_bytes;
81 if (p.
data().
size() > initSize()+1) {
82 if (p->llc_snap_flag())
84 if (p->ip_datagram_version().value() == 4)
86 if (p->ip_datagram_version().value() == 6)
95 p->section_length() = p.
data().
size() - 3;
96 p->crc() = p->calcCrc();
IPv6Packet public header.
static void dump(packet p, std::ostream &os)
Dump given MPESection in readable form to given output stream.
std::string fieldName(std::string const &s)
static PacketParserBase::size_type initHeadSize()
PacketData & data() const
Access the packets raw data container.
Protocol specific packet handle.
static factory_t nextPacketType(packet p)
Packet next() const
Get next packet in chain.
MPESection public header.
detail::packet::size_type size_type
Unsigned integral type.
senf::UIntFieldParser<?,?+2 > addr_scrmbl_ctrl() const
size_type size() const
Returns the number of bytes in the packet data.
static PacketParserBase::size_type initSize()
PacketData & data() const
Access the packets raw data container.
SENF_PACKET_INSTANTIATE_TEMPLATE(senf::MPESection)
static factory_t factory()
Return factory for packets of specific type.
IPv4Packet public header.
static void finalize(packet p)
boost::uint32_t calcCrc() const
bool is() const
Check, whether this packet is of the given type.
Factory const * factory_t