length


Description:

public int length ()

Returns the length of the string that would be produced by toString().

Example:

    var joiner = new StringJoiner (", ", "[", "]");
joiner.add ("ab");
assert (joiner.length () == 4); // "[ab]"

Returns:

the length of the joined string.