Class XSSFBRichTextString

java.lang.Object
org.apache.poi.xssf.binary.XSSFBRichTextString
All Implemented Interfaces:
RichTextString

@Internal public class XSSFBRichTextString extends Object implements RichTextString
Wrapper class around String so that we can use it in Comment. Nothing has been implemented yet except for getString().
Since:
3.16-beta3
  • Method Details

    • applyFont

      @NotImplemented public void applyFont(int startIndex, int endIndex, short fontIndex)
      Description copied from interface: RichTextString
      Applies a font to the specified characters of a string.
      Specified by:
      applyFont in interface RichTextString
      Parameters:
      startIndex - The start index to apply the font to (inclusive)
      endIndex - The end index to apply the font to (exclusive)
      fontIndex - The font to use.
    • applyFont

      @NotImplemented public void applyFont(int startIndex, int endIndex, Font font)
      Description copied from interface: RichTextString
      Applies a font to the specified characters of a string.
      Specified by:
      applyFont in interface RichTextString
      Parameters:
      startIndex - The start index to apply the font to (inclusive)
      endIndex - The end index to apply to font to (exclusive)
      font - The index of the font to use.
    • applyFont

      @NotImplemented public void applyFont(Font font)
      Description copied from interface: RichTextString
      Sets the font of the entire string.
      Specified by:
      applyFont in interface RichTextString
      Parameters:
      font - The font to use.
    • clearFormatting

      @NotImplemented public void clearFormatting()
      Description copied from interface: RichTextString
      Removes any formatting that may have been applied to the string.
      Specified by:
      clearFormatting in interface RichTextString
    • getString

      public String getString()
      Description copied from interface: RichTextString
      Returns the plain string representation.
      Specified by:
      getString in interface RichTextString
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • length

      public int length()
      Specified by:
      length in interface RichTextString
      Returns:
      the number of characters in the font.
    • numFormattingRuns

      @NotImplemented public int numFormattingRuns()
      Specified by:
      numFormattingRuns in interface RichTextString
      Returns:
      The number of formatting runs used.
    • getIndexOfFormattingRun

      @NotImplemented public int getIndexOfFormattingRun(int index)
      Description copied from interface: RichTextString
      The index within the string to which the specified formatting run applies.
      Specified by:
      getIndexOfFormattingRun in interface RichTextString
      Parameters:
      index - the index of the formatting run
      Returns:
      the index within the string.
    • applyFont

      @NotImplemented public void applyFont(short fontIndex)
      Description copied from interface: RichTextString
      Applies the specified font to the entire string.
      Specified by:
      applyFont in interface RichTextString
      Parameters:
      fontIndex - the font to apply.