1smi_class(3)          SMI Management Information Library          smi_class(3)
2
3
4

NAME

6       smiGetClass   smiGetFirstClass,   smiGetNextClass,   smiGetClassModule,
7       smiGetParentClass, smiIsClassScalar - SMI class information routines
8

SYNOPSIS

10       #include <smi.h>
11
12       SmiClass *smiGetClass(SmiModule *smiModulePtr, char *name);
13
14       SmiClass *smiGetFirstClass(SmiModule *smiModulePtr);
15
16       SmiClass *smiGetNextClass(SmiClass *smiClassPtr);
17
18       SmiClass *smiGetParentClass(SmiClass *smiClassPtr);
19
20       SmiModule *smiGetClassModule(SmiClass *smiClassPtr);
21
22       int smiIsClassScalar(SmiClass *smiClassPtr);
23
24       typedef struct SmiClass {
25           SmiIdentifier       name;
26           SmiDecl             decl;
27           SmiStatus           status;
28           char                *description;
29           char                *reference;
30       } SmiClass;
31
32

DESCRIPTION

34       These functions  retrieve  information  on  a  SMIng  class  definition
35       (SMIng).
36
37       smiGetClass(SmiModule  *smiModulePtr,char  *name)  returns a pointer to
38       struct SmiClass that represents the class with the given  name  in  the
39       given  module(smiModulePtr  ), or NULL if the class with the given name
40       does not exist.
41
42       smiGetFirstClass(SmiModule *smiModulePtr) and  smiGetNextClass(SmiClass
43       *smiClassPtr)  are  used  to  iterate through the classes of the module
44       given by smiModulePtr. They return a pointer to  struct  SmiClass  that
45       represents  a class or NULL if there are no classes left in the module,
46       or error has occurred.
47
48       smiGetClassModule(SmiClass *smiClassPtr) returns a  pointer  to  struct
49       SmiModule, of the module containing the given class.
50
51       smiGetParentClass(SmiClass  *smiClassPtr)  returns  a pointer to struct
52       SmiClass pointing to the parent of the given smiClassPtr,  or  NULL  if
53       the class is not derived.
54
55       smiIsClassScalar(SmiClass  *smiClassPtr)  returns int 1 if the class is
56       scalar(its unique statement contains an empty  list)  or  0  otherwise.
57       This  method  can  be  used  in  conjunction  with smiGetFirstUniqueAt‐
58       tribute() to determine whether the class is meant  to  be  instantiated
59       separately (has unique statement with nonempty list), or if it is meant
60       to be used as part of another class (has no unique statement).
61

FILES

63       /usr/include/smi.h    SMI library header file
64

SEE ALSO

66       libsmi(3), smi_module(3), smi.h
67

AUTHOR

69       (C) 2007 Kaloyan Kanev, Jacobs University, Germany <k.kanev@jacobs-uni‐
70       versity.de>
71
72
73
74                               February 10, 2007                  smi_class(3)
Impressum