Class TextComponent

    • Constructor Summary

      Constructors 
      Constructor Description
      TextComponent()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      TextComponent append​(java.lang.String str)
      appends the given string to the internal buffer
      int length()
      Returns current size of text, number of characters
      void setLength​(int newLength)
      Sets the new length of the internal buffer
      java.lang.String substring​(int start)
      Returns a string containing the string copied beginning with the given position
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Method Detail

      • length

        public int length()
        Returns current size of text, number of characters
        Returns:
        length
      • setLength

        public void setLength​(int newLength)
        Sets the new length of the internal buffer
        Parameters:
        newLength - length to be set
      • append

        public TextComponent append​(java.lang.String str)
        appends the given string to the internal buffer
        Parameters:
        str - string to be appended
        Returns:
        this instance
      • substring

        public java.lang.String substring​(int start)
        Returns a string containing the string copied beginning with the given position
        Parameters:
        start - first character to be copied
        Returns:
        string
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object