< prev index next >
src/java.desktop/share/classes/javax/print/attribute/IntegerSyntax.java
Print this page
*** 67,79 ****
* @param value Integer value.
* @param lowerBound Lower bound.
* @param upperBound Upper bound.
*
* @exception IllegalArgumentException
! * (Unchecked exception) Thrown if <CODE>value</CODE> is less than
! * <CODE>lowerBound</CODE> or greater than
! * <CODE>upperBound</CODE>.
*/
protected IntegerSyntax(int value, int lowerBound, int upperBound) {
if (lowerBound > value || value > upperBound) {
throw new IllegalArgumentException("Value " + value +
" not in range " + lowerBound +
--- 67,79 ----
* @param value Integer value.
* @param lowerBound Lower bound.
* @param upperBound Upper bound.
*
* @exception IllegalArgumentException
! * (Unchecked exception) Thrown if {@code value} is less than
! * {@code lowerBound} or greater than
! * {@code upperBound}.
*/
protected IntegerSyntax(int value, int lowerBound, int upperBound) {
if (lowerBound > value || value > upperBound) {
throw new IllegalArgumentException("Value " + value +
" not in range " + lowerBound +
*** 93,113 ****
/**
* Returns whether this integer attribute is equivalent to the passed in
* object. To be equivalent, all of the following conditions must be true:
* <OL TYPE=1>
* <LI>
! * <CODE>object</CODE> is not null.
* <LI>
! * <CODE>object</CODE> is an instance of class IntegerSyntax.
* <LI>
! * This integer attribute's value and <CODE>object</CODE>'s value are
* equal.
* </OL>
*
* @param object Object to compare to.
*
! * @return True if <CODE>object</CODE> is equivalent to this integer
* attribute, false otherwise.
*/
public boolean equals(Object object) {
return (object != null && object instanceof IntegerSyntax &&
--- 93,113 ----
/**
* Returns whether this integer attribute is equivalent to the passed in
* object. To be equivalent, all of the following conditions must be true:
* <OL TYPE=1>
* <LI>
! * {@code object} is not null.
* <LI>
! * {@code object} is an instance of class IntegerSyntax.
* <LI>
! * This integer attribute's value and {@code object}'s value are
* equal.
* </OL>
*
* @param object Object to compare to.
*
! * @return True if {@code object} is equivalent to this integer
* attribute, false otherwise.
*/
public boolean equals(Object object) {
return (object != null && object instanceof IntegerSyntax &&
< prev index next >