Top Description Fields Constructors Methods
org.apache.pdfbox.pdmodel.graphics.color

public final Class PDTristimulus

extends Object
implements COSObjectable
Class Inheritance
All Implemented Interfaces
org.apache.pdfbox.pdmodel.common.COSObjectable
Imports
org.apache.pdfbox.cos.COSArray, .COSBase, .COSFloat, .COSNumber, org.apache.pdfbox.pdmodel.common.COSObjectable

A tristimulus, or collection of three floating point parameters used for color operations.
Author
Ben Litchfield

Field Summary

Modifier and TypeField and Description
private final COSArray

Constructor Summary

AccessConstructor and Description
public
PDTristimulus()

Constructor.

public
PDTristimulus(COSArray
the array containing the XYZ values
array
)

Constructor from COS object.

public
PDTristimulus(float[]
the array containing the XYZ values
array
)

Constructor from COS object.

Method Summary

Modifier and TypeMethod and Description
public COSBase

Returns:

the cos object that matches this Java object
getCOSObject
()

Implements org.apache.pdfbox.pdmodel.common.COSObjectable.getCOSObject.

Convert this standard java object to a COS object.

public float

Returns:

the X value
getX
()

Returns the x value of the tristimulus.

public float

Returns:

the Y value
getY
()

Returns the y value of the tristimulus.

public float

Returns:

the Z value
getZ
()

Returns the z value of the tristimulus.

public void
setX(float
the x value for the tristimulus
x
)

Sets the x value of the tristimulus.

public void
setY(float
the y value for the tristimulus
y
)

Sets the y value of the tristimulus.

public void
setZ(float
the z value for the tristimulus
z
)

Sets the z value of the tristimulus.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

valuesback to summary
private final COSArray values

Constructor Detail

PDTristimulusback to summary
public PDTristimulus()

Constructor. Defaults all values to 0, 0, 0.

PDTristimulusback to summary
public PDTristimulus(COSArray array)

Constructor from COS object.

Parameters
array:COSArray

the array containing the XYZ values

PDTristimulusback to summary
public PDTristimulus(float[] array)

Constructor from COS object.

Parameters
array:float[]

the array containing the XYZ values

Method Detail

getCOSObjectback to summary
public COSBase getCOSObject()

Implements org.apache.pdfbox.pdmodel.common.COSObjectable.getCOSObject.

Convert this standard java object to a COS object.

Returns:COSBase

the cos object that matches this Java object

Annotations
@Override
getXback to summary
public float getX()

Returns the x value of the tristimulus.

Returns:float

the X value

getYback to summary
public float getY()

Returns the y value of the tristimulus.

Returns:float

the Y value

getZback to summary
public float getZ()

Returns the z value of the tristimulus.

Returns:float

the Z value

setXback to summary
public void setX(float x)

Sets the x value of the tristimulus.

Parameters
x:float

the x value for the tristimulus

setYback to summary
public void setY(float y)

Sets the y value of the tristimulus.

Parameters
y:float

the y value for the tristimulus

setZback to summary
public void setZ(float z)

Sets the z value of the tristimulus.

Parameters
z:float

the z value for the tristimulus