setEmptyValue


Description:

public StringJoiner setEmptyValue (string value)

Sets the value to return from toString() when no elements have been added. By default, the empty value is prefix + suffix.

Example:

    var joiner = new StringJoiner (", ", "[", "]");
joiner.setEmptyValue ("EMPTY");
assert (joiner.toString () == "EMPTY");

Parameters:

value

the string to use when no elements are present.

Returns:

this StringJoiner for chaining.