APIdia Launch Partner
Top Description Inners Fields Constructors Methods
javax.print.attribute.standard

public Class MediaSize

extends Size2DSyntax
implements Attribute
Class Inheritance
All Implemented Interfaces
javax.print.attribute.Attribute, java.io.Serializable
Imports
java.io.Serial, java.util.HashMap, .Vector, javax.print.attribute.Attribute, .Size2DSyntax

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. Thus, the Y dimension must be greater than or equal to the X dimension. Class MediaSize declares many standard media size values, organized into nested classes for ISO, JIS, North American, engineering, and other media.

MediaSize is not yet used to specify media. Its current role is as a mapping for named media (see MediaSizeName). Clients can use the mapping method MediaSize.getMediaSizeForName(MediaSizeName) to find the physical dimensions of the MediaSizeName instances enumerated in this API. This is useful for clients which need this information to format & paginate printing.

Author
Phil Race, Alan Kaminsky

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
MediaSize.Engineering

Class MediaSize.Engineering includes MediaSize values for engineering media.

public static class
MediaSize.ISO

Class MediaSize.ISO includes MediaSize values for ISO media.

public static class
MediaSize.JIS

Class MediaSize.JIS includes MediaSize values for JIS (Japanese) media.

public static class
MediaSize.NA

Class MediaSize.NA includes MediaSize values for North American media.

public static class
MediaSize.Other

Class MediaSize.Other includes MediaSize values for miscellaneous media.

Field Summary

Modifier and TypeField and Description
private static HashMap<MediaSizeName, MediaSize>
private MediaSizeName
private static final long
serialVersionUID

Hides javax.print.attribute.Size2DSyntax.serialVersionUID.

Use serialVersionUID from JDK 1.4 for interoperability.
private static Vector<MediaSize>
Inherited from javax.print.attribute.Size2DSyntax:
INCHMM

Constructor Summary

AccessConstructor and Description
public
MediaSize(float
X dimension
x
,
float
Y dimension
y
,
int
unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM
units
)

Construct a new media size attribute from the given floating-point values.

public
MediaSize(int
X dimension
x
,
int
Y dimension
y
,
int
unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM
units
)

Construct a new media size attribute from the given integer values.

public
MediaSize(float
X dimension
x
,
float
Y dimension
y
,
int
unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM
units
,
MediaSizeName
a media name to associate with this MediaSize
media
)

Construct a new media size attribute from the given floating-point values.

public
MediaSize(int
X dimension
x
,
int
Y dimension
y
,
int
unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM
units
,
MediaSizeName
a media name to associate with this MediaSize
media
)

Construct a new media size attribute from the given integer values.

Method Summary

Modifier and TypeMethod and Description
public boolean

Returns:

true if object is equivalent to this media size attribute, false otherwise
equals
(Object
Object to compare to
object
)

Overrides javax.print.attribute.Size2DSyntax.equals.

Returns whether this media size attribute is equivalent to the passed in object.

public static MediaSizeName

Returns:

MediaSizeName matching these dimensions, or null
findMedia
(float
X dimension
x
,
float
Y dimension
y
,
int
unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM
units
)

The specified dimensions are used to locate a matching MediaSize instance from amongst all the standard MediaSize instances.

public final Class<? extends Attribute>

Returns:

printing attribute class (category), an instance of class java.lang.Class
getCategory
()

Implements javax.print.attribute.Attribute.getCategory.

Get the printing attribute class which is to be used as the "category" for this printing attribute value.

public static MediaSize

Returns:

size of the media, or null if this media is not associated with any size
getMediaSizeForName
(MediaSizeName
the name of the media for which the size is sought
media
)

Get the MediaSize for the specified named media.

public MediaSizeName

Returns:

the name for this media size, or null if no name was associated with this size (an anonymous size)
getMediaSizeName
()

Get the media name, if any, for this size.

public final String

Returns:

attribute category name
getName
()

Implements javax.print.attribute.Attribute.getName.

Get the name of the category of which this attribute value is an instance.

Inherited from javax.print.attribute.Size2DSyntax:
getSizegetXgetXMicrometersgetYgetYMicrometershashCodetoStringtoString

Field Detail

