      *>----------------------------------------------------------------
      *> Copyright (C) 1995-1996 Micro Focus International Ltd.
      *>----------------------------------------------------------------
      $set hidemessage(731)
       class-id. characterarray is external.
        object section.
        class-control.
           characterarray is class "chararry"
           .
       class-object.
       method-id. "withLengthValue".
       linkage section.
       01 lnksize           pic s9(9) comp-5.
       01 lnkobject         usage object reference.
       01 lnkvalue.
           03 aByte pic x.
       procedure division using lnksize lnkvalue
                            returning lnkobject
      *> vocabulary
       INVOKED as
       == withLengthValue
         [using] ([<self>] ,
                   <lnksize> ,
                   <lnkvalue> )
         returning <lnkobject>
       == or
       function == FnwithLengthValue
         [using] ([<self>] ,
                   <lnksize> ,
                   <lnkvalue> )
       ==.
       end method "withLengthValue".
       method-id. "withValue".
       linkage section.
       01 lnkstring pic x.
       01 lnkObject usage object reference.
       procedure division using lnkstring returning lnkObject
      *> vocabulary
       INVOKED as
       ==
           CREATE characterarray <lnkObject>
               [from [class] <self>] [WITH] <lnkString>
       == or
       ==
           *> warning: the vocabulary below is for backwards compatibilty
           *> only. Please use the vocabulary above instead.
           CREATE <self> <lnkObject>
                [WITH] <lnkString>
       == or
       == withValue
         [using] ([<self>] ,
                   <lnkstring> )
         returning <lnkObject>
       == or
       function == FnwithValue
         [using] ([<self>] ,
                   <lnkstring> )
       ==.
       end method "withValue".
       end class-object.
       object.
       method-id. "compareTo".
       linkage section.
       01 comparevalue.
           03 abyte               pic x.
       01 anarray              usage object reference.
       01 lnkResult            pic s9(9) comp-5.
           88  lnkGreaterThan value  1.
           88  lnkLessThan    value -1.
           88  lnkEqual       value  0.
       procedure division using anarray returning lnkResult
      *> vocabulary
       INVOKED as
       == compareTo
         [using] ([<self>] ,
                   <anarray> )
         returning <lnkResult>
       == or
       == compare
          <self> to <anarray> returning <lnkResult>
       == or
       function == strcmp
         (<self> , <anarray> )
       == or
       function == FncompareTo
         [using] ([<self>] ,
                   <anarray> )
       ==.
       end method "compareTo".
       method-id. "setValue".
       linkage section.
       01 lnkstring.
           03 abyte           pic x.
       procedure division using lnkstring
      *> vocabulary
       INVOKED as
       == setValue
         [using] ([<self>] ,
                   <lnkstring> )
       ==.
       end method "setValue".
       method-id. "sizeInBytes".
       linkage section.
       01 acollectionsize      pic s9(9) comp-5.
       procedure division returning acollectionsize
      *> vocabulary
       INVOKED as
       == sizeInBytes
         [[using] (<self>)]
         returning <acollectionsize>
       == or
       function == sizeof (<self>)
       == or
       function == strlen (<self>)
       == or
       function == FnsizeInBytes
         [[using] (<self>)]
       ==.
       end method "sizeInBytes".
       method-id. "concat".
       linkage section.
       01 lnkworkingstring1.
           03 abyte           pic x.
       01 lnknewstring      usage object reference.
       01 lnkobject         usage object reference.
       01 lnkworkingstring2.
           03 abyte           pic x.
       procedure division using lnkobject returning lnknewstring
      *> vocabulary
       INVOKED as
       == concat
         [using] ([<self>] ,
                   <lnkobject> )
         returning <lnknewstring>
       == or
       function == Fnconcat
         [using] ([<self>] ,
                   <lnkobject> )
       ==.
       end method "concat".
       method-id. "getValue".
       linkage section.
       01 lnkstring.
           03 abyte           pic x.
       procedure division returning lnkstring
      *> vocabulary
       INVOKED as
       == getValue
         [[using] (<self>)]
         returning <lnkstring>
       == or
       function == FngetValue
         [[using] (<self>)]
       ==.
       end method "getValue".
       method-id. "asParameter".
       linkage section.
       01 lnkstring.
           03 abyte           pic x.
       procedure division returning lnkstring
      *> vocabulary
       INVOKED as
       == asParameter
         [[using] (<self>)]
         returning <lnkstring>
       == or
       function == FnasParameter
         [[using] (<self>)]
       ==.
       end method "asParameter".
       method-id. "display".
       procedure division
      *> vocabulary
       INVOKED as
       == idisplay
         [[using] (<self>)]
       ==.
       end method "display".
       method-id. "asLowercase".
       linkage section.
       01 lnkworkingstring1.
           03 abyte           pic x.
       01 lnknewstring      usage object reference.
       procedure division returning lnknewstring
      *> vocabulary
       INVOKED as
       == asLowercase
         [[using] (<self>)]
         returning <lnknewstring>
       == or
       function == FnasLowercase
         [[using] (<self>)]
       ==.
       end method "asLowercase".
       method-id. "asUppercase".
       linkage section.
       01 lnkworkingstring1.
           03 abyte           pic x.
       01 lnknewstring      usage object reference.
       procedure division returning lnknewstring
      *> vocabulary
       INVOKED as
       == asUppercase
         [[using] (<self>)]
         returning <lnknewstring>
       == or
       == convert <self> to upper case
         returning <lnknewstring>
       == or
       function == strupper (<self>)
       == or
       function == FnasUppercase
         [[using] (<self>)]
       ==.
       end method "asUppercase".
       method-id. "asLowercase".
       linkage section.
       01 lnkworkingstring1.
           03 abyte           pic x.
       01 lnknewstring      usage object reference.
       procedure division returning lnknewstring
      *> vocabulary
       INVOKED as
       == asLowercase
         [[using] (<self>)]
         returning <lnknewstring>
       == or
       == convert <self> to lower case
         returning <lnknewstring>
       == or
       function == strlower (<self>)
       == or
       function == FnasLowercase
         [[using] (<self>)]
       ==.
       end method "asLowercase".
       method-id. "Copy".
       linkage section.
       01 result               usage object reference.
       procedure division returning result
      *> vocabulary
       INVOKED as
       == iCopy
         [[using] (<self>)]
         returning <result>
       == or
       function == FnCopy
         [[using] (<self>)]
       ==.
       end method "Copy".
       method-id. "equal".
       linkage section.
       01 anotherstring        usage object reference.
       01 arealstring.
           03 achar                   pic x.
       01 lnkresult             pic x comp-5.
           88 isEqual          value 1.
           88 isNotEqual       value 0.
       procedure division using anotherstring returning lnkresult
      *> vocabulary
       INVOKED as
       == isequal
         [using] ([<self>] ,
                   <anotherstring> )
         returning <lnkresult>
       == or
       function == Fnequal
         [using] ([<self>] ,
                   <anotherstring> )
       == or
       FUNCTION ==
           CONDITION <self> EQUALTO <anotherString>
       ==.
       end method "equal".
       end object.
       end class characterarray.
