javax.swing.event
public class HyperlinkEvent extends EventObject
Modifier and Type | Class and Description |
---|---|
static class |
HyperlinkEvent.EventType |
source
Constructor and Description |
---|
HyperlinkEvent(Object source,
HyperlinkEvent.EventType type,
URL url)
Creates a new
HyperlinkEvent with the given arguments. |
HyperlinkEvent(Object source,
HyperlinkEvent.EventType type,
URL url,
String description)
Creates a new
HyperlinkEvent with the given arguments. |
HyperlinkEvent(Object source,
HyperlinkEvent.EventType type,
URL url,
String description,
Element element)
Creates a new
HyperlinkEvent with the given arguments. |
Modifier and Type | Method and Description |
---|---|
String |
getDescription()
Returns the description of this event.
|
HyperlinkEvent.EventType |
getEventType()
Returns the type of this event.
|
Element |
getSourceElement()
Returns the element of the document repesenting this anchor.
|
URL |
getURL()
Returns the URL of this event.
|
getSource, toString
public HyperlinkEvent(Object source, HyperlinkEvent.EventType type, URL url)
HyperlinkEvent
with the given arguments.source
- The object this link is associated to.type
- The type of event.url
- The URL this link pointing too.public HyperlinkEvent(Object source, HyperlinkEvent.EventType type, URL url, String description)
HyperlinkEvent
with the given arguments.source
- The object this link is associated to.type
- The type of event.url
- The URL this link pointing too.description
- The description for this link.public HyperlinkEvent(Object source, HyperlinkEvent.EventType type, URL url, String description, Element element)
HyperlinkEvent
with the given arguments.source
- The object this link is associated to.type
- The type of event.url
- The URL this link pointing too.description
- The description for this link.element
- The element in the document representing the anchor.public Element getSourceElement()
public HyperlinkEvent.EventType getEventType()
public String getDescription()