com.hammingweight.hammock.mocks.microedition.lcdui
Class MockCanvas

java.lang.Object
  extended by javax.microedition.lcdui.Displayable
      extended by javax.microedition.lcdui.Canvas
          extended by com.hammingweight.hammock.mocks.microedition.lcdui.MockCanvas
All Implemented Interfaces:
IMockObject

public class MockCanvas
extends javax.microedition.lcdui.Canvas
implements IMockObject


Field Summary
static MockMethod MTHD_ADD_COMMAND_$_COMMAND
           
static MockMethod MTHD_GET_GAME_ACTION_$_INT
           
static MockMethod MTHD_GET_HEIGHT
           
static MockMethod MTHD_GET_KEY_CODE_$_INT
           
static MockMethod MTHD_GET_KEY_NAME_$_INT
           
static MockMethod MTHD_GET_TICKER
           
static MockMethod MTHD_GET_TITLE
           
static MockMethod MTHD_GET_WIDTH
           
static MockMethod MTHD_HAS_POINTER_EVENTS
           
static MockMethod MTHD_HAS_POINTER_MOTION_EVENTS
           
static MockMethod MTHD_HAS_REPEAT_EVENTS
           
static MockMethod MTHD_HIDE_NOTIFY
           
static MockMethod MTHD_IS_DOUBLE_BUFFERED
           
static MockMethod MTHD_IS_SHOWN
           
static MockMethod MTHD_KEY_PRESSED_$_INT
           
static MockMethod MTHD_KEY_RELEASED_$_INT
           
static MockMethod MTHD_KEY_REPEATED_$_INT
           
static MockMethod MTHD_PAINT_$_GRAPHICS
           
static MockMethod MTHD_POINTER_DRAGGED_$_INT_INT
           
static MockMethod MTHD_POINTER_PRESSED_$_INT_INT
           
static MockMethod MTHD_POINTER_RELEASED_$_INT_INT
           
static MockMethod MTHD_REMOVE_COMMAND_$_COMMAND
           
static MockMethod MTHD_SET_COMMAND_LISTENER_$_COMMANDLISTENER
           
static MockMethod MTHD_SET_FULL_SCREEN_MODE_$_BOOLEAN
           
static MockMethod MTHD_SET_TICKER_$_TICKER
           
static MockMethod MTHD_SET_TITLE_$_STRING
           
static MockMethod MTHD_SHOW_NOTIFY
           
static MockMethod MTHD_SIZE_CHANGED_$_INT_INT
           
 
Fields inherited from class javax.microedition.lcdui.Canvas
DOWN, FIRE, GAME_A, GAME_B, GAME_C, GAME_D, KEY_NUM0, KEY_NUM1, KEY_NUM2, KEY_NUM3, KEY_NUM4, KEY_NUM5, KEY_NUM6, KEY_NUM7, KEY_NUM8, KEY_NUM9, KEY_POUND, KEY_STAR, LEFT, RIGHT, UP
 
Constructor Summary
MockCanvas()
           
MockCanvas(IInvocationHandler handler)
           
 
Method Summary
 void addCommand(javax.microedition.lcdui.Command arg0)
           
 int getGameAction(int arg0)
           
 int getHeight()
           
 IInvocationHandler getInvocationHandler()
          Gets the invocation handler that the mock object uses to evaluate method invocations.
 int getKeyCode(int arg0)
           
 java.lang.String getKeyName(int arg0)
           
 javax.microedition.lcdui.Ticker getTicker()
           
 java.lang.String getTitle()
           
 int getWidth()
           
 boolean hasPointerEvents()
           
 boolean hasPointerMotionEvents()
           
 boolean hasRepeatEvents()
           
 void hideNotify()
           
 boolean isDoubleBuffered()
           
 boolean isShown()
           
 void keyPressed(int arg0)
           
 void keyReleased(int arg0)
           
 void keyRepeated(int arg0)
           
 void paint(javax.microedition.lcdui.Graphics arg0)
           
 void pointerDragged(int arg0, int arg1)
           
 void pointerPressed(int arg0, int arg1)
           
 void pointerReleased(int arg0, int arg1)
           
 void removeCommand(javax.microedition.lcdui.Command arg0)
           
 void setCommandListener(javax.microedition.lcdui.CommandListener arg0)
           
 void setFullScreenMode(boolean arg0)
           
 void setInvocationHandler(IInvocationHandler handler)
          Sets the invocation handler that the mock object should use to evaluate method invocations.
 void setTicker(javax.microedition.lcdui.Ticker arg0)
           
 void setTitle(java.lang.String arg0)
           
 void showNotify()
           
 void sizeChanged(int arg0, int arg1)
           
 
Methods inherited from class javax.microedition.lcdui.Canvas
repaint, repaint, serviceRepaints
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MTHD_ADD_COMMAND_$_COMMAND

public static final MockMethod MTHD_ADD_COMMAND_$_COMMAND

MTHD_GET_GAME_ACTION_$_INT

public static final MockMethod MTHD_GET_GAME_ACTION_$_INT

MTHD_GET_HEIGHT

public static final MockMethod MTHD_GET_HEIGHT

MTHD_GET_KEY_CODE_$_INT

public static final MockMethod MTHD_GET_KEY_CODE_$_INT

MTHD_GET_KEY_NAME_$_INT

public static final MockMethod MTHD_GET_KEY_NAME_$_INT

MTHD_GET_TICKER

public static final MockMethod MTHD_GET_TICKER

MTHD_GET_TITLE

public static final MockMethod MTHD_GET_TITLE

MTHD_GET_WIDTH

public static final MockMethod MTHD_GET_WIDTH

MTHD_HAS_POINTER_EVENTS

public static final MockMethod MTHD_HAS_POINTER_EVENTS

MTHD_HAS_POINTER_MOTION_EVENTS

public static final MockMethod MTHD_HAS_POINTER_MOTION_EVENTS

MTHD_HAS_REPEAT_EVENTS

public static final MockMethod MTHD_HAS_REPEAT_EVENTS

MTHD_HIDE_NOTIFY

public static final MockMethod MTHD_HIDE_NOTIFY

MTHD_IS_DOUBLE_BUFFERED

public static final MockMethod MTHD_IS_DOUBLE_BUFFERED

MTHD_IS_SHOWN

public static final MockMethod MTHD_IS_SHOWN

MTHD_KEY_PRESSED_$_INT

public static final MockMethod MTHD_KEY_PRESSED_$_INT

MTHD_KEY_RELEASED_$_INT

public static final MockMethod MTHD_KEY_RELEASED_$_INT

MTHD_KEY_REPEATED_$_INT

public static final MockMethod MTHD_KEY_REPEATED_$_INT

MTHD_PAINT_$_GRAPHICS

public static final MockMethod MTHD_PAINT_$_GRAPHICS

MTHD_POINTER_DRAGGED_$_INT_INT

public static final MockMethod MTHD_POINTER_DRAGGED_$_INT_INT

MTHD_POINTER_PRESSED_$_INT_INT

public static final MockMethod MTHD_POINTER_PRESSED_$_INT_INT

MTHD_POINTER_RELEASED_$_INT_INT

public static final MockMethod MTHD_POINTER_RELEASED_$_INT_INT

MTHD_REMOVE_COMMAND_$_COMMAND

public static final MockMethod MTHD_REMOVE_COMMAND_$_COMMAND

MTHD_SET_COMMAND_LISTENER_$_COMMANDLISTENER

public static final MockMethod MTHD_SET_COMMAND_LISTENER_$_COMMANDLISTENER

MTHD_SET_FULL_SCREEN_MODE_$_BOOLEAN

public static final MockMethod MTHD_SET_FULL_SCREEN_MODE_$_BOOLEAN

MTHD_SET_TICKER_$_TICKER

public static final MockMethod MTHD_SET_TICKER_$_TICKER

MTHD_SET_TITLE_$_STRING

public static final MockMethod MTHD_SET_TITLE_$_STRING

MTHD_SHOW_NOTIFY

public static final MockMethod MTHD_SHOW_NOTIFY

MTHD_SIZE_CHANGED_$_INT_INT

public static final MockMethod MTHD_SIZE_CHANGED_$_INT_INT
Constructor Detail

MockCanvas

public MockCanvas()

MockCanvas

public MockCanvas(IInvocationHandler handler)
Method Detail

setInvocationHandler

public final void setInvocationHandler(IInvocationHandler handler)
Description copied from interface: IMockObject
Sets the invocation handler that the mock object should use to evaluate method invocations.

