com.github.cage.image
Class RgbColorGenerator
java.lang.Object
com.github.cage.image.RgbColorGenerator
- All Implemented Interfaces:
- IGenerator<Color>
public class RgbColorGenerator
- extends Object
- implements IGenerator<Color>
Random RGB Color
object generator. The returned Color
-s are
not too bright so they look good on white background. This class is thread
safe.
- Author:
- akiraly
Method Summary |
Color |
next()
Returns an object with type T on every call. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RgbColorGenerator
public RgbColorGenerator(Random rnd)
- Constructor.
- Parameters:
rnd
- random generator to be used, can be null
next
public Color next()
- Description copied from interface:
IGenerator
- Returns an object with type
T
on every call. The returned
object does not have to be a new instance.
- Specified by:
next
in interface IGenerator<Color>
- Returns:
- generated object
Copyright © 2011. All Rights Reserved.