Package org.jline.utils
Class AttributedString
java.lang.Object
org.jline.utils.AttributedCharSequence
org.jline.utils.AttributedString
- All Implemented Interfaces:
CharSequence
Attributed string.
Instances of this class are immutables.
Substrings are created without any memory copy.
- Author:
- Guillaume Nodet
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jline.utils.AttributedCharSequence
AttributedCharSequence.ForceMode -
Field Summary
FieldsFields inherited from class org.jline.utils.AttributedCharSequence
TRUE_COLORS -
Constructor Summary
ConstructorsConstructorDescriptionAttributedString(CharSequence str, int start, int end) AttributedString(CharSequence str, int start, int end, AttributedStyle s) -
Method Summary
Modifier and TypeMethodDescriptionprotected char[]buffer()booleanstatic AttributedStringstatic AttributedStringstatic AttributedStringstatic AttributedStringstatic AttributedStringinthashCode()static AttributedStringjoin(AttributedString delimiter, Iterable<AttributedString> elements) static AttributedStringjoin(AttributedString delimiter, AttributedString... elements) intlength()protected intoffset()static StringstyleAt(int index) styleMatches(Pattern pattern, AttributedStyle style) subSequence(int start, int end) Methods inherited from class org.jline.utils.AttributedCharSequence
charAt, codePointAt, codePointBefore, codePointCount, columnLength, columnSplitLength, columnSplitLength, columnSubSequence, contains, isHidden, print, println, rgbColor, roundColor, roundRgbColor, runLimit, runStart, substring, toAnsi, toAnsi, toAnsi, toAnsi, toAnsi, toAnsi, toAnsi, toAttributedString, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.CharSequence
chars, codePoints, isEmpty
-
Field Details
-
EMPTY
-
NEWLINE
-
-
Constructor Details
-
AttributedString
-
AttributedString
-
AttributedString
-
AttributedString
-
-
Method Details
-
fromAnsi
-
fromAnsi
-
fromAnsi
-
fromAnsi
-
fromAnsi
-
stripAnsi
-
buffer
protected char[] buffer()- Specified by:
bufferin classAttributedCharSequence
-
offset
protected int offset()- Specified by:
offsetin classAttributedCharSequence
-
length
public int length() -
styleAt
- Specified by:
styleAtin classAttributedCharSequence
-
subSequence
- Specified by:
subSequencein interfaceCharSequence- Specified by:
subSequencein classAttributedCharSequence
-
styleMatches
-
equals
-
hashCode
-
join
-
join
public static AttributedString join(AttributedString delimiter, Iterable<AttributedString> elements)
-