Class FixedColorer<D extends Drawable>
java.lang.Object
org.opentrafficsim.core.animation.FixedColorer<D>
- Type Parameters:
D- the Drawable type
- All Implemented Interfaces:
Colorer<D>
public class FixedColorer<D extends Drawable> extends Object implements Colorer<D>
FixedColorer stores a fixed color for drawing.
Copyright (c) 2003-2019 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information www.simulation.tudelft.nl. The source code and binary code of this software is proprietary information of Delft University of Technology.
Copyright (c) 2003-2019 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information www.simulation.tudelft.nl. The source code and binary code of this software is proprietary information of Delft University of Technology.
- Author:
- Alexander Verbraeck
-
Constructor Summary
Constructors Modifier Constructor Description protectedFixedColorer(Color color)Initialize the FixedColorer with a color. -
Method Summary
Modifier and Type Method Description static <D extends Drawable>
FixedColorer<D>black()static <D extends Drawable>
FixedColorer<D>blue()static <D extends Drawable>
FixedColorer<D>create(Color color)Instantiate a singleton fixed colorer for a certain color.static <D extends Drawable>
FixedColorer<D>cyan()static <D extends Drawable>
FixedColorer<D>darkGray()ColorgetColor(D drawable)Get the color, based on the Drawable object.static <D extends Drawable>
FixedColorer<D>gray()static <D extends Drawable>
FixedColorer<D>green()static <D extends Drawable>
FixedColorer<D>lightGray()static <D extends Drawable>
FixedColorer<D>magenta()static <D extends Drawable>
FixedColorer<D>orange()static <D extends Drawable>
FixedColorer<D>pink()static <D extends Drawable>
FixedColorer<D>red()static <D extends Drawable>
FixedColorer<D>white()static <D extends Drawable>
FixedColorer<D>yellow()
-
Constructor Details
-
FixedColorer
Initialize the FixedColorer with a color.- Parameters:
color- Color; the fixed color to use
-
-
Method Details
-
getColor
Get the color, based on the Drawable object. -
create
Instantiate a singleton fixed colorer for a certain color.- Type Parameters:
D- the Drawable type- Parameters:
color- Color; the fixed color to use- Returns:
- the FixedColorer
-
black
- Type Parameters:
D- the Drawable type- Returns:
- black color
-
blue
- Type Parameters:
D- the Drawable type- Returns:
- blue color
-
cyan
- Type Parameters:
D- the Drawable type- Returns:
- cyan color
-
darkGray
- Type Parameters:
D- the Drawable type- Returns:
- darkGray color
-
gray
- Type Parameters:
D- the Drawable type- Returns:
- gray color
-
green
- Type Parameters:
D- the Drawable type- Returns:
- green color
-
lightGray
- Type Parameters:
D- the Drawable type- Returns:
- lightGray color
-
magenta
- Type Parameters:
D- the Drawable type- Returns:
- magenta color
-
orange
- Type Parameters:
D- the Drawable type- Returns:
- orange color
-
pink
- Type Parameters:
D- the Drawable type- Returns:
- pink color
-
red
- Type Parameters:
D- the Drawable type- Returns:
- red color
-
white
- Type Parameters:
D- the Drawable type- Returns:
- white color
-
yellow
- Type Parameters:
D- the Drawable type- Returns:
- yellow color
-