xclasses manifest

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

xclasses manifest

Pierantonio Marchesini
Hello everybody:

  sorry for the rather long posting. Indeed, I hope you'll
  like it, despite my "Maccheroni" English.

  This is just an announcement for a "beta" version of xclasses
  for NetRexx. If you are interested in trying them, please let
  me know, since I'm looking for some feedback before releasing
  them officially.

  Follows the "manifest" for the xclasses.

  Best Regards

    Pierantonio

--------------------------------------------------------------

  This is the Manifest for the
  "Extended Programmer Toolkit for NetRexx Script Applications".
  To make the thing shorter the package is also known as
  "NetRexx Xclasses".

* 1.00
* -- the main idea

  Many tasks performed when writing script applications
  are always the same.

  Among those tasks, you might find:
    - parsing command line options;
    - executing system commands;
    - reading (and interpreting) configuration files;
    - handle socket connections, FTP & HTMLs;
    - handle error conditions and tracebacks;
    - etc.

  Just looking at my Classical REXX code, I find that
  99% of the programs always contain a "kernel-set" of
  procedures (worth 400 lines of code). This code is
  always the same.

  In my NetRexx Tutorial I've put some of this functionality
  in some of the examples.

  The idea is to package all this in a better way, and offer
  a Toolkit for NetRexx Script Applications.

* 2.00
* -- features

  o - extended classes to support
       - basic option & configuration parsing
       - system I/F
       - socket operations
       - HTML operations
       - file & directory operations
       - date & time operations
       - etc.
  o - public domain code with source code available
  o - all classes available in a single JAR file
  o - documented in the NetRexx Tutorial

* 3.00
* -- examples

  To give you the real "feeling" of what I'm talking about,
  here are some examples of code fragments (which are also
  fully functional programs by themselves):

   -- 1.00
   -- execute a command
   cmd = xexec('jar -cvf test.jar *.class')
   if cmd.rc <> 0
     then xsys.die(300,'error from jar command.')

   -- 2.00
   -- print 31 Dec 1998 from Europe FMT to Julian
   say xsys.xdate('E','31/12/98','J')
   -- print next Monday in Julian FMT
   say xsys.xdate('NEXT','MONDAY','J')

   -- 3.00
   -- a simple FINGER client
   parse arg user'@'node
   cs = xsock(node,'FINGER')
   cs.send(user)
   cs.receive()
   cs.close()
   exit

   -- 4.00
   -- read record 123 of a recfm=F lrecl=80 file
   fid = xfile('test.test')
   fid.options('recfm=F,lrecl=80')
   say fid.recread(123)

   -- 5.00
   -- a simple FTP session
   say 'This is just a small test connecting to "asisftp.cern.ch".'
   ftpc = xftp('asisftp.cern.ch')
   ftpc.cmd('user anonymous [hidden email]')
   ftpc.cmd('ascii')
   ftpc.cmd('replace Y')
   ftpc.cmd('get wylbur.help')
   exit

   -- 6.00
   -- will fetch ALL the html files contained in the
   --   Tutorial HTML URL
   page = xurl('http://wwwinfo.cern.ch/news/netrexx/html/nr_toc.html')
   page.readlines()
   page.getreferences()
   list = page.referencelist
   loop while list <> ''
     parse list item list
     xurl.fetch(page.base||item)
   end
   exit

* 4.00
* -- using the xclasses

 To use the xclasses you need to:
   - copy the "xclasses.jar" in your preferred location
     (ex. /java/lib/xclasses.jar)
   - add this location to the CLASSPATH
   - add the statement "import xclasses." in your
     program

----------------------------------------------------------------
Pierantonio Marchesini                                  C.E.R.N.
ETH Zurich                                     CH-1211 GENEVE 23
email: [hidden email]    Phone: +41.22.767.50.23
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to
[hidden email]
with the following message in the body of the note
unsubscribe ibm-netrexx <e-mail address>

Reply | Threaded
Open this post in threaded view
|

Re: xclasses manifest

dIon Gillard/Multitask Consulting/AU
Where can we get them from?

On Fri, 1 May 1998 22:09:27 +0200, Pierantonio Marchesini wrote:

|   Hello everybody:
|  
|     sorry for the rather long posting. Indeed, I hope you'll
|     like it, despite my "Maccheroni" English.
|  
|     This is just an announcement for a "beta" version of xclasses
|     for NetRexx. If you are interested in trying them, please let
|     me know, since I'm looking for some feedback before releasing
|     them officially.



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To unsubscribe from this mailing list ( ibm-netrexx ), please send a note to
[hidden email]
with the following message in the body of the note
unsubscribe ibm-netrexx <e-mail address>