TestDataGenerator (jCharts-0.7.5 API)
Keywords: org.jCharts.test.TestDataGenerator,TestDataGenerator class

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jCharts.test
Class TestDataGenerator

    java.lang.Object
      |
      +--org.jCharts.test.TestDataGenerator

public final class TestDataGenerator
extends java.lang.Object

Field Summary
`private static java.awt.Font[]` | `ALL_FONTS`

Constructor Summary
`TestDataGenerator()`

Method Summary
`protected static java.awt.Color` | `getRandomColor()` Random Color generator.
`static java.awt.Font` | `getRandomFont(double minSize, double maxSize)` Random font generator based on the available Fonts on this machine.
`static double` | `getRandomNumber(double maxValue)` Random number generator.
`protected static double` | `getRandomNumber(double minValue, double maxValue)` Random number generator in specified range.
`static double[]` | `getRandomNumbers(int numToGenerate, double minValue, double maxValue)` Random numbers generator in specified range.
`static double[][]` | `getRandomNumbers(int numberOfDataSets, int numToGenerate, double minValue, double maxValue)` Random numbers generator in specified range.
`protected static java.awt.Paint` | `getRandomPaint()` Random Paint generator.
`static java.awt.Paint[]` | `getRandomPaints(int numToCreate)` Random Color generator.
`static java.awt.geom.Point2D.Double[]` | `getRandomPoints(int numToGenerate, double xMinValue, double xMaxValue, double yMinValue, double yMaxValue)` Random numbers generator in specified range.
`protected static java.lang.String` | `getRandomString(int maxStringLength, boolean canBeNull)` Random String generator.
`protected static java.lang.String[]` | `getRandomStrings(int numToCreate, int maxStringLength, boolean canBeNull)` Random String generator.
`protected static void` | `randomizeAxisProperties(AxisProperties axisProperties)` Takes the passed AxisProperties and randomizes it.
`protected static void` | `randomizeLegend(LegendProperties legendProperties)` Takes the passed Legend and randomizes it.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### ALL_FONTS

    private static final java.awt.Font[] ALL_FONTS

Constructor Detail

### TestDataGenerator

    public TestDataGenerator()

Method Detail

### getRandomFont

    public static java.awt.Font getRandomFont(double minSize,
                                              double maxSize)

  Random font generator based on the available Fonts on this machine.

  Parameters:
    `minSize` -
    `maxSize` -
  Returns:
    Font

### getRandomNumber

    public static double getRandomNumber(double maxValue)

  Random number generator.

  Parameters:
    `maxValue` -
  Returns:
    double

### getRandomNumber

    protected static double getRandomNumber(double minValue,
                                            double maxValue)

  Random number generator in specified range.

  Parameters:
    `minValue` -
    `maxValue` -
  Returns:
    double

### getRandomNumbers

    public static double[] getRandomNumbers(int numToGenerate,
                                            double minValue,
                                            double maxValue)

  Random numbers generator in specified range.

  Parameters:
    `numToGenerate` - the number of doubles to generate
    `minValue` -
    `maxValue` -
  Returns:
    double[]

### getRandomNumbers

    public static double[][] getRandomNumbers(int numberOfDataSets,
                                              int numToGenerate,
                                              double minValue,
                                              double maxValue)

  Random numbers generator in specified range.

  Parameters:
    `numberOfDataSets` - to generate
    `numToGenerate` - the number of doubles to generate
    `minValue` -
    `maxValue` -
  Returns:
    double[]

### getRandomPoints

    public static java.awt.geom.Point2D.Double[] getRandomPoints(int numToGenerate,
                                                                 double xMinValue,
                                                                 double xMaxValue,
                                                                 double yMinValue,
                                                                 double yMaxValue)

  Random numbers generator in specified range.

  Parameters:
    `numToGenerate` - the number of doubles to generate
    `xMinValue` -
    `xMaxValue` -
    `yMinValue` -
    `yMaxValue` -
  Returns:
    Point.Double[]

### getRandomPaint

    protected static java.awt.Paint getRandomPaint()

  Random Paint generator.

  Returns:
    Paint

### getRandomPaints

    public static java.awt.Paint[] getRandomPaints(int numToCreate)

  Random Color generator.

  Returns:
    Paint[]

### getRandomColor

    protected static java.awt.Color getRandomColor()

  Random Color generator.

  Returns:
    Color

### getRandomString

    protected static java.lang.String getRandomString(int maxStringLength,
                                                      boolean canBeNull)

  Random String generator.

  Parameters:
    `maxStringLength` -
    `canBeNull` -
  Returns:
    String

### getRandomStrings

    protected static java.lang.String[] getRandomStrings(int numToCreate,
                                                         int maxStringLength,
                                                         boolean canBeNull)

  Random String generator.

  Returns:
    String[]

### randomizeAxisProperties

    protected static void randomizeAxisProperties(AxisProperties axisProperties)

  Takes the passed AxisProperties and randomizes it.

  Parameters:
    `axisProperties` -

### randomizeLegend

    protected static void randomizeLegend(LegendProperties legendProperties)

  Takes the passed Legend and randomizes it.

  Parameters:
    `legendProperties` -

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD