Package org.netbeans.jemmy.operators
Class LabelOperator
java.lang.Object
org.netbeans.jemmy.operators.Operator
org.netbeans.jemmy.operators.ComponentOperator
org.netbeans.jemmy.operators.LabelOperator
- All Implemented Interfaces:
Outputable
,Timeoutable
Timeouts used:
ComponentOperator.WaitComponentTimeout - time to wait component displayed
.
- Author:
- Alexandre Iline (alexandre.iline@sun.com)
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Allows to find component by LabelByLabelFinder.static class
Checks component type.Nested classes/interfaces inherited from class org.netbeans.jemmy.operators.Operator
Operator.ComponentVisualizer, Operator.DefaultPathParser, Operator.DefaultStringComparator, Operator.Finder, Operator.MapAction, Operator.MapBooleanAction, Operator.MapByteAction, Operator.MapCharacterAction, Operator.MapDoubleAction, Operator.MapFloatAction, Operator.MapIntegerAction, Operator.MapLongAction, Operator.MapVoidAction, Operator.NoBlockingAction, Operator.PathParser, Operator.StringComparator
-
Field Summary
FieldsFields inherited from class org.netbeans.jemmy.operators.ComponentOperator
HEIGHT_DPROP, IS_SHOWING_DPROP, IS_VISIBLE_DPROP, NAME_DPROP, WIDTH_DPROP, X_DPROP, Y_DPROP
Fields inherited from class org.netbeans.jemmy.operators.Operator
CLASS_DPROP, TO_STRING_DPROP
-
Constructor Summary
ConstructorsConstructorDescriptionConstructor.Constructor.LabelOperator
(ContainerOperator cont, int index) Constructor.LabelOperator
(ContainerOperator cont, String text) Constructor.LabelOperator
(ContainerOperator cont, String text, int index) Constructor.LabelOperator
(ContainerOperator cont, ComponentChooser chooser) Constructs a LabelOperator object.LabelOperator
(ContainerOperator cont, ComponentChooser chooser, int index) Constructs a LabelOperator object. -
Method Summary
Modifier and TypeMethodDescriptionstatic Label
Searches Label by text.static Label
Searches Label by text.static Label
findLabel
(Container cont, ComponentChooser chooser) Searches Label in container.static Label
findLabel
(Container cont, ComponentChooser chooser, int index) Searches Label in container.int
MapsLabel.getAlignment()
through queuegetDump()
Returns information about component.getText()
MapsLabel.getText()
through queuevoid
setAlignment
(int i) MapsLabel.setAlignment(int)
through queuevoid
MapsLabel.setText(String)
through queuestatic Label
Waits Label by text.static Label
Waits Label by text.static Label
waitLabel
(Container cont, ComponentChooser chooser) Waits Label in container.static Label
waitLabel
(Container cont, ComponentChooser chooser, int index) Waits Label in container.Methods inherited from class org.netbeans.jemmy.operators.ComponentOperator
activateWindow, add, addComponentListener, addFocusListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, checkImage, checkImage, clickForPopup, clickForPopup, clickForPopup, clickForPopup, clickMouse, clickMouse, clickMouse, clickMouse, clickMouse, clickMouse, clickMouse, contains, contains, copyEnvironment, createImage, createImage, dispatchEvent, doLayout, dragMouse, dragMouse, dragMouse, dragNDrop, dragNDrop, dragNDrop, enableInputMethods, enterMouse, exitMouse, findComponent, findComponent, getAlignmentX, getAlignmentY, getBackground, getBounds, getBounds, getCenterX, getCenterXForClick, getCenterY, getCenterYForClick, getColorModel, getComponentAt, getComponentAt, getComponentOrientation, getContainer, getContainers, getCursor, getDropTarget, getEventDispatcher, getFocus, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getInputContext, getInputMethodRequests, getLocale, getLocation, getLocation, getLocationOnScreen, getMaximumSize, getMinimumSize, getName, getOutput, getParent, getPreferredSize, getSize, getSize, getSource, getTimeouts, getToolkit, getTreeLock, getWidth, getWindow, getX, getY, hasFocus, imageUpdate, invalidate, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isShowing, isValid, isVisible, list, list, list, list, list, makeComponentVisible, moveMouse, paint, paintAll, prepareImage, prepareImage, pressKey, pressKey, pressMouse, pressMouse, print, printAll, pushKey, pushKey, releaseKey, releaseKey, releaseMouse, releaseMouse, remove, removeComponentListener, removeFocusListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFont, setForeground, setLocale, setLocation, setLocation, setName, setOutput, setSize, setSize, setTimeouts, setVisible, transferFocus, typeKey, typeKey, typeKey, update, validate, waitComponent, waitComponent, waitComponent, waitComponent, waitComponentEnabled, waitComponentShowing, waitComponentVisible, waitHasFocus, wtComponentEnabled
Methods inherited from class org.netbeans.jemmy.operators.Operator
addOperatorPackage, addToDump, addToDump, createOperator, getCharBindingMap, getCharKey, getCharModifiers, getCharsKeys, getCharsKeys, getCharsModifiers, getCharsModifiers, getComparator, getDefaultComponentVisualizer, getDefaultMouseButton, getDefaultPathParser, getDefaultStringComparator, getDefaultVerification, getEnvironmentOperator, getParentPath, getParentPath, getPathParser, getPopupMouseButton, getProperties, getQueueTool, getVerification, getVisualizer, isCaptionEqual, isCaptionEqual, isCaptionEqual, lockQueue, parseString, parseString, printDump, produceNoBlocking, produceNoBlocking, produceTimeRestricted, produceTimeRestricted, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, runMapping, setCharBindingMap, setComparator, setDefaultComponentVisualizer, setDefaultPathParser, setDefaultStringComparator, setDefaultVerification, setPathParser, setProperties, setVerification, setVisualizer, toStringSource, unlockAndThrow, unlockQueue, waitState
-
Field Details
-
TEXT_DPROP
Identifier for a "text" property.- See Also:
-
-
Constructor Details
-
LabelOperator
Constructor.- Parameters:
b
- a component
-
LabelOperator
Constructs a LabelOperator object.- Parameters:
cont
- a containerchooser
- a component chooser specifying searching criteria.index
- an index between appropriate ones.
-
LabelOperator
Constructs a LabelOperator object.- Parameters:
cont
- a containerchooser
- a component chooser specifying searching criteria.
-
LabelOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont
- a containertext
- Button text.index
- Ordinal component index.- Throws:
TimeoutExpiredException
- See Also:
-
LabelOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont
- a containertext
- Button text.- Throws:
TimeoutExpiredException
- See Also:
-
LabelOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont
- a containerindex
- Ordinal component index.- Throws:
TimeoutExpiredException
-
LabelOperator
Constructor. Waits component in container first. Uses cont's timeout and output for waiting and to init operator.- Parameters:
cont
- a container- Throws:
TimeoutExpiredException
-
-
Method Details
-
findLabel
Searches Label in container.- Parameters:
cont
- Container to search component in.chooser
- a component chooser specifying searching criteria.index
- Ordinal component index.- Returns:
- Label instance or null if component was not found.
-
findLabel
Searches Label in container.- Parameters:
cont
- Container to search component in.chooser
- a component chooser specifying searching criteria.- Returns:
- Label instance or null if component was not found.
-
findLabel
Searches Label by text.- Parameters:
cont
- Container to search component in.text
- Component text.ce
- Compare text exactly.ccs
- Compare text case sensitively.index
- Ordinal component index.- Returns:
- Label instance or null if component was not found.
- See Also:
-
findLabel
Searches Label by text.- Parameters:
cont
- Container to search component in.text
- Component text.ce
- Compare text exactly.ccs
- Compare text case sensitively.- Returns:
- Label instance or null if component was not found.
- See Also:
-
waitLabel
Waits Label in container.- Parameters:
cont
- Container to search component in.chooser
- a component chooser specifying searching criteria.index
- Ordinal component index.- Returns:
- Label instance.
- Throws:
TimeoutExpiredException
-
waitLabel
Waits Label in container.- Parameters:
cont
- Container to search component in.chooser
- a component chooser specifying searching criteria.- Returns:
- Label instance.
- Throws:
TimeoutExpiredException
-
waitLabel
Waits Label by text.- Parameters:
cont
- Container to search component in.text
- Component text.ce
- Compare text exactly.ccs
- Compare text case sensitively.index
- Ordinal component index.- Returns:
- Label instance.
- Throws:
TimeoutExpiredException
- See Also:
-
waitLabel
Waits Label by text.- Parameters:
cont
- Container to search component in.text
- Component text.ce
- Compare text exactly.ccs
- Compare text case sensitively.- Returns:
- Label instance.
- Throws:
TimeoutExpiredException
- See Also:
-
getDump
Description copied from class:ComponentOperator
Returns information about component.- Overrides:
getDump
in classComponentOperator
- Returns:
- a Hashtable containing name-value pairs.
-
getAlignment
public int getAlignment()MapsLabel.getAlignment()
through queue -
getText
MapsLabel.getText()
through queue -
setAlignment
public void setAlignment(int i) MapsLabel.setAlignment(int)
through queue -
setText
MapsLabel.setText(String)
through queue
-