Pragmas can be used in dynamic model files to convey SNMP MIB qualities, and other directives, to the dynamic model compiler. Pragmas used in dynamic modeling lists the available pragmas.

Table 1. Pragmas used in dynamic modeling

Pragma

Description

#pragma DotNotation

Specifies that an SNMP instrumented attribute is to be converted from dotted notation when retrieved from an SNMP agent.

#pragma HexNotation

Specifies that an SNMP instrumented attribute is to be converted from hex notation when retrieved from an SNMP agent.

#pragma Local Operation

Locks only the object on which the operation is invoked. Normally, the dynamic model compiler generates code so that invoking an operation implicitly locks the entire repository.

#pragma ObjectID

Appears before an instrumented attribute declaration of type string whose value is the OID of an SNMP device. This pragma tells the repository to convert the OID type returned by the SNMP agent into a MODEL string.

#pragma Uses Propagation

Must appear before the attribute declaration to which it applies. This pragma tells the dynamic model compiler that access to this attribute may require access to other repository instances. Use this pragma before any attribute that can be refined as propagated or as computed with an expression that refers to other propagated attributes. This pragma locks the entire repository, however, the lock type (read/write) will be according to the type of operation called on the attribute. For example, if you are setting the value of an attribute, it will be a write lock.

#pragma WrapCounter

Specifies that an SNMP instrumented attribute is to be treated as a wrapping counter, which affects comparisons of previous and current values.