smi

package
v0.4.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 18, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultErrorLevel   = 3
	DefaultGlobalConfig = "/etc/smi.conf"
	DefaultUserConfig   = ".smirc"
)

Variables

View Source
var DefaultSmiPaths []string = []string{
	"/usr/local/share/mibs/ietf",
	"/usr/local/share/mibs/iana",
	"/usr/local/share/mibs/irtf",
	"/usr/local/share/mibs/site",
	"/usr/local/share/mibs/jacobs",
	"/usr/local/share/mibs/tubs",
}

Functions

func AppendFS

func AppendFS(fs ...NamedFS)

func Exit

func Exit()

void smiExit(void)

func GetElementNode

func GetElementNode(smiElementPtr *types.SmiElement) *types.SmiNode

SmiNode *smiGetElementNode(SmiElement *smiElementPtr)

func GetFirstChildNode

func GetFirstChildNode(smiNodePtr *types.SmiNode) *types.SmiNode

SmiNode *smiGetFirstChildNode(SmiNode *smiNodePtr)

func GetFirstElement

func GetFirstElement(smiNodePtr *types.SmiNode) *types.SmiElement

SmiElement *smiGetFirstElement(SmiNode *smiNodePtr)

func GetFirstImport

func GetFirstImport(smiModulePtr *types.SmiModule) *types.SmiImport

SmiImport *smiGetFirstImport(SmiModule *smiModulePtr)

func GetFirstMacro

func GetFirstMacro(smiModulePtr *types.SmiModule) *types.SmiMacro

SmiMacro *smiGetFirstMacro(SmiModule *smiModulePtr)

func GetFirstModule

func GetFirstModule() *types.SmiModule

SmiModule *smiGetFirstModule(void)

func GetFirstNamedNumber

func GetFirstNamedNumber(smiTypePtr *types.SmiType) *types.SmiNamedNumber

SmiNamedNumber *smiGetFirstNamedNumber(SmiType *smiTypePtr)

func GetFirstNode

func GetFirstNode(smiModulePtr *types.SmiModule, nodekind types.NodeKind) *types.SmiNode

SmiNode *smiGetFirstNode(SmiModule *smiModulePtr, SmiNodekind nodekind)

func GetFirstOption

func GetFirstOption(smiComplianceNodePtr *types.SmiNode) *types.SmiOption

SmiOption *smiGetFirstOption(SmiNode *smiComplianceNodePtr)

func GetFirstRange

func GetFirstRange(smiTypePtr *types.SmiType) *types.SmiRange

SmiRange *smiGetFirstRange(SmiType *smiTypePtr)

func GetFirstRefinement

func GetFirstRefinement(smiComplianceNodePtr *types.SmiNode) *types.SmiRefinement

SmiRefinement *smiGetFirstRefinement(SmiNode *smiComplianceNodePtr)

func GetFirstRevision

func GetFirstRevision(smiModulePtr *types.SmiModule) *types.SmiRevision

SmiRevision *smiGetFirstRevision(SmiModule *smiModulePtr)

func GetFirstType

func GetFirstType(smiModulePtr *types.SmiModule) *types.SmiType

SmiType *smiGetFirstType(SmiModule *smiModulePtr)

func GetFlags

func GetFlags() int

int smiGetFlags(void)

func GetMacro

func GetMacro(smiModulePtr *types.SmiModule, macro string) *types.SmiMacro

SmiMacro *smiGetMacro(SmiModule *smiModulePtr, char *macro)

func GetMacroLine

func GetMacroLine(smiMacroPtr *types.SmiMacro) int

int smiGetMacroLine(SmiMacro *smiMacroPtr)

func GetMacroModule

func GetMacroModule(smiMacroPtr *types.SmiMacro) *types.SmiModule

SmiModule *smiGetMacroModule(SmiMacro *smiMacroPtr)

func GetMinMaxRange

func GetMinMaxRange(smiType *types.SmiType) *types.SmiRange

