Package jetbrains.buildServer.web.util
Class HtmlUtil
- java.lang.Object
-
- jetbrains.buildServer.web.util.HtmlUtil
-
public class HtmlUtil extends Object
-
-
Constructor Summary
Constructors Constructor Description HtmlUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
truncate(String html, int maxLength)
Trim visible message with html to maximum length.
-
-
-
Method Detail
-
truncate
@Contract("null,_->null;!null,_->!null") @Nullable public static String truncate(@Nullable String html, int maxLength)
Trim visible message with html to maximum length. Special characters count as one. e.g. < > ... Html tags are ignored when calculating length.- Parameters:
html
- text with html tagsmaxLength
- maximum count of visible characters- Returns:
- truncated valid html message
-
-