protected class

JPasswordField.AccessibleJPasswordField

extends JTextField.AccessibleJTextField
java.lang.Object
   ↳ javax.accessibility.AccessibleContext
     ↳ java.awt.Component.AccessibleAWTComponent
       ↳ java.awt.Container.AccessibleAWTContainer
         ↳ javax.swing.JComponent.AccessibleJComponent
           ↳ javax.swing.text.JTextComponent.AccessibleJTextComponent
             ↳ javax.swing.JTextField.AccessibleJTextField
               ↳ javax.swing.JPasswordField.AccessibleJPasswordField

Class Overview

This class implements accessibility support for the JPasswordField class. It provides an implementation of the Java Accessibility API appropriate to password field user-interface elements.

Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeansTM has been added to the java.beans package. Please see XMLEncoder.

Summary

[Expand]
Inherited Constants
From class javax.accessibility.AccessibleContext
From interface javax.accessibility.AccessibleExtendedText
From interface javax.accessibility.AccessibleText
[Expand]
Inherited Fields
From class javax.swing.JComponent.AccessibleJComponent
From class java.awt.Container.AccessibleAWTContainer
From class java.awt.Component.AccessibleAWTComponent
From class javax.accessibility.AccessibleContext
From interface javax.accessibility.AccessibleAction
Protected Constructors
JPasswordField.AccessibleJPasswordField()
Public Methods
AccessibleRole getAccessibleRole()
Gets the role of this object.
AccessibleText getAccessibleText()
Gets the AccessibleText for the JPasswordField.
String getAfterIndex(int part, int index)
Returns the String after a given index.
String getAtIndex(int part, int index)
Returns the String at a given index.
String getBeforeIndex(int part, int index)
Returns the String before a given index.
String getTextRange(int startIndex, int endIndex)
Returns the text between two indices.
AccessibleTextSequence getTextSequenceAfter(int part, int index)
Returns the AccessibleTextSequence after a given index.
AccessibleTextSequence getTextSequenceAt(int part, int index)
Returns the AccessibleTextSequence at a given index.
AccessibleTextSequence getTextSequenceBefore(int part, int index)
Returns the AccessibleTextSequence before a given index.
[Expand]
Inherited Methods
From class javax.swing.JTextField.AccessibleJTextField
From class javax.swing.text.JTextComponent.AccessibleJTextComponent
From class javax.swing.JComponent.AccessibleJComponent
From class java.awt.Container.AccessibleAWTContainer
From class java.awt.Component.AccessibleAWTComponent
From class javax.accessibility.AccessibleContext
From class java.lang.Object
From interface javax.accessibility.AccessibleAction
From interface javax.accessibility.AccessibleComponent
From interface javax.accessibility.AccessibleEditableText
From interface javax.accessibility.AccessibleExtendedComponent
From interface javax.accessibility.AccessibleExtendedText
From interface javax.accessibility.AccessibleText
From interface javax.swing.event.CaretListener
From interface javax.swing.event.DocumentListener

Protected Constructors

protected JPasswordField.AccessibleJPasswordField ()

Public Methods

public AccessibleRole getAccessibleRole ()

Gets the role of this object.

Returns
  • an instance of AccessibleRole describing the role of the object (AccessibleRole.PASSWORD_TEXT)
See Also

public AccessibleText getAccessibleText ()

Gets the AccessibleText for the JPasswordField. The returned object also implements the AccessibleExtendedText interface.

Returns
  • AccessibleText for the JPasswordField

public String getAfterIndex (int part, int index)

Returns the String after a given index.

Parameters
part the CHARACTER, WORD or SENTENCE to retrieve
index an index within the text
Returns
  • a String if part and index are valid. Otherwise, null is returned

public String getAtIndex (int part, int index)

Returns the String at a given index.

Parameters
part the CHARACTER, WORD or SENTENCE to retrieve
index an index within the text
Returns
  • a String if part and index are valid. Otherwise, null is returned

public String getBeforeIndex (int part, int index)

Returns the String before a given index.

Parameters
part the CHARACTER, WORD or SENTENCE to retrieve
index an index within the text
Returns
  • a String if part and index are valid. Otherwise, null is returned

public String getTextRange (int startIndex, int endIndex)

Returns the text between two indices.

Parameters
startIndex the start index in the text
endIndex the end index in the text
Returns
  • the text string if the indices are valid. Otherwise, null is returned

public AccessibleTextSequence getTextSequenceAfter (int part, int index)

Returns the AccessibleTextSequence after a given index.

Parameters
part the CHARACTER, WORD, SENTENCE, LINE or ATTRIBUTE_RUN to retrieve
index an index within the text
Returns
  • an AccessibleTextSequence specifying the text if part and index are valid. Otherwise, null is returned

public AccessibleTextSequence getTextSequenceAt (int part, int index)

Returns the AccessibleTextSequence at a given index.

Parameters
part the CHARACTER, WORD, SENTENCE, LINE or ATTRIBUTE_RUN to retrieve
index an index within the text
Returns
  • an AccessibleTextSequence specifying the text if part and index are valid. Otherwise, null is returned

public AccessibleTextSequence getTextSequenceBefore (int part, int index)

Returns the AccessibleTextSequence before a given index.

Parameters
part the CHARACTER, WORD, SENTENCE, LINE or ATTRIBUTE_RUN to retrieve
index an index within the text
Returns
  • an AccessibleTextSequence specifying the text if part and index are valid. Otherwise, null is returned