org.askalon.graph.chart
Enum Renderer

java.lang.Object
  extended by java.lang.Enum<Renderer>
      extended by org.askalon.graph.chart.Renderer
All Implemented Interfaces:
Serializable, Comparable<Renderer>

public enum Renderer
extends Enum<Renderer>

This enum should be used to create renderer-specific ChartFactories.

Author:
Georg Schild and Franz Endstrasser
See Also:
ChartFactory

Enum Constant Summary
HARD
          The hard renderer uses hardware rendering based on Java3D to display the charts.
SOFT
          The sofware renderer uses an own rendering engine based on Java2D.
 
Method Summary
 ChartFactory getFactory()
          Call this to get an instance of a renderer specific ChartFactory.
 boolean isChartAvailable(ChartType chart)
          Determines the availability of a chart-type for this renderer.
abstract  boolean isChartAvailable(Class<? extends Chart> c)
          Determines the availability of a chart-type for this renderer.
abstract  boolean isFunctional()
          Determines the availability of a renderer-type.
static Renderer valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Renderer[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

HARD

public static final Renderer HARD
The hard renderer uses hardware rendering based on Java3D to display the charts.


SOFT

public static final Renderer SOFT
The sofware renderer uses an own rendering engine based on Java2D.

Method Detail

values

public static final Renderer[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(Renderer c : Renderer.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static Renderer valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name

isFunctional

public abstract boolean isFunctional()
Determines the availability of a renderer-type.

Returns:
true if the renderer works and is ready to use, false if this renderer type is not available

isChartAvailable

public abstract boolean isChartAvailable(Class<? extends Chart> c)
Determines the availability of a chart-type for this renderer.

Parameters:
c - the class of the chart to check
Returns:
true if the chart is available for this renderer, false otherwise
See Also:
isChartAvailable(ChartType)

isChartAvailable

public boolean isChartAvailable(ChartType chart)
Determines the availability of a chart-type for this renderer.

Parameters:
chart - the type of the chart for which the availability should be checked
Returns:
true if the chart is available for this renderer, false otherwise
See Also:
ChartType, isChartAvailable(Class)

getFactory

public ChartFactory getFactory()
Call this to get an instance of a renderer specific ChartFactory. This will usually be the same all the time, for all charts used by the application.

Returns:
an instance of a ChartFactory
See Also:
ChartFactory, getFactoryClass()


Part of:
Askalon_Logo
ASKALON Visualisation Diagrams