|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavalib.worldimages.AImage
javalib.worldimages.ColoredImage
javalib.worldimages.RectangularImage
javalib.worldimages.EllipseImage
class EllipseImage
An outlined ellipse
Field Summary |
---|
Fields inherited from class javalib.worldimages.ColoredImage |
---|
defaultColor |
Fields inherited from interface javalib.worldimages.WorldImage |
---|
LOOKS_SAME |
Constructor Summary | |
---|---|
protected |
EllipseImage(int width,
int height,
Color color,
Mode mode)
The full constructor for an EllipseImage. |
Method Summary | |
---|---|
void |
draw(Graphics2D g)
Draw this image in the provided Graphics2D context. |
(package private) static EllipseImage |
make(int width,
int height)
Another pseudo-constructor with a default color. |
(package private) static EllipseImage |
make(int width,
int height,
Color color)
Pseudo-constructor. |
(package private) static EllipseImage |
make(int width,
int height,
Color color,
Mode mode)
Pseudo-constructor. |
(package private) static EllipseImage |
make(int width,
int height,
IColor color)
Pseudo-constructor. |
(package private) static EllipseImage |
make(int width,
int height,
IColor color,
Mode mode)
Pseudo-constructor. |
(package private) static EllipseImage |
make(int width,
int height,
Mode mode)
Another pseudo-constructor with a default color. |
(package private) ColoredImage |
replaceColor(Color color)
Functional setter for the color field Define this in all concrete subclasses. |
(package private) RectangularImage |
replaceDimensions(int width,
int height)
Functional setter for width and height. |
(package private) ColoredImage |
replaceMode(Mode mode)
Functional setter for the mode field Define this in all concrete subclasses. |
String |
toIndentedString(String indent)
Produce a String that represents this image, indented by the given indent . |
Methods inherited from class javalib.worldimages.RectangularImage |
---|
equals, getBottom, getRight, hashCode, replaceHeight, replaceWidth |
Methods inherited from class javalib.worldimages.ColoredImage |
---|
getColor, getMode, replaceColor |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
protected EllipseImage(int width, int height, Color color, Mode mode)
width
- height
- color
- Method Detail |
---|
public void draw(Graphics2D g)
Graphics2D
context.
g
- the provided Graphics2D
contextstatic EllipseImage make(int width, int height)
width
- height
- static EllipseImage make(int width, int height, Color color)
width
- height
- color
- static EllipseImage make(int width, int height, Color color, Mode mode)
width
- height
- color
- mode
- static EllipseImage make(int width, int height, IColor color)
width
- height
- color
- static EllipseImage make(int width, int height, IColor color, Mode mode)
width
- height
- color
- mode
- static EllipseImage make(int width, int height, Mode mode)
width
- height
- mode
- ColoredImage replaceColor(Color color)
ColoredImage
replaceColor
in class ColoredImage
RectangularImage replaceDimensions(int width, int height)
RectangularImage
replaceDimensions
in class RectangularImage
ColoredImage replaceMode(Mode mode)
ColoredImage
replaceMode
in class ColoredImage
public String toIndentedString(String indent)
WorldImage
String
that represents this image, indented by the given indent
.
Define this in all concrete subclasses.
Convention: The result of toIndentedString() will neither begin nor end with a newline; the specified indent will immediately follow each internal newline.
indent
- the given prefix representing the desired indentation
String
representation of this image
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |