*** *** xarray *** Brief summary: xarray .. - constructor. No real use, since this is a collection of static methods. version() S. - display the version of xarray init(a=rexx[],value) S. - init NR array's contents with VALUE copy(a=rexx[],b=rexx[]) S. - copy array's contents A -> B reverse(a=rexx[],nrec=rexx) S. - reverse record nos, i.e. 1...N will become N...1 sort(a=rexx[],mode) S. - sorts an array. MODE=R will do reverse sorting sort(a=rexx[]) S. - sorts an array in ascending order dump(a=rexx[],name) S. - dump array's contents. NAME=comment dump(a=rexx[]) S. - dump array's contents. NAME='' ba2x(a=byte[],start=rexx,length=rex S. - Returns a string after a conversion ByteArray to HEX ba2c(a=byte[],start=rexx,length=rex S. - Like BA2X, but converting ByteArray to CHARS ba2d(a=byte[],start=rexx,length=rex S. - Like BA2X but converting ByteArray to DEC bagrepx(a=byte[],search=rexx,start= S. - grep SEARCH (an HEX qty) in a ByteArray, starting at byte START bagrepx(a=byte[],search=rexx) S. - grep SEARCH (an HEX qty) in a ByteArray, starting at byte 1 bahexline(buf=byte[],bs=rexx) S. - prepare a line bahexdump(buf=byte[],lstart=rexx,le S. - HEX dumps a BYTEARRAY main(args=String[]) S. - just test the main functions simply running "java xarray" *** *** xcmdline *** Brief summary: xcmdline(instr=Rexx,rules=Rexx) .. - command line parser option(in=Rexx) .. - returns value of option IN arguments() .. - returns the other arguments version() S. - just display this library's info main(args=String[]) S. - try out the parser ('java xclasses/xcmdline ARGS OPTIONS') *** *** xconfig *** Brief summary: xconfig(fid=Rexx) .. - define a configuration file refresh() .. - (re-)reads the configuration file value(variable=Rexx) .. - returns value of option IN keys() .. - returns the valid keys in the current config file dump() .. - dumps the current config file version() S. - just display this library's info main(args=String[]) S. - try out the reader ('java xclasses/xcmdline ARGS OPTIONS') *** *** xdir *** Brief summary: xdir(dir=Rexx) .. - initializes xdir pointing to directory DIR xdir() .. - initilizes xdir pointing to directory "." version() S. - display the running version of xdir str_ls(dir=Rexx) S. - returns a string with the file list as contained in DIR str_ls() S. - returns a string with the files in "." ls(opt=rexx) .. - gets the files contained in the DIR ls() .. - gets the files contained (no options) options_set(opt=rexx) S. - set the options dir(opt=rexx) .. - Issues a directory command (like "ls -l") dir() .. - Issues a directory command with no options set str_tree(tpath=rexx) S. - gets the current tree structure tree(opt=rexx) .. - gets the directories unter DIR (-> directories) tree() .. - ditto, with no special options str_find(tpath=rexx,search=rexx) S. - finds SEARCH string in the tree beyong TPATH find(search=rexx) .. - find the string SEARCH in the current directory tree pwd() .. - get the current working directory main(args=String[]) S. - just test the main functions simply running java xclasses/xdir *** *** xexec *** Brief summary: xexec(cmd=String,dest=Rexx,oner=Rex .. - execute a system command xexec(cmd=Rexx,dest=Rexx) .. - ditto, on error WARNING xexec(cmd=Rexx) .. - ditto, output SCREEN main(args=String[]) S. - just test the main functions simply running *** *** xfile *** Brief summary: xfile(fid=Rexx) .. - construtor for xfile (fid=filename) version() S. - display the version options(optl=Rexx) .. - set the options (REPLACE,RECFM,LRECL,etc) read() .. - read a full file into the NR array split(csize=rexx) .. - split a file in several chunks of N bytes split() .. - ditto, with N=1450000 extract(sou=rexx,des=rexx,st_tag=re S. - extract a portion of a file and write it into another readbuf() .. - read an entire file into the buffer writebuf() .. - write the entire buffer onto a file addline(in=Rexx) .. - add a line to the OUTPUT array write() .. - ARRAY -> disk file operation append() .. - append the line buffer to the file lineappend(fname=Rexx,oline=Rexx) S. - append a line to a file recio(oper=Rexx,recno=Rexx,out=Rexx .. - RANDOM access file record operation recread(recno=Rexx) .. - RANDOM access file record read recwrite(recno=Rexx,rec=Rexx) .. - RANDOM access file record write state(fid=Rexx) S. - returns 1 if file exists (0 otherwise) fexist(fid=Rexx) S. - returns 1 if file exists (0 otherwise) main(args=String[]) S. - just test the main functions of xfile *** *** xftp *** Brief summary: xftp(h=Rexx,p=Rexx) .. - opens an FTP connection to host H, port P xftp(h=Rexx) .. - as above, port = 21 version() S. - just display this library's info rcclear() .. - rcset(n=rexx) .. - the RC and the GLOBAL rc are set xopen(h=Rexx,p=Rexx) .. - open the FTP connection (this is done automatically by constructor) xlogin(up=Rexx) .. - remote login xls(t=rexx) .. - list the remote directory (on screen) xmore(fid=Rexx) .. - type the file on terminal xget(fids=Rexx) .. - fetch the remote file xput(fids=Rexx) .. - put the remote file xcd(d=rexx) .. - remote change of directory xreplace(f=rexx) .. - set replace ON|OFF xmode(modet=rexx) .. - set the mode (ASCII BINARY) xquery() .. - display the current settings exec(carg=rexx) .. - main dispatcher: FTP commands are translated in xftp methods cmd(carg=rexx) .. - main dispatcher: FTP commands are translated in xftp methods main(args=String[]) S. - just test the main functions simply running *** *** xhistory *** Brief summary: xhistory(n=Rexx) .. - builds an history object with history depth=N xhistory() .. - ditto, history depth=100 counter() .. - returns the value of the counter dump(n=Rexx) .. - dumps the history records retrieve(n=Rexx) .. - retrieve an history item save(entry=Rexx) .. - save a line in the history buffer version() S. - display the version main(args=String[]) S. - just test the functions simply running "java xhistory" *** *** xinfoline *** Brief summary: xinfoline() .. - constructor display(i1=Rexx,i2=Rexx,rest=Rexx) .. - main(args=String[]) S. - *** *** xinterpret *** Brief summary: version() S. - display the version xinterpter(options=Rexx) .. - constructor tokenize(in=Rexx) S. - build valid tokens from a string translate(intk=Rexx) S. - convert an infix tokenized string to a Polish priority(op=Rexx) S. - computes the priority of an operand evalrpn(intk=Rexx,precision=Rexx) S. - evaluates an RPN expression interpret(expr=Rexx,precision=Rexx) S. - really BASIC interpret interpret(expr=Rexx) S. - main(args=String[]) S. - maily used to do testing *** *** xmath *** Brief summary: xmath .. - contructor; pretty useless sive this is a static method collection n2cu(n=Rexx) S. - converts N to Computer Units (K, M,...) [ex. 2048=2K] s2h(s=Rexx) S. - convert S(seconds) to hours (or days) [ex. 3655 -> 01:00:55] hexop(in=Rexx) S. - execute simple HEX operations (=,-,*,/) dotify(n=Rexx) S. - put dots into a numeric string [ex: 300000 -> 300,000] binop(in=Rexx) S. - execute simple BIN operations (+,-,*,/) gcd(a=int,b=int) S. - find the greatest common divisor foa A and B gauss(n=int,a=Rexx[,],y=Rexx[],c=re S. - Solves a linear equation with the GAUSS method random(max=Rexx) S. - returns a random number ( < MAX) random() S. - returns a random number ( < 1000) main(args=String[]) S. - just test the main functions *** *** xpager *** Brief summary: xpager() .. - build a pager object version() S. - display the version help() SP - gives a short help of available commands screensize(dlines=Rexx,dcolumns=Rex S. - sets the screen size (col lines) forcerefresh() .. - forces a refresh at next display setprompt(str=Rexx) .. - set the prompt to the value options(str=Rexx) .. - set the options for this screen display() .. - run the pager main(args=String[]) S. - test the xpager funtionality *** *** xserv *** Brief summary: xserv(socketport=Rexx,userc=Rexx) .. - defines a server on SOCKETPORT, with user commands USERC xserv(socketport=Rexx) .. - defines a server (USERC='': no user commands) version() S. - just display xserv's current version get_remote_user() .. - returns the remote userid (userid@system) addline(out=rexx) .. - add a line to the output queue dispatch(carg=rexx) .. - main internal command dispatcher cmd_version() .P - returns to client the program version cmd_status() .P - returns to client server's status answer() .. - answer the client what was in the output queue answer(linereply=Rexx) .. - answer just LINEREPLY to the client run() .. - main loop (waits for commands on port) main(args=String[]) S. - small test server on port 6002 (no user commands) *** *** xsock *** Brief summary: xsock(host=Rexx,port=Rexx) .. - define a socket connection,opening HOST,PORT xsock() .. - define a socket connection (no open is done) version() S. - just display XSOCK version open(host=Rexx,prot=Rexx) .. - open a socket connection to HOST, using protocol PROT getservbyname(serv=Rexx) S. - get the service port for SERV service [i.e. FTP=21] setprotdef(prot=Rexx) .. - set protocol specific parameters send(iline=Rexx) .. - sends ILINE to the server port readline() .. - read a line from the server receive(where=rexx,maxl=rexx) .. - receives on WHERE MAXL lines of output from server receive(where=Rexx) .. - receives on WHERE, max 10000 lines of output from server receive() .. - as above, on SCREEN close() .. - closes the xsock connection hostname() S. - get the local hostname main(args=String[]) S. - just test the functions simply running "java xsock" *** *** xstring *** Brief summary: xstring(options=Rexx) .. - constructor. Pretty useless since this is a collection of STATIC methods version() S. - display the current xstring version ssay(str=Rexx) S. - display a line without CR say_column(str=Rexx) S. - display a string in colums (a la UNIX "ls") censure(s1=Rexx,s2=Rexx,ch=Rexx) S. - get totally rid of S2 sequence inside string S1, replace with CH censure(s1=Rexx,s2=Rexx) S. - get totally rid of S2 sequence inside string S1 listexpand(il=Rexx) S. - expand a list (1.2 3-6) hash(str=Rexx) S. - hash a string STR a2m(str=Rexx) S. - Convert a string from ASCII to MIME m2a(str=Rexx) S. - Convert a string from MIME to ASCII sort(stri=Rexx,mode=Rexx) S. - Sort a string (MODE A = ascending, R = reverse) sort(stri=Rexx) S. - Sort a string ascending c2x(in=Rexx) S. - convert char to HEX x2c(in=Rexx) S. - convert HEX to CHAR s2a(str=Rexx,a=Rexx) S. - converts a string to an array a2s(a=Rexx) S. - converts a Rexx array to a string unique_char(string=Rexx,uch=Rexx) S. - remove UCH duplicates from STRING [a****rn -> a*rn] match(string=Rexx,pattern=Rexx) S. - string matching (using '*' and '?') [pattern = 'p*.txt' , '???.hlp'] main(args=String[]) S. - used to perform testing *** *** xsys *** Brief summary: version() S. - display the version userid() S. - Show the current userid nodeid() S. - Show the nodename time(type=Rexx) S. - Show time in the Classical REXX format time() S. - Show time (format = 'N') date(type=Rexx) S. - Show date in the standard Classical REXX format date() S. - Show date (type = 'TODAY') xdate(p1=Rexx,p2=Rexx,p3=Rexx) S. - interface to xmisc xdate (date conversion) xdate(p1=Rexx,p2=Rexx) S. - interface to xmisc xdate (date) xdate(p1=Rexx) S. - interface to xmisc xdate (date) timestamp() S. - prints a classical timestamp format die(erc=Rexx,msg=Rexx) S. - exit program warn(erc=Rexx,msg=Rexx) S. - send a WARNING message to stderr dump(e=Exception) S. - prints the StackTrace in the "correct" order really(question=rexx) S. - asks the question in argument, waiting for answer. sleep(n=rexx) S. - sleeps N seconds main(args=String[]) S. - just test the main functions (try java xclasses/xsys) *** *** xtimer *** Brief summary: xtimer() .. - constructor display(type .. - Show the CURRENT time in the standard Classical REXX reset() .. - reset the timer; returns '0.000' seconds sleep(n=int) .. - sleeps N seconds elapsed() .. - returns the elapsed time in SSSS.MMM main(args=String[]) S. - none *** *** xurl *** Brief summary: xurl(addr=Rexx) .. - create an XURL object (address is in the form "http://wwwcn.cern.ch") options(optl=Rexx) .. - set the options (trace/notrace,replace/noreplace,etc. etc.) readlines() .. - read an entire URL into the I/O array (obj.line[]) post(string=Rexx) .. - sends data via a POST and then reads the result into an array (obj.line[]) fetch(remote=rexx,locfid=rexx) S. - fetches an URL from REMOTE location into LOCFID file fetch(remote=rexx) S. - fetches an URL from REMOTE location, it will go to a FID with same name fetch() .. - fetches the XURL, it will go to a FID with same name fetchall(mask=rexx) .. - fetch all the URLs pointed by URL, provided that their name matches mask exists(url_addr=rexx) S. - checks if the url url_addr exists (returns 1=YES,0=NO) exists() .. - like above, for an xurl object sockfetch(remote=rexx,locfid=rexx) S. - just like fetch() but using pure sockets (debug tool) sockfetch(remote=rexx) S. - socket_cmd(htmlcmd=rexx) .. - send a command via sockets for VERY special cases getreferences() .. - get the URLs referenced by a page status_line(i1=Rexx,i2=Rexx,rest=Re SP - display the "nice" status line version() S. - display the current XURL version main(args=String[]) S. - just test the main functions simply running "java xclasses/xurl"