com.mtp.pounder
Class KeyItem

java.lang.Object
  |
  +--com.mtp.pounder.RecordingItem
        |
        +--com.mtp.pounder.ComponentItem
              |
              +--com.mtp.pounder.KeyItem

public class KeyItem
extends ComponentItem

Represents a keyboard event.

Author:
Matthew Pekar

Field Summary
protected  char keyChar
           
protected  int keyCode
           
protected  int modifiers
           
protected  int type
          Pressed, released, or typed.
 
Fields inherited from class com.mtp.pounder.ComponentItem
component, robots, windowID
 
Fields inherited from class com.mtp.pounder.RecordingItem
decimalNumberFormat, delay
 
Constructor Summary
KeyItem(Element e, PounderPrefs prefs, ComponentIdentifierFactory f)
           
KeyItem(int windowID, ComponentIdentifier component, int keyCode, char keyChar, int type, int modifiers, long delay)
           
KeyItem(KeyEvent e, int windowID, long delay, ComponentIdentifierFactory f)
           
 
Method Summary
protected  void addXMLAttributes(Element e, Document doc)
           
protected  Element buildXMLElement(Document doc)
           
 boolean equals(Object o)
          Should be called by all subclasses.
protected  String getTypeAsString(int type)
           
 void playback(WindowWatcher ww, PounderPrefs prefs)
          Playback on this Component.
 String toString()
           
 
Methods inherited from class com.mtp.pounder.ComponentItem
getAttribs, getComponent, getComponentIdentifier, getRobot, getWindowID, setComponentIdentifier, setWindowID
 
Methods inherited from class com.mtp.pounder.RecordingItem
getDelay, instantiate, setDelay, toXML
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

keyCode

protected int keyCode

keyChar

protected char keyChar

type

protected int type
Pressed, released, or typed.


modifiers

protected int modifiers
Constructor Detail

KeyItem

public KeyItem(Element e,
               PounderPrefs prefs,
               ComponentIdentifierFactory f)

KeyItem

public KeyItem(KeyEvent e,
               int windowID,
               long delay,
               ComponentIdentifierFactory f)

KeyItem

public KeyItem(int windowID,
               ComponentIdentifier component,
               int keyCode,
               char keyChar,
               int type,
               int modifiers,
               long delay)
Method Detail

buildXMLElement

protected Element buildXMLElement(Document doc)
Specified by:
buildXMLElement in class RecordingItem

addXMLAttributes

protected void addXMLAttributes(Element e,
                                Document doc)
Overrides:
addXMLAttributes in class ComponentItem

equals

public boolean equals(Object o)
Description copied from class: RecordingItem
Should be called by all subclasses.

Overrides:
equals in class ComponentItem

playback

public void playback(WindowWatcher ww,
                     PounderPrefs prefs)
              throws PlaybackException
Description copied from class: RecordingItem
Playback on this Component.

Specified by:
playback in class RecordingItem
PlaybackException

getTypeAsString

protected String getTypeAsString(int type)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2002 Matthew Pekar. All Rights Reserved.