Specified by:
setInvocationHandler in interface IMockObject
Parameters:
handler - The invocation handler to be used by the mock object.

getInvocationHandler

public final IInvocationHandler getInvocationHandler()
Description copied from interface: IMockObject
Gets the invocation handler that the mock object uses to evaluate method invocations.

Specified by:
getInvocationHandler in interface IMockObject
Returns:
The invocation handler used by the mock object.

addCommand

public void addCommand(javax.microedition.lcdui.Command arg0)
Overrides:
addCommand in class javax.microedition.lcdui.Displayable

getGameAction

public int getGameAction(int arg0)
Overrides:
getGameAction in class javax.microedition.lcdui.Canvas

getHeight

public int getHeight()
Overrides:
getHeight in class javax.microedition.lcdui.Displayable

getKeyCode

public int getKeyCode(int arg0)
Overrides:
getKeyCode in class javax.microedition.lcdui.Canvas

getKeyName

public java.lang.String getKeyName(int arg0)
Overrides:
getKeyName in class javax.microedition.lcdui.Canvas

getTicker

public javax.microedition.lcdui.Ticker getTicker()
Overrides:
getTicker in class javax.microedition.lcdui.Displayable

getTitle

public java.lang.String getTitle()
Overrides:
getTitle in class javax.microedition.lcdui.Displayable

getWidth

public int getWidth()
Overrides:
getWidth in class javax.microedition.lcdui.Displayable

hasPointerEvents

public boolean hasPointerEvents()
Overrides:
hasPointerEvents in class javax.microedition.lcdui.Canvas

hasPointerMotionEvents

public boolean hasPointerMotionEvents()
Overrides:
hasPointerMotionEvents in class javax.microedition.lcdui.Canvas

hasRepeatEvents

public boolean hasRepeatEvents()
Overrides:
hasRepeatEvents in class javax.microedition.lcdui.Canvas

hideNotify

public void hideNotify()
Overrides:
hideNotify in class javax.microedition.lcdui.Canvas

isDoubleBuffered

public boolean isDoubleBuffered()
Overrides:
isDoubleBuffered in class javax.microedition.lcdui.Canvas

isShown

public boolean isShown()
Overrides:
isShown in class javax.microedition.lcdui.Displayable

keyPressed

public void keyPressed(int arg0)
Overrides:
keyPressed in class javax.microedition.lcdui.Canvas

keyReleased

public void keyReleased(int arg0)
Overrides:
keyReleased in class javax.microedition.lcdui.Canvas

keyRepeated

public void keyRepeated(int arg0)
Overrides:
keyRepeated in class javax.microedition.lcdui.Canvas

paint

public void paint(javax.microedition.lcdui.Graphics arg0)
Specified by:
paint in class javax.microedition.lcdui.Canvas

pointerDragged

public void pointerDragged(int arg0,
                           int arg1)
Overrides:
pointerDragged in class javax.microedition.lcdui.Canvas

pointerPressed

public void pointerPressed(int arg0,
                           int arg1)
Overrides:
pointerPressed in class javax.microedition.lcdui.Canvas

pointerReleased

public void pointerReleased(int arg0,
                            int arg1)
Overrides:
pointerReleased in class javax.microedition.lcdui.Canvas

removeCommand

public void removeCommand(javax.microedition.lcdui.Command arg0)
Overrides:
removeCommand in class javax.microedition.lcdui.Displayable

setCommandListener

public void setCommandListener(javax.microedition.lcdui.CommandListener arg0)
Overrides:
setCommandListener in class javax.microedition.lcdui.Displayable

setFullScreenMode

public void setFullScreenMode(boolean arg0)
Overrides:
setFullScreenMode in class javax.microedition.lcdui.Canvas

setTicker

public void setTicker(javax.microedition.lcdui.Ticker arg0)
Overrides:
setTicker in class javax.microedition.lcdui.Displayable

setTitle

public void setTitle(java.lang.String arg0)
Overrides:
setTitle in class javax.microedition.lcdui.Displayable

showNotify

public void showNotify()
Overrides:
showNotify in class javax.microedition.lcdui.Canvas

sizeChanged

public void sizeChanged(int arg0,
                        int arg1)
Overrides:
sizeChanged in class javax.microedition.lcdui.Canvas