home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
viscobv6.zip
/
vac22os2
/
ibmcobol
/
samples
/
toolkit
/
rexx
/
ccreply.cmd
next >
Wrap
OS/2 REXX Batch file
|
1996-11-19
|
2KB
|
25 lines
/******************************************************************************/
/* ccreply Object REXX Samples */
/* */
/* A concurrent programming example. */
/* */
/* This program demonstrates how to use reply to run two methods at the same */
/* time. */
/******************************************************************************/
object1 = .example~new /* Create two new instances of */
object2 = .example~new /* the example class. */
say object1~repeat(10, 'Object 1 running') /* Start first object running */
say object2~repeat(10, 'Object 2 running') /* Start second object running */
say 'Main ended.'
exit /* Exit and watch our kids run */
::class example /* Define the example class */
::method repeat /* Define the repeat method */
use arg reps,msg
reply 'Repeating "'msg'",' reps 'times.' /* Reply so others can run */
do reps
say msg /* Show that we're working */
end