× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi David, interesting!

I can provide two things: an advice and some source code (it's an RPG not
Java).

About the advice, PCML it's basically Xml without steroids. Try to add to
the string the missing pieces and you get a useable Xml object:

Pcml = '<?xml version="1.0" encoding="UTF-8"?>';

entry_off = rcvr.offset_First_Entry;
for i = 1 to rcvr.Number_Entries;
pEntry = pRcvr + entry_off;
entry_off = entry.Offset_Next_Entry;
pEntryData = pRcvr + entry.Offset_Interface_Info;
Pcml += %subst(EntryData:1:entry.Interface_Info_Length_Ret);
endfor;

About the source code (I understand you took Java's route) we have a
working extractor that takes care of all data definitions (that are NOT in
the interfaces) and replies to the caller with the exploded interface. If
you plan to port this project also to RPG I can strip down (and translate)
the code. As usual the problem with RPG is that it doesn't play well with
complex structures so the basic definitions to return to the caller are...
huge or complex.

Last hint, if you plan to use PCML and Service Programs you can vote this
RFE:

https://www.ibm.com/developerworks/rfe/execute?use_case=viewRfe&CR_ID=135628


Since IBM accepted the RFE, we can hope for a better interface to call SRV
procedures without the 7 parm's limit.

HTH
--
Marco Facchinetti

Mr S.r.l.

Tel. 035 962885
Cel. 393 9620498

Skype: facchinettimarco


Il giorno gio 30 apr 2020 alle ore 21:46 David Gibbs via JAVA400-L <
java400-l@xxxxxxxxxxxxxxxxxx> ha scritto:

Folks:

I've started a small open source project on github to implement something
I've
been wanting to do for quite a while.

Basically, it's a utility class that will retrieve the PCML from a *PGM or
*SRVPGM object who's modules were created using PGMINFO(*PCML:*MODULE).

Currently it can return a string containing the PCML source, a Document
object
based on the PCML, or a ProgramCallDocument object.

If there are multiple modules in a service program that contain PCML, it
merges
them all together.

It's hosted on github ... here's the URL:
https://github.com/fallingrock/pcmltools

I'm just getting the hang of github ... dealing with the functions is
taking
more time than I thought it would.

Testing has only been moderate so far ... but if you care to take a look,
I'd
value any input.

david

--
IBM i on Power Systems: For when you can't afford to be out of business!

I'm riding in the American Diabetes Association's Tour de Cure to raise
money
for diabetes research, education, advocacy, and awareness. You can make a
tax-deductible donation to my ride by visiting
https://mideml.diabetessucks.net.

You can see where my donations come from by visiting my interactive
donation map
... https://mideml.diabetessucks.net/map (it's a geeky thing).

I may have diabetes, but diabetes doesn't have me!
--
This is the Java Programming on and around the IBM i (JAVA400-L) mailing
list
To post a message email: JAVA400-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/java400-l.

Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.