VASSAL.counters
Class Replace

java.lang.Object
  |
  +--VASSAL.counters.Decorator
        |
        +--VASSAL.counters.PlaceMarker
              |
              +--VASSAL.counters.Replace
All Implemented Interfaces:
EditablePiece, GamePiece

public class Replace
extends PlaceMarker

GamePiece trait that replaces a GamePiece with another one


Nested Class Summary
protected static class Replace.Ed
           
 
Nested classes inherited from class VASSAL.counters.PlaceMarker
 
Field Summary
static java.lang.String ID
           
 
Fields inherited from class VASSAL.counters.PlaceMarker
command, key, markerSpec
 
Constructor Summary
Replace()
           
Replace(java.lang.String type, GamePiece inner)
           
 
Method Summary
 java.lang.String getDescription()
          A plain-English description of this type of piece
 PieceEditor getEditor()
          Get the configurer for this trait
 HelpFile getHelpFile()
           
 java.lang.String myGetType()
           
 Command myKeyEvent(javax.swing.KeyStroke stroke)
          The response of this trait alone to the given KeyStroke
 
Methods inherited from class VASSAL.counters.PlaceMarker
boundingBox, draw, getName, myGetKeyCommands, myGetState, mySetState, mySetType, selectionBounds
 
Methods inherited from class VASSAL.counters.Decorator
getDecorator, getId, getInner, getInnermost, getKeyCommands, getMap, getOutermost, getParent, getPosition, getProperty, getState, getType, keyEvent, mergeState, setId, setInner, setMap, setParent, setPosition, setProperty, setState
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface VASSAL.counters.GamePiece
getId, getMap, getParent, getPosition, getProperty, getState, getType, keyEvent, setId, setMap, setParent, setPosition, setProperty, setState
 

Field Detail

ID

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

Replace

public Replace()

Replace

public Replace(java.lang.String type,
               GamePiece inner)
Method Detail

myKeyEvent

public Command myKeyEvent(javax.swing.KeyStroke stroke)
Description copied from class: Decorator
The response of this trait alone to the given KeyStroke

Overrides:
myKeyEvent in class PlaceMarker
Parameters:
stroke -
Returns:
null if no effect
See Also:
Decorator.keyEvent(javax.swing.KeyStroke)

getDescription

public java.lang.String getDescription()
Description copied from interface: EditablePiece
A plain-English description of this type of piece

Specified by:
getDescription in interface EditablePiece
Overrides:
getDescription in class PlaceMarker

getHelpFile

public HelpFile getHelpFile()
Specified by:
getHelpFile in interface EditablePiece
Overrides:
getHelpFile in class PlaceMarker

myGetType

public java.lang.String myGetType()
Overrides:
myGetType in class PlaceMarker
Returns:
the type of this trait alone
See Also:
Decorator.getType()

getEditor

public PieceEditor getEditor()
Description copied from interface: EditablePiece
Get the configurer for this trait

Specified by:
getEditor in interface EditablePiece
Overrides:
getEditor in class PlaceMarker