Spec-Zone .ru
спецификации, руководства, описания, API
|
T
- the event class to which this type appliespublic class EventType<T extends Event>
extends java.lang.Object
Event
.
Event types form a hierarchy with the EventType.ROOT
(equals to
Event.ANY
) as its root. This is useful in event filter / handler
registration where a single event filter / handler can be registered to a
super event type and will be receiving its sub type events as well.
Modifier and Type | Field and Description |
---|---|
static EventType<Event> |
ROOT
The root event type.
|
Constructor and Description |
---|
EventType()
Constructs a new
EventType with the EventType.ROOT as its
super type and the name set to null . |
EventType(EventType<? super T> superType)
Constructs a new
EventType with the specified super type and
the name set to null . |
EventType(EventType<? super T> superType,
java.lang.String name)
Constructs a new
EventType with the specified super type and
name. |
EventType(java.lang.String name)
Constructs a new
EventType with the specified name and the
EventType.ROOT as its super type. |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getName()
Gets the name of this event type.
|
EventType<? super T> |
getSuperType()
Gets the super type of this event type.
|
java.lang.String |
toString()
Returns a string representation of this
EventType object. |
public EventType()
EventType
with the EventType.ROOT
as its
super type and the name set to null
.public EventType(java.lang.String name)
EventType
with the specified name and the
EventType.ROOT
as its super type.name
- the namepublic EventType(EventType<? super T> superType)
EventType
with the specified super type and
the name set to null
.superType
- the event super typepublic final EventType<? super T> getSuperType()
null
only for the EventType.ROOT
.public final java.lang.String getName()
public java.lang.String toString()
EventType
object.toString
in class java.lang.Object
EventType
object.Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. Use is subject to