Class CBLBlankString

All Implemented Interfaces:
AbstractDataObject, IFormatTypes, ICBLContainer, ICBLDataType, IFieldContainer, ISMDataType, ISMObject, ISMString

public class CBLBlankString extends CBLString
For internal use only
This class is created purely for overcoming COBOL arrayIndexOutOfBound problems. COBOL arrays are 1 based, ie they start at 1. However, accessing element '0' will just return empty spaces. In java this translates to accessing array element of -1 ... This class is used to reproduce functionality of element -1.
  • Constructor Details

    • CBLBlankString

      protected CBLBlankString()
      for internal use only
  • Method Details

    • createInstance

      public static CBLBlankString createInstance(AbstractCBLField owner)
    • getObjectValue

      public final Object getObjectValue()
    • retrieveAsStringFormatted

      public String retrieveAsStringFormatted()
      For a group item - it returns the fully expanded String representing the group. Ie if Group contains FIELD-1 PIC (X) OCCURS 4 time. field1[0].set("A"); group.stringValue() returns : "A " ; FOr a field - it returnes the value. Ie for an integer (PIC X(5)) value 10 it would return "10" , Please also see retrieveAsStringFormatted which would return "10 "
      Specified by:
      retrieveAsStringFormatted in interface ISMObject
      Overrides:
      retrieveAsStringFormatted in class AbstractCBLField
      Returns:
      String representation of a group
    • isFiller

      public boolean isFiller()
      Description copied from class: AbstractCBLField
      used internally by the framework to indicate if a field represents COBOL FILLER
      Specified by:
      isFiller in interface ISMObject
      Overrides:
      isFiller in class CBLString
      Returns: