Your description sounds a lot like "reentrant" modules.  That is, multiple
users are all making their way through a single code module at the same
time.  When code is said to be "fully reentrant", each user has their own
local variables.  Each user has their own "next-instruction-register" into
the program.  The key features of reentrant code is that it does not modify
itself and that each user has their own variables.  It is possible for a
reentrant program to modify itself - the circumstances and technique are
peculiar [string copy where the length is copied as a literal into the code
and all interrupts are masked until the copy completes].

In (almost) all cases, programs on AS/400 are reentrant.  I assume that
AS/400 Java programs are reentrant but I do not know for sure.  As you know,
Java is interpreted by the runtime.  As a regular AS/400 program, the
400-side runtime module is most-likely reentrant.

OO is defined by classes, inheritance, polymorphism, overloading, and
encapsulation - information hiding.  There is nothing in the theoretical OO
definition about implementation - like how the code is stored in memory.
For example, there is nothing about OO that requires that parameters be
passed between modules using a stack.

I submit that either he didn't explain it correctly or that you
misunderstood the explanation.

Richard Jackson
(speaking only for myself)

-----Original Message-----
From: owner-java400-l@midrange.com
[mailto:owner-java400-l@midrange.com]On Behalf Of Bartell, Aaron L. (TC)
Sent: Friday, January 19, 2001 11:01 AM
To: 'JAVA400-L@midrange.com'
Subject: OO Programming?


This question has been bugging me for some time now.  Here it is:

Java is known as an OO programming language but RPG is considered
procedural.  The other day I had a Java programmer explain to me that the OO
difference is not necessarily how you develop one program using a bunch of
different classes and objects but rather how they are stored in memory when
they are called.  Only one copy of a program is stored in memory in Java and
all programs making a call to that particular program are always referencing
that same one.

Is this also true for RPGILE type programming? With the advent of *SRVPGM
programs is the same thing basically happening with RPG?  From what I
understand the first initial call to a service program will load it into
memory and then leave it there for other programs to use.  Or is it just for
the length of that particular job.

I am not up on my Java or RPGILE lingo so please excuse any miss-use of
terms.

Trying to swallow the ocean one drop at a time,
Aaron Bartell

+---
| This is the JAVA/400 Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner: joe@zappie.net
+---

+---
| This is the JAVA/400 Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner: joe@zappie.net
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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

This mailing list archive is Copyright 1997-2022 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.