All Packages Class Hierarchy This Package Previous Next Index
Class objects.EuObject
java.lang.Object
|
+----objects.EuObject
- public abstract class EuObject
- extends Object
- implements constants, Cloneable
An abstract class from which the concrete EuObject classed are derived.
-
sameAs
- The
-
status
- The status of the object, determining how it appears in the
-
warner
-
-
EuObject()
-
-
atParameter(double)
- Returns the cartesian coordinates at the parameter in the
internal representation of the object.
-
atParameter(EuReal)
- Returns the cartesian coordinates at the parameter in the
internal representation of the object
-
blankoutInvisible(Graphics, mouseInfo)
- If the object is marked
-
castIdentical(EuObject)
- Determines whether or not another object is derived from the same
full object of th epresent one, i.e.
-
cloneObject()
-
-
closureContains(EuVector)
- Determines whether or not a given point is contained
in the closure of the present object (up
to a small error,
-
draw(Graphics, mouseInfo)
- Draw the object to a Graphics canvas.
-
drawFlash(Graphics, mouseInfo, boolean)
- If the object is or was flashing, draw it
to a Graphics canvas, using the color indicated by
-
drawVisible(Graphics, mouseInfo)
- If the object is marked
-
equals(EuObject)
- Compares EuObjects in a mathematical sense: returns true if
they are equal up to a reasonable error (
-
interiorContains(EuVector)
- Determines whether or not a given point is contained
in the interior the present object (up
to a small error,
-
isFull()
-
-
mouseVicinity(mouseVector, mouseInfo)
- Determines whether or not the mouse is close (in a sense
determined in
-
myFullShadow()
- Returns the
-
overlaps(EuObject)
- Determines whether or not another object overlaps nontrivially with
the present one, i.e.
-
setColors(int, int)
- A method for setting the color of the object as it appears on screen.
-
setShadow(int)
- Sets the
-
setStatus(int)
- A method for setting the status of the object
-
setWarner(EuWarner)
- Pass a
-
startFlash()
- Indicate that the objects should be flashed.
-
subType()
- Overridden to return one of the constants A_RADIUS, A_POINT, A_LINE,
A_HALF, AN_INTERVAL, A_CIRCLE, AN_ARC from
the
-
type()
- Overridden to return one of the constants RADIUS, POINT, LINE, CIRCLE from
the
status
public int status
- The status of the object, determining how it appears in the @see EuLab window,
and its accessibility by mouse.
sameAs
public int sameAs
- The @see EuLab number of another object, identical to the present one,
in the same @see EuLab, or -1 if
there is no such object. The first instance points to the second. All other point back
to the first.
warner
protected static EuWarner warner
EuObject
public EuObject()
startFlash
public void startFlash()
- Indicate that the objects should be flashed. Only takes effect on screen after a
drawFlash() command.
setWarner
public void setWarner(EuWarner warner)
- Pass a @see EuWarner to all objects. As the warner is stored in a static variable,
one warner is being shared by all objects.
- Parameters:
- warner - The @see EuWarner
setColors
public void setColors(int normal,
int flash)
- A method for setting the color of the object as it appears on screen.
- Parameters:
- normal - the standard color of this object
- flash - the color used to flash this object
setStatus
public void setStatus(int status)
- A method for setting the status of the object
- Parameters:
- status - the required status
equals
public boolean equals(EuObject other)
- Compares EuObjects in a mathematical sense: returns true if
they are equal up to a reasonable error (@see EuReal).
Overrides Object method. Warning: This is not truly an equivalence relation!
It will be reflexive and symmetric, but could fail to be transitive for
roundoff error reasons.
- Parameters:
- other - the other EuObject
atParameter
public abstract EuWorkVector atParameter(double t)
- Returns the cartesian coordinates at the parameter in the
internal representation of the object.
- Parameters:
- t - the parameter
- Returns:
- a workVector containing the coordinates
atParameter
public EuWorkVector atParameter(EuReal t)
- Returns the cartesian coordinates at the parameter in the
internal representation of the object
- Parameters:
- t - the parameter
- Returns:
- a workVector containing the coordinates
drawVisible
public void drawVisible(Graphics g,
mouseInfo info)
- If the object is marked @see VISIBLE, or if it is flashing, draw it
to a Graphics canvas, using the color indicated by @see color or @see flashcolor.
- Parameters:
- g - the Graphics handle on the window
- info - information used in scaling and positioning the object
drawFlash
public void drawFlash(Graphics g,
mouseInfo info,
boolean endFlash)
- If the object is or was flashing, draw it
to a Graphics canvas, using the color indicated by @see color or @see flashcolor.
- Parameters:
- g - the Graphics handle on the window
- info - information used in scaling and positioning the object
- endFlash - if true, stop flashing and draw in normal color.
blankoutInvisible
public void blankoutInvisible(Graphics g,
mouseInfo info)
- If the object is marked @see HIDDEN or @see HIDDENTARGET, and it is not flashing, draw it
to a Graphics canvas in the @see INVISIBLE color, effectively blanking it out from the canvas.
- Parameters:
- g - the Graphics handle on the window
- info - information used in scaling and positioning the object
draw
public abstract void draw(Graphics g,
mouseInfo info)
- Draw the object to a Graphics canvas. The color must be set
in advance.
- Parameters:
- g - the Graphics handle on the window
- info - information used in scaling and positioning the object
mouseVicinity
public abstract boolean mouseVicinity(mouseVector mouseAt,
mouseInfo info)
- Determines whether or not the mouse is close (in a sense
determined in @see mouseVector) to the object's
representation on screen.
- Parameters:
- mouseAt - The coordinates of the mouse position
- info - information used in locating the object on screen
- Returns:
- true if the mouse is close
castIdentical
public abstract boolean castIdentical(EuObject other)
- Determines whether or not another object is derived from the same
full object of th epresent one, i.e. whether they are equal (up
to a small error, @see EuReal) in
themselves, or
possibly just after being cast to
full circles or full lines
- Parameters:
- other - the object being compared to the present one
- Returns:
- true if they are equal
interiorContains
public abstract boolean interiorContains(EuVector point)
- Determines whether or not a given point is contained
in the interior the present object (up
to a small error, @see EuReal).
- Parameters:
- point - the point being compared to the present object
- Returns:
- true if the point is contained
closureContains
public abstract boolean closureContains(EuVector point)
- Determines whether or not a given point is contained
in the closure of the present object (up
to a small error, @see EuReal).
- Parameters:
- point - the point being compared to the present object
- Returns:
- true if the point is contained
overlaps
public abstract boolean overlaps(EuObject other)
- Determines whether or not another object overlaps nontrivially with
the present one, i.e. whether they have an intersection (up
to a small error, @see EuReal) with infinitely many points.
- Parameters:
- other - the object being compared to the present one
- Returns:
- true if they have an overlap
type
public int type()
- Overridden to return one of the constants RADIUS, POINT, LINE, CIRCLE from
the @see constants interface
subType
public int subType()
- Overridden to return one of the constants A_RADIUS, A_POINT, A_LINE,
A_HALF, AN_INTERVAL, A_CIRCLE, AN_ARC from
the @see constants interface
myFullShadow
public abstract int myFullShadow()
- Returns the @see EuLab number of the full object behind the present one,
or -1 if no such object exists. The full objects always return -1.
- Returns:
- -1 or a EuLab index.
setShadow
public abstract void setShadow(int i)
- Sets the @see EuLab number of the full object behind the present one,
- Returns:
- i the EuLab index.
cloneObject
public EuObject cloneObject()
isFull
public boolean isFull()
- Returns:
- true if the item is of subtype A_RADIUS, A_POINT, A_LINE, A_CIRCLE
All Packages Class Hierarchy This Package Previous Next Index