public class EmbosserTools
extends java.lang.Object
Modifier and Type | Field | Description |
---|---|---|
static double |
INCH_IN_MM |
Number of mm/inch
|
Constructor | Description |
---|---|
EmbosserTools() |
Modifier and Type | Method | Description |
---|---|---|
static int |
getHeight(Dimensions dim,
double unit) |
Get height, in units
|
static int |
getWidth(Dimensions dim,
double unit) |
Get width, in units
|
static byte[] |
toBytes(int val,
int size) |
Converts an integer to bytes and padding the value with zeros
to the required size.
|
public static final double INCH_IN_MM
public static byte[] toBytes(int val, int size)
val
- the value to convertsize
- the number of bytes to outputjava.lang.IllegalArgumentException
- if the integer value requires more bytes than
specified by size.public static int getWidth(Dimensions dim, double unit)
unit
- unit in mmpublic static int getHeight(Dimensions dim, double unit)
unit
- unit in mm