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

## org.jini.rio.event
Class EventDescriptor

    java.lang.Object
      net.jini.entry.AbstractEntry
          org.jini.rio.event.EventDescriptor

All Implemented Interfaces:
  Serializable, Entry

    public class EventDescriptor

extends AbstractEntry

The EventDescriptor describes an event that an EventProducer will advertise as part of it's attribute set in a Jini Lookup Service.

See Also:
  Serialized Form

Field Summary
`Class` | `eventClass` The event classes Class that this EventDescriptor describes
`Long` | `eventID` The event class event identifier.

Constructor Summary
`EventDescriptor()` Construct an EventDescriptor with attributes set to null
`EventDescriptor(Class eventClass)` Construct an EventDescriptor with a class
`EventDescriptor(Class eventClass, long eventID)` Construct an EventDescriptor with a class and long event ID.
`EventDescriptor(Class eventClass, Long eventID)` Construct an EventDescriptor with a class and an event ID.
`EventDescriptor(long eventID)` Construct an EventDescriptor with a long event ID.
`EventDescriptor(Long eventID)` Construct an EventDescriptor with a Long event ID.

Method Summary
`boolean` | `matches(EventDescriptor template)` Determine whether the provided EventDescriptor matches properties of this EventDescriptor
`String` | `toString()` Produce a String representation of an EventDescriptor

Methods inherited from class net.jini.entry.AbstractEntry
`equals, equals, hashCode, hashCode, toString`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### eventClass

    public Class eventClass

  The event classes Class that this EventDescriptor describes

### eventID

    public Long eventID

  The event class event identifier. Care should be taken that this identifier is unique

Constructor Detail

### EventDescriptor

    public EventDescriptor()

  Construct an EventDescriptor with attributes set to null

### EventDescriptor

    public EventDescriptor(Class eventClass)

  Construct an EventDescriptor with a class

### EventDescriptor

    public EventDescriptor(long eventID)

  Construct an EventDescriptor with a long event ID.

### EventDescriptor

    public EventDescriptor(Long eventID)

  Construct an EventDescriptor with a Long event ID.

### EventDescriptor

    public EventDescriptor(Class eventClass,
                           long eventID)

  Construct an EventDescriptor with a class and long event ID. The eventID will be turned into a Long

### EventDescriptor

    public EventDescriptor(Class eventClass,
                           Long eventID)

  Construct an EventDescriptor with a class and an event ID.

Method Detail

### matches

    public boolean matches(EventDescriptor template)

  Determine whether the provided EventDescriptor matches properties of this EventDescriptor

  Parameters:
    `template` -
  Returns:
    The following logic determines EventDescriptor matching semantics :
    - If the provided EventDescriptor properties `eventID` and `eventClass` are `null`, return `true`.
    - If the provided EventDescriptor property `eventID` is `null`, and the `eventClass` property is not `null`, return whether the provided EventDescriptor property `eventClass` is equal to the `eventClass` property
    - If the `eventID` property is `null`, return `false`.
    - If the `eventID` property is not `null`, and the provided EventDescriptor `eventID` property is not `null`, return whether the provided EventDescriptor property `eventID` is equal to the `eventID` property
  Throws:
    `NullPointerException` - if the the provided EventDescriptor is `null`

### toString

    public String toString()

  Produce a String representation of an EventDescriptor

  Overrides:
    `toString` in class `AbstractEntry`

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

Copyright © Project Rio.