Blame lib/smi_render.3

Packit Service 9ccfef
.\"
Packit Service 9ccfef
.\" $Id: smi_render.3.in 1432 2002-07-24 11:54:18Z strauss $
Packit Service 9ccfef
.\"
Packit Service 9ccfef
.TH smi_render 3  "July 24, 2002" "IBR" "SMI Management Information Library"
Packit Service 9ccfef
.SH NAME
Packit Service 9ccfef
.\" START OF MAN PAGE COPIES
Packit Service 9ccfef
smiRenderOID,
Packit Service 9ccfef
smiRenderValue,
Packit Service 9ccfef
smiRenderNode,
Packit Service 9ccfef
smiRenderType
Packit Service 9ccfef
.\" END OF MAN PAGE COPIES
Packit Service 9ccfef
\- SMI data and MIB data rendering routines
Packit Service 9ccfef
.SH SYNOPSIS
Packit Service 9ccfef
.nf
Packit Service 9ccfef
.B #include <smi.h>
Packit Service 9ccfef
.RS
Packit Service 9ccfef
.RE
Packit Service 9ccfef
.sp
Packit Service 9ccfef
.BI 
Packit Service 9ccfef
.RE
Packit Service 9ccfef
.sp
Packit Service 9ccfef
.BI "char *smiRenderOID(unsigned int " oidlen ", SmiSubid *" oid ", int " flags );
Packit Service 9ccfef
.RE
Packit Service 9ccfef
.sp
Packit Service 9ccfef
.BI "char *smiRenderValue(SmiValue *" smiValuePtr ", SmiType *" smiTypePtr ", int " flags );
Packit Service 9ccfef
.RE
Packit Service 9ccfef
.sp
Packit Service 9ccfef
.BI "char *smiRenderNode(SmiNode *" smiNodePtr ", int " flags );
Packit Service 9ccfef
.RE
Packit Service 9ccfef
.sp
Packit Service 9ccfef
.BI "char *smiRenderType(SmiType *" smiTypePtr ", int " flags );
Packit Service 9ccfef
.RE
Packit Service 9ccfef
.SH DESCRIPTION
Packit Service 9ccfef
These functions provide can be used to render OIDs, values of MIB data,
Packit Service 9ccfef
or names of MIB nodes or types.
Packit Service 9ccfef
.PP
Packit Service 9ccfef
The \fBsmiRenderOID()\fP function renders an OID given by its
Packit Service 9ccfef
length \fIoidlen\fP and its array of sub-identifiers \fIoid*\fP. 
Packit Service 9ccfef
The \fIflags\fP can be used to control the resulting format, see FORMATS below.
Packit Service 9ccfef
.PP
Packit Service 9ccfef
The \fBsmiRenderValue()\fP function renders a MIB data value given by 
Packit Service 9ccfef
\fIsmiValuePtr\fP. An underlying type \fIsmiTypePtr\fP may be supplied
Packit Service 9ccfef
to support a more human friendly rendering.
Packit Service 9ccfef
The \fIflags\fP can be used to control the resulting format, see FORMATS below.
Packit Service 9ccfef
.PP
Packit Service 9ccfef
The \fBsmiRenderNode()\fP function renders the name of a node given
Packit Service 9ccfef
by \fIsmiNodePtr\fP.
Packit Service 9ccfef
The \fIflags\fP can be used to control the resulting format, see FORMATS below.
Packit Service 9ccfef
.PP
Packit Service 9ccfef
The \fBsmiRenderType()\fP function renders the name of a type given
Packit Service 9ccfef
by \fIsmiTypePtr\fP.
Packit Service 9ccfef
The \fIflags\fP can be used to control the resulting format, see FORMATS below.
Packit Service 9ccfef
.SH "FORMATS"
Packit Service 9ccfef
Each of these functions gets a last argument named \fIflags\fP. This is
Packit Service 9ccfef
a logcially or-ed set of flags that can be used to control the format
Packit Service 9ccfef
of the rendered items:
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_NUMERIC
Packit Service 9ccfef
Allow numeric representation (default).
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_NAME
Packit Service 9ccfef
Allow a representation by name(s) if possible.
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_QUALIFIED
Packit Service 9ccfef
In case of a name representation, force a module prefix, e.g. IF-MIB::ifIndex
Packit Service 9ccfef
instead of just ifIndex.
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_FORMAT
Packit Service 9ccfef
In case of \fIsmiRenderValue()\fP, force the application of a format
Packit Service 9ccfef
specification (e.g. an SMIv2 DISPLAY-HINT) of an underlying type if
Packit Service 9ccfef
the \fIsmiTypePtr\fP argument is not NULL and this type contains such a
Packit Service 9ccfef
format specification.
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_PRINTABLE
Packit Service 9ccfef
In case of octet string value rendering, force a printable representation
Packit Service 9ccfef
if all octets of the octet string are printable.
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_UNKNOWN
Packit Service 9ccfef
Force the return of a string containing SMI_LABEL_UNKNOWN ("<unknown>"),
Packit Service 9ccfef
if the rendering would fail. This way, the only condition where NULL can
Packit Service 9ccfef
be returned is the lack of memory.
Packit Service 9ccfef
.TP
Packit Service 9ccfef
\fBSMI_RENDER_ALL
Packit Service 9ccfef
Apply a combination of all these flags. This supports the (hopefully) most
Packit Service 9ccfef
human friendly representations.
Packit Service 9ccfef
.SH "RETURN VALUE"
Packit Service 9ccfef
All of these functions return a string, if successful, or NULL in case
Packit Service 9ccfef
of a rendering failure. See also the \fBSMI_RENDER_UNKNOWN\fP flag above.
Packit Service 9ccfef
.SH "SEE ALSO"
Packit Service 9ccfef
.BR libsmi "(3), "
Packit Service 9ccfef
.BR smi.h
Packit Service 9ccfef
.SH "AUTHOR"
Packit Service 9ccfef
(C) 2002 Frank Strauss, TU Braunschweig, Germany <strauss@ibr.cs.tu-bs.de>
Packit Service 9ccfef
.br