int smiGetMinMaxRange(SmiType *smiType, SmiValue *min, SmiValue *max)

func GetModule

func GetModule(module string) *types.SmiModule

SmiModule *smiGetModule(const char *module)

func GetModuleIdentityNode

func GetModuleIdentityNode(smiModulePtr *types.SmiModule) *types.SmiNode

SmiNode *smiGetModuleIdentityNode(SmiModule *smiModulePtr)

func GetNextChildNode

func GetNextChildNode(smiNodePtr *types.SmiNode) *types.SmiNode

SmiNode *smiGetNextChildNode(SmiNode *smiNodePtr)

func GetNextElement

func GetNextElement(smiElementPtr *types.SmiElement) *types.SmiElement

SmiElement *smiGetNextElement(SmiElement *smiElementPtr)

func GetNextImport

func GetNextImport(smiImportPtr *types.SmiImport) *types.SmiImport

SmiImport *smiGetNextImport(SmiImport *smiImportPtr)

func GetNextMacro

func GetNextMacro(smiMacroPtr *types.SmiMacro) *types.SmiMacro

SmiMacro *smiGetNextMacro(SmiMacro *smiMacroPtr)

func GetNextModule

func GetNextModule(smiModulePtr *types.SmiModule) *types.SmiModule

SmiModule *smiGetNextModule(SmiModule *smiModulePtr)

func GetNextNamedNumber

func GetNextNamedNumber(smiNamedNumberPtr *types.SmiNamedNumber) *types.SmiNamedNumber

SmiNamedNumber *smiGetNextNamedNumber(SmiNamedNumber *smiNamedNumberPtr)

func GetNextNode

func GetNextNode(smiNodePtr *types.SmiNode, nodekind types.NodeKind) *types.SmiNode

SmiNode *smiGetNextNode(SmiNode *smiNodePtr, SmiNodekind nodekind)

func GetNextOption

func GetNextOption(smiOptionPtr *types.SmiOption) *types.SmiOption

SmiOption *smiGetNextOption(SmiOption *smiOptionPtr)

func GetNextRange

func GetNextRange(smiRangePtr *types.SmiRange) *types.SmiRange

SmiRange *smiGetNextRange(SmiRange *smiRangePtr)

func GetNextRefinement

func GetNextRefinement(smiRefinementPtr *types.SmiRefinement) *types.SmiRefinement

SmiRefinement *smiGetNextRefinement(SmiRefinement *smiRefinementPtr)

func GetNextRevision

func GetNextRevision(smiRevisionPtr *types.SmiRevision) *types.SmiRevision

SmiRevision *smiGetNextRevision(SmiRevision *smiRevisionPtr)

func GetNextType

func GetNextType(smiTypePtr *types.SmiType) *types.SmiType

SmiType *smiGetNextType(SmiType *smiTypePtr)

func GetNode

func GetNode(smiModulePtr *types.SmiModule, name string) *types.SmiNode

SmiNode *smiGetNode(SmiModule *smiModulePtr, const char *name)

func GetNodeByOID

func GetNodeByOID(oid types.Oid) *types.SmiNode

SmiNode *smiGetNodeByOID(unsigned int oidlen, SmiSubid oid[])

func GetNodeLine

func GetNodeLine(smiNodePtr *types.SmiNode) int

int smiGetNodeLine(SmiNode *smiNodePtr)

func GetNodeModule

func GetNodeModule(smiNodePtr *types.SmiNode) *types.SmiModule

SmiModule *smiGetNodeModule(SmiNode *smiNodePtr)

func GetNodeType

func GetNodeType(smiNodePtr *types.SmiNode) *types.SmiType

SmiType *smiGetNodeType(SmiNode *smiNodePtr)

func GetOptionLine

func GetOptionLine(smiOptionPtr *types.SmiOption) int

int smiGetOptionLine(SmiOption *smiOptionPtr)

func GetOptionNode

