API Overview API Index Package Overview Direct link to this page
JDK 1.6
  javax.print.attribute.standard. MediaSize View Source
Author(s)
Phil Race, Alan Kaminsky
Since
Version
Serial
Hierarchy
 Object
      Size2DSyntax
          MediaSize
Implements
 Attribute
Subclasses
Description
public class MediaSize
  Class MediaSize is a two-dimensional size valued printing attribute class that indicates the dimensions of the medium in a portrait orientation, with the X dimension running along the bottom edge and the Y dimension running along the left edge.
See also:   
Constructors
public MediaSize (float x, float y, int units)
  Construct a new media size attribute from the given floating-point values.
public MediaSize (float x, float y, int units, MediaSizeName media)
  Construct a new media size attribute from the given floating-point values.
public MediaSize (int x, int y, int units)
  Construct a new media size attribute from the given integer values.
public MediaSize (int x, int y, int units, MediaSizeName media)
  Construct a new media size attribute from the given integer values.
Methods
Hide/Show inherited methods
public boolean equals (Object object) [Overrides Size2DSyntax]
  Returns whether this media size attribute is equivalent to the passed in object.
publicstatic MediaSizeName findMedia (float x, float y, int units)
  The specified dimensions are used to locate a matching MediaSize instance from amongst all the standard MediaSize instances.
publicfinal Class<Attribute> getCategory () [Specified in Attribute]
  Get the printing attribute class which is to be used as the "category" for this printing attribute value.
publicstatic MediaSize getMediaSizeForName (MediaSizeName media)
  Get the MediaSize for the specified named media.
public MediaSizeName getMediaSizeName ()
  Get the media name, if any, for this size.
publicfinal String getName () [Specified in Attribute]
  Get the name of the category of which this attribute value is an instance.
public float getSize (int units) [Inherited From Size2DSyntax]
  Get this two-dimensional size attribute's dimensions in the given units as floating-point values.
public float getX (int units) [Inherited From Size2DSyntax]
  Returns this two-dimensional size attribute's X dimension in the given units as a floating-point value.
protected int getXMicrometers () [Inherited From Size2DSyntax]
  Returns this two-dimensional size attribute's X dimension in units of micrometers (µm).
public float getY (int units) [Inherited From Size2DSyntax]
  Returns this two-dimensional size attribute's Y dimension in the given units as a floating-point value.
protected int getYMicrometers () [Inherited From Size2DSyntax]
  Returns this two-dimensional size attribute's Y dimension in units of micrometers (µm).
public int hashCode () [Inherited From Size2DSyntax]
Returns a hash code value for this two-dimensional size attribute.
public String toString () [Inherited From Size2DSyntax]
  Returns a string version of this two-dimensional size attribute.
public String toString (int units, String unitsName) [Inherited From Size2DSyntax]
  Returns a string version of this two-dimensional size attribute in the given units.
Fields
Hide/Show inherited fields
publicfinalstatic int INCH = "25400" [Inherited From Size2DSyntax]
  Value to indicate units of inches (in).
publicfinalstatic int MM = "1000" [Inherited From Size2DSyntax]
  Value to indicate units of millimeters (mm).
Nested Classes
  MediaSize.ISO
Class MediaSize.ISO includes MediaSize values for ISO media.
  MediaSize.JIS
Class MediaSize.JIS includes MediaSize values for JIS (Japanese) media.
  MediaSize.NA
Class MediaSize.NA includes MediaSize values for North American media.
  MediaSize.Engineering
Class MediaSize.Engineering includes MediaSize values for engineering media.
  MediaSize.Other
Class MediaSize.Other includes MediaSize values for miscellaneous media.
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar