Class AppendableCharSequence

    • Constructor Detail

      • AppendableCharSequence

        public AppendableCharSequence​(int length)
    • Method Detail

      • setLength

        public void setLength​(int length)
      • charAt

        public char charAt​(int index)
        Specified by:
        charAt in interface CharSequence
      • charAtUnsafe

        public char charAtUnsafe​(int index)
        Access a value in this CharSequence. This method is considered unsafe as index values are assumed to be legitimate. Only underlying array bounds checking is done.
        Parameters:
        index - The index to access the underlying array at.
        Returns:
        The value at index.
      • reset

        public void reset()
        Reset the AppendableCharSequence. Be aware this will only reset the current internal position and not shrink the internal char array.
      • substring

        public String substring​(int start,
                                int end)
        Create a new String from the given start to end.
      • subStringUnsafe

        public String subStringUnsafe​(int start,
                                      int end)
        Create a new String from the given start to end. This method is considered unsafe as index values are assumed to be legitimate. Only underlying array bounds checking is done.