Interface MessageBuilder
-
- All Known Implementing Classes:
AnsiMessageBuilder
,PlainMessageBuilder
public interface MessageBuilder
Message builder that supports configurable styling.- Since:
- 3.1.0
- See Also:
MessageUtils
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description MessageBuilder
a(char[] value)
Append content to the message buffer.MessageBuilder
a(char[] value, int offset, int len)
Append content to the message buffer.MessageBuilder
a(java.lang.CharSequence value)
Append content to the message buffer.MessageBuilder
a(java.lang.CharSequence value, int start, int end)
Append content to the message buffer.MessageBuilder
a(java.lang.Object value)
Append content to the message buffer.MessageBuilder
debug(java.lang.Object message)
MessageBuilder
error(java.lang.Object message)
MessageBuilder
failure(java.lang.Object message)
Append message content in failure style.MessageBuilder
format(java.lang.String pattern, java.lang.Object... args)
Append formatted content to the buffer.MessageBuilder
info(java.lang.Object message)
MessageBuilder
mojo(java.lang.Object message)
Append message content in mojo style.MessageBuilder
newline()
Append newline to the message buffer.MessageBuilder
project(java.lang.Object message)
Append message content in project style.MessageBuilder
strong(java.lang.Object message)
Append message content in strong style.MessageBuilder
success(java.lang.Object message)
Append message content in success style.MessageBuilder
warning(java.lang.Object message)
Append message content in warning style.
-
-
-
Method Detail
-
debug
MessageBuilder debug(java.lang.Object message)
-
info
MessageBuilder info(java.lang.Object message)
-
error
MessageBuilder error(java.lang.Object message)
-
success
MessageBuilder success(java.lang.Object message)
Append message content in success style. By default, bold green- Parameters:
message
- the message to append- Returns:
- the current builder
-
warning
MessageBuilder warning(java.lang.Object message)
Append message content in warning style. By default, bold yellow- Parameters:
message
- the message to append- Returns:
- the current builder
-
failure
MessageBuilder failure(java.lang.Object message)
Append message content in failure style. By default, bold red- Parameters:
message
- the message to append- Returns:
- the current builder
-
strong
MessageBuilder strong(java.lang.Object message)
Append message content in strong style. By default, bold- Parameters:
message
- the message to append- Returns:
- the current builder
-
mojo
MessageBuilder mojo(java.lang.Object message)
Append message content in mojo style. By default, green- Parameters:
message
- the message to append- Returns:
- the current builder
-
project
MessageBuilder project(java.lang.Object message)
Append message content in project style. By default, cyan- Parameters:
message
- the message to append- Returns:
- the current builder
-
a
MessageBuilder a(char[] value, int offset, int len)
Append content to the message buffer.- Parameters:
value
- the content to appendoffset
- the index of the firstchar
to appendlen
- the number ofchar
s to append- Returns:
- the current builder
-
a
MessageBuilder a(char[] value)
Append content to the message buffer.- Parameters:
value
- the content to append- Returns:
- the current builder
-
a
MessageBuilder a(java.lang.CharSequence value, int start, int end)
Append content to the message buffer.- Parameters:
value
- the content to appendstart
- the starting index of the subsequence to be appendedend
- the end index of the subsequence to be appended- Returns:
- the current builder
-
a
MessageBuilder a(java.lang.CharSequence value)
Append content to the message buffer.- Parameters:
value
- the content to append- Returns:
- the current builder
-
a
MessageBuilder a(java.lang.Object value)
Append content to the message buffer.- Parameters:
value
- the content to append- Returns:
- the current builder
-
newline
MessageBuilder newline()
Append newline to the message buffer.- Returns:
- the current builder
-
format
MessageBuilder format(java.lang.String pattern, java.lang.Object... args)
Append formatted content to the buffer.- Parameters:
pattern
- a format stringargs
- arguments referenced by the format specifiers in the format string.- Returns:
- the current builder
- See Also:
String.format(String, Object...)
-
-