Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.jmx.adaptor.snmp.agent
Interface NotificationWrapper

All Known Implementing Classes:
  NotificationWrapperSupport

public interface NotificationWrapper

`NotificationWrapper` is a "wide" read only interface providing "unstructured" access to agent internals and paylod carried by notifications. The alternatives were: 1. Precompile assumptions regarding the notification stucture and its payload in the trap factory 2. Use introspection but with a potential large execution overhead. The use of delegated wrappers stands somewhere in the middle. Trap factory can be extended with the definition and use of new wpappers that will be able to cope with any kind of notfications. Run time overhead is minimal as wrappers can be instantiated only once. Tags used to locate attributes in the notification fixed (i.e. excluding user defined fields) payload are defined. Implementations should not use these tags in any of the notification payload. To avoid conflicts the following convention is proposed: standard notification payload is qualified by the "n:" prefix. Agent properties are qualified by the "a:" prefix. User defined payload can be qualified with e.g. the "u:" prefix

Version:
  $Revision: 1.2.6.1 $
Author:
  Spyros Pollatos, Dimitris Andreadis

Field Summary
`static String` | `ALL_TAG`
`static String` | `CLASS_TAG`
`static String` | `MESSAGE_TAG`
`static String` | `SEQNO_TAG`
`static String` | `STARTTIME_TAG`
`static String` | `TRAPCOUNT_TAG`
`static String` | `TSTAMP_TAG`
`static String` | `TYPE_TAG`
`static String` | `UPTIME_TAG`

Method Summary
`Object` | `get(String attrTag)` Defines the communication protocol between the caller and the data source (notification).
`void` | `prime(javax.management.Notification n)` Sets notification to be used as the data source
`void` | `set(Clock uptime, Counter count)` Sets the uptime clock and trap counter

Field Detail

### MESSAGE_TAG

    public static final String MESSAGE_TAG

See Also:
  Constant Field Values

### SEQNO_TAG

    public static final String SEQNO_TAG

See Also:
  Constant Field Values

### TSTAMP_TAG

    public static final String TSTAMP_TAG

See Also:
  Constant Field Values

### TYPE_TAG

    public static final String TYPE_TAG

See Also:
  Constant Field Values

### ALL_TAG

    public static final String ALL_TAG

See Also:
  Constant Field Values

### CLASS_TAG

    public static final String CLASS_TAG

See Also:
  Constant Field Values

### STARTTIME_TAG

    public static final String STARTTIME_TAG

See Also:
  Constant Field Values

### UPTIME_TAG

    public static final String UPTIME_TAG

See Also:
  Constant Field Values

### TRAPCOUNT_TAG

    public static final String TRAPCOUNT_TAG

See Also:
  Constant Field Values

Method Detail

### set

    public void set(Clock uptime,
                    Counter count)

  Sets the uptime clock and trap counter

### prime

    public void prime(javax.management.Notification n)

  Sets notification to be used as the data source

  Parameters:
    `n` - the notification to be used as a data source at subsequent calls of method get

### get

    public Object get(String attrTag)
               throws MappingFailedException

  Defines the communication protocol between the caller and the data source (notification). Implementations are expected to map the provided attribute name to some aspect of the notification payload. The later is defined by method prime.

  Parameters:
    `attrTag` - the tag of the attribute the value of which is required
  Returns:
    the content attrTag maps to
  Throws:
    `MappingFailedException` - if for any reason the requested attribute can not be found

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002 JBoss Group, LLC. All Rights Reserved.