Public Member Functions | Private Attributes | List of all members
eip::CPFPacket Class Reference

#include <cpf_packet.h>

Inheritance diagram for eip::CPFPacket:
Inheritance graph
[legend]

Public Member Functions

virtual Reader & deserialize (Reader &reader, size_t length)
 
virtual Reader & deserialize (Reader &reader)
 
EIP_UINT getItemCount () const
 
vector< CPFItem > & getItems ()
 
virtual size_t getLength () const
 
virtual Writer & serialize (Writer &writer) const
 

Private Attributes

vector< CPFItemitems_
 

Detailed Description

Representation of an EtherNet/IP Common Packet Format packet.

Definition at line 49 of file cpf_packet.h.

Member Function Documentation

virtual Reader& eip::CPFPacket::deserialize ( Reader &  reader,
size_t  length 
)
inlinevirtual

Length data isn't meaningful here. Instead just calls the deserialize without the added information.

Definition at line 89 of file cpf_packet.h.

Reader & eip::CPFPacket::deserialize ( Reader &  reader)
virtual

Deserialize data from the given reader without length information

Parameters
readerReader to use for deserialization
Returns
the reader again
Exceptions
std::length_errorif the buffer is overrun while deserializing

Definition at line 56 of file cpf_packet.cpp.

EIP_UINT eip::CPFPacket::getItemCount ( ) const
inline

Get the number of items in the packet, including both address and data items

Returns
number of items in packet

Definition at line 57 of file cpf_packet.h.

vector<CPFItem>& eip::CPFPacket::getItems ( )
inline

Get the items in this packet

Returns
vector of the items in this packet

Definition at line 66 of file cpf_packet.h.

size_t eip::CPFPacket::getLength ( ) const
virtual

Get the length in bytes of this packet after serialization

Returns
Total length in bytes to be serialized

Definition at line 35 of file cpf_packet.cpp.

Writer & eip::CPFPacket::serialize ( Writer &  writer) const
virtual

Serialize data into the given buffer

Parameters
writerWriter to use for serialization
Returns
the writer again
Exceptions
std::length_errorif the buffer is too small for the header data

Definition at line 46 of file cpf_packet.cpp.

Member Data Documentation

vector< CPFItem > eip::CPFPacket::items_
private

Definition at line 104 of file cpf_packet.h.


The documentation for this class was generated from the following files:


odva_ethernetip
Author(s): Kareem Shehata
autogenerated on Mon Jun 10 2019 14:00:16