SnmpDisplayString Class Reference

The class snmpDisplayString implements the textual convention DisplayString. More...

#include <snmp_textual_conventions.h>

Inheritance diagram for SnmpDisplayString:

MibLeaf MibEntry ThreadManager Synchronized sysDescr

List of all members.

Public Member Functions

 SnmpDisplayString (const Oidx &, mib_access, NS_SNMP OctetStr *)
 Construct a DisplayString with initial value.
 SnmpDisplayString (const Oidx &, mib_access, NS_SNMP OctetStr *, boolean)
 Construct a DisplayString with initial value.
 SnmpDisplayString (const Oidx &, mib_access, NS_SNMP OctetStr *, boolean, int, int)
 Construct a DisplayString with initial value.
virtual ~SnmpDisplayString ()
virtual MibEntryPtr clone ()
 Clone the receiver object.
virtual boolean value_ok (const Vbx &)
 Check whether the receiver's value may be set to the given new value.
virtual int prepare_set_request (Request *, int &)
 Let the receiver prepare a SNMP SET subrequest.

Protected Attributes

unsigned int max_size
unsigned int min_size


Detailed Description

The class snmpDisplayString implements the textual convention DisplayString.

It may also be used to implement the SnmpAdminString textual convention.

Author:
Frank Fock
Version:
3.2

Constructor & Destructor Documentation

SnmpDisplayString::SnmpDisplayString ( const Oidx ,
mib_access  ,
NS_SNMP OctetStr *   
)

Construct a DisplayString with initial value.

Parameters:
oid the oid of the leaf or the column of the columnar object.
access the max-access rights for the object.
octetstr a pointer to an OctetStr containing the initial value for the object.

SnmpDisplayString::SnmpDisplayString ( const Oidx ,
mib_access  ,
NS_SNMP OctetStr *  ,
boolean   
)

Construct a DisplayString with initial value.

Parameters:
oid the oid of the leaf or the column of the columnar object.
access the max-access rights for the object.
octetstr a pointer to an OctetStr containing the initial value for the object.
hasdefault if TRUE treat the inital value as default value (this applies to columnar objects only)

SnmpDisplayString::SnmpDisplayString ( const Oidx ,
mib_access  ,
NS_SNMP OctetStr *  ,
boolean  ,
int  ,
int   
)

Construct a DisplayString with initial value.

Parameters:
oid the oid of the leaf or the column of the columnar object.
access the max-access rights for the object.
octetstr a pointer to an OctetStr containing the initial value for the object.
hasdefault if TRUE treat the inital value as default value (this applies to columnar objects only)
min_size the minimum size of the DisplayString.
max_size the maxmimum size of the DisplayString.

virtual SnmpDisplayString::~SnmpDisplayString (  )  [virtual]


Member Function Documentation

virtual MibEntryPtr SnmpDisplayString::clone (  )  [virtual]

Clone the receiver object.

Returns:
A pointer to the clone.

Reimplemented from MibLeaf.

virtual boolean SnmpDisplayString::value_ok ( const Vbx  )  [virtual]

Check whether the receiver's value may be set to the given new value.

Note:
Override this mehtod in subclasses.
Parameters:
v - A new value.
Returns:
TRUE if the new value is valid, otherwise FALSE.

Reimplemented from MibLeaf.

virtual int SnmpDisplayString::prepare_set_request ( Request ,
int &   
) [virtual]

Let the receiver prepare a SNMP SET subrequest.

Parameters:
req - A pointer to the whole SNMP SET request.
ind - The index of the subrequest to be processed.
Returns:
SNMP_ERROR_SUCCESS on success and SNMP_ERROR_WRONG_VALUE, SNMP_ERROR_WRONG_TYPE, or SNMP_ERROR_NOT_WRITEABLE on failure.

Reimplemented from MibLeaf.


Member Data Documentation

unsigned int SnmpDisplayString::max_size [protected]

unsigned int SnmpDisplayString::min_size [protected]


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

Generated on Fri May 29 22:36:55 2009 for AGENT++ by  doxygen 1.5.6