format
Returns a formatted version of the given value.
Following the minimum requirements for an ObjectFormatter:
it will return Text.string in case value is a Text
it will return the translation of value in case it is a Translatable
Besides that it is up to the concrete implementation how it formats value. Nonetheless, following some conventions:
return
"true"in case value istruereturn
"false"in case value isfalsewrap Char in apostrophes (e.g.
"'a'")wrap CharSequence in quotes (e.g.
"\"hello\"")
Return
The formatted value.
Parameters
value
The value which shall be formatted.