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

Represents an Integer as descibed in RFC 2741. More...

#include <Gauge32.hpp>

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

List of all members.

Public Member Functions

 Gauge32 ()
 Create a Gauge32 without initialization.
 Gauge32 (data_t::const_iterator &pos, const data_t::const_iterator &end, bool big_endian=true)
 Construct the object from input stream.
virtual data_t serialize () const
 Encode the object as described in RFC 2741, section 5.4.

Protected Attributes

uint32_t value
 The value.

Detailed Description

Represents an Integer as descibed in RFC 2741.

Definition at line 32 of file Gauge32.hpp.


Constructor & Destructor Documentation

Create a Gauge32 without initialization.

The value after creation is undefined.

Definition at line 46 of file Gauge32.hpp.

Gauge32::Gauge32 ( data_t::const_iterator &  pos,
const data_t::const_iterator &  end,
bool  big_endian = true 
)

Construct the object from input stream.

This constructor parses the serialized form of the object. It takes an iterator, starts parsing at the position of the iterator and advances the iterator to the position right behind the object.

The constructor expects valid data from the stream; if parsing fails, parse_error is thrown. In this case, the iterator position is undefined.

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 input stream is in big endian format

Definition at line 38 of file Gauge32.cpp.

References value.


Member Function Documentation

data_t Gauge32::serialize ( ) const [virtual]

Encode the object as described in RFC 2741, section 5.4.

This function uses big endian.

Implements variable.

Definition at line 24 of file Gauge32.cpp.

References value.


Member Data Documentation

The value.

Definition at line 38 of file Gauge32.hpp.

Referenced by Gauge32(), and serialize().


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