
      *>-----------------------------------------
      *> base class library version information
      *>
      *> Copyright (C) 1991-1999 Micro Focus International Ltd.
      *>
      *>-----------------------------------------
       program-id. "classm".
       working-storage section.
      $if version not defined
       78  version           value "development version".
      $end
      $if revision not defined
       78  revision     value 000.
      $end
       01 resultblock.
          03 resflags               pic x comp-x value 0.
          03 buildrevision          pic x comp-x value revision.
          03 minorversion           pic x comp-x value 1.
          03 majorversion           pic x comp-x value 2.
       01 result redefines resultblock pic 9(9) comp-5.
       01 versionInfoType           pic x(4) comp-5 value 1.
       01 oops-version-string       pic x(40).
       01 filler pic x(80) value 
                                x"0D0A" & "@(#)Vrn " &
                                "Class Library " & version & 
                                " nrV>" & x"0D0A".

       78 expected                  value "0002.0002".

       linkage section.

       01 theParameters. 
          03 filler occurs 15.
                05 parm              usage pointer.
          03 parmmessagePtr          pointer.
          03 parmreceiver            usage object reference.

       01 lnkMessage                 pic x.

       procedure division.
           call "oopsgetversion" using by value versionInfoType,
                            by reference oops-version-string           
           if oops-version-string(26:9) < expected
               move 0 to result         *>> Version incompatability
           end-if           
           exit program returning result
           .


       entry "MessageHeader" using theParameters.
           set address of lnkMessage to parmMessagePtr
           invoke parmReceiver lnkMessage using
                                                 by value parm(1)
                                                 by value parm(2)
                                                 by value parm(3)
                                                 by value parm(4)
                                                 by value parm(5)
                                                 by value parm(6)
                                                 by value parm(7)
                                                 by value parm(8)
                                                 by value parm(9)
                                                 by value parm(10)
                                                 by value parm(11)
                                                 by value parm(12)
                                                 by value parm(13)
                                                 by value parm(14)
                                                 by value parm(15)
           call "CBL_THREAD_EXIT" using by value 0
           .
