|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectSceneElement
An element that knows how to draw itself in a scene with a turtle
Field Summary | |
protected Picture |
myPic
the picture that this element holds |
protected SceneElement |
next
the next element in the list -- any SceneElement |
Constructor Summary | |
SceneElement()
|
Method Summary | |
void |
add(SceneElement node)
Add the input node after the last node in this list. |
void |
drawFromMeOn(Picture bg)
Method to draw from this node on in the list. |
abstract void |
drawWith(Turtle t)
|
SceneElement |
getNext()
|
Picture |
getPicture()
Returns the picture in the node. |
void |
insertAfter(SceneElement node)
Insert the input node after this node. |
SceneElement |
last()
Return the last element in the list |
void |
remove(SceneElement node)
Method to remove node from list, fixing links appropriately. |
SceneElement |
reverse()
Reverse the list starting at this, and return the last element of the list. |
void |
setNext(SceneElement nextOne)
Methods to set and get next elements |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected Picture myPic
protected SceneElement next
Constructor Detail |
public SceneElement()
Method Detail |
public void setNext(SceneElement nextOne)
nextOne
- next element in listpublic SceneElement getNext()
public Picture getPicture()
public void drawFromMeOn(Picture bg)
bg
- Picture to draw drawing onpublic abstract void drawWith(Turtle t)
public void remove(SceneElement node)
node
- element to remove from list.public void insertAfter(SceneElement node)
node
- element to insert after this.public SceneElement last()
public SceneElement reverse()
public void add(SceneElement node)
node
- element to insert after this.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |