java.lang.Object
com.pholser.junit.quickcheck.generator.java.lang.strings.CodePoints

public class CodePoints extends Object
Maps ordinal values to corresponding Unicode code points in a Charset.
  • Field Details

  • Constructor Details

    • CodePoints

      CodePoints()
  • Method Details

    • at

      public int at(int index)
      Parameters:
      index - index to look up
      Returns:
      this code point set's index'th code point
      Throws:
      IndexOutOfBoundsException - if there is no such code point
    • size

      public int size()
      Returns:
      how many code points are in this code point set
    • contains

      public boolean contains(int codePoint)
      Parameters:
      codePoint - a code point
      Returns:
      whether this code point set contains the given code point
    • forCharset

      public static CodePoints forCharset(Charset c)
      Gives a set of the code points in the given charset.
      Parameters:
      c - a charset
      Returns:
      the set of code points in the charset
    • load

      private static CodePoints load(Charset c)
    • add

      void add(CodePoints.CodePointRange range)
    • encodableCodePoints

      private static CodePoints encodableCodePoints(CharsetEncoder encoder)