home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 35 Internet / 35-Internet.zip / goswish5.zip / rxswish.txt < prev    next >
Text File  |  1999-05-03  |  3KB  |  66 lines

  1. 5 May 1999.  christopher.mcrae@mq.edu.au
  2.  
  3. The RxSWISH dynamic link library for OS/2.
  4.  
  5. This is an early release of the RxSwish dynamic link library (DLL).
  6. One procedure is supported: rxswEMULATE -- which will emulate
  7. execution SWISH.  Later versions will contain a richer set of 
  8. procedures that programers can use for specific purposes (such as
  9. finding matches, adding to an index, etc.).
  10.  
  11.  
  12.  
  13. I)RxSWISH Emulation Mode:
  14.  
  15. This simply emulates execution of SWISH from a command line; with exactly
  16. the same switches.  The only difference is that output is returned (if
  17. desired) to the calling program. Only one procedure is used, rxswEMULATE.
  18.  
  19. rxswEMULATE  : Emulate command line execution of SWISH
  20.  
  21.   Syntax:
  22.       status=rxswEMULATE(swish_command_string,[output_mode, stem or
  23.                                                             filename])
  24.   where:
  25.     swish_command_string : 
  26.          a command string that one would use when executing SWISH from an
  27.          OS/2 command prompt.  For example:
  28.             ' -c index1.con '                 
  29.             ' -i index.swish -w oxygen nitrogen'                     
  30.     output_Mode (optional)
  31.          If specified, output_mode specifies where output should be
  32.          directed to. Allowed options are:
  33.                 0) Discard all output (this is the default)
  34.                 1) Return output to the caller in a stem variable,
  35.                    specified as the next argument. Stem.0 contains the
  36.                    number of lines returned
  37.                 2) Write output to the file specified as the next
  38.                    argument.
  39.  
  40.      status:  Status code. Valid status codes are:
  41.                  0 = Success
  42.                 11 = Error creating Stem variable.
  43.                 21 = Bad filename for Dump file.
  44.                100 = Unknown -S option.
  45.                101 = No configuration file specified.
  46.                102 = Specify Tag fields (HBtheca).
  47.                103 = Specify the index file to decode.
  48.                104 = Couldn't open index file.
  49.                105 = index file has an unknown format.
  50.                106 - Specify directories or files to index.
  51.                107 - Couldn't write the index file.
  52.                108 - Specify index files and an output file.
  53.                109 - The index file(s) is empty.
  54.                200 - All search words too common to be useful.
  55.                202 - No search words specified.
  56.                204 - The supplied metaName doesn't exist in  user
  57.                      configfile.
  58.  
  59.   Example:
  60.        status=rxswEMULATE('-c myconfig.con ','1','Output')
  61.        status=rxswEMULATE('-c myconfig.con ','2','Output.txt')
  62.        status=rxswEMULATE('-f myindex.swi -w foo and bar')
  63.  
  64.  
  65.  
  66.