public interface Summariser
It must be remembered that the Summariser will not automatically ensure the returned String is encoded for safe use. Encoding for display is a function of the client of the Summariser component.
Modifier and Type | Method and Description |
---|---|
String |
summarise(String xhtml)
The default summary process will shorten the String to a maximum of 255 characters and end it with ellipses (well
actually '...') if it required truncation.
|
String |
summarise(String xhtml,
int maxLength,
boolean ellipses)
Like
summarise(String) but provides more control over the summary process. |
String summarise(String xhtml)
xhtml
- the content to be summarised.String summarise(String xhtml, int maxLength, boolean ellipses)
summarise(String)
but provides more control over the summary process.xhtml
- the content to be summarised.maxLength
- the maximum length of String to returnellipses
- if true then truncated text will be ended with '...'.IllegalArgumentException
- if the maxLength is less than 4 and ellipses was true.Copyright © 2003–2018 Atlassian. All rights reserved.