Class DefaultTextAttribute.Builder

  • Enclosing class:
    DefaultTextAttribute

    public static class DefaultTextAttribute.Builder
    extends Object
    Provides a builder for a default text attribute.
    • Constructor Detail

      • Builder

        public Builder()
        Creates a new builder.
      • Builder

        public Builder​(String attribute)
        Creates a new builder with the specified attribute name.
        Parameters:
        attribute - the attribute name
    • Method Detail

      • add

        public DefaultTextAttribute.Builder add​(int val)
        Adds a new attribute with the specified width.
        Parameters:
        val - the width of the attribute
        Returns:
        returns this builder
      • build

        public DefaultTextAttribute build​(int length)
        Creates a new default text attribute based on the current state of the builder.
        Parameters:
        length - the total length of the contained attributes
        Returns:
        returns a new default text attribute