Class tred.Item
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class tred.Item

java.lang.Object
   |
   +----tred.EditorObject
           |
           +----tred.Item

public class Item
extends EditorObject
implements Cloneable
abstract class Item to items

Method Index

 o delete(int, int)
This methid is implemented to be overridden.
 o getSlot()
 o isInfinite()
 o move(EditorObject, int, int)
This method changes the objects slot reference to new location.
 o move(int, int)
This method changes the objects x and y coordinates to new location.
 o move(Trash, int, int)
 o paint(Graphics)
Generic paint method for Items.
 o setInfinite()
 o toString()

Methods

 o setInfinite
  public void setInfinite()
 o isInfinite
  public boolean isInfinite()
 o getSlot
  protected Slot getSlot()
Returns:
the slot this item is attached to.
See Also:
Slot
 o move
  public void move(int x,
                   int y)
This method changes the objects x and y coordinates to new location.
Overrides:
move in class EditorObject
 o delete
  public boolean delete(int x,
                        int y)
This methid is implemented to be overridden.
Overrides:
delete in class EditorObject
 o move
  public void move(Trash trash,
                   int x,
                   int y)
 o move
  public void move(EditorObject object,
                   int x,
                   int y)
This method changes the objects slot reference to new location. If there was any previous location where this object was attached to the item reference of the old slot is set empty by invoking putItem(null) for the old slot. If reference to origSlot is null it is set to point to the new slot.
Overrides:
move in class EditorObject
 o paint
  public boolean paint(Graphics g)
Generic paint method for Items. The items movement after the release (MouseUp) is handled here.
Returns:
true if the place this object is moving to is reached; false if the movement is not completed.
Overrides:
paint in class EditorObject
 o toString
  public String toString()
Overrides:
toString in class EditorObject

All Packages  Class Hierarchy  This Package  Previous  Next  Index