Skip to content

Commit 4c3177a

Browse files
committed
Lots of typing, let's hope it was worth it
1 parent 8225184 commit 4c3177a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+670
-8
lines changed

build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ plugins {
44
}
55

66
group = 'com.labelzoom.api'
7-
version = '1.0.2'
7+
version = '1.0.3'
88

99
repositories {
1010
mavenCentral()

src/main/java/com/labelzoom/api/input/LabelReader.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package com.labelzoom.api.input;
22

3-
import com.labelzoom.api.model.ILabel;
3+
import com.labelzoom.api.model.components.ILabel;
44

55
public interface LabelReader<E>
66
{
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
package com.labelzoom.api.model;
2+
3+
public enum BarcodeStyle
4+
{
5+
Unknown(-1),
6+
Aztec(0),
7+
Code11(1),
8+
Interleaved2of5(2),
9+
Code39(3),
10+
Code49(4),
11+
PlanetCode(5),
12+
PDF417(7),
13+
EAN_8(8),
14+
UPC_E(9),
15+
Code93(10),
16+
CODABLOCK(11),
17+
Code128(12),
18+
UPSMaxiCode(13),
19+
EAN_13(14),
20+
Micro_PDF417(15),
21+
Industrial2of5(18),
22+
Standard2of5(19),
23+
ANSICodabar(20),
24+
LOGMARS(21),
25+
MSI(22),
26+
Aztec2(24),
27+
Plessey(25),
28+
QRCode(26),
29+
GS1Databar(27),
30+
UPC_EAN(28),
31+
UPC_A(30),
32+
DataMatrix(33),
33+
PostNet(35);
34+
35+
private int value;
36+
BarcodeStyle(final int value) {
37+
this.value = value;
38+
}
39+
public int getValue() {
40+
return value;
41+
}
42+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package com.labelzoom.api.model;
2+
3+
public enum HorizontalAlignment
4+
{
5+
Left, Center, Right
6+
}

src/main/java/com/labelzoom/api/model/ILabel.java

-5
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package com.labelzoom.api.model;
2+
3+
public enum Justification
4+
{
5+
Left, Right, Auto
6+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package com.labelzoom.api.model;
2+
3+
public enum Orientation
4+
{
5+
Horizontal, Vertical;
6+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
package com.labelzoom.api.model;
2+
3+
public enum PageOrientation
4+
{
5+
Landscape (1),
6+
Portrait (2),
7+
ReverseLandscape (3),
8+
ReversePortrait (4);
9+
10+
private final int value;
11+
PageOrientation(final int value) {
12+
this.value = value;
13+
}
14+
public int getValue() {
15+
return value;
16+
}
17+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package com.labelzoom.api.model;
2+
3+
public enum PositioningMode
4+
{
5+
Origin, Typeset
6+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface IAddressBlock extends IFontComponent
4+
{
5+
boolean isUseLocalizedAddressFormat();
6+
void setUseLocalizedAddressFormat(boolean useLocalizedAddressFormat);
7+
8+
int getStaticAddressFormat();
9+
void setStaticAddressFormat(int addressFormat);
10+
11+
boolean isShowContactName();
12+
void setShowContactName(boolean showContactName);
13+
14+
boolean isShowCountry();
15+
void setShowCountry(boolean showCountry);
16+
17+
String getAddressId();
18+
void setAddressId(String addressId);
19+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import com.labelzoom.api.model.Justification;
4+
import com.labelzoom.api.model.PositioningMode;
5+
6+
public interface IComponent extends Cloneable
7+
{
8+
int getLeft();
9+
void setLeft(int left);
10+
11+
int getTop();
12+
void setTop(int top);
13+
14+
float getRotation();
15+
void setRotation(float rotation);
16+
17+
boolean isReverse();
18+
void setReverse();
19+
20+
Justification getJustification();
21+
void setJustification(Justification justification);
22+
23+
PositioningMode getPositioningMode();
24+
void setPositioningMode(PositioningMode positioningMode);
25+
26+
int getZIndex();
27+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface IContainer extends IComponent
4+
{
5+
Iterable<IComponent> getChildren();
6+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface IDataCommand extends Cloneable
4+
{
5+
String getLanguage();
6+
void setLanguage(String language);
7+
8+
String getDataCommand();
9+
void setDataCommand(String dataCommand);
10+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import java.util.regex.Pattern;
4+
5+
public interface IDynamicField
6+
{
7+
Pattern SIMPLE_EXPRESSION_PATTERN = Pattern.compile("\"\\$\\{([A-Za-z0-9_]+)\\}\"");
8+
Pattern VARIABLE_EXPRESSION_PATTERN = Pattern.compile("\\$\\{([A-Za-z0-9_]+)\\}");
9+
Pattern VARIABLE_NAME_PATTERN = Pattern.compile("^([A-Za-z0-9_]+)$");
10+
11+
void setExpression(String expression);
12+
String getExpression();
13+
14+
void setFieldValue(String value);
15+
String getFieldValue();
16+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface IFontComponent extends IComponent, ISuppressible
4+
{
5+
String getFont();
6+
void setFont(String font);
7+
8+
float getFontSize();
9+
void setFontSize(float fontSize);
10+
11+
float getHorizontalScaling();
12+
void setHorizontalScaling(float horizontalScaling);
13+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import java.awt.image.RenderedImage;
4+
5+
public interface IImage extends IComponent
6+
{
7+
IImageWrapper getImage();
8+
void setImage(IImageWrapper imageWrapper);
9+
10+
float getHorizontalScaling();
11+
void setHorizontalScaling(float horizontalScaling);
12+
13+
float getVerticalScaling();
14+
void setVerticalScaling(float verticalScaling);
15+
16+
interface IImageWrapper
17+
{
18+
RenderedImage getImage();
19+
}
20+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import com.labelzoom.api.model.PageOrientation;
4+
5+
import java.util.Comparator;
6+
import java.util.List;
7+
import java.util.UUID;
8+
9+
public interface ILabel
10+
{
11+
String DEFAULT_LAYER_NAME = "background";
12+
13+
int getWidth();
14+
void setWidth(int width);
15+
16+
int getHeight();
17+
void setHeight(int height);
18+
19+
boolean isHighRes();
20+
void setHighRes(boolean highRes);
21+
22+
PageOrientation getOrientation();
23+
void setOrientation(PageOrientation orientation);
24+
25+
List<ILayer> getLayers();
26+
void setLayers(List<ILayer> layers);
27+
28+
IDataCommand getDataCommand();
29+
void setDataCommand(IDataCommand dataCommand);
30+
31+
String getSchemaLocation();
32+
void setSchemaLocation(String schemaLocation);
33+
34+
String getSchemaVersion();
35+
void setSchemaVersion(String schemaVersion);
36+
37+
UUID getId();
38+
void setId(UUID id);
39+
40+
List<IComponent> getElements();
41+
List<IComponent> getSortedElements();
42+
void setElements(List<IComponent> elements);
43+
44+
void addElement(IComponent element);
45+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import java.util.List;
4+
5+
public interface ILayer
6+
{
7+
String getName();
8+
void setName(String name);
9+
10+
List<IComponent> getElements();
11+
void setElements(List<IComponent> elements);
12+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import com.labelzoom.api.model.Orientation;
4+
5+
public interface ILine extends IComponent
6+
{
7+
Orientation getOrientation();
8+
void setOrientation(Orientation orientation);
9+
10+
int getThickness();
11+
void setThickness(int thickness);
12+
13+
int getLength();
14+
void setLength(int length);
15+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface IRectangle extends IComponent
4+
{
5+
int getWidth();
6+
void setWidth(int width);
7+
8+
int getHeight();
9+
void setHeight(int height);
10+
11+
int getThickness();
12+
void setThickness(int thickness);
13+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface IStaticText extends IFontComponent
4+
{
5+
String getText();
6+
void setText(String text);
7+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
package com.labelzoom.api.model.components;
2+
3+
public interface ISuppressible
4+
{
5+
boolean isBlankWhenNull();
6+
void setBlankWhenNull(boolean blankWhenNull);
7+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
package com.labelzoom.api.model.components;
2+
3+
/* Copyright (C) 2021, LabelZoom, a subsidiary of RJF Technology Solutions, Inc.
4+
* All rights reserved. Proprietary and confidential.
5+
*
6+
* This file is subject to the license terms found at
7+
* https://www.labelzoom.net/end-user-license-agreement/
8+
*
9+
* The methods and techniques described herein are considered
10+
* confidential and/or trade secrets.
11+
* No part of this file may be copied, modified, propagated,
12+
* or distributed except as authorized by the license.
13+
*/
14+
15+
@Deprecated
16+
public interface IVariableField
17+
{
18+
void setDataField(String fldnam);
19+
String getDataField();
20+
21+
void setFieldValue(String value);
22+
String getFieldValue();
23+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
package com.labelzoom.api.model.components;
2+
3+
import com.labelzoom.api.model.HorizontalAlignment;
4+
5+
public interface IVariableText extends IFontComponent, IDynamicField
6+
{
7+
boolean isAutoSize();
8+
void setAutoSize(boolean autoSize);
9+
10+
int getWidth();
11+
void setWidth(int width);
12+
13+
int getHeight();
14+
void setHeight(int height);
15+
16+
HorizontalAlignment getHorizontalAlignment();
17+
void setHorizontalAlignment(HorizontalAlignment alignment);
18+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
package com.labelzoom.api.model.components.barcodes;
2+
3+
import com.labelzoom.api.model.BarcodeStyle;
4+
import com.labelzoom.api.model.components.IComponent;
5+
import com.labelzoom.api.model.components.IDynamicField;
6+
import com.labelzoom.api.model.components.ISuppressible;
7+
8+
public interface IBarcode extends IComponent, IDynamicField, ISuppressible
9+
{
10+
BarcodeStyle getBarcodeStyle();
11+
void setBarcodeStyle(BarcodeStyle barcodeStyle);
12+
}

0 commit comments

Comments
 (0)