java.awt

Class Choice.AccessibleAWTChoice

protected class Choice.AccessibleAWTChoice extends AccessibleAWTComponent implements AccessibleAction

This class provides accessibility support for the combo box.
Constructor Summary
AccessibleAWTChoice()
Default constructor which simply calls the super class for generic component accessibility handling.
Method Summary
booleandoAccessibleAction(int i)
Executes the action with the specified id.
AccessibleActiongetAccessibleAction()
Returns an implementation of the AccessibleAction interface for this accessible object.
intgetAccessibleActionCount()
Returns the number of actions associated with this accessible object.
StringgetAccessibleActionDescription(int i)
Returns a description of the action with the supplied id.
AccessibleRolegetAccessibleRole()
Returns the role of this accessible object.

Constructor Detail

AccessibleAWTChoice

public AccessibleAWTChoice()
Default constructor which simply calls the super class for generic component accessibility handling.

Method Detail

doAccessibleAction

public boolean doAccessibleAction(int i)
Executes the action with the specified id. In this case, calling this method provides the same behaviour as would choosing a choice from the list in a visual manner.

Parameters: i the id of the choice to select.

Returns: true if a valid choice was specified.

See Also: AccessibleAction

getAccessibleAction

public AccessibleAction getAccessibleAction()
Returns an implementation of the AccessibleAction interface for this accessible object. In this case, the current instance is simply returned (with a more appropriate type), as it also implements the accessible action as well as the context.

Returns: the accessible action associated with this context.

See Also: AccessibleAction

getAccessibleActionCount

public int getAccessibleActionCount()
Returns the number of actions associated with this accessible object. In this case, it is the number of choices available.

Returns: the number of choices available.

See Also: getAccessibleActionCount

getAccessibleActionDescription

public String getAccessibleActionDescription(int i)
Returns a description of the action with the supplied id. In this case, it is the text used in displaying the particular choice on-screen.

Parameters: i the id of the choice whose description should be retrieved.

Returns: the String used to describe the choice.

See Also: AccessibleAction

getAccessibleRole

public AccessibleRole getAccessibleRole()
Returns the role of this accessible object.

Returns: the instance of AccessibleRole, which describes this object.

See Also: AccessibleRole