com.ibm.jzos.fields

Class CobolDatatypeFactory

    • Constructor Detail

      • CobolDatatypeFactory

        public CobolDatatypeFactory()
    • Method Detail

      • getBinaryAsLongField

        public BinaryAsLongField getBinaryAsLongField(int precision,
                                             boolean signed)
        Construct and return a BinaryAsLongField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        signed - true if the value is signed
        Returns:
        BinaryAsLongField
      • getBinaryAsIntField

        public BinaryAsIntField getBinaryAsIntField(int precision,
                                           boolean signed)
        Construct and return a BinaryAsIntField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        signed - true if the value is signed
        Returns:
        BinaryAsIntField
      • getBinaryAsBigDecimalField

        public BinaryAsBigDecimalField getBinaryAsBigDecimalField(int precision,
                                                         int scale,
                                                         boolean signed)
        Construct and return a BinaryAsBigDecimalField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        signed - true if the value is signed
        Returns:
        BinaryAsLongField
      • getBinaryAsBigIntegerField

        public BinaryAsBigIntegerField getBinaryAsBigIntegerField(int precision,
                                                         int scale,
                                                         boolean signed)
        Construct and return a BinaryAsBigIntegerField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        scale - a negative integer specifying the power of the number
        signed - true if the value is signed
        Returns:
        BinaryAsBigIntegerField
      • getBinaryField

        public Field getBinaryField(int precision,
                           int scale,
                           boolean signed,
                           boolean comp5)
        Construct and return a BinaryField, advancing the current offset by its byte length. The actual field returned is based on the precision and scale:
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        comp5 - true if the entire bit range is to be allowed
        Returns:
        Field
      • getExternalDecimalField

        public Field getExternalDecimalField(int precision,
                                    int scale,
                                    boolean signed,
                                    boolean signTailing,
                                    boolean signExternal,
                                    boolean blankWhenZero)
        Construct and return a ExternalDecimalAs<*>Field, advancing the current offset by its byte length. The actual field returned is based on the precision and scale:
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        signed - boolean true if the value is signed
        signTailing - true if the sign is stored at the end of the field
        signExternal - true if the sign is stored in a separate byte
        blankWhenZero - true if the field is all spaces when zero
        Returns:
        Field
        See Also:
        ExternalDecimalAsIntField, ExternalDecimalAsLongField, ExternalDecimalAsBigIntegerField, ExternalDecimalAsBigDecimalField
      • getExternalFloatField

        public ExternalFloatField getExternalFloatField(int precision,
                                               int scale,
                                               boolean showMantissaPlusSign,
                                               boolean showExponentPlusSign,
                                               boolean impliedDecimalPoint)
        Construct and return a FloatDisplayField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        showMantissaPlusSign - true if a plus sign is to be displayed for positive mantissa values
        showExponentPlusSign - true if a plus sign is to be displayed for positive exponent values
        impliedDecimalPoint - true if the decimal point is implied.
        Returns:
        ExternalFloatField
      • getPackedDecimalField

        public Field getPackedDecimalField(int precision,
                                  int scale,
                                  boolean signed)
        Construct and return a PackedDecimalAs<*>Field, advancing the current offset by its byte length. The actual field returned is based on the precision and scale.
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        signed - true if the value is signed
        Returns:
        Field
        Throws:
        java.lang.IllegalArgumentException - if length implies a precision > 31 digits.
        See Also:
        PackedDecimalAsIntField, PackedDecimalAsLongField, PackedDecimalAsBigIntegerField, PackedDecimalAsBigDecimalField
      • getPackedDecimalAsBigDecimalField

        public PackedDecimalAsBigDecimalField getPackedDecimalAsBigDecimalField(int precision,
                                                                       int scale,
                                                                       boolean signed)
        Construct and return a PackedDecimalAsBigDecimalField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        signed - boolean true if the value is signed
        Returns:
        PackedDecimalAsBigDecimalField
        See Also:
        PackedDecimalAsBigDecimalField.PackedDecimalAsBigDecimalField(int, int, int, boolean)
      • getPackedDecimalAsBigIntegerField

        public PackedDecimalAsBigIntegerField getPackedDecimalAsBigIntegerField(int precision,
                                                                       int scale,
                                                                       boolean signed)
        Construct and return a PackedDecimalAsBigIntegerField, advancing the current offset by its byte length.
        Parameters:
        precision - the number of decimal digits of precision
        scale - the number of implied decimal digits in the fractional part of the field
        signed - boolean true if the value is signed
        Returns:
        PackedDecimalAsBigIntegerField
        See Also:
        PackedDecimalAsBigIntegerField.PackedDecimalAsBigIntegerField(int, int, int, boolean)
      • getIbmFloatField

        public IbmFloatField getIbmFloatField()
        Construct and return an IbmFloatField (hex floating point COMP-1), advancing the current offset by its byte length.
        Returns:
        IbmFloatField
      • getIbmDoubleField

        public IbmDoubleField getIbmDoubleField()
        Construct and return an IbmDoubleField (hex floating point COMP-2), advancing the current offset by its byte length.
        Returns:
        IbmDoubleField
© Copyright IBM Corporation 2005, 2014.