mediaMapback to summary
private static HashMap<MediaSizeName, MediaSize> mediaMap
mediaNameback to summary
private MediaSizeName mediaName
serialVersionUIDback to summary
private static final long serialVersionUID

Hides javax.print.attribute.Size2DSyntax.serialVersionUID.

Use serialVersionUID from JDK 1.4 for interoperability.

Annotations
@Serial
sizeVectorback to summary
private static Vector<MediaSize> sizeVector

Constructor Detail

MediaSizeback to summary
public MediaSize(float x, float y, int units)

Construct a new media size attribute from the given floating-point values.

Parameters
x:float

X dimension

y:float

Y dimension

units:int

unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM

Exceptions
IllegalArgumentException:
if x < 0 or y < 0 or units < 1 or x > y
MediaSizeback to summary
public MediaSize(int x, int y, int units)

Construct a new media size attribute from the given integer values.

Parameters
x:int

X dimension

y:int

Y dimension

units:int

unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM

Exceptions
IllegalArgumentException:
if x < 0 or y < 0 or units < 1 or x > y
MediaSizeback to summary
public MediaSize(float x, float y, int units, MediaSizeName media)

Construct a new media size attribute from the given floating-point values.

Parameters
x:float

X dimension

y:float

Y dimension

units:int

unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM

media:MediaSizeName

a media name to associate with this MediaSize

Exceptions
IllegalArgumentException:
if x < 0 or y < 0 or units < 1 or x > y
MediaSizeback to summary
public MediaSize(int x, int y, int units, MediaSizeName media)

Construct a new media size attribute from the given integer values.

Parameters
x:int

X dimension

y:int

Y dimension

units:int

unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM

media:MediaSizeName

a media name to associate with this MediaSize

Exceptions
IllegalArgumentException:
if x < 0 or y < 0 or units < 1 or x > y

Method Detail

equalsback to summary
public boolean equals(Object object)

Overrides javax.print.attribute.Size2DSyntax.equals.

Returns whether this media size attribute is equivalent to the passed in object. To be equivalent, all of the following conditions must be true:

  1. object is not null.
  2. object is an instance of class MediaSize.
  3. This media size attribute's X dimension is equal to object's X dimension.
  4. This media size attribute's Y dimension is equal to object's Y dimension.
Parameters
object:Object

Object to compare to

Returns:boolean

true if object is equivalent to this media size attribute, false otherwise

Annotations
@Override
findMediaback to summary
public static 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. If there is no exact match, the closest match is used.

The MediaSize is in turn used to locate the MediaSizeName object. This method may return null if the closest matching MediaSize has no corresponding Media instance.

This method is useful for clients which have only dimensions and want to find a Media which corresponds to the dimensions.

Parameters
x:float

X dimension

y:float

Y dimension

units:int

unit conversion factor, e.g. Size2DSyntax.INCH or Size2DSyntax.MM

Returns:MediaSizeName

MediaSizeName matching these dimensions, or null

Exceptions
IllegalArgumentException:
if x <= 0, y <= 0, or units < 1
getCategoryback to summary
public final Class<? extends Attribute> getCategory()

Implements javax.print.attribute.Attribute.getCategory.

Get the printing attribute class which is to be used as the "category" for this printing attribute value.

For class MediaSize and any vendor-defined subclasses, the category is class MediaSize itself.

Returns:Class<? extends Attribute>

printing attribute class (category), an instance of class java.lang.Class

Annotations
@Override
getMediaSizeForNameback to summary
public static MediaSize getMediaSizeForName(MediaSizeName media)

Get the MediaSize for the specified named media.

Parameters
media:MediaSizeName

the name of the media for which the size is sought

Returns:MediaSize

size of the media, or null if this media is not associated with any size

getMediaSizeNameback to summary
public MediaSizeName getMediaSizeName()

Get the media name, if any, for this size.

Returns:MediaSizeName

the name for this media size, or null if no name was associated with this size (an anonymous size)

getNameback to summary
public final String getName()

Implements javax.print.attribute.Attribute.getName.

Get the name of the category of which this attribute value is an instance.

For class MediaSize and any vendor-defined subclasses, the category name is "media-size".

Returns:String

attribute category name

Annotations
@Override
javax.print.attribute.standard back to summary

public final Class MediaSize.Engineering

