[ Previous | Next | Contents | Glossary | Home | Search ]
AIX Version 4.3 Communications Technical Reference, Volume 2

oid_extend or oid_normalize Subroutine

Purpose

Extends the base ISODE library subroutines.

Library

SNMP Library (libsnmp.a)

Syntax

#include <isode/snmp/objects.h>
OID oid_extend (q, howmuch) 
OID q;
integer howmuch;
OID oid_normalize (q, howmuch, initial)
OID q;
integer howmuch, initial;

Description

The oid_extend subroutine is used to extend the current object identifier data (OID) structure. The OID structure contains an integer number of entries and an array of integers. The oid_extend subroutine creates a new, extended OID structure with an array of the size specified in the howmuch parameter plus the original array size specified in the q parameter. The original values are copied into the first entries of the new structure. The new values are uninitialized. The entries of the OID structure are used to represent the values of an Management Information Base (MIB) tree in dot notation. Each entry represents a level in the MIB tree.

The oid_normalize subroutine extends and adjusts the values of the OID structure entries. The oid_normalize subroutine extends the OID structure and then decrements all nonzero values by 1. The new values are initialized to the value of the initial parameter. This subroutine stores network address and netmask information in the OID structure.

These subroutines do not free the q parameter.

Parameters

q Specifies the size of the original array.
howmuch Specifies the size of the array for the new OID structure.
initial Indicates the initialized value of the OID structure extensions.

Return Values

Both subroutines, when successful, return the pointer to the new object identifier structure. If the subroutines fail, the NULLOID value is returned.

Implementation Specifics

These subroutines are part of the SNMP Application Programming Interface in the TCP/IP facility.

Related Information

The oid_cmp, oid_cpy, oid_free, sprintoid, str2oid, ode2oid, oid2ode, oid2ode_aux, prim2oid, or oid2prim subroutine.

List of Network Manager Programming References.

SNMP Overview for Programmers in AIX Version 4.3 Communications Programming Concepts.


[ Previous | Next | Contents | Glossary | Home | Search ]