TPTP 4.4.0 Testing Tools Project
Internal API Specification

org.eclipse.tptp.test.auto.gui.internal.commands
Class ChoiceSelectionCommand

java.lang.Object
  extended byorg.eclipse.tptp.test.auto.gui.internal.macro.AbstractMacroInstruction
      extended byorg.eclipse.tptp.test.auto.gui.internal.commands.AbstractMacroCommand
          extended byorg.eclipse.tptp.test.auto.gui.internal.commands.ChoiceSelectionCommand
All Implemented Interfaces:
IMacroCommand, IMacroInstruction, IPlayable, IWritable

public class ChoiceSelectionCommand
extends AbstractMacroCommand

A choice selection command represents a user selection of an item from a set of items present. For example, selecting a specific tab from a tab group or an item from a combo box.


Field Summary
static java.lang.String TYPE
           
 
Fields inherited from class org.eclipse.tptp.test.auto.gui.internal.commands.AbstractMacroCommand
DESCRIPTIVE_FIELD_BOUND
 
Constructor Summary
ChoiceSelectionCommand(MacroCommandShell parent, WidgetIdentifier wid)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
          Overwrite this method in order to indicate that two choice commands that have different choice ids are not the same
 java.lang.String getType()
          Returns the type of this command
 void load(org.w3c.dom.Node node, java.util.Hashtable lineTable)
          Invoked to load the macro instruction based on its corresponding XML node.
 boolean mergeEvent(org.eclipse.swt.widgets.Event e)
          If this command occurs consecutively, then this method gives this command a chance to merge mutliple commands together to reduce the overhead.
 boolean playback(org.eclipse.swt.widgets.Display display, org.eclipse.swt.widgets.Composite parent, org.eclipse.core.runtime.IProgressMonitor monitor)
           
 void processEvent(org.eclipse.swt.widgets.Event e)
          Allows this command to process the corresponding event.
 void write(int indent, java.lang.StringBuffer sb)
          Equivalent to write(indent, writer, false, false)
 
Methods inherited from class org.eclipse.tptp.test.auto.gui.internal.commands.AbstractMacroCommand
findDescriptiveField, findDescriptiveField, getDescriptiveField, getObjectClassName, getParent, getText, getTimeDifference, isRepeatRedundant, setDescriptiveField, setParent, setTimeDifference, toString, write, writeFinish, writeStart
 
Methods inherited from class org.eclipse.tptp.test.auto.gui.internal.macro.AbstractMacroInstruction
bindSourceLocation, getCorrespondingObject, getStartLine, getStopLine, getWidgetId, setCorrespondingObject, setWidgetId
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.tptp.test.auto.gui.internal.core.IMacroInstruction
getCorrespondingObject, getStartLine, getStopLine, getWidgetId, setCorrespondingObject, setWidgetId
 

Field Detail

TYPE

public static final java.lang.String TYPE
See Also:
Constant Field Values
Constructor Detail

ChoiceSelectionCommand

public ChoiceSelectionCommand(MacroCommandShell parent,
                              WidgetIdentifier wid)
Method Detail

getType

public java.lang.String getType()
Description copied from interface: IMacroCommand
Returns the type of this command

Returns:
The type

processEvent

public void processEvent(org.eclipse.swt.widgets.Event e)
Description copied from interface: IMacroCommand
Allows this command to process the corresponding event.

Parameters:
e - The event that awaits processing

load

public void load(org.w3c.dom.Node node,
                 java.util.Hashtable lineTable)
          throws org.eclipse.core.runtime.CoreException
Description copied from interface: IMacroInstruction
Invoked to load the macro instruction based on its corresponding XML node.

Specified by:
load in interface IMacroInstruction
Overrides:
load in class AbstractMacroCommand
Throws:
org.eclipse.core.runtime.CoreException

write

public void write(int indent,
                  java.lang.StringBuffer sb)
Description copied from class: AbstractMacroCommand
Equivalent to write(indent, writer, false, false)

Specified by:
write in interface IWritable
Overrides:
write in class AbstractMacroCommand

playback

public boolean playback(org.eclipse.swt.widgets.Display display,
                        org.eclipse.swt.widgets.Composite parent,
                        org.eclipse.core.runtime.IProgressMonitor monitor)
                 throws org.eclipse.core.runtime.CoreException
Throws:
org.eclipse.core.runtime.CoreException

mergeEvent

public boolean mergeEvent(org.eclipse.swt.widgets.Event e)
Description copied from interface: IMacroCommand
If this command occurs consecutively, then this method gives this command a chance to merge mutliple commands together to reduce the overhead.

Specified by:
mergeEvent in interface IMacroCommand
Overrides:
mergeEvent in class AbstractMacroCommand

equals

public boolean equals(java.lang.Object obj)
Overwrite this method in order to indicate that two choice commands that have different choice ids are not the same

Overrides:
equals in class AbstractMacroCommand

TPTP 4.4.0 Testing Tools Project
Internal API Specification