- java.lang.Object
-
- javax.print.attribute.URISyntax
-
- All Implemented Interfaces:
Serializable,Cloneable
- Direct Known Subclasses:
Destination,PrinterMoreInfo,PrinterMoreInfoManufacturer,PrinterURI
public abstract class URISyntax extends Object implements Serializable, Cloneable
ClassURISyntaxis an abstract base class providing the common implementation of all attributes whose value is a Uniform Resource Identifier (URI). Once constructed, aURIattribute's value is immutable.- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object object)Returns whether thisURIattribute is equivalent to the passed in object.URIgetURI()Returns thisURIattribute'sURIvalue.inthashCode()Returns a hashcode for thisURIattribute.StringtoString()Returns aStringidentifying thisURIattribute.
-
-
-
Constructor Detail
-
URISyntax
protected URISyntax(URI uri)
Constructs aURIattribute with the specifiedURI.- Parameters:
uri- theURI- Throws:
NullPointerException- ifuriisnull
-
-
Method Detail
-
getURI
public URI getURI()
Returns thisURIattribute'sURIvalue.- Returns:
- the
URI
-
hashCode
public int hashCode()
Returns a hashcode for thisURIattribute.- Overrides:
hashCodein classObject- Returns:
- a hashcode value for this object
- See Also:
Object.equals(java.lang.Object),System.identityHashCode(java.lang.Object)
-
equals
public boolean equals(Object object)
Returns whether thisURIattribute is equivalent to the passed in object. To be equivalent, all of the following conditions must be true:objectis notnull.objectis an instance of classURISyntax.- This
URIattribute's underlyingURIandobject's underlyingURIare equal.
- Overrides:
equalsin classObject- Parameters:
object-Objectto compare to- Returns:
trueifobjectis equivalent to thisURIattribute,falseotherwise- See Also:
Object.hashCode(),HashMap
-
-