AccessibleAction
JEditorPane.JEditorPaneAccessibleHypertextSupport
public class JEditorPane.JEditorPaneAccessibleHypertextSupport.HTMLLink extends AccessibleHyperlink
CLICK, DECREMENT, INCREMENT, TOGGLE_EXPAND, TOGGLE_POPUP
Constructor | Description |
---|---|
HTMLLink |
Constructs a HTMLLink . |
Modifier and Type | Method | Description |
---|---|---|
boolean |
doAccessibleAction |
Perform the specified Action on the object |
Object |
getAccessibleActionAnchor |
Return an object that represents the link anchor, as appropriate for that link. |
int |
getAccessibleActionCount() |
Returns the number of accessible actions available in this Link If there are more than one, the first one is NOT considered the "default" action of this LINK object (e.g. in an HTML imagemap). |
String |
getAccessibleActionDescription |
Return a String description of this particular link action. |
Object |
getAccessibleActionObject |
Returns a URL object that represents the link. |
int |
getEndIndex() |
Get the index with the hypertext document at which this link ends |
int |
getStartIndex() |
Get the index with the hypertext document at which this link begins |
boolean |
isValid() |
Since the document a link is associated with may have changed, this method returns whether this Link is valid anymore (with respect to the document it references). |
public HTMLLink(Element e)
HTMLLink
.e
- the elementpublic boolean isValid()
isValid
in class AccessibleHyperlink
public int getAccessibleActionCount()
getAccessibleActionCount
in interface AccessibleAction
getAccessibleActionCount
in class AccessibleHyperlink
public boolean doAccessibleAction(int i)
doAccessibleAction
in interface AccessibleAction
doAccessibleAction
in class AccessibleHyperlink
i
- zero-based index of actionspublic String getAccessibleActionDescription(int i)
getAccessibleActionDescription
in interface AccessibleAction
getAccessibleActionDescription
in class AccessibleHyperlink
i
- zero-based index of the actionspublic Object getAccessibleActionObject(int i)
getAccessibleActionObject
in class AccessibleHyperlink
i
- zero-based index of the actionspublic Object getAccessibleActionAnchor(int i)
E.g. from HTML: <a href="https://openjdk.org">OpenJDK</a> this method would return a String containing the text: 'OpenJDK'.
Similarly, from this HTML: <a HREF="#top"><img src="top-hat.gif" alt="top hat"></a> this might return the object ImageIcon("top-hat.gif", "top hat");
getAccessibleActionAnchor
in class AccessibleHyperlink
i
- zero-based index of the actionspublic int getStartIndex()
getStartIndex
in class AccessibleHyperlink
public int getEndIndex()
getEndIndex
in class AccessibleHyperlink
© 1993, 2023, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
https://docs.oracle.com/en/java/javase/21/docs/api/java.desktop/javax/swing/JEditorPane.JEditorPaneAccessibleHypertextSupport.HTMLLink.html