extends Object
Class Inheritance

Class MediaSize.Engineering includes MediaSize values for engineering media.

Field Summary

Modifier and TypeField and Description
public static final MediaSize
A

Specifies the engineering A size, 8.5 inch by 11 inch.

public static final MediaSize
B

Specifies the engineering B size, 11 inch by 17 inch.

public static final MediaSize
C

Specifies the engineering C size, 17 inch by 22 inch.

public static final MediaSize
D

Specifies the engineering D size, 22 inch by 34 inch.

public static final MediaSize
E

Specifies the engineering E size, 34 inch by 44 inch.

Constructor Summary

AccessConstructor and Description
private
Engineering()

Hide all constructors.

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

Aback to summary
public static final MediaSize A

Specifies the engineering A size, 8.5 inch by 11 inch.

Bback to summary
public static final MediaSize B

Specifies the engineering B size, 11 inch by 17 inch.

Cback to summary
public static final MediaSize C

Specifies the engineering C size, 17 inch by 22 inch.

Dback to summary
public static final MediaSize D

Specifies the engineering D size, 22 inch by 34 inch.

Eback to summary
public static final MediaSize E

Specifies the engineering E size, 34 inch by 44 inch.

Constructor Detail

Engineeringback to summary
private Engineering()

Hide all constructors.

javax.print.attribute.standard back to summary

public final Class MediaSize.ISO

extends Object
Class Inheritance

Class MediaSize.ISO includes MediaSize values for ISO media.

Field Summary

Modifier and TypeField and Description
public static final MediaSize
A0

Specifies the ISO A0 size, 841 mm by 1189 mm.

public static final MediaSize
A1

Specifies the ISO A1 size, 594 mm by 841 mm.

public static final MediaSize
A10

Specifies the ISO A10 size, 26 mm by 37 mm.

public static final MediaSize
A2

Specifies the ISO A2 size, 420 mm by 594 mm.

public static final MediaSize
A3

Specifies the ISO A3 size, 297 mm by 420 mm.

public static final MediaSize
A4

Specifies the ISO A4 size, 210 mm by 297 mm.

public static final MediaSize
A5

Specifies the ISO A5 size, 148 mm by 210 mm.

public static final MediaSize
A6

Specifies the ISO A6 size, 105 mm by 148 mm.

public static final MediaSize
A7

Specifies the ISO A7 size, 74 mm by 105 mm.

public static final MediaSize
A8

Specifies the ISO A8 size, 52 mm by 74 mm.

public static final MediaSize
A9

Specifies the ISO A9 size, 37 mm by 52 mm.

public static final MediaSize
B0

Specifies the ISO B0 size, 1000 mm by 1414 mm.

public static final MediaSize
B1

Specifies the ISO B1 size, 707 mm by 1000 mm.

public static final MediaSize
B10

Specifies the ISO B10 size, 31 mm by 44 mm.

public static final MediaSize
B2

Specifies the ISO B2 size, 500 mm by 707 mm.

public static final MediaSize
B3

Specifies the ISO B3 size, 353 mm by 500 mm.

public static final MediaSize
B4

Specifies the ISO B4 size, 250 mm by 353 mm.

public static final MediaSize
B5

Specifies the ISO B5 size, 176 mm by 250 mm.

public static final MediaSize
B6

Specifies the ISO B6 size, 125 mm by 176 mm.

public static final MediaSize
B7

Specifies the ISO B7 size, 88 mm by 125 mm.

public static final MediaSize
B8

Specifies the ISO B8 size, 62 mm by 88 mm.

public static final MediaSize
B9

Specifies the ISO B9 size, 44 mm by 62 mm.

public static final MediaSize
C3

Specifies the ISO C3 size, 324 mm by 458 mm.

public static final MediaSize
C4

Specifies the ISO C4 size, 229 mm by 324 mm.

public static final MediaSize
C5

Specifies the ISO C5 size, 162 mm by 229 mm.

public static final MediaSize
C6

Specifies the ISO C6 size, 114 mm by 162 mm.

public static final MediaSize
DESIGNATED_LONG

Specifies the ISO Designated Long size, 110 mm by 220 mm.

Constructor Summary

AccessConstructor and Description
private
ISO()

Hide all constructors.

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

