AgentXcpp  Version:0.3
Internals Documentation
All Classes Namespaces Files Functions Variables Enumerations Enumerator Friends Pages
The PDU Objects

The PDU objects, such as OpenPDU, RegisterPDU and so on represent the AgentX Protocol Data Units. Each of these classes inherits from the abstract PDU class which represents the header of a PDU. The header is identical for each PDU. Some classes inherit from the PDUwithContext class, which in turn derives from PDU. PDU is used for classes without the context field while PDUwithContext is used for classes with the context field. The latter only implements functionality to handle the context.

The concrete PDU classes mainly serve as data containers, holding the information which is required by RFC 2741 and providing functionality to serialize and deserialize the PDU. Each field of the class can be manipulated using setters and getters. For example, the OpenPDU class has the set_descr() and get_descr() methods to manipulate the 'descr' field (see RFC 2741, '6.2.1. The agentx-Open-PDU' for an explanation of the field). The PDU class also provides such setters and getters to manipulate the header fields.

Each concrete PDU class also has a default constructor which initializes the object to its default values. These default constructors also invoke the constructor of the base class, PDU, which initializes the header fields to their default values.

Further information can be found on these pages: