de.erichseifert.gral.plots.colors
Class SingleColor

java.lang.Object
  extended by de.erichseifert.gral.plots.colors.SingleColor
All Implemented Interfaces:
ColorMapper

public class SingleColor
extends Object
implements ColorMapper

Class that represents a ColorMapper with a single color.


Constructor Summary
SingleColor(Color color)
          Creates a new instance with the specified color.
 
Method Summary
 Color get(double value)
          Returns the Color according to the specified value.
 Color getColor()
          Returns the color of this ColorMapper.
 void setColor(Color color)
          Sets the color of this ColorMapper.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SingleColor

public SingleColor(Color color)
Creates a new instance with the specified color.

Parameters:
color - Color to use.
Method Detail

get

public Color get(double value)
Description copied from interface: ColorMapper
Returns the Color according to the specified value.

Specified by:
get in interface ColorMapper
Parameters:
value - Value of color.
Returns:
Color.

getColor

public Color getColor()
Returns the color of this ColorMapper.

Returns:
Color.

setColor

public void setColor(Color color)
Sets the color of this ColorMapper.

Parameters:
color - Color to be set.


Copyright © 2009-2010. All Rights Reserved.