A0back to summary
public static final MediaSize A0

Specifies the ISO A0 size, 841 mm by 1189 mm.

A1back to summary
public static final MediaSize A1

Specifies the ISO A1 size, 594 mm by 841 mm.

A10back to summary
public static final MediaSize A10

Specifies the ISO A10 size, 26 mm by 37 mm.

A2back to summary
public static final MediaSize A2

Specifies the ISO A2 size, 420 mm by 594 mm.

A3back to summary
public static final MediaSize A3

Specifies the ISO A3 size, 297 mm by 420 mm.

A4back to summary
public static final MediaSize A4

Specifies the ISO A4 size, 210 mm by 297 mm.

A5back to summary
public static final MediaSize A5

Specifies the ISO A5 size, 148 mm by 210 mm.

A6back to summary
public static final MediaSize A6

Specifies the ISO A6 size, 105 mm by 148 mm.

A7back to summary
public static final MediaSize A7

Specifies the ISO A7 size, 74 mm by 105 mm.

A8back to summary
public static final MediaSize A8

Specifies the ISO A8 size, 52 mm by 74 mm.

A9back to summary
public static final MediaSize A9

Specifies the ISO A9 size, 37 mm by 52 mm.

B0back to summary
public static final MediaSize B0

Specifies the ISO B0 size, 1000 mm by 1414 mm.

B1back to summary
public static final MediaSize B1

Specifies the ISO B1 size, 707 mm by 1000 mm.

B10back to summary
public static final MediaSize B10

Specifies the ISO B10 size, 31 mm by 44 mm.

B2back to summary
public static final MediaSize B2

Specifies the ISO B2 size, 500 mm by 707 mm.

B3back to summary
public static final MediaSize B3

Specifies the ISO B3 size, 353 mm by 500 mm.

B4back to summary
public static final MediaSize B4

Specifies the ISO B4 size, 250 mm by 353 mm.

B5back to summary
public static final MediaSize B5

Specifies the ISO B5 size, 176 mm by 250 mm.

B6back to summary
public static final MediaSize B6

Specifies the ISO B6 size, 125 mm by 176 mm.

B7back to summary
public static final MediaSize B7

Specifies the ISO B7 size, 88 mm by 125 mm.

B8back to summary
public static final MediaSize B8

Specifies the ISO B8 size, 62 mm by 88 mm.

B9back to summary
public static final MediaSize B9

Specifies the ISO B9 size, 44 mm by 62 mm.

C3back to summary
public static final MediaSize C3

Specifies the ISO C3 size, 324 mm by 458 mm.

C4back to summary
public static final MediaSize C4

Specifies the ISO C4 size, 229 mm by 324 mm.

C5back to summary
public static final MediaSize C5

Specifies the ISO C5 size, 162 mm by 229 mm.

C6back to summary
public static final MediaSize C6

Specifies the ISO C6 size, 114 mm by 162 mm.

DESIGNATED_LONGback to summary
public static final MediaSize DESIGNATED_LONG

Specifies the ISO Designated Long size, 110 mm by 220 mm.

Constructor Detail

ISOback to summary
private ISO()

Hide all constructors.

javax.print.attribute.standard back to summary

public final Class MediaSize.JIS

extends Object
Class Inheritance

Class MediaSize.JIS includes MediaSize values for JIS (Japanese) media.

Field Summary

Modifier and TypeField and Description
public static final MediaSize
B0

Specifies the JIS B0 size, 1030 mm by 1456 mm.

public static final MediaSize
B1

Specifies the JIS B1 size, 728 mm by 1030 mm.

public static final MediaSize
B10

Specifies the JIS B10 size, 32 mm by 45 mm.

public static final MediaSize
B2

Specifies the JIS B2 size, 515 mm by 728 mm.

public static final MediaSize
B3

Specifies the JIS B3 size, 364 mm by 515 mm.

public static final MediaSize
B4

Specifies the JIS B4 size, 257 mm by 364 mm.

public static final MediaSize
B5

Specifies the JIS B5 size, 182 mm by 257 mm.

public static final MediaSize
B6

Specifies the JIS B6 size, 128 mm by 182 mm.

public static final MediaSize
B7

Specifies the JIS B7 size, 91 mm by 128 mm.

