Class Range

java.lang.Object
com.itextpdf.layout.font.Range

public class Range extends Object
Class represents ordered list of Range.SubRange. This class is used in FontInfo as internal field and in one of the overloads of the FontProvider.addFont(String, String, Range) method as range of characters to be used in font.

To create a custom Range instance RangeBuilder shall be used.

  • Method Details

    • contains

      public boolean contains (int n)
      Binary search over ordered segments.
      Parameters:
      n - numeric character reference based on the character's Unicode code point
      Returns:
      true if this Range contains the specified code point, otherwise false
    • equals

      public boolean equals (Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object