backend.spheremodel
Class SpherePointCircModel

java.lang.Object
  extended by java.util.Observable
      extended by backend.spheremodel.SphereBasicObject
          extended by backend.spheremodel.SpherePointModel
              extended by backend.spheremodel.SpherePointCircModel
All Implemented Interfaces:
java.util.Observer

public class SpherePointCircModel
extends SpherePointModel
implements java.util.Observer

SpherePointCircModel represents a point that is part of a SphereCircleModel this point will stay with the SphereCircleModel as it is moved around the sphere


Constructor Summary
SpherePointCircModel(float x, float y, float z, java.lang.String ptLbl)
          SpherePointCircModel constructor for reading in SpherePointCircModels from datafiles This constructor should only be used when reading in from files because it does not completely initalize the SpherePointCircModel.
SpherePointCircModel(SphereCircleModel theCirc, javax.vecmath.Point3f startLoc)
          SpherePointCircModel default constructor
 
Method Summary
 SphereCircleModel getCircle()
          getCircle returns the circle this SpherePointCircModel is part of
 void setCircle(SphereCircleModel myCirc)
          setCircle should be used on combination with the constructor meant for reading in SpherePointCircModels from file.
 void setLocation(javax.vecmath.Point3f newLoc)
          setLocation should be called to set this SpherePointCircModel to a new location.
 void update(java.util.Observable o, java.lang.Object arg)
           
 
Methods inherited from class backend.spheremodel.SpherePointModel
equals, getID, getLabel, getPoint, setLabel
 
Methods inherited from class backend.spheremodel.SphereBasicObject
addChild, getChild, getChildCount, getSelected, isBeingRemoved, isHidden, notifyFamily, removeChild, setBeingRemoved, setHidden, setSelected
 
Methods inherited from class java.util.Observable
addObserver, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpherePointCircModel

public SpherePointCircModel(SphereCircleModel theCirc,
                            javax.vecmath.Point3f startLoc)
SpherePointCircModel default constructor

Parameters:
theCirc - is the circle this point will be placed on
startLoc - is a starting location supplied by the user

SpherePointCircModel

public SpherePointCircModel(float x,
                            float y,
                            float z,
                            java.lang.String ptLbl)
SpherePointCircModel constructor for reading in SpherePointCircModels from datafiles This constructor should only be used when reading in from files because it does not completely initalize the SpherePointCircModel. You will need to set a circle to this SpherePointCircModel with the setCircle function if you use this constructor

Parameters:
x - is the x coordinate for this point
y - is the y coordinate for this point
z - is the z coordinate for this point
ptLbl - is the label to place on this SpherePointCircModel
Method Detail

setCircle

public void setCircle(SphereCircleModel myCirc)
setCircle should be used on combination with the constructor meant for reading in SpherePointCircModels from file. This function will be disabled after it is called once or if the SpherePointCircModel was initalizing using the first constructor

Parameters:
myCirc - is the circle to set this SpherePointCircModel to

getCircle

public SphereCircleModel getCircle()
getCircle returns the circle this SpherePointCircModel is part of

Returns:
the SpherePointCircModel we are part of

setLocation

public void setLocation(javax.vecmath.Point3f newLoc)
setLocation should be called to set this SpherePointCircModel to a new location. The location passed in does not have to be even remotely close to the circle. This function will take care of placing it in a 'logical' location on the circle

Overrides:
setLocation in class SpherePointModel
Parameters:
newLoc - is the new location for this SpherePointCircModel to go to

update

public void update(java.util.Observable o,
                   java.lang.Object arg)
Specified by:
update in interface java.util.Observer