public static final MediaSize
B8

Specifies the JIS B8 size, 64 mm by 91 mm.

public static final MediaSize
B9

Specifies the JIS B9 size, 45 mm by 64 mm.

public static final MediaSize
CHOU_1

Specifies the JIS Chou ("long") #1 envelope size, 142 mm by 332 mm.

public static final MediaSize
CHOU_2

Specifies the JIS Chou ("long") #2 envelope size, 119 mm by 277 mm.

public static final MediaSize
CHOU_3

Specifies the JIS Chou ("long") #3 envelope size, 120 mm by 235 mm.

public static final MediaSize
CHOU_30

Specifies the JIS Chou ("long") #30 envelope size, 92 mm by 235 mm.

public static final MediaSize
CHOU_4

Specifies the JIS Chou ("long") #4 envelope size, 90 mm by 205 mm.

public static final MediaSize
CHOU_40

Specifies the JIS Chou ("long") #40 envelope size, 90 mm by 225 mm.

public static final MediaSize
KAKU_0

Specifies the JIS Kaku ("square") #0 envelope size, 287 mm by 382 mm.

public static final MediaSize
KAKU_1

Specifies the JIS Kaku ("square") #1 envelope size, 270 mm by 382 mm.

public static final MediaSize
KAKU_2

Specifies the JIS Kaku ("square") #2 envelope size, 240 mm by 332 mm.

public static final MediaSize
KAKU_20

Specifies the JIS Kaku ("square") #20 envelope size, 229 mm by 324 mm.

public static final MediaSize
KAKU_3

Specifies the JIS Kaku ("square") #3 envelope size, 216 mm by 277 mm.

public static final MediaSize
KAKU_4

Specifies the JIS Kaku ("square") #4 envelope size, 197 mm by 267 mm.

public static final MediaSize
KAKU_5

Specifies the JIS Kaku ("square") #5 envelope size, 190 mm by 240 mm.

public static final MediaSize
KAKU_6

Specifies the JIS Kaku ("square") #6 envelope size, 162 mm by 229 mm.

public static final MediaSize
KAKU_7

Specifies the JIS Kaku ("square") #7 envelope size, 142 mm by 205 mm.

public static final MediaSize
KAKU_8

Specifies the JIS Kaku ("square") #8 envelope size, 119 mm by 197 mm.

public static final MediaSize
KAKU_A4

Specifies the JIS Kaku ("square") A4 envelope size, 228 mm by 312 mm.

public static final MediaSize
YOU_1

Specifies the JIS You ("Western") #1 envelope size, 120 mm by 176 mm.

public static final MediaSize
YOU_2

Specifies the JIS You ("Western") #2 envelope size, 114 mm by 162 mm.

public static final MediaSize
YOU_3

Specifies the JIS You ("Western") #3 envelope size, 98 mm by 148 mm.

public static final MediaSize
YOU_4

Specifies the JIS You ("Western") #4 envelope size, 105 mm by 235 mm.

public static final MediaSize
YOU_5

Specifies the JIS You ("Western") #5 envelope size, 95 mm by 217 mm.

public static final MediaSize
YOU_6

Specifies the JIS You ("Western") #6 envelope size, 98 mm by 190 mm.

public static final MediaSize
YOU_7

Specifies the JIS You ("Western") #7 envelope size, 92 mm by 165 mm.

Constructor Summary

AccessConstructor and Description
private
JIS()

Hide all constructors.

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

B0back to summary
public static final MediaSize B0

Specifies the JIS B0 size, 1030 mm by 1456 mm.

B1back to summary
public static final MediaSize B1

Specifies the JIS B1 size, 728 mm by 1030 mm.

B10back to summary
public static final MediaSize B10

Specifies the JIS B10 size, 32 mm by 45 mm.

B2back to summary
public static final MediaSize B2

Specifies the JIS B2 size, 515 mm by 728 mm.

B3back to summary
public static final MediaSize B3

Specifies the JIS B3 size, 364 mm by 515 mm.

B4back to summary
public static final MediaSize B4

Specifies the JIS B4 size, 257 mm by 364 mm.

B5back to summary
public static final MediaSize B5

Specifies the JIS B5 size, 182 mm by 257 mm.

B6back to summary
public static final MediaSize B6

