VxWorks API Reference : OS Libraries

wvNetLib

NAME

wvNetLib - WindView for Networking Interface Library

ROUTINES

wvNetEnable( ) - begin reporting network events to WindView
wvNetDisable( ) - end reporting of network events to WindView
wvNetLevelAdd( ) - enable network events with specific priority level
wvNetLevelRemove( ) - disable network events with specific priority level
wvNetEventEnable( ) - activate specific network events
wvNetEventDisable( ) - deactivate specific network events
wvNetAddressFilterSet( ) - specify an address filter for events
wvNetAddressFilterClear( ) - remove the address filter for events
wvNetPortFilterSet( ) - specify an address filter for events
wvNetPortFilterClear( ) - remove the port number filter for events

DESCRIPTION

This library provides the user interface to the network-related events for the WindView system visualization tool. These events are divided into two WindView classes. The NET_CORE_EVENT class indicates events directly related to data transfer. All other events (such as memory allocation and API routines) use the NET_AUX_EVENT class. Within each class, events are assigned one of eight priority levels. The four highest priority levels (EMERGENCY, ALERT, CRITICAL, and ERROR) indicate the occurrence of errors and the remaining four (WARNING, NOTICE, INFO, and VERBOSE) provide progressively more detailed information about the internal processing in the network stack.

USER INTERFACE

If WindView support is included, the wvNetStart( ) and wvNetStop( ) routines will enable and disable event reporting for the network stack. The start routine takes a single parameter specifying the minimum priority level for all network components. That setting may be modified with the wvNetLevelAdd( ) and wvNetLevelRemove( ) routines. Individual events may be included or removed with the wvNetEventEnable( ) and wvNetDisable( ) routines.

The wvNetAddressFilterSet( ) and wvNetPortFilterSet( ) routines provide further screening for some events.

INCLUDE FILES

SEE ALSO

WindView for Tornado User's Guide


OS Libraries : Routines

wvNetEnable( )

NAME

wvNetEnable( ) - begin reporting network events to WindView

SYNOPSIS

void wvNetEnable
    (
    int priority              /* minimum priority, or 0 for default of */
                              /* WV_NET_VERBOSE */ 
    )

DESCRIPTION

This routine activates WindView event reporting for network components, after disabling all events with a priority less than level. The default value (or a level of WV_NET_VERBOSE) will not disable any additional events. The available priority values are:

    WV_NET_EMERGENCY (1)
    WV_NET_ALERT (2)
    WV_NET_CRITICAL (3)
    WV_NET_ERROR (4)
    WV_NET_WARNING (5)
    WV_NET_NOTICE (6)
    WV_NET_INFO (7)
    WV_NET_VERBOSE (8)

If an event is not explicitly disabled by the priority level, it uses the current event selection map and class settings. The initial values enable all events of both classes.

RETURNS

N/A

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetDisable( )

NAME

wvNetDisable( ) - end reporting of network events to WindView

SYNOPSIS

void wvNetDisable (void)

DESCRIPTION

This routine stops WindView event reporting for all network components.

RETURNS

N/A

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetLevelAdd( )

NAME

wvNetLevelAdd( ) - enable network events with specific priority level

SYNOPSIS

STATUS wvNetLevelAdd
    (
    int priority              /* priority level to enable */
    )

DESCRIPTION

This routine changes the event selection map to allow reporting of any events with priority equal to level. It will override current event selections for the given priority, but has no effect on settings for events with higher or lower priorities. The available priority values are:

    WV_NET_EMERGENCY (1)
    WV_NET_ALERT (2)
    WV_NET_CRITICAL (3)
    WV_NET_ERROR (4)
    WV_NET_WARNING (5)
    WV_NET_NOTICE (6)
    WV_NET_INFO (7)
    WV_NET_VERBOSE (8)

Events are only reported based on the current WindView class setting. The initial (default) setting includes networking events from both classes.

RETURNS

OK, or ERROR for unknown event level.

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetLevelRemove( )

NAME

wvNetLevelRemove( ) - disable network events with specific priority level

SYNOPSIS

STATUS wvNetLevelRemove
    (
    int priority              /* priority level to disable */
    )

DESCRIPTION

This routine changes the event selection map to prevent reporting of any events with priority equal to level. It will override the current event selection for the given priority, but has no effect on settings for events with higher or lower priorities. The available priority values are:

    WV_NET_EMERGENCY (1)
    WV_NET_ALERT (2)
    WV_NET_CRITICAL (3)
    WV_NET_ERROR (4)
    WV_NET_WARNING (5)
    WV_NET_NOTICE (6)
    WV_NET_INFO (7)
    WV_NET_VERBOSE (8)

Events are only reported based on the current WindView class setting. The initial (default) setting includes networking events from both classes.

RETURNS

OK, or ERROR for unknown event level.

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetEventEnable( )

NAME

wvNetEventEnable( ) - activate specific network events

SYNOPSIS

STATUS wvNetEventEnable
    (
    int priority,             /* priority level of event */
    int offset                /* identifier within priority level */
    )

DESCRIPTION

This routine allows reporting of a single event within the priority equal to level. The activation is overridden if the setting for the entire priority level changes. The available priority values are:

    WV_NET_EMERGENCY (1)
    WV_NET_ALERT (2)
    WV_NET_CRITICAL (3)
    WV_NET_ERROR (4)
    WV_NET_WARNING (5)
    WV_NET_NOTICE (6)
    WV_NET_INFO (7)
    WV_NET_VERBOSE (8)

Offset values for individual events are listed in the documentation.

RETURNS

OK, or ERROR for unknown event.

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetEventDisable( )

NAME

wvNetEventDisable( ) - deactivate specific network events

SYNOPSIS

STATUS wvNetEventDisable
    (
    int priority,             /* priority level of event */
    int offset                /* identifier within priority level */
    )

DESCRIPTION

This routine prevents reporting of a single event within the priority equal to level. The activation is overridden if the setting for the entire priority level changes. The available priority values are:

    WV_NET_EMERGENCY (1)
    WV_NET_ALERT (2)
    WV_NET_CRITICAL (3)
    WV_NET_ERROR (4)
    WV_NET_WARNING (5)
    WV_NET_NOTICE (6)
    WV_NET_INFO (7)
    WV_NET_VERBOSE (8)

Offset values for individual events are listed in the documentation.

RETURNS

OK, or ERROR for unknown event.

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetAddressFilterSet( )

NAME

wvNetAddressFilterSet( ) - specify an address filter for events

SYNOPSIS

STATUS wvNetAddressFilterSet
    (
    char * pAddress,          /* target address for event comparisons */
    char * pMask,             /* mask value applied to data fields */
    int    type,              /* 0 for source, 1 for destination */
    int    direction          /* 0 for input, 1 for output */
    )

DESCRIPTION

This routine activates an additional test that disables certain events that do not match the specified IP address. The pAddress parameter provides the test value in dotted-decimal format. The type parameter indicates whether that address is compared against the source or destination values, and the direction value identifies whether the type is interpreted from the perspective of incoming or outgoing traffic. The pMask parameter provides a network mask to support testing for a group of events.

RETURNS

OK if filter set, or ERROR otherwise.

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetAddressFilterClear( )

NAME

wvNetAddressFilterClear( ) - remove the address filter for events

SYNOPSIS

void wvNetAddressFilterClear
    (
    int type,                 /* 0 for source, 1 for destination */
    int direction             /* 0 for input, 1 for output */
    )

DESCRIPTION

This routine removes any active address filter test indicated by the type and direction parameters used to enable it. Affected events will be reported unconditionally.

RETURNS

N/A

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetPortFilterSet( )

NAME

wvNetPortFilterSet( ) - specify an address filter for events

SYNOPSIS

STATUS wvNetPortFilterSet
    (
    int port,                 /* target port for event comparisons */
    int type,                 /* 0 for source, 1 for destination */
    int direction             /* 0 for input, 1 for output */
    )

DESCRIPTION

This routine activates an additional filter, which disables certain events that do not match the specified port value. The port parameter provides the test value and the type parameter indicates whether that value is compared against the source or destination fields. The direction setting identifies whether the type is interpreted from the perspective of incoming or outgoing traffic.

RETURNS

OK if filter set, or ERROR otherwise.

ERRNO

N/A

SEE ALSO

wvNetLib


OS Libraries : Routines

wvNetPortFilterClear( )

NAME

wvNetPortFilterClear( ) - remove the port number filter for events

SYNOPSIS

void wvNetPortFilterClear
    (
    int type,                 /* 0 for source, 1 for destination */
    int direction             /* 0 for input, 1 for output */
    )

DESCRIPTION

This routine removes any active port filter test indicated by the type and direction parameters used to enable it. Affected events will be reported unconditionally.

RETURNS

N/A

ERRNO

N/A

SEE ALSO

wvNetLib