You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@plc4x.apache.org by cd...@apache.org on 2020/10/07 10:36:12 UTC
[plc4x] branch feature/socketcan updated: - Tweaked the handling of
arrays in dataIo serializers
This is an automated email from the ASF dual-hosted git repository.
cdutz pushed a commit to branch feature/socketcan
in repository https://gitbox.apache.org/repos/asf/plc4x.git
The following commit(s) were added to refs/heads/feature/socketcan by this push:
new 4cb98f9 - Tweaked the handling of arrays in dataIo serializers
4cb98f9 is described below
commit 4cb98f9a5a2b223cf2aa39ed19250811d7bca3a8
Author: Christofer Dutz <ch...@c-ware.de>
AuthorDate: Wed Oct 7 12:35:57 2020 +0200
- Tweaked the handling of arrays in dataIo serializers
---
.../src/main/resources/templates/java/data-io-template.ftlh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/build-utils/language-java/src/main/resources/templates/java/data-io-template.ftlh b/build-utils/language-java/src/main/resources/templates/java/data-io-template.ftlh
index 99b6871..3f680da 100644
--- a/build-utils/language-java/src/main/resources/templates/java/data-io-template.ftlh
+++ b/build-utils/language-java/src/main/resources/templates/java/data-io-template.ftlh
@@ -279,8 +279,8 @@ public class ${type.name}IO {
<#case "array">
PlcList values = (PlcList) _value;
- for (Plc${case.name} val : ((List<Plc${case.name}>) values.getList())) {
- ${helper.getLanguageTypeNameForField(field)} value = (${helper.getLanguageTypeNameForField(field)}) val.get${case.name}();
+ for (PlcValue val : ((List<PlcValue>) values.getList())) {
+ ${helper.getLanguageTypeNameForField(field)} value = (${helper.getLanguageTypeNameForField(field)}) val.get${helper.getLanguageTypeNameForField(field)?cap_first}();
${helper.getWriteBufferWriteMethodCall(field.type, "(" + field.name + ")")};
}