From c45fc85b78f3d8701346a231f07b7ffa984ca4ed Mon Sep 17 00:00:00 2001 From: CGantert345 <57003061+CGantert345@users.noreply.github.com> Date: Fri, 23 Apr 2021 13:41:58 +0200 Subject: update --- src/main/java/org/uic/barcode/Encoder.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/main/java/org/uic/barcode/Encoder.java') diff --git a/src/main/java/org/uic/barcode/Encoder.java b/src/main/java/org/uic/barcode/Encoder.java index aafe5cc..29ce63d 100644 --- a/src/main/java/org/uic/barcode/Encoder.java +++ b/src/main/java/org/uic/barcode/Encoder.java @@ -5,6 +5,7 @@ import java.security.PrivateKey; import java.security.PublicKey; import org.uic.barcode.asn1.datatypesimpl.OctetString; +import org.uic.barcode.dynamicContent.dfcb1.UicDynamicContentData1; import org.uic.barcode.dynamicFrame.Constants; import org.uic.barcode.dynamicFrame.DataType; import org.uic.barcode.dynamicFrame.DynamicFrame; @@ -165,6 +166,15 @@ public class Encoder { } } + public void setDynamicContentDataUIC1(UicDynamicContentData1 dcd) { + if (dynamicFrame != null) { + if (dynamicFrame.getLevel2SignedData() == null) { + dynamicFrame.setLevel2SignedData(new Level2DataType()); + } + dynamicFrame.getLevel2SignedData().setLevel2Data(dcd.getDataType()); + } + } + public DataType getLevel2Data() { if (dynamicFrame != null && dynamicFrame.getLevel2SignedData() != null) { return dynamicFrame.getLevel2SignedData().getLevel2Data(); @@ -172,6 +182,14 @@ public class Encoder { return null; } + public UicDynamicContentData1 getDynamicContentDataUIC1() { + if (dynamicFrame != null && dynamicFrame.getLevel2SignedData() != null) { + return dynamicFrame.getDynamicDataFDC1(); + } + return null; + } + + /** * Sign level 1 of a dynamic bar code or a static bar code. * -- cgit v1.2.3 From 9c27db0284c86583c135282e637f5e4dcb220c89 Mon Sep 17 00:00:00 2001 From: CGantert345 <57003061+CGantert345@users.noreply.github.com> Date: Wed, 12 May 2021 14:00:22 +0200 Subject: - Bug fix StaticHeader date format - Dynamic content for the dynamic content of the dynamic frame --- src/main/java/org/uic/barcode/Encoder.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/main/java/org/uic/barcode/Encoder.java') diff --git a/src/main/java/org/uic/barcode/Encoder.java b/src/main/java/org/uic/barcode/Encoder.java index 29ce63d..d971214 100644 --- a/src/main/java/org/uic/barcode/Encoder.java +++ b/src/main/java/org/uic/barcode/Encoder.java @@ -5,7 +5,7 @@ import java.security.PrivateKey; import java.security.PublicKey; import org.uic.barcode.asn1.datatypesimpl.OctetString; -import org.uic.barcode.dynamicContent.dfcb1.UicDynamicContentData1; +import org.uic.barcode.dynamicContent.fdc1.UicDynamicContentDataFDC1; import org.uic.barcode.dynamicFrame.Constants; import org.uic.barcode.dynamicFrame.DataType; import org.uic.barcode.dynamicFrame.DynamicFrame; @@ -166,7 +166,7 @@ public class Encoder { } } - public void setDynamicContentDataUIC1(UicDynamicContentData1 dcd) { + public void setDynamicContentDataUIC1(UicDynamicContentDataFDC1 dcd) { if (dynamicFrame != null) { if (dynamicFrame.getLevel2SignedData() == null) { dynamicFrame.setLevel2SignedData(new Level2DataType()); @@ -182,7 +182,7 @@ public class Encoder { return null; } - public UicDynamicContentData1 getDynamicContentDataUIC1() { + public UicDynamicContentDataFDC1 getDynamicContentDataUIC1() { if (dynamicFrame != null && dynamicFrame.getLevel2SignedData() != null) { return dynamicFrame.getDynamicDataFDC1(); } -- cgit v1.2.3