public final class PaperSize
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
PaperSize.Unit
Represents the measurement unit of the paper size.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
int |
height()
Returns the paper height in microns.
|
java.util.Optional<java.lang.String> |
name()
Returns an
Optional that contains the paper size name, otherwise an empty
Optional . |
static PaperSize |
of(float width,
float height,
PaperSize.Unit unit)
Creates a new
PaperSize setting. |
static PaperSize |
of(float width,
float height,
PaperSize.Unit unit,
java.lang.String name)
Creates a new
PaperSize setting. |
java.lang.String |
toString() |
static java.util.Collection<PaperSize> |
values()
Returns an immutable collection of the known
PaperSize values. |
int |
width()
Returns the paper width in microns.
|
public static final PaperSize NA_5X7
public static final PaperSize NA_6X9
public static final PaperSize NA_7X9
public static final PaperSize NA_9X11
public static final PaperSize NA_10X11
public static final PaperSize NA_10X13
public static final PaperSize NA_10X14
public static final PaperSize NA_10X15
public static final PaperSize NA_11X12
public static final PaperSize NA_11X15
public static final PaperSize NA_12X19
public static final PaperSize NA_INDEX_3X5
public static final PaperSize NA_INDEX_4X6
public static final PaperSize NA_INDEX_4X6_EXT
public static final PaperSize NA_INDEX_5X8
public static final PaperSize NA_NUMBER_9
public static final PaperSize NA_NUMBER_10
public static final PaperSize NA_NUMBER_11
public static final PaperSize NA_NUMBER_12
public static final PaperSize NA_NUMBER_14
public static final PaperSize NA_PERSONAL
public static final PaperSize NA_MONARCH
public static final PaperSize NA_INVOICE
public static final PaperSize NA_EXECUTIVE
public static final PaperSize NA_GOVT_LETTER
public static final PaperSize NA_GOVT_LEGAL
public static final PaperSize NA_QUARTO
public static final PaperSize NA_LETTER
public static final PaperSize NA_LETTER_PLUS
public static final PaperSize NA_LETTER_EXTRA
public static final PaperSize NA_LEGAL
public static final PaperSize NA_LEGAL_EXTRA
public static final PaperSize NA_FANFOLD_EUR
public static final PaperSize NA_FOOLSCAP
public static final PaperSize NA_FANFOLD_US
public static final PaperSize NA_SUPER_A
public static final PaperSize NA_SUPER_B
public static final PaperSize NA_A2
public static final PaperSize NA_ARCH_A
public static final PaperSize NA_ARCH_B
public static final PaperSize NA_ARCH_C
public static final PaperSize NA_ARCH_D
public static final PaperSize NA_ARCH_E
public static final PaperSize NA_C
public static final PaperSize NA_C5
public static final PaperSize NA_D
public static final PaperSize NA_E
public static final PaperSize NA_F
public static final PaperSize NA_EDP
public static final PaperSize NA_EUR_EDP
public static final PaperSize NA_LEDGER
public static final PaperSize NA_B_PLUS
public static final PaperSize NA_ASME_F
public static final PaperSize NA_WIDE_FORMAT
public static final PaperSize PRC_1
public static final PaperSize PRC_2
public static final PaperSize PRC_3
public static final PaperSize PRC_4
public static final PaperSize PRC_5
public static final PaperSize PRC_6
public static final PaperSize PRC_7
public static final PaperSize PRC_8
public static final PaperSize PRC_10
public static final PaperSize PRC_16K
public static final PaperSize PRC_32K
public static final PaperSize ROC_8K
public static final PaperSize ROC_16K
public static final PaperSize OM_JUURO_KU_KAI
public static final PaperSize OM_PA_KAI
public static final PaperSize OM_DAI_PA_KAI
public static final PaperSize ISO_A0
public static final PaperSize ISO_A1
public static final PaperSize ISO_A2
public static final PaperSize ISO_A3
public static final PaperSize ISO_A3_EXTRA
public static final PaperSize ISO_A4
public static final PaperSize ISO_A4_TAB
public static final PaperSize ISO_A4_EXTRA
public static final PaperSize ISO_A5
public static final PaperSize ISO_A5_EXTRA
public static final PaperSize ISO_A6
public static final PaperSize ISO_A7
public static final PaperSize ISO_A8
public static final PaperSize ISO_A9
public static final PaperSize ISO_A10
public static final PaperSize ISO_A4X3
public static final PaperSize ISO_A4X4
public static final PaperSize ISO_A4X5
public static final PaperSize ISO_A4X6
public static final PaperSize ISO_A4X7
public static final PaperSize ISO_A4X8
public static final PaperSize ISO_A4X9
public static final PaperSize ISO_A3X3
public static final PaperSize ISO_A3X4
public static final PaperSize ISO_A3X5
public static final PaperSize ISO_A3X6
public static final PaperSize ISO_A3X7
public static final PaperSize ISO_A2X3
public static final PaperSize ISO_A2X4
public static final PaperSize ISO_A2X5
public static final PaperSize ISO_A1X3
public static final PaperSize ISO_A1X4
public static final PaperSize ISO_2A0
public static final PaperSize ISO_A0X3
public static final PaperSize ISO_B0
public static final PaperSize ISO_B1
public static final PaperSize ISO_B2
public static final PaperSize ISO_B3
public static final PaperSize ISO_B4
public static final PaperSize ISO_B5
public static final PaperSize ISO_B5_EXTRA
public static final PaperSize ISO_B6
public static final PaperSize ISO_B6C4
public static final PaperSize ISO_B7
public static final PaperSize ISO_B8
public static final PaperSize ISO_B9
public static final PaperSize ISO_B10
public static final PaperSize ISO_C0
public static final PaperSize ISO_C1
public static final PaperSize ISO_C2
public static final PaperSize ISO_C3
public static final PaperSize ISO_C4
public static final PaperSize ISO_C5
public static final PaperSize ISO_C6
public static final PaperSize ISO_C6C5
public static final PaperSize ISO_C7
public static final PaperSize ISO_C7C6
public static final PaperSize ISO_C8
public static final PaperSize ISO_C9
public static final PaperSize ISO_C10
public static final PaperSize ISO_DL
public static final PaperSize ISO_RA2
public static final PaperSize ISO_SRA2
public static final PaperSize ISO_RA1
public static final PaperSize ISO_SRA1
public static final PaperSize ISO_RA0
public static final PaperSize ISO_SRA0
public static final PaperSize JIS_B0
public static final PaperSize JIS_B1
public static final PaperSize JIS_B2
public static final PaperSize JIS_B3
public static final PaperSize JIS_B4
public static final PaperSize JIS_B5
public static final PaperSize JIS_B6
public static final PaperSize JIS_B7
public static final PaperSize JIS_B8
public static final PaperSize JIS_B9
public static final PaperSize JIS_B10
public static final PaperSize JIS_EXEC
public static final PaperSize JPN_CHOU2
public static final PaperSize JPN_CHOU3
public static final PaperSize JPN_CHOU4
public static final PaperSize JPN_HAGAKI
public static final PaperSize JPN_OUFUKU
public static final PaperSize JPN_YOU4
public static final PaperSize JPN_KAHU
public static final PaperSize JPN_KAKU2
public static final PaperSize OM_SMALL_PHOTO
public static final PaperSize OM_ITALIAN
public static final PaperSize OM_POSTFIX
public static final PaperSize OM_LARGE_PHOTO
public static final PaperSize OM_FOLIO
public static final PaperSize OM_FOLIO_SP
public static final PaperSize OM_INVITE
public static PaperSize of(float width, float height, PaperSize.Unit unit)
PaperSize
setting.width
- the paper size widthheight
- the paper size heightunit
- the width
and height
measurement unitjava.lang.IllegalArgumentException
- when width
is negativejava.lang.IllegalArgumentException
- when height
is negativepublic static PaperSize of(float width, float height, PaperSize.Unit unit, java.lang.String name)
PaperSize
setting.width
- the paper size widthheight
- the paper size heightunit
- the width
and height
measurement unitname
- the paper size namejava.lang.IllegalArgumentException
- when width
is negativejava.lang.IllegalArgumentException
- when height
is negativejava.lang.IllegalArgumentException
- when name
is empty or blankpublic static java.util.Collection<PaperSize> values()
PaperSize
values.public int width()
public int height()
public java.util.Optional<java.lang.String> name()
Optional
that contains the paper size name, otherwise an empty
Optional
.public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object