--
--
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 post to this group, send email to jpos-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/8e72b884-3934-42cd-9fdf-d0d6cb8b64b5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAOfY%3Dj8KaAcQ%2Bh1FiE6fiLL0NWcAicQcEkCp-pomdckVLQLSLw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAPazefDV7F4cVPMfxfFkbxm1xinZ1wfjZ%3D6Z1c2UrE4er_qNpw%40mail.gmail.com.
import java.io.IOException;
import java.net.MalformedURLException;
import java.text.SimpleDateFormat;
import java.util.Date;
import org.jdom.JDOMException;
import org.jpos.iso.ISOException;
import org.jpos.iso.ISOMsg;
import org.jpos.iso.ISOUtil;
import org.jpos.iso.packager.GenericPackager;
import org.jpos.util.Logger;
import org.jpos.util.SimpleLogListener;
public class Test {
public static void main(String[] args) throws ISOException, MalformedURLException, JDOMException, IOException {
GenericPackager packager = new GenericPackager("C:\\temp\\basic.xml");
Logger l = new Logger();
l.addListener(new SimpleLogListener());
packager.setLogger(l, "jsagfj");
ISOMsg isoMsg = new ISOMsg();
isoMsg.setPackager(packager);
isoMsg.set(0, "0100");
isoMsg.set(2, "4289697648928752");
isoMsg.set(3, "000000");
isoMsg.set(4, "000000020000");
isoMsg.set(7, new SimpleDateFormat("MMddHHmmss").format(new Date()));
isoMsg.set(11, "105790");
isoMsg.set(12, new SimpleDateFormat("HHmmss").format(new Date()));
isoMsg.set(13, "0326");
isoMsg.set(14, "2407");
isoMsg.set(18, "5691");
isoMsg.set(22, "012");
isoMsg.set(25, "08");
isoMsg.set(32, "454899");
isoMsg.set(37, "908507105790");
isoMsg.set(41, "00050041");
isoMsg.set(42, "027174 ");
isoMsg.set(43, "COMMERCIAL8360DubaiAEAE");
isoMsg.set(49, "784");
isoMsg.set(123, "100030104000000");
try {
byte[] b = isoMsg.pack();
isoMsg.dump(System.out, "");
System.out.println(ISOUtil.hexdump(b));
}
catch (Exception e) {
e.printStackTrace();
isoMsg.dump(System.out, "");
}
}
}
<isomsg direction="none">
<!-- org.jpos.iso.packager.GenericPackager[C:\temp\basic.xml] -->
<field id="0" value="0100"/>
<field id="2" value="4289697648928752"/>
<field id="3" value="000000"/>
<field id="4" value="000000020000"/>
<field id="7" value="0610195140"/>
<field id="11" value="105790"/>
<field id="12" value="195140"/>
<field id="13" value="0326"/>
<field id="14" value="2407"/>
<field id="18" value="5691"/>
<field id="22" value="012"/>
<field id="25" value="08"/>
<field id="32" value="454899"/>
<field id="37" value="908507105790"/>
<field id="41" value="00050041"/>
<field id="42" value="027174 "/>
<field id="43" value="COMMERCIAL8360DubaiAEAE"/>
<field id="49" value="784"/>
<field id="123" value="100030104000000"/>
</isomsg>
0000 30 31 30 30 F2 3C 44 81 08 E0 80 00 00 00 00 00 0100.<D.........
0010 00 00 00 20 31 36 34 32 38 39 36 39 37 36 34 38 ... 164289697648
0020 39 32 38 37 35 32 30 30 30 30 30 30 30 30 30 30 9287520000000000
0030 30 30 30 32 30 30 30 30 30 36 31 30 31 39 35 31 0002000006101951
0040 34 30 31 30 35 37 39 30 31 39 35 31 34 30 30 33 4010579019514003
0050 32 36 32 34 30 37 35 36 39 31 30 31 32 30 38 30 2624075691012080
0060 36 34 35 34 38 39 39 39 30 38 35 30 37 31 30 35 6454899908507105
0070 37 39 30 30 30 30 35 30 30 34 31 30 32 37 31 37 7900005004102717
0080 34 20 20 20 20 20 20 20 20 20 43 4F 4D 4D 45 52 4 COMMER
0090 43 49 41 4C 38 33 36 30 44 75 62 61 69 41 45 41 CIAL8360DubaiAEA
00a0 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 E
00b0 20 20 37 38 34 30 31 35 31 30 30 30 33 30 31 30 78401510003010
00c0 34 30 30 30 30 30 30 4000000
--
--
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 post to this group, send email to jpos-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/df6171c0-8b72-4310-86f3-b1a65a58e65e%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAPazefDnQcRYM7XA9W65VjP8q8s5D8%3DgZE-3Rch9F917Ga2OOg%40mail.gmail.com.
To unsubscribe from this group and stop receiving emails from it, send an email to jpos-...@googlegroups.com.
0000 30 31 30 30 F2 3C 44 81 08 E0 80 00 00 00 00 00 0100.<D.........
0010 00 00 00 20 31 36 34 32 38 39 36 39 37 36 34 38 ... 164289697648
0020 39 32 38 37 35 32 30 30 30 30 30 30 30 30 30 30 9287520000000000
0030 30 30 30 32 30 30 30 30 30 36 31 30 31 39 35 31 0002000006101951
0040 34 30 31 30 35 37 39 30 31 39 35 31 34 30 30 33 4010579019514003
0050 32 36 32 34 30 37 35 36 39 31 30 31 32 30 38 30 2624075691012080
0060 36 34 35 34 38 39 39 39 30 38 35 30 37 31 30 35 6454899908507105
0070 37 39 30 30 30 30 35 30 30 34 31 30 32 37 31 37 7900005004102717
0080 34 20 20 20 20 20 20 20 20 20 43 4F 4D 4D 45 52 4 COMMER
0090 43 49 41 4C 38 33 36 30 44 75 62 61 69 41 45 41 CIAL8360DubaiAEA
00a0 45 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 E
00b0 20 20 37 38 34 30 31 35 31 30 30 30 33 30 31 30 78401510003010
00c0 34 30 30 30 30 30 30 4000000
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAOfY%3Dj9o95bs-o_axoBEHdiPGwY-DAqJReqRZr%2B7RwBEGVJ7Wg%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAPazefDX4JJ3zGnKDn-sW3ZSNNwRBrnRpcmFNDyxbc3qkNwMFQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAOfY%3Dj-%2Bc3q97uurF2c2GFmBshfH1L5GAG%3DKHSP0G3M%3DqaaKAQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAPazefBRoNm-MRZ-Fwa_fLdoiwGdaOFFMUZfBdLAfhaR5q4hhw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAOfY%3Dj8MFrFmpcix30OgcP_LPNH4SR0ze5FHHNwpXx0%3DY_UNBw%40mail.gmail.com.
Hi ccav
You are not defining the bitmap subfield for field 127:
You need something like this:
<isofieldpackager
id="127"
length="999999"
name="RESERVED PRIVATE USE"
class="org.jpos.iso.IFA_LLLLLLBINARY"
packager="org.jpos.iso.packager.GenericSubFieldPackager">
<isofield id="0" length="0" name="Placeholder" class="org.jpos.iso.IF_NOP" /> <isofield id="1" length="16" name="Bit Map" class="org.jpos.iso.IFA_BITMAP" /> And declare all the fields previous to tye field 38 I believe, take a look at postpack.xml as an example. Good luck
Transactility, Inc.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/CAOfY%3Dj8MFrFmpcix30OgcP_LPNH4SR0ze5FHHNwpXx0%3DY_UNBw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jpos-users/039c8dd5-1896-ab5e-4c60-954956ca0ee5%40transactility.com.