|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
AccessibleContext represents the minimum information all accessible objects return. This information includes the accessible name, role, and state of the object, as well as information about its parent and children. AccessibleContext also contains methods for obtaining more specific accessibility information about a component. If the component supports them, these methods will return an object that implements one or more of the following interfaces:
AccessibleText - the object presents editable textual
information on the display. This interface provides the standard mechanism
for an assistive technology to access that text via its content, attributes,
and spatial location. Any object that contains editable text should support
this interface.
AccessibleTable - the object presents tabular information on the
display. This interface provides the standard mechanism for an assistive
technology to access table columns and rows and current selection. Any object
that represents a table should support this interface.
AccessibleValue - the object supports a numerical value. This
interface provides the standard mechanism for an assistive technology to
determine and set the current value of the object, as well as obtain its
minimum and maximum values. Any object that supports a numerical value should
support this interface.
| Field Summary | ||
static int |
ACCESSIBLE_CARET_CHANGED
Specifies caret movement event. |
|
static int |
ACCESSIBLE_CHILD_CHANGED
Specifies child change event. |
|
static int |
ACCESSIBLE_NAME_CHANGED
Specifies element name change. |
|
static int |
ACCESSIBLE_SELECTION_CHANGED
Specifies selection change event. |
|
static int |
ACCESSIBLE_STATE_CHANGED
Specifies accessible state transition event type. |
|
static int |
ACCESSIBLE_TEXT_CHANGED
Specifies text change event. |
|
static int |
ACCESSIBLE_VALUE_CHANGED
Specifies numerical or sequential value change. |
|
| Method Summary | ||
AccessibleContext |
getAccessibleChildAt(int index)
Returns the specified Accessible child of the object. |
|
int |
getAccessibleChildCount()
Return number of children for conatiners |
|
String |
getAccessibleName()
Returns accessible name of the element. |
|
AccessibleContext |
getAccessibleParent()
For Screens/Dialogs this returns null For Fields - this returns the Screen/Dialog containing the Field For complex Field elements (ex: menu items, etc) - this returns the Field (ex: menu, etc) |
|
int |
getAccessibleRole()
Returns accessible role of the element. |
|
AccessibleContext |
getAccessibleSelectionAt(int index)
This method returns an AccessibleContext that is currently selected where the index is the index in the list of selected items For classes where there is only 1 item selected at a time only the index of 0 is valid For classes that allow multi-selection the index is the position in the list of selected items where 0 indicates the start of the selection |
|
int |
getAccessibleSelectionCount()
Returns the number of Accessible children currently selected. |
|
int |
getAccessibleStateSet()
Returns current states set. |
|
AccessibleTable |
getAccessibleTable()
Gets the AccessibleTable associated with an object |
|
AccessibleText |
getAccessibleText()
Returns accessible text for textual fields. |
|
AccessibleValue |
getAccessibleValue()
Returns accessible value for numerical fields. |
|
boolean |
isAccessibleChildSelected(int index)
Determines if the current child of this object is selected. |
|
boolean |
isAccessibleStateSet(int state)
Determines whether the particular state is set on accessible element. |
|
| Field Detail |
public static final int ACCESSIBLE_CARET_CHANGED
public static final int ACCESSIBLE_CHILD_CHANGED
The two notification parameters in the
AccessibleEventListener.accessibleEventOccurred(int, Object, Object, AccessibleContext)
method may optionally provide information about which container elements
have been removed and added. This may help assistive technology to read
only the affected elements if container has many of them. Both parameters
are optional, however, if any of them is provided then the set must be
complete meaning no other components were added or removed from the
container. For example, if a screen changes dramatically affecting many
fields then it is better to pass NULL parameter values indicating that
screen reader should re-read the whole screen. On the other hand if
relatively small number of fields were added or removed from the screen
with big number of fields then it is advised to provide only the set of
changed fields. In order to pass affected elements the two method
parameter should be an array with the following type:
AccessibleContext[]. The oldValue (2nd method parameter)
contains container elements that existed before the notification and were
removed. Similarly, the newValue (3rd method parameter) contains new
elements that were added.
public static final int ACCESSIBLE_NAME_CHANGED
public static final int ACCESSIBLE_SELECTION_CHANGED
public static final int ACCESSIBLE_STATE_CHANGED
public static final int ACCESSIBLE_TEXT_CHANGED
public static final int ACCESSIBLE_VALUE_CHANGED
getAccessibleValue()
method.| Method Detail |
public AccessibleContext getAccessibleChildAt(int index)
index - -
index of child requestedpublic int getAccessibleChildCount()
public String getAccessibleName()
public AccessibleContext getAccessibleParent()
public int getAccessibleRole()
AccessibleRolepublic AccessibleContext getAccessibleSelectionAt(int index)
index - of selelected item, does not correspond to the child indexpublic int getAccessibleSelectionCount()
public int getAccessibleStateSet()
AccessibleStatepublic AccessibleTable getAccessibleTable()
public AccessibleText getAccessibleText()
public AccessibleValue getAccessibleValue()
public boolean isAccessibleChildSelected(int index)
index - of childpublic boolean isAccessibleStateSet(int state)
The method parameter should be one of the states flags constants from the
AccessibleState class. If the state method parameter contains
more than one states flag then the returning value will be true if
any of the given states is possessed by the component, false if component
doesn't have any of the given states.
state - -
determine if this state flag belongs to the set
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2009 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.