Package org.cactoos.text
Class Abbreviated
- java.lang.Object
-
- org.cactoos.text.TextEnvelope
-
- org.cactoos.text.Abbreviated
-
- All Implemented Interfaces:
Text
public final class Abbreviated extends TextEnvelope
Abbreviates a Text using ellipses.There is no thread-safety guarantee.
- Since:
- 0.29
-
-
Constructor Summary
Constructors Constructor Description Abbreviated(CharSequence text)
Ctor.Abbreviated(CharSequence text, int max)
Ctor.Abbreviated(Text text)
Ctor.Abbreviated(Text text, int max)
Ctor.
-
-
-
Constructor Detail
-
Abbreviated
public Abbreviated(CharSequence text)
Ctor.By default, the max line width is 80 characters.
- Parameters:
text
- The CharSequence
-
Abbreviated
public Abbreviated(Text text)
Ctor.By default, the max line width is 80 characters.
- Parameters:
text
- The Text
-
Abbreviated
public Abbreviated(CharSequence text, int max)
Ctor.- Parameters:
text
- A CharSequencemax
- Max width of the result string
-
Abbreviated
public Abbreviated(Text text, int max)
Ctor.- Parameters:
text
- The Textmax
- Max width of the result string
-
-