org.omegahat.Graphics.Utils
Class ColorParser
java.lang.Object
|
+--org.omegahat.Graphics.Utils.ColorParser
- All Implemented Interfaces:
- ColorParserInt
- public class ColorParser
- extends java.lang.Object
- implements ColorParserInt
Facilities for processing color specifications
in string form; for example, from properties files, etc.
|
Field Summary |
protected java.util.Hashtable |
namedColors
Table of named colors. |
|
Method Summary |
java.util.Hashtable |
namedColors()
|
java.util.Hashtable |
namedColors(java.util.Hashtable props)
|
java.util.Hashtable |
namedColors(java.io.InputStream stream)
|
java.util.Hashtable |
namedColors(java.lang.String[] names,
java.awt.Color[] colors)
|
java.awt.Color |
parse(java.lang.String c)
Parse the specified string and lookup the
color in the internal table of this class
or use the default decode method. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
namedColors
protected java.util.Hashtable namedColors
- Table of named colors.
ColorParser
public ColorParser()
parse
public java.awt.Color parse(java.lang.String c)
- Parse the specified string and lookup the
color in the internal table of this class
or use the default
decode method.
- Specified by:
parse in interface ColorParserInt
namedColors
public java.util.Hashtable namedColors()
namedColors
public java.util.Hashtable namedColors(java.io.InputStream stream)
namedColors
public java.util.Hashtable namedColors(java.util.Hashtable props)
namedColors
public java.util.Hashtable namedColors(java.lang.String[] names,
java.awt.Color[] colors)