Class RecordBuilder

    • Constructor Detail

      • RecordBuilder

        public RecordBuilder​(java.lang.String name)
        Constructs a new RecordBuilder.
        Parameters:
        name - the record name
      • RecordBuilder

        public RecordBuilder​(java.lang.String name,
                             java.lang.Class<?> type)
        Constructs a new RecordBuilder.
        Parameters:
        name - the record name
        type - the record type
    • Method Detail

      • order

        public RecordBuilder order​(int order)
        Sets the order of this record relative to other children of the same parent.
        Parameters:
        order - the order
        Returns:
        this
      • minLength

        public RecordBuilder minLength​(int min)
        Sets the minimum length of the record (i.e the number of fields in a delimited record, or the number of characters in a fixed length record).
        Parameters:
        min - the minimum length
        Returns:
        this
      • maxLength

        public RecordBuilder maxLength​(int max)
        Sets the minimum length of the record (i.e the number of fields in a delimited record, or the number of characters in a fixed length record).
        Parameters:
        max - the maximum length, or -1 if unbounded
        Returns:
        this
      • length

        public RecordBuilder length​(int n)
        Sets the length of the record (i.e the number of fields in a delimited record, or the number of characters in a fixed length record).
        Parameters:
        n - the length
        Returns:
        this
      • length

        public RecordBuilder length​(int min,
                                    int max)
        Sets the minimum and maximum length of the record (i.e the number of fields in a delimited record, or the number of characters in a fixed length record).
        Parameters:
        min - the minimum length
        max - the maximum length, or -1 if unbounded
        Returns:
        this
      • ridLength

        public RecordBuilder ridLength​(int n)
        Sets the length of the record for identification.
        Parameters:
        n - the length
        Returns:
        this
      • ridLength

        public RecordBuilder ridLength​(int min,
                                       int max)
        Sets the minimum and maximum length of the record for identification.
        Parameters:
        min - the minimum length
        max - the maximum length, or -1 if unbounded
        Returns:
        this
      • build

        public RecordConfig build()
        Builds the record configuration.
        Returns:
        the record configuration