abstract class CharacterUtils extends AnyRef

CharacterUtils provides a unified interface to Character-related operations.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CharacterUtils
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new CharacterUtils()

Abstract Value Members

  1. abstract def codePointAt(chars: Array[Char], offset: Int, limit: Int): Int

    Returns the code point at the given index of the char array where only elements with index less than the limit are used.

    Returns the code point at the given index of the char array where only elements with index less than the limit are used.

    chars

    a character array

    offset

    the offset to the char values in the chars array to be converted

    limit

    the index afer the last element that should be used to calculate codepoint.

    returns

    the Unicode code point at the given index

    Exceptions thrown

    IndexOutOfBoundsException - if the value offset is negative or not less than the length of the char array.

    NullPointerException - if the array is null.

  2. abstract def codePointAt(seq: CharSequence, offset: Int): Int

    Returns the code point at the given index of the CharSequence.

    Returns the code point at the given index of the CharSequence.

    seq

    a character sequence

    offset

    the offset to the char values in the chars array to be converted

    returns

    the Unicode code point at the given index

    Exceptions thrown

    IndexOutOfBoundsException - if the value offset is negative or not less than the length of the character sequence.

    NullPointerException - if the sequence is null.

  3. abstract def codePointCount(seq: CharSequence): Int

    Return the number of characters in seq.

    Return the number of characters in seq.

  4. abstract def fill(buffer: CharacterBuffer, reader: Reader, numChars: Int): Boolean

    Fills the CharacterBuffer with characters read from the given reader Reader.

    Fills the CharacterBuffer with characters read from the given reader Reader. This method tries to read numChars characters into the CharacterBuffer, each call to fill will start filling the buffer from offset 0 up to numChars. In case code points can span across 2 java characters, this method may only fill numChars - 1 characters in order not to split in the middle of a surrogate pair, even if there are remaining characters in the Reader.

    A return value of false means that this method call exhausted the reader, but there may be some bytes which have been read, which can be verified by checking whether buffer.getLength() > 0.

    buffer

    the buffer to fill.

    reader

    the reader to read characters from.

    numChars

    the number of chars to read

    returns

    false if and only if reader.read returned -1 while trying to fill the buffer

    Exceptions thrown

    IOException if the reader throws an IOException.

  5. abstract def offsetByCodePoints(buf: Array[Char], start: Int, count: Int, index: Int, offset: Int): Int

    Return the index within buf[start:start+count] which is by offset code points from index.

    Return the index within buf[start:start+count] which is by offset code points from index.

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. final def fill(buffer: CharacterBuffer, reader: Reader): Boolean

    Convenience method which calls fill(buffer, reader, buffer.buffer.length).

    Convenience method which calls fill(buffer, reader, buffer.buffer.length).

  9. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  10. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
  11. def hashCode(): Int
    Definition Classes
    AnyRef → Any
  12. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  13. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  14. final def notify(): Unit
    Definition Classes
    AnyRef
  15. final def notifyAll(): Unit
    Definition Classes
    AnyRef
  16. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  17. final def toChars(src: Array[Int], srcOff: Int, srcLen: Int, dest: Array[Char], destOff: Int): Int

    Converts a sequence of unicode code points to a sequence of Java characters.

    Converts a sequence of unicode code points to a sequence of Java characters.

    returns

    the number of chars written to the destination buffer

  18. final def toCodePoints(src: Array[Char], srcOff: Int, srcLen: Int, dest: Array[Int], destOff: Int): Int

    Converts a sequence of Java characters to a sequence of unicode code points.

    Converts a sequence of Java characters to a sequence of unicode code points.

    returns

    the number of code points written to the destination buffer

  19. final def toLowerCase(buffer: Array[Char], offset: Int, limit: Int): Unit

    Converts each unicode codepoint to lowerCase via Character#toLowerCase(int) starting at the given offset.

    Converts each unicode codepoint to lowerCase via Character#toLowerCase(int) starting at the given offset.

    buffer

    the char buffer to lowercase

    offset

    the offset to start at

    limit

    the max char in the buffer to lower case

  20. def toString(): String
    Definition Classes
    AnyRef → Any
  21. final def toUpperCase(buffer: Array[Char], offset: Int, limit: Int): Unit

    Converts each unicode codepoint to UpperCase via Character#toUpperCase(int) starting at the given offset.

    Converts each unicode codepoint to UpperCase via Character#toUpperCase(int) starting at the given offset.

    buffer

    the char buffer to UPPERCASE

    offset

    the offset to start at

    limit

    the max char in the buffer to lower case

  22. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped