GP.Graphics
Class Composite

java.lang.Object
  |
  +--GP.Graphics.Shape
        |
        +--GP.Containers.Manager
              |
              +--GP.Graphics.Composite
All Implemented Interfaces:
Behavioral, Clippable, Colorable, Container, Graphic, Movable, Orientable, Originable, PackageFriendlyContainer, Playable, Positionable, Reactive, Refreshable, Scalable, Selectable, Viewable

public class Composite
extends GP.Containers.Manager


Fields inherited from class GP.Graphics.Shape
ourNumShapes
 
Constructor Summary
Composite()
           
Composite(Container container)
           
 
Method Summary
 Position GetOffset()
           
 Position GetPosition()
          This method should return the current position of the object.
 Size GetSize()
          This method should return the current size of the object.
 boolean IsPositionInside(Position position)
          This methods should determine whether the position passed into it is inside the graphical boundries of the object, and return the result of that calculation.
 void Move(double x, double y)
           
 void Move(Value x, Value y)
           
 void Move(Velocity velocity)
           
 boolean PositionIsOnlyInsideMe(Position position)
          This method should determine whether the position passed into it is inside the graphical boundries of the object, but not within any of its sub-objects, and return the result of that calculation.
 void SetColor(Color color)
          This method should set the current color of the object.
 void SetPosition(Position position)
          This method should set the current position of the object.
 
Methods inherited from class GP.Containers.Manager
AddItem, ApplyBehaviors, ApplyInstincts, Copy, DisableClipping, DoForEach, EnableClipping, GetActiveGraphic, GetComponent, GetGPGraphic, GetGraphic, GetItemsList, GetRandomPosition, GetSource, GetTopLevel, NeedToUpdate, NumberOfItems, ObjectSelected, PreferedSize, Realize, Refresh, RemoveAllItems, RemoveItem, Scale, SetBorderWidth, SetGeometryManager, SetHorizontalAligner, SetSelectionReactor, SetSize, SetVerticalAligner, toString
 
Methods inherited from class GP.Graphics.Shape
Act, AddBehavior, DeSelect, equals, Fill, Frame, GetApplet, GetBoxBoundedSize, GetColor, GetContainer, GetCurrentTime, GetFillStyle, GetOrientation, GetPivot, Hide, IsVisible, MoveBackward, MoveForward, MoveToBack, MoveToFront, Pause, Play, React, RemoveAllBehaviors, RemoveBehavior, ReplaceAllBehaviors, Scale, Scale, Select, SetContainer, SetFillStyle, SetOrientation, SetPivot, Show, Show, Start, Stop, Turn, Turn, Turn, Turn, Turn, Turn
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface GP.Scalable
Scale, Scale
 
Methods inherited from interface GP.Viewable
Hide, IsVisible, Show
 
Methods inherited from interface GP.Playable
GetCurrentTime, Pause, Play, Stop
 
Methods inherited from interface GP.Colorable
GetColor
 

Constructor Detail

Composite

public Composite()

Composite

public Composite(Container container)
Method Detail

PositionIsOnlyInsideMe

public boolean PositionIsOnlyInsideMe(Position position)
Description copied from interface: Graphic
This method should determine whether the position passed into it is inside the graphical boundries of the object, but not within any of its sub-objects, and return the result of that calculation. This will usually be an identaical result to IsPositionInside(GP.Attributes.Position), but may differ when dealing with composite structures such as GP.MultiManagers
Overrides:
PositionIsOnlyInsideMe in class GP.Containers.Manager
Following copied from interface: GP.Graphic
Parameters:
position - the position in question
Returns:
true if the position is inside this object only, false otherwise

IsPositionInside

public boolean IsPositionInside(Position position)
Description copied from interface: Graphic
This methods should determine whether the position passed into it is inside the graphical boundries of the object, and return the result of that calculation.
Overrides:
IsPositionInside in class Shape
Following copied from interface: GP.Graphic
Parameters:
position - the position in question
Returns:
true if the position is inside, false otherwise

SetColor

public void SetColor(Color color)
Description copied from interface: Colorable
This method should set the current color of the object.
Overrides:
SetColor in class Shape
Following copied from interface: GP.Colorable
Parameters:
color - the new color

GetSize

public Size GetSize()
Description copied from interface: Scalable
This method should return the current size of the object.
Overrides:
GetSize in class GP.Containers.Manager
Following copied from interface: GP.Scalable
Returns:
the current size of the object

Move

public void Move(double x,
                 double y)
Overrides:
Move in class Shape

Move

public void Move(Value x,
                 Value y)
Overrides:
Move in class Shape

Move

public void Move(Velocity velocity)
Overrides:
Move in class Shape

SetPosition

public void SetPosition(Position position)
Description copied from interface: Positionable
This method should set the current position of the object.
Overrides:
SetPosition in class Shape
Following copied from interface: GP.Positionable
Parameters:
position - the new position

GetPosition

public Position GetPosition()
Description copied from interface: Positionable
This method should return the current position of the object.
Overrides:
GetPosition in class Shape
Following copied from interface: GP.Positionable
Returns:
the current position of the object

GetOffset

public Position GetOffset()
Overrides:
GetOffset in class GP.Containers.Manager
Following copied from interface: GP.PackageFriendlyContainer
Returns:
the offset from the applet's origin