Specifies the JIS B6 size, 128 mm by 182 mm.

B7back to summary
public static final MediaSize B7

Specifies the JIS B7 size, 91 mm by 128 mm.

B8back to summary
public static final MediaSize B8

Specifies the JIS B8 size, 64 mm by 91 mm.

B9back to summary
public static final MediaSize B9

Specifies the JIS B9 size, 45 mm by 64 mm.

CHOU_1back to summary
public static final MediaSize CHOU_1

Specifies the JIS Chou ("long") #1 envelope size, 142 mm by 332 mm.

CHOU_2back to summary
public static final MediaSize CHOU_2

Specifies the JIS Chou ("long") #2 envelope size, 119 mm by 277 mm.

CHOU_3back to summary
public static final MediaSize CHOU_3

Specifies the JIS Chou ("long") #3 envelope size, 120 mm by 235 mm.

CHOU_30back to summary
public static final MediaSize CHOU_30

Specifies the JIS Chou ("long") #30 envelope size, 92 mm by 235 mm.

CHOU_4back to summary
public static final MediaSize CHOU_4

Specifies the JIS Chou ("long") #4 envelope size, 90 mm by 205 mm.

CHOU_40back to summary
public static final MediaSize CHOU_40

Specifies the JIS Chou ("long") #40 envelope size, 90 mm by 225 mm.

KAKU_0back to summary
public static final MediaSize KAKU_0

Specifies the JIS Kaku ("square") #0 envelope size, 287 mm by 382 mm.

KAKU_1back to summary
public static final MediaSize KAKU_1

Specifies the JIS Kaku ("square") #1 envelope size, 270 mm by 382 mm.

KAKU_2back to summary
public static final MediaSize KAKU_2

Specifies the JIS Kaku ("square") #2 envelope size, 240 mm by 332 mm.

KAKU_20back to summary
public static final MediaSize KAKU_20

Specifies the JIS Kaku ("square") #20 envelope size, 229 mm by 324 mm.

KAKU_3back to summary
public static final MediaSize KAKU_3

Specifies the JIS Kaku ("square") #3 envelope size, 216 mm by 277 mm.

KAKU_4back to summary
public static final MediaSize KAKU_4

Specifies the JIS Kaku ("square") #4 envelope size, 197 mm by 267 mm.

KAKU_5back to summary
public static final MediaSize KAKU_5

Specifies the JIS Kaku ("square") #5 envelope size, 190 mm by 240 mm.

KAKU_6back to summary
public static final MediaSize KAKU_6

Specifies the JIS Kaku ("square") #6 envelope size, 162 mm by 229 mm.

KAKU_7back to summary
public static final MediaSize KAKU_7

Specifies the JIS Kaku ("square") #7 envelope size, 142 mm by 205 mm.

KAKU_8back to summary
public static final MediaSize KAKU_8

Specifies the JIS Kaku ("square") #8 envelope size, 119 mm by 197 mm.

KAKU_A4back to summary
public static final MediaSize KAKU_A4

Specifies the JIS Kaku ("square") A4 envelope size, 228 mm by 312 mm.

YOU_1back to summary
public static final MediaSize YOU_1

Specifies the JIS You ("Western") #1 envelope size, 120 mm by 176 mm.

YOU_2back to summary
public static final MediaSize YOU_2

Specifies the JIS You ("Western") #2 envelope size, 114 mm by 162 mm.

YOU_3back to summary
public static final MediaSize YOU_3

Specifies the JIS You ("Western") #3 envelope size, 98 mm by 148 mm.

YOU_4back to summary
public static final MediaSize YOU_4

Specifies the JIS You ("Western") #4 envelope size, 105 mm by 235 mm.

YOU_5back to summary
public static final MediaSize YOU_5

Specifies the JIS You ("Western") #5 envelope size, 95 mm by 217 mm.

YOU_6back to summary
public static final MediaSize YOU_6

Specifies the JIS You ("Western") #6 envelope size, 98 mm by 190 mm.

YOU_7back to summary
public static final MediaSize YOU_7

Specifies the JIS You ("Western") #7 envelope size, 92 mm by 165 mm.

Constructor Detail

JISback to summary
private JIS()

Hide all constructors.

javax.print.attribute.standard back to summary

public final Class MediaSize.NA

extends Object
Class Inheritance

Class MediaSize.NA includes MediaSize values for North American media.

Field Summary

Modifier and TypeField and Description
public static final MediaSize
LEGAL

Specifies the North American legal size, 8.5 inches by 14 inches.

public static final MediaSize
LETTER

Specifies the North American letter size, 8.5 inches by 11 inches.

public static final MediaSize
NA_10x13_ENVELOPE

Specifies the North American 10 inch by 13 inch envelope size.

public static final MediaSize
NA_10x14_ENVELOPE

Specifies the North American 10 inch by 14 inch envelope size.

public static final MediaSize
NA_10X15_ENVELOPE

Specifies the North American 10 inch by 15 inch envelope size.

public static final MediaSize
NA_5X7

Specifies the North American 5 inch by 7 inch paper.

public static final MediaSize
NA_6X9_ENVELOPE

Specifies the North American 6 inch by 9 inch envelope size.

public static final MediaSize
NA_7X9_ENVELOPE

Specifies the North American 7 inch by 9 inch envelope size.

public static final MediaSize
NA_8X10

Specifies the North American 8 inch by 10 inch paper.

public static final MediaSize
NA_9x11_ENVELOPE

Specifies the North American 9 inch by 11 inch envelope size.

public static final MediaSize
NA_9x12_ENVELOPE

Specifies the North American 9 inch by 12 inch envelope size.

public static final MediaSize
NA_NUMBER_10_ENVELOPE

Specifies the North American Number 10 business envelope size, 4.125 inches by 9.5 inches.

public static final MediaSize
NA_NUMBER_11_ENVELOPE

Specifies the North American Number 11 business envelope size, 4.5 inches by 10.375 inches.

public static final MediaSize
NA_NUMBER_12_ENVELOPE

Specifies the North American Number 12 business envelope size, 4.75 inches by 11 inches.

public static final MediaSize
NA_NUMBER_14_ENVELOPE

Specifies the North American Number 14 business envelope size, 5 inches by 11.5 inches.

public static final MediaSize
NA_NUMBER_9_ENVELOPE

Specifies the North American Number 9 business envelope size, 3.875 inches by 8.875 inches.

Constructor Summary

AccessConstructor and Description
private
NA()

Hide all constructors.

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

LEGALback to summary
public static final MediaSize LEGAL

Specifies the North American legal size, 8.5 inches by 14 inches.

LETTERback to summary
public static final MediaSize LETTER

Specifies the North American letter size, 8.5 inches by 11 inches.

NA_10x13_ENVELOPEback to summary
public static final MediaSize NA_10x13_ENVELOPE

Specifies the North American 10 inch by 13 inch envelope size.

NA_10x14_ENVELOPEback to summary
public static final MediaSize NA_10x14_ENVELOPE

Specifies the North American 10 inch by 14 inch envelope size.

NA_10X15_ENVELOPEback to summary
public static final MediaSize NA_10X15_ENVELOPE

Specifies the North American 10 inch by 15 inch envelope size.

NA_5X7back to summary
public static final MediaSize NA_5X7

Specifies the North American 5 inch by 7 inch paper.

NA_6X9_ENVELOPEback to summary
public static final MediaSize NA_6X9_ENVELOPE

Specifies the North American 6 inch by 9 inch envelope size.

NA_7X9_ENVELOPEback to summary
public static final MediaSize NA_7X9_ENVELOPE

Specifies the North American 7 inch by 9 inch envelope size.

NA_8X10back to summary
public static final MediaSize NA_8X10

Specifies the North American 8 inch by 10 inch paper.

NA_9x11_ENVELOPEback to summary
public static final MediaSize NA_9x11_ENVELOPE

Specifies the North American 9 inch by 11 inch envelope size.

NA_9x12_ENVELOPEback to summary
public static final MediaSize NA_9x12_ENVELOPE

Specifies the North American 9 inch by 12 inch envelope size.

NA_NUMBER_10_ENVELOPEback to summary
public static final MediaSize NA_NUMBER_10_ENVELOPE

Specifies the North American Number 10 business envelope size, 4.125 inches by 9.5 inches.

NA_NUMBER_11_ENVELOPEback to summary
public static final MediaSize NA_NUMBER_11_ENVELOPE

Specifies the North American Number 11 business envelope size, 4.5 inches by 10.375 inches.

NA_NUMBER_12_ENVELOPEback to summary
public static final MediaSize NA_NUMBER_12_ENVELOPE

Specifies the North American Number 12 business envelope size, 4.75 inches by 11 inches.

NA_NUMBER_14_ENVELOPEback to summary
public static final MediaSize NA_NUMBER_14_ENVELOPE

Specifies the North American Number 14 business envelope size, 5 inches by 11.5 inches.

NA_NUMBER_9_ENVELOPEback to summary
public static final MediaSize NA_NUMBER_9_ENVELOPE

Specifies the North American Number 9 business envelope size, 3.875 inches by 8.875 inches.

Constructor Detail

NAback to summary
private NA()

Hide all constructors.

javax.print.attribute.standard back to summary

public final Class MediaSize.Other

extends Object
Class Inheritance

Class MediaSize.Other includes MediaSize values for miscellaneous media.

Field Summary

Modifier and TypeField and Description
public static final MediaSize
EXECUTIVE

Specifies the executive size, 7.25 inches by 10.5 inches.

public static final MediaSize
FOLIO

Specifies the folio size, 8.5 inches by 13 inches.

public static final MediaSize
INVOICE

Specifies the invoice size, 5.5 inches by 8.5 inches.

public static final MediaSize
ITALY_ENVELOPE

Specifies the Italy envelope size, 110 mm by 230 mm.

public static final MediaSize
JAPANESE_DOUBLE_POSTCARD

Specifies the Japanese Double postcard size, 148 mm by 200 mm.

public static final MediaSize
JAPANESE_POSTCARD

Specifies the Japanese postcard size, 100 mm by 148 mm.

public static final MediaSize
LEDGER

Specifies the ledger size, 11 inches by 17 inches.

public static final MediaSize
MONARCH_ENVELOPE

Specifies the Monarch envelope size, 3.87 inch by 7.5 inch.

public static final MediaSize
PERSONAL_ENVELOPE

Specifies the Personal envelope size, 3.625 inch by 6.5 inch.

public static final MediaSize
QUARTO

Specifies the quarto size, 8.5 inches by 10.83 inches.

public static final MediaSize
TABLOID

Specifies the tabloid size, 11 inches by 17 inches.

Constructor Summary

AccessConstructor and Description
private
Other()

Hide all constructors.

Method Summary

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

EXECUTIVEback to summary
public static final MediaSize EXECUTIVE

Specifies the executive size, 7.25 inches by 10.5 inches.

FOLIOback to summary
public static final MediaSize FOLIO

Specifies the folio size, 8.5 inches by 13 inches.

INVOICEback to summary
public static final MediaSize INVOICE

Specifies the invoice size, 5.5 inches by 8.5 inches.

ITALY_ENVELOPEback to summary
public static final MediaSize ITALY_ENVELOPE

Specifies the Italy envelope size, 110 mm by 230 mm.

JAPANESE_DOUBLE_POSTCARDback to summary
public static final MediaSize JAPANESE_DOUBLE_POSTCARD

Specifies the Japanese Double postcard size, 148 mm by 200 mm.

JAPANESE_POSTCARDback to summary
public static final MediaSize JAPANESE_POSTCARD

Specifies the Japanese postcard size, 100 mm by 148 mm.

LEDGERback to summary
public static final MediaSize LEDGER

Specifies the ledger size, 11 inches by 17 inches.

MONARCH_ENVELOPEback to summary
public static final MediaSize MONARCH_ENVELOPE

Specifies the Monarch envelope size, 3.87 inch by 7.5 inch.

PERSONAL_ENVELOPEback to summary
public static final MediaSize PERSONAL_ENVELOPE

Specifies the Personal envelope size, 3.625 inch by 6.5 inch.

QUARTOback to summary
public static final MediaSize QUARTO

Specifies the quarto size, 8.5 inches by 10.83 inches.

TABLOIDback to summary
public static final MediaSize TABLOID

Specifies the tabloid size, 11 inches by 17 inches.

Since
1.5

Constructor Detail

Otherback to summary
private Other()

Hide all constructors.