DE 48 Packing Issue

58 views
Skip to first unread message

Thulasiram Reddy Keesanuru

unread,
Jun 19, 2021, 1:46:13 PMJun 19
to jPOS Users
Team required your assistance to pack DE 48 . shared below DE48 field specification and expected Hex a dump value.

Field 48 Additional Data, Private Representation: b..999 (LLLVAR) Description: Reserved for private use to define data unique to specific applications  

Requirements: This field is conditional in 1100, 1110, 1120, 1130, 1200, 1210, 1220, and 1230 messages. This field is logically subdivided into the following subfields using the Fixed Tag Length Value (Fixed TLV) method. The lengths shown are the number of bytes of data. Each Tag element is exactly 2 bytes, and each Length element is exactly 1 byte.  

DE -48 package specification is below :
<isofieldpackager
id="48"
length="999"
name="ADITIONAL DATA - PRIVATE"
class="org.jpos.iso.IFB_LLLHBINARY"
token="0000"
packager="org.jpos.tlv.packager.TaggedSequencePackager">
<isofield
id="1"
length="99"
token="####"
name="Default Tag Packager"
class="org.jpos.tlv.packager.IFTA_LLCHAR"/>
</isofieldpackager>

Packing value : A021042020(A021 -tag , 04 length,2020 --Value)


0130    00 07 a0 21 04 32 30 32 30 09 | ...!.2020. | .......... |

please assist me to pack 48 fld with above format.



Thulasiram Reddy Keesanuru

unread,
Jun 21, 2021, 6:25:10 AMJun 21
to jpos-...@googlegroups.com
Dear Jpos Users,

Any assistance on below issue.


--
--
jPOS is licensed under AGPL - free for community usage for your open-source project. Licenses are also available for commercial usage. Please support jPOS, contact: sa...@jpos.org
---
You received this message because you are subscribed to the Google Groups "jPOS Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jpos-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/c3169450-04af-40a4-97ed-3741150bec16n%40googlegroups.com.

Alejandro Revilla

unread,
Jun 23, 2021, 7:25:01 AMJun 23
to jpos-...@googlegroups.com
Take a look at the org.jpos.tlv package. See its unit tests as examples. 

--

Thulasiram Reddy Keesanuru

unread,
Jun 28, 2021, 8:33:53 AMJun 28
to jpos-...@googlegroups.com

  Thanks  Alejandro,  Using TlvList I am able to achieve.
     
TLVList tlvList = new TLVList();
tlvList.append(Integer.parseInt("A021",16), ISOUtil.hexString("****".getBytes()));
         




  

Alejandro Revilla

unread,
Jun 28, 2021, 9:11:57 AMJun 28
to jPOS Users
Excellent. 

Dont trust getBytes(). Make sure you specify the encoding there. I suggest you use getBytes(StandardCharsets.ISO_8859_1).

--


Reply all
Reply to author
Forward
0 new messages