func GetOptionNode(smiOptionPtr *types.SmiOption) *types.SmiNode

SmiNode *smiGetOptionNode(SmiOption *smiOptionPtr)

func GetParentNode

func GetParentNode(smiNodePtr *types.SmiNode) *types.SmiNode

SmiNode *smiGetParentNode(SmiNode *smiNodePtr)

func GetParentType

func GetParentType(smiTypePtr *types.SmiType) *types.SmiType

SmiType *smiGetParentType(SmiType *smiTypePtr)

func GetPath

func GetPath() string

char *smiGetPath(void)

func GetRefinementLine

func GetRefinementLine(smiRefinementPtr *types.SmiRefinement) int

int smiGetRefinementLine(SmiRefinement *smiRefinementPtr)

func GetRefinementNode

func GetRefinementNode(smiRefinementPtr *types.SmiRefinement) *types.SmiNode

SmiNode *smiGetRefinementNode(SmiRefinement *smiRefinementPtr)

func GetRefinementType

func GetRefinementType(smiRefinementPtr *types.SmiRefinement) *types.SmiType

SmiType *smiGetRefinementType(SmiRefinement *smiRefinementPtr)

func GetRefinementWriteType

func GetRefinementWriteType(smiRefinementPtr *types.SmiRefinement) *types.SmiType

SmiType *smiGetRefinementWriteType(SmiRefinement *smiRefinementPtr)

func GetRelatedNode

func GetRelatedNode(smiNodePtr *types.SmiNode) *types.SmiNode

SmiNode *smiGetRelatedNode(SmiNode *smiNodePtr)

func GetRevisionLine

func GetRevisionLine(smiRevisionPtr *types.SmiRevision) int

int smiGetRevisionLine(SmiRevision *smiRevisionPtr)

func GetType

func GetType(smiModulePtr *types.SmiModule, typeName string) *types.SmiType

SmiType *smiGetType(SmiModule *smiModulePtr, char *type)

func GetTypeLine

func GetTypeLine(smiTypePtr *types.SmiType) int

int smiGetTypeLine(SmiType *smiTypePtr)

func GetTypeModule

func GetTypeModule(smiTypePtr *types.SmiType) *types.SmiModule

SmiModule *smiGetTypeModule(SmiType *smiTypePtr)

func Init

func Init(tag ...string) bool

int smiInit(const char *tag)

func IsImported

func IsImported(smiModulePtr *types.SmiModule, importedModulePtr *types.SmiModule, importedName string) bool

int smiIsImported(SmiModule *smiModulePtr, SmiModule *importedModulePtr, char *importedName)

func IsLoaded

func IsLoaded(module string) bool

int smiIsLoaded(const char *module)

func LoadModule

func LoadModule(module string) (string, error)

char *smiLoadModule(const char *module)

func PrependFS

func PrependFS(fs ...NamedFS)

func ReadConfig

func ReadConfig(filename string, tag ...string) error

int smiReadConfig(const char *filename, const char *tag)

func RenderNode

func RenderNode(smiNodePtr *types.SmiNode, flags types.Render) string

func RenderOID

func RenderOID(oid types.Oid, flags types.Render) string

func SetErrorHandler

func SetErrorHandler(smiErrorHandler types.SmiErrorHandler)

void smiSetErrorHandler(SmiErrorHandler smiErrorHandler)

func SetErrorLevel

func SetErrorLevel(level int)

void smiSetErrorLevel(int level)

func SetFS

func SetFS(fs ...NamedFS)

func SetFlags

func SetFlags(userflags int)

void smiSetFlags(int userflags)

func SetPath

func SetPath(path string)

int smiSetPath(const char *path)

func SetSeverity

func SetSeverity(pattern string, severity int)

void smiSetSeverity(char *pattern, int severity)

Types

type FS

type FS = internal.FS

type NamedFS

type NamedFS = internal.NamedFS

func NewNamedFS

func NewNamedFS(name string, fs FS) NamedFS

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL