|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.Vector<Object>
org.cip4.jdflib.datatypes.JDFNumList
org.cip4.jdflib.datatypes.JDFCMYKColor
public class JDFCMYKColor
This class is a representation of a CMYK color (JDFCMYKColor). It is a blank separated list of double values consisting of C the cyan color, M the magenta color, Y the yellow color and K the black color value.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.cip4.jdflib.datatypes.JDFBaseDataTypes |
|---|
JDFBaseDataTypes.EnumFitsValue |
| Field Summary |
|---|
| Fields inherited from class java.util.Vector |
|---|
capacityIncrement, elementCount, elementData |
| Fields inherited from class java.util.AbstractList |
|---|
modCount |
| Fields inherited from interface org.cip4.jdflib.datatypes.JDFBaseDataTypes |
|---|
EPSILON, MAX_CMYK_COLOR, MAX_LAB_COLOR, MAX_MATRIX_DIMENSION, MAX_RECTANGLE_DIMENSION, MAX_RGB_COLOR, MAX_SHAPE_DIMENSION, MAX_XY_DIMENSION |
| Constructor Summary | |
|---|---|
JDFCMYKColor()
constructs a CMYK color with all values set to 0.0 Double |
|
JDFCMYKColor(double c,
double m,
double y,
double k)
constructs a new CMYK color with the given double values |
|
JDFCMYKColor(JDFNumList nl)
constructs a CMYK color with a given JDFNumberList |
|
JDFCMYKColor(String s)
constructs a CMYK color with the given String |
|
JDFCMYKColor(Vector v)
Deprecated. use typesafe constructors |
|
| Method Summary | |
|---|---|
static JDFCMYKColor |
createCMYKColor(String s)
factory for JDFCMYKColor that silently returns null in case of illegal strings |
double |
getC()
getC - returns the value C of the CMYK color |
double |
getK()
getK - returns the value K of the CMYK color |
double |
getM()
getM - returns the value M of the CMYK color |
JDFRGBColor |
getRGB()
|
double |
getY()
getY - returns the value Y of the CMYK color |
boolean |
isValid()
isValid - the size of the vector must be 4 and all instances are Double types |
void |
setC(double c)
setC - sets the value C of the CMYK color |
void |
setK(double k)
setK - sets the value K of the CMYK color |
void |
setM(double m)
setM - sets the value M of the CMYK color |
void |
setNamedColor(String name)
set the cmyk value of this to a matching value |
void |
setY(double y)
setY - sets the value Y of the CMYK color |
| Methods inherited from class org.cip4.jdflib.datatypes.JDFNumList |
|---|
abs, clone, contains, containsAll, copyNumList, doubleAt, elementAt, equals, getDoubleList, getIntArray, getString, getString, hashCode, isValidString, matches, removeElementAt, replaceElementAt, scale, scaleFromCM, scaleFromMM, scaleToCM, scaleToMM, set, setString, subtract, toString, unify |
| Methods inherited from class java.util.Vector |
|---|
add, add, addAll, addAll, addElement, capacity, clear, contains, containsAll, copyInto, elements, ensureCapacity, firstElement, get, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, trimToSize |
| Methods inherited from class java.util.AbstractList |
|---|
iterator, listIterator, listIterator |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
|---|
iterator, listIterator, listIterator |
| Constructor Detail |
|---|
public JDFCMYKColor()
@Deprecated
public JDFCMYKColor(Vector v)
throws DataFormatException
Vector - v - the given vector
DataFormatException - - if the Vector has not a valid format
public JDFCMYKColor(String s)
throws DataFormatException
s - - the given String
DataFormatException - - if the String has not a valid format
public JDFCMYKColor(JDFNumList nl)
throws DataFormatException
nl - - the given number list
DataFormatException - - if the String has not a valid format
public JDFCMYKColor(double c,
double m,
double y,
double k)
c - - the value cm - - the value my - - the value yk - - the value k| Method Detail |
|---|
public static JDFCMYKColor createCMYKColor(String s)
s - the string to parse
public boolean isValid()
throws DataFormatException
isValid in class JDFNumListDataFormatException - - if the Vector has not a valid formatpublic double getC()
public void setC(double c)
c - the value C of the CMYK colorpublic double getM()
public void setM(double m)
m - the value M of the CMYK colorpublic double getY()
public void setY(double y)
y - the value Y of the CMYK colorpublic double getK()
public void setK(double k)
k - the value K of the CMYK colorpublic JDFRGBColor getRGB()
public void setNamedColor(String name)
name -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||