AgentX++  2.0.5
Public Member Functions | Protected Attributes | List of all members
AgentXSearchRange Class Reference

The AgentXSearchRange class represents an item in an AgentX SearchRangeList. More...

#include <agentx_pdu.h>

Public Member Functions

 AgentXSearchRange ()
 Default constructor.
 
 AgentXSearchRange (const Oidx &, const Oidx &, bool=FALSE)
 Create a SearchRange with a given lower and a upper bound, optionally define the lower bound as inclusive or exclusive.
 
 AgentXSearchRange (const AgentXSearchRange &)
 Copy constructor.
 
 AgentXSearchRange (const OidxRange &)
 Copy constructor from OidxRange.
 
virtual ~AgentXSearchRange ()
 Destructor.
 
virtual AgentXSearchRangeclone () const
 Clone.
 
virtual AgentXSearchRangeoperator= (const AgentXSearchRange &)
 
virtual bool operator== (const AgentXSearchRange &) const
 Compare the receiver with another OID range for equality.
 
virtual bool operator< (const AgentXSearchRange &) const
 Compare the receiver with another OID range.
 
virtual bool operator> (const AgentXSearchRange &) const
 Compare the receiver with another OID range.
 
void set_include (bool inc)
 Set whether the lower bound is included or not.
 
virtual bool includes (const Oidx &) const
 Check whether an OID is within the receiver's range.
 
virtual bool includes_excl (const Oidx &) const
 Check whether an OID is within the receiver's range.
 
virtual bool is_lower_included () const
 Check whether the lower bound is is itself included or excluded from the search range.
 
void no_upper_bound ()
 Unset upper bound.
 
bool is_unbounded ()
 Return TRUE if search range has no upper bound.
 
void set_reference (int ref)
 Set the reference to a SNMP subrequest index.
 
int get_reference () const
 Get the reference for the receiver.
 
Oidx get_lower () const
 Get the lower bound.
 
Oidx get_upper () const
 Get the upper bound.
 

Protected Attributes

OidxRange range
 
bool include
 
int reference
 

Detailed Description

The AgentXSearchRange class represents an item in an AgentX SearchRangeList.

Author
Frank Fock
Version
1.0

Constructor & Destructor Documentation

AgentXSearchRange::AgentXSearchRange ( )

Default constructor.

AgentXSearchRange::AgentXSearchRange ( const Oidx &  ,
const Oidx &  ,
bool  = FALSE 
)

Create a SearchRange with a given lower and a upper bound, optionally define the lower bound as inclusive or exclusive.

Parameters
lowerthe lower bound of the search range
upperthe upper bound of the search range
includeLowerif TRUE the lower bound is included in the search range, otherwise it is excluded.
AgentXSearchRange::AgentXSearchRange ( const AgentXSearchRange )

Copy constructor.

Parameters
otheranother SearchRange
AgentXSearchRange::AgentXSearchRange ( const OidxRange &  )

Copy constructor from OidxRange.

Parameters
otheran OidxRange instance
virtual AgentXSearchRange::~AgentXSearchRange ( )
virtual

Destructor.

Member Function Documentation

virtual AgentXSearchRange* AgentXSearchRange::clone ( ) const
virtual

Clone.

Returns
a pointer to a clone of the receiver.
Oidx AgentXSearchRange::get_lower ( ) const
inline

Get the lower bound.

Returns
a Oidx specifying the lower bound of the search range.
int AgentXSearchRange::get_reference ( ) const
inline

Get the reference for the receiver.

Returns
an index into a SNMP request PDU.
Oidx AgentXSearchRange::get_upper ( ) const
inline

Get the upper bound.

Returns
a Oidx specifying the upper bound of the search range.
virtual bool AgentXSearchRange::includes ( const Oidx &  ) const
virtual

Check whether an OID is within the receiver's range.

Parameters
oidan object identifier
Returns
TRUE if oid is greater or equal to the receiver's lower bound and less or equal to its upper bound.
virtual bool AgentXSearchRange::includes_excl ( const Oidx &  ) const
virtual

Check whether an OID is within the receiver's range.

Parameters
oidan object identifier
Returns
TRUE if oid is greater as the receiver's lower bound and less than its upper bound.
virtual bool AgentXSearchRange::is_lower_included ( ) const
inlinevirtual

Check whether the lower bound is is itself included or excluded from the search range.

Returns
TRUE if the lower bound is included
bool AgentXSearchRange::is_unbounded ( )
inline

Return TRUE if search range has no upper bound.

Returns
TRUE if the receiver has no upper bound, FALSE otherwise.
void AgentXSearchRange::no_upper_bound ( )
inline

Unset upper bound.

virtual bool AgentXSearchRange::operator< ( const AgentXSearchRange ) const
virtual

Compare the receiver with another OID range.

Parameters
otheranother OidxRange instance
Returns
TRUE if the upper bound of the receiver is less than the lower bound of other
virtual AgentXSearchRange& AgentXSearchRange::operator= ( const AgentXSearchRange )
virtual
virtual bool AgentXSearchRange::operator== ( const AgentXSearchRange ) const
virtual

Compare the receiver with another OID range for equality.

Parameters
otheranother OidxRange instance
Returns
TRUE if lower and upper bounds of both OID ranges are equal
virtual bool AgentXSearchRange::operator> ( const AgentXSearchRange ) const
virtual

Compare the receiver with another OID range.

Parameters
otheranother OidxRange instance
Returns
TRUE if the lower bound of the receiver is greater than the upper bound of other
void AgentXSearchRange::set_include ( bool  inc)
inline

Set whether the lower bound is included or not.

Parameters
includeif TRUE, the lower bound is included in the search range, if FALSE, the lower bound is excluded.
void AgentXSearchRange::set_reference ( int  ref)
inline

Set the reference to a SNMP subrequest index.

Parameters
indexan index into a SNMP request PDU.

Member Data Documentation

bool AgentXSearchRange::include
protected
OidxRange AgentXSearchRange::range
protected
int AgentXSearchRange::reference
protected

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