TableListing.Builder (Apache Hadoop Common 3.5.0 API)
Description: declaration: package: org.apache.hadoop.tools, class: TableListing, class: Builder

Package org.apache.hadoop.tools

# Class TableListing.Builder

java.lang.Object
org.apache.hadoop.tools.TableListing.Builder

Enclosing class:
  TableListing

public static class TableListing.Builder extends Object

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Builder()`
  Create a new Builder.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `TableListing.Builder`
  `addField(String title)`
  `TableListing.Builder`
  `addField(String title, boolean wrap)`
  `TableListing.Builder`
  `addField(String title, TableListing.Justification justification)`
  `TableListing.Builder`
  `addField(String title, TableListing.Justification justification, boolean wrap)`
  Add a new field to the Table under construction.
  `TableListing`
  `build()`
  Create a new TableListing.
  `TableListing.Builder`
  `hideHeaders()`
  Whether to hide column headers in table output.
  `TableListing.Builder`
  `showHeaders()`
  Whether to show column headers in table output.
  `TableListing.Builder`
  `wrapWidth(int width)`
  Set the maximum width of a row in the TableListing.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### Builder

    public Builder()
    Create a new Builder.

- ## Method Details

  - ### addField

    public TableListing.Builder addField(String title)

  - ### addField

    public TableListing.Builder addField(String title, TableListing.Justification justification)

  - ### addField

    public TableListing.Builder addField(String title, boolean wrap)

  - ### addField

    public TableListing.Builder addField(String title, TableListing.Justification justification, boolean wrap)
    Add a new field to the Table under construction.
    Parameters:
      `title` - Field title.
      `justification` - Right or left justification. Defaults to left.
      `wrap` - Width at which to auto-wrap the content of the cell. Defaults to Integer.MAX_VALUE.
    Returns:
      This Builder object

  - ### hideHeaders

    public TableListing.Builder hideHeaders()
    Whether to hide column headers in table output.
    Returns:
      Builder.

  - ### showHeaders

    public TableListing.Builder showHeaders()
    Whether to show column headers in table output. This is the default.
    Returns:
      Builder.

  - ### wrapWidth

    public TableListing.Builder wrapWidth(int width)
    Set the maximum width of a row in the TableListing. Must have one or more wrappable fields for this to take effect.
    Parameters:
      `width` - width.
    Returns:
      Builder.

  - ### build

    public TableListing build()
    Create a new TableListing.
    Returns:
      TableListing.