org.apache.poi.hssf.record.cf

## Class BorderFormatting

- java.lang.Object
- - org.apache.poi.hssf.record.cf.BorderFormatting

- All Implemented Interfaces:
    Duplicatable

      public final class BorderFormatting
      extends java.lang.Object
      implements Duplicatable

  Border Formatting Block of the Conditional Formatting Rule Record.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static short` | `BORDER_DASH_DOT` dash-dot border
    `static short` | `BORDER_DASH_DOT_DOT` dash-dot-dot border
    `static short` | `BORDER_DASHED` dash border
    `static short` | `BORDER_DOTTED` hair-line border
    `static short` | `BORDER_DOUBLE` double-line border
    `static short` | `BORDER_HAIR` dot border
    `static short` | `BORDER_MEDIUM` Medium border
    `static short` | `BORDER_MEDIUM_DASH_DOT` medium dash-dot border
    `static short` | `BORDER_MEDIUM_DASH_DOT_DOT` medium dash-dot-dot border
    `static short` | `BORDER_MEDIUM_DASHED` Medium dashed border
    `static short` | `BORDER_NONE` No border
    `static short` | `BORDER_SLANTED_DASH_DOT` slanted dash-dot border
    `static short` | `BORDER_THICK` Thick border
    `static short` | `BORDER_THIN` Thin border

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `BorderFormatting()`
    `BorderFormatting(BorderFormatting other)`
    `BorderFormatting(LittleEndianInput in)` Creates new FontFormatting

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `BorderFormatting` | `clone()` Deprecated.
    `BorderFormatting` | `copy()`
    `int` | `getBorderBottom()` get the type of border to use for the bottom border of the cell
    `int` | `getBorderDiagonal()` get the type of border to use for the diagonal border of the cell
    `int` | `getBorderLeft()` get the type of border to use for the left border of the cell
    `int` | `getBorderRight()` get the type of border to use for the right border of the cell
    `int` | `getBorderTop()` get the type of border to use for the top border of the cell
    `int` | `getBottomBorderColor()` get the color to use for the bottom border
    `int` | `getDataLength()`
    `int` | `getDiagonalBorderColor()` get the color to use for the diagonal border
    `int` | `getLeftBorderColor()` get the color to use for the left border
    `int` | `getRightBorderColor()` get the color to use for the right border
    `int` | `getTopBorderColor()` get the color to use for the top border
    `boolean` | `isBackwardDiagonalOn()`
    `boolean` | `isForwardDiagonalOn()`
    `int` | `serialize(int offset, byte[] data)`
    `void` | `serialize(LittleEndianOutput out)`
    `void` | `setBackwardDiagonalOn(boolean on)` Of/off top left to bottom right line
    `void` | `setBorderBottom(int border)` set the type of border to use for the bottom border of the cell
    `void` | `setBorderDiagonal(int border)` set the type of border to use for the diagonal border of the cell
    `void` | `setBorderLeft(int border)` set the type of border to use for the left border of the cell
    `void` | `setBorderRight(int border)` set the type of border to use for the right border of the cell
    `void` | `setBorderTop(int border)` set the type of border to use for the top border of the cell
    `void` | `setBottomBorderColor(int color)` set the color to use for the bottom border
    `void` | `setDiagonalBorderColor(int color)` set the color to use for the diagonal borders
    `void` | `setForwardDiagonalOn(boolean on)` Of/off bottom left to top right line
    `void` | `setLeftBorderColor(int color)` set the color to use for the left border
    `void` | `setRightBorderColor(int color)` set the color to use for the right border
    `void` | `setTopBorderColor(int color)` set the color to use for the top border
    `java.lang.String` | `toString()`

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

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

- - ### Field Detail

    - #### BORDER_NONE

          public static final short BORDER_NONE

      No border
      See Also:
        Constant Field Values

    - #### BORDER_THIN

          public static final short BORDER_THIN

      Thin border
      See Also:
        Constant Field Values

    - #### BORDER_MEDIUM

          public static final short BORDER_MEDIUM

      Medium border
      See Also:
        Constant Field Values

    - #### BORDER_DASHED

          public static final short BORDER_DASHED

      dash border
      See Also:
        Constant Field Values

    - #### BORDER_HAIR

          public static final short BORDER_HAIR

      dot border
      See Also:
        Constant Field Values

    - #### BORDER_THICK

          public static final short BORDER_THICK

      Thick border
      See Also:
        Constant Field Values

    - #### BORDER_DOUBLE

          public static final short BORDER_DOUBLE

      double-line border
      See Also:
        Constant Field Values

    - #### BORDER_DOTTED

          public static final short BORDER_DOTTED

      hair-line border
      See Also:
        Constant Field Values

    - #### BORDER_MEDIUM_DASHED

          public static final short BORDER_MEDIUM_DASHED

      Medium dashed border
      See Also:
        Constant Field Values

    - #### BORDER_DASH_DOT

          public static final short BORDER_DASH_DOT

      dash-dot border
      See Also:
        Constant Field Values

    - #### BORDER_MEDIUM_DASH_DOT

          public static final short BORDER_MEDIUM_DASH_DOT

      medium dash-dot border
      See Also:
        Constant Field Values

    - #### BORDER_DASH_DOT_DOT

          public static final short BORDER_DASH_DOT_DOT

      dash-dot-dot border
      See Also:
        Constant Field Values

    - #### BORDER_MEDIUM_DASH_DOT_DOT

          public static final short BORDER_MEDIUM_DASH_DOT_DOT

      medium dash-dot-dot border
      See Also:
        Constant Field Values

    - #### BORDER_SLANTED_DASH_DOT

          public static final short BORDER_SLANTED_DASH_DOT

      slanted dash-dot border
      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### BorderFormatting

          public BorderFormatting()

    - #### BorderFormatting

          public BorderFormatting(BorderFormatting other)

    - #### BorderFormatting

          public BorderFormatting(LittleEndianInput in)

      Creates new FontFormatting

  - ### Method Detail

    - #### getDataLength

          public int getDataLength()

    - #### setBorderLeft

          public void setBorderLeft(int border)

      set the type of border to use for the left border of the cell
      Parameters:
        `border` - type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### getBorderLeft

          public int getBorderLeft()

      get the type of border to use for the left border of the cell
      Returns:
        border type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### setBorderRight

          public void setBorderRight(int border)

      set the type of border to use for the right border of the cell
      Parameters:
        `border` - type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### getBorderRight

          public int getBorderRight()

      get the type of border to use for the right border of the cell
      Returns:
        border type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### setBorderTop

          public void setBorderTop(int border)

      set the type of border to use for the top border of the cell
      Parameters:
        `border` - type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### getBorderTop

          public int getBorderTop()

      get the type of border to use for the top border of the cell
      Returns:
        border type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### setBorderBottom

          public void setBorderBottom(int border)

      set the type of border to use for the bottom border of the cell
      Parameters:
        `border` - type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### getBorderBottom

          public int getBorderBottom()

      get the type of border to use for the bottom border of the cell
      Returns:
        border type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### setBorderDiagonal

          public void setBorderDiagonal(int border)

      set the type of border to use for the diagonal border of the cell
      Parameters:
        `border` - type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### getBorderDiagonal

          public int getBorderDiagonal()

      get the type of border to use for the diagonal border of the cell
      Returns:
        border type
      See Also:
        `BORDER_NONE`, `BORDER_THIN`, `BORDER_MEDIUM`, `BORDER_DASHED`, `BORDER_DOTTED`, `BORDER_THICK`, `BORDER_DOUBLE`, `BORDER_HAIR`, `BORDER_MEDIUM_DASHED`, `BORDER_DASH_DOT`, `BORDER_MEDIUM_DASH_DOT`, `BORDER_DASH_DOT_DOT`, `BORDER_MEDIUM_DASH_DOT_DOT`, `BORDER_SLANTED_DASH_DOT`

    - #### setLeftBorderColor

          public void setLeftBorderColor(int color)

      set the color to use for the left border
      Parameters:
        `color` - The index of the color definition

    - #### getLeftBorderColor

          public int getLeftBorderColor()

      get the color to use for the left border
      Returns:
        The index of the color definition
      See Also:
        `HSSFPalette.getColor(short)`

    - #### setRightBorderColor

          public void setRightBorderColor(int color)

      set the color to use for the right border
      Parameters:
        `color` - The index of the color definition

    - #### getRightBorderColor

          public int getRightBorderColor()

      get the color to use for the right border
      Returns:
        The index of the color definition
      See Also:
        `HSSFPalette.getColor(short)`

    - #### setTopBorderColor

          public void setTopBorderColor(int color)

      set the color to use for the top border
      Parameters:
        `color` - The index of the color definition

    - #### getTopBorderColor

          public int getTopBorderColor()

      get the color to use for the top border
      Returns:
        The index of the color definition
      See Also:
        `HSSFPalette.getColor(short)`

    - #### setBottomBorderColor

          public void setBottomBorderColor(int color)

      set the color to use for the bottom border
      Parameters:
        `color` - The index of the color definition

    - #### getBottomBorderColor

          public int getBottomBorderColor()

      get the color to use for the bottom border
      Returns:
        The index of the color definition
      See Also:
        `HSSFPalette.getColor(short)`

    - #### setDiagonalBorderColor

          public void setDiagonalBorderColor(int color)

      set the color to use for the diagonal borders
      Parameters:
        `color` - The index of the color definition

    - #### getDiagonalBorderColor

          public int getDiagonalBorderColor()

      get the color to use for the diagonal border
      Returns:
        The index of the color definition
      See Also:
        `HSSFPalette.getColor(short)`

    - #### setForwardDiagonalOn

          public void setForwardDiagonalOn(boolean on)

      Of/off bottom left to top right line
      Parameters:
        `on` - - if `true` - on, otherwise off

    - #### setBackwardDiagonalOn

          public void setBackwardDiagonalOn(boolean on)

      Of/off top left to bottom right line
      Parameters:
        `on` - - if `true` - on, otherwise off

    - #### isForwardDiagonalOn

          public boolean isForwardDiagonalOn()

      Returns:
        `true` if forward diagonal is on

    - #### isBackwardDiagonalOn

          public boolean isBackwardDiagonalOn()

      Returns:
        `true` if backward diagonal is on

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`

    - #### clone

          @Deprecated
           @Removal(version="5.0.0")
          public BorderFormatting clone()

      Deprecated.
      Overrides:
        `clone` in class `java.lang.Object`

    - #### copy

          public BorderFormatting copy()

      Specified by:
        `copy` in interface `Duplicatable`
      Returns:
        a deep copy of the implementing class / instance

    - #### serialize

          public int serialize(int offset,
                               byte[] data)

    - #### serialize

          public void serialize(LittleEndianOutput out)

Copyright 2020 The Apache Software Foundation or its licensors, as applicable.