× 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.



I'm not going to pretend I'm a java programmer (or even play one on TV), but aren't classes analogous to service programs? Don't they, too, have to be created by the developer, or is this something that comes with the jdk?

I will say that a couple of years ago I was given a task that seemed impossible to do in RPG (as I knew it, anyway). Until I had a couple of belts of sour mash and remembered java classes and methods (I did take one class years ago when java was going to replace all other languages). Translated that concept into a service program and, bang, done.

Now, back to these class libraries? And why can't one do that in RPG IV?

Jerry C. Adams
IBM System i Programmer/Analyst
B&W Wholesale
office: 615-995-7024
email: jerry@xxxxxxxxxxxxxxx


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Steve Richter
Sent: Wednesday, June 18, 2008 2:26 PM
To: RPG programming on the AS400 / iSeries
Subject: Re: Is RPG 'DEAD"

On Wed, Jun 18, 2008 at 2:19 PM, Lim Hock-Chai
<Lim.Hock-Chai@xxxxxxxxxxxxxxx> wrote:
uuumm. RPG send a escape message, which provide immidiate attention to the user that the program is not function properly. If user took option c, all open files and locks are automatically closed and released. If a programmer is contacted, programmer can start a sevice job and jump into the program thru debugger to look at value of all variables or takes option D to dump the program. How do you do that in java?

I'm not understanding the example you given. If a file is open/lock by another job, there is no way for a java or RPG program to close it.


Steve, you cannot simply pick a few features that java has and say that RPG is inferior to java. If it is that easy, I can do the same and say the java is inferior to RPG because:
1) java does not support F spec. In RPG, you easily read/update/write record to a file by simply add a F spec.
2) You cannot use a simple statement like this in java to assign the value of a int variable to a decimal variable: myDecimalVariable = myIntVariable.
3) You cannot use a simple statement like this in java to concate 5 different char strings variable myNewString = string1+string2+string3+string4+string5.
4) RPG allows function parameter to pass by value/const/reference.
5) By adding Bnddir('QC2LE') in the H spec, RPG can easily call function in c standard lib.


Lim,

a feature by feature discussion is interesting to me, but the bottom
line from my POV is that C# and Java have class libraries and RPG does
not. The reason is because those two languages have the features
needed to write and use a robust set of reuseable classes. RPG is a
good language. Applications written in RPG dont sink under their own
weight like they do in COBOL.

On the other hand, a case can be made that delegates, virtual methods
and now monads make apps written in C# too complicated to read.
http://blogs.msdn.com/wesdyer/archive/2008/01/11/the-marvels-of-monads.aspx

-Steve
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.