× 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 think we work in object-oriented ways more than we know. For one thing, consider the object-based design of the S/38 - AS/400 - iSeries - i5 and you will have some groundwork. E.g., a *FILE object could be considered a class - I know, it's deeper than that, but let's keep this simple - am just forming this on the fly - and a *FILE object has certain attributes at what we call file-level (file level identifier os one). ALL *FILE objects have these same attributes.

Now on the iSeries there are also methods contained in every object - things you can do - you can't write to a *PGM but you can to a *FILE.

Then you get a subclass, PF is one, DSPF is another, PRTF another. These all inherit the attributes and methods of the parent *FILE. Then each one adds attributes and methods and perhaps puts in a subclass-specific version of methods that are called first, maybe.

With PFs you can get further subclass of SQL table - and on it goes.

In our programming, as soon as you get into service programs and subprocedures, you are starting to talk about separating routines - you may even be setting up variables and using setters and getters for various things - you CAN do OO programming in any language, it's just easier in a language that supports it.

HTH and does not confuse too much! And hope it is a little on point!
Vern

-------------- Original message --------------
From: Pete Helgren <Pete@xxxxxxxxxx>

Phil,

I probably should restate the "the basics of programming that you use
every day in RPG will serve you well" then.

What I meant was that things like variables, arrays, loops, calculations
and many of things things we are familiar with in a procedural language
are also present in Java so making the transition from a "for loop" in
RPG to a "for loop" in Java wasn't that difficult for me (for example).
Where I had issues was in designing classes and methods that were truly
objects. I was doing some heavy mental gymnastics in thinking in
objects and I STILL have issues when I design classes as to what should
be an abstract class vs an interface vs a "regular" class. I move more
comfortably between RPG and Java now but I still trip over the object
stuff from time to time.

So it was the very basic "programming concepts" that were easy (to me at
least) to move to Java. Designing an object that contained both data
and processes for managing the data within the object was the hard jump
for me to make.

Pete


Phil Kestenbaum wrote:
Pete, How would you describe the RPG background as serving well in
object oriented programming? When I was studying this, I instinctively
was trying to make this connection, unsuccessfully.

Thank you,
Phil

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.