Package org.cip4.jdflib.datatypes
Class JDFShapeRangeList
java.lang.Object
org.cip4.jdflib.datatypes.JDFRangeList
org.cip4.jdflib.datatypes.JDFShapeRangeList
- All Implemented Interfaces:
JDFBaseDataTypes
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.cip4.jdflib.datatypes.JDFBaseDataTypes
JDFBaseDataTypes.EnumFitsValue -
Field Summary
Fields inherited from class org.cip4.jdflib.datatypes.JDFRangeList
rangeListFields 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
ConstructorsConstructorDescriptionempty constructorconstructs a JDFShapeRangeList from the values of a given Stringcopy constructor
constructs a JDFShapeRangeList with the given JDFShapeRangeList -
Method Summary
Modifier and TypeMethodDescriptionvoidappend - adds an individual JDFShape elementvoidappend - adds an element defined by a JDFShapeRangevoidappend - adds an element defined by two JDFShapes: xMin~xMaxstatic JDFShapeRangeListfactory for JDFShapeRangeList that silently returns null in case of illegal stringsbooleaninRange - check whether shape 'x' is in the shape range defined by 'this'booleanisOrdered - tests if 'this' is OrderedRangeListbooleanisUniqueOrdered - tests if 'this' is UniqueOrdered RangeListbooleanisValid - validate the given StringvoidsetString - deserialize a string Reads the string, which represents JDFShapeRangeList, and converts it into real JDFShapeRangeList
-
Constructor Details
-
JDFShapeRangeList
public JDFShapeRangeList()empty constructor -
JDFShapeRangeList
copy constructor
constructs a JDFShapeRangeList with the given JDFShapeRangeList- Parameters:
rl-
-
JDFShapeRangeList
constructs a JDFShapeRangeList from the values of a given String- Parameters:
s- the given String- Throws:
DataFormatException- - if the String has not a valid format
-
-
Method Details
-
createShapeRangeList
factory for JDFShapeRangeList that silently returns null in case of illegal strings- Parameters:
s- the string to parse- Returns:
- the JDFShapeRangeList, null if s is not compatible
-
inRange
inRange - check whether shape 'x' is in the shape range defined by 'this'- Parameters:
x- shape value to test- Returns:
- boolean - true if 'x' is in the range defined by 'this'
-
setString
setString - deserialize a string Reads the string, which represents JDFShapeRangeList, and converts it into real JDFShapeRangeList- Parameters:
s- string to read- Throws:
DataFormatException- - if the String has not a valid format
-
isValid
isValid - validate the given String- Parameters:
s- the given string- Returns:
- boolean - false if the String has not a valid format
-
append
append - adds an element defined by a JDFShapeRange- Parameters:
x- the range to append to the list
-
append
append - adds an individual JDFShape element- Parameters:
x- the left and right value of the range to append to the list
-
append
append - adds an element defined by two JDFShapes: xMin~xMax- Parameters:
xMin- the left value of the range to append to the listxMax- the right value of the range to append to the list
-
isOrdered
public boolean isOrdered()isOrdered - tests if 'this' is OrderedRangeList- Specified by:
isOrderedin classJDFRangeList- Returns:
- boolean - true if 'this' is a OrdneredRangeList
-
getOrderedArray
-
isUniqueOrdered
public boolean isUniqueOrdered()isUniqueOrdered - tests if 'this' is UniqueOrdered RangeList- Specified by:
isUniqueOrderedin classJDFRangeList- Returns:
- boolean - true if 'this' is UniqueOrdered RangeList
-