AgentXcpp  Revision:4ac4848
Internals Documentation
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends
agentxcpp::RegisterPDU Class Reference

This class represents a Register-PDU. More...

#include <RegisterPDU.hpp>

Inheritance diagram for agentxcpp::RegisterPDU:
[legend]
Collaboration diagram for agentxcpp::RegisterPDU:
[legend]

List of all members.

Public Member Functions

void set_upper_bound (uint32_t upper_bound)
 Set the upper_bound.
uint32_t get_upper_bound ()
 Get the upper_bound.
void set_subtree (oid subtree)
 Set the subtree.
oid get_subtree ()
 Get the subtree.
void set_range_subid (byte_t range_subid)
 Set the range_subid.
byte_t get_range_subid ()
 Get the range_subid.
void set_priority (byte_t priority)
 Set the priority.
byte_t get_priority ()
 Get the priority.
void set_timeout (byte_t timeout)
 Set the timeout.
byte_t get_timeout ()
 Get the timeout.
 RegisterPDU (data_t::const_iterator &pos, const data_t::const_iterator &end, bool big_endian)
 Parse constructor.
data_t serialize () const
 Serialize the PDU.
 RegisterPDU ()
 Default Constructor.
bool get_instance_registration ()
 Get instance_registration flag.
void set_instance_registration (bool ir)
 Set instance_registration flag.

Private Attributes

byte_t timeout
byte_t priority
oid subtree
byte_t range_subid
uint32_t upper_bound

Detailed Description

This class represents a Register-PDU.

Definition at line 33 of file RegisterPDU.hpp.


Constructor & Destructor Documentation

RegisterPDU::RegisterPDU ( data_t::const_iterator &  pos,
const data_t::const_iterator &  end,
bool  big_endian 
)

Parse constructor.

Construct the object by parsing a stream. See Parsing incoming PDUs for details about PDU parsing.

Parameters:
posIterator pointing to the current stream position. The iterator is advanced while reading the header.
endIterator pointing one element past the end of the current stream. This is needed to mark the end of the buffer.
big_endianWhether the serialized form of the PDU is in big_endian format.
Exceptions:
parse_errorIf parsing fails, for example because reading the stream fails or the PDU is malformed.

Definition at line 24 of file RegisterPDU.cpp.

References priority, range_subid, read32(), subtree, timeout, and upper_bound.

Default Constructor.

Sets the state of the object to the defaults as set by the PDU::PDU() constructor, plus the following:

  • timeout = 0
  • priority = 127 (According to RFC 2741, section '6.2.3. The agentx-Register-PDU')
  • subtree = null Object Identifier
  • range_subid = 0
  • upper_bound = null Object Identifier

Definition at line 77 of file RegisterPDU.cpp.


Member Function Documentation

Get instance_registration flag.

The instance_registration flag is part of the PDU header and therefore located in the PDU class. However, it is used only by Register-PDUs, therefore the getter method is located here.

Definition at line 168 of file RegisterPDU.hpp.

References agentxcpp::PDU::instance_registration.

Get the priority.

Definition at line 98 of file RegisterPDU.hpp.

References priority.

Get the range_subid.

Definition at line 83 of file RegisterPDU.hpp.

References range_subid.

Get the subtree.

Definition at line 68 of file RegisterPDU.hpp.

References subtree.

Get the timeout.

Definition at line 113 of file RegisterPDU.hpp.

References timeout.

Get the upper_bound.

Definition at line 53 of file RegisterPDU.hpp.

References upper_bound.

Set instance_registration flag.

The instance_registration flag is part of the PDU header and therefore located in the PDU class. However, it is used only by Register-PDUs, therefore the setter method is located here.

Definition at line 180 of file RegisterPDU.hpp.

References agentxcpp::PDU::instance_registration.

void agentxcpp::RegisterPDU::set_priority ( byte_t  priority) [inline]

Set the priority.

Definition at line 91 of file RegisterPDU.hpp.

References priority.

void agentxcpp::RegisterPDU::set_range_subid ( byte_t  range_subid) [inline]

Set the range_subid.

Definition at line 76 of file RegisterPDU.hpp.

References range_subid.

void agentxcpp::RegisterPDU::set_subtree ( oid  subtree) [inline]

Set the subtree.

Definition at line 61 of file RegisterPDU.hpp.

References subtree.

void agentxcpp::RegisterPDU::set_timeout ( byte_t  timeout) [inline]

Set the timeout.

Definition at line 106 of file RegisterPDU.hpp.

References timeout.

void agentxcpp::RegisterPDU::set_upper_bound ( uint32_t  upper_bound) [inline]

Set the upper_bound.

Definition at line 46 of file RegisterPDU.hpp.

References upper_bound.


Member Data Documentation

Definition at line 38 of file RegisterPDU.hpp.

Referenced by get_subtree(), RegisterPDU(), serialize(), and set_subtree().


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