AppendableJoiner.Builder

public static final class org.apache.commons.lang3.AppendableJoiner.Builder<T> implements Supplier<AppendableJoiner<T>>[source]

Builds instances of AppendableJoiner.

Type parameters:

<T> – The type of elements to join.

Methods

AppendableJoiner<T>

get()

Gets a new instance of AppendableJoiner.

AppendableJoiner.Builder<T>

setDelimiter(CharSequence delimiter)

Sets the delimiter that separates each element.

AppendableJoiner.Builder<T>

setElementAppender(FailableBiConsumer<Appendable, T, IOException> appender)

Sets the consumer used to render each element of type T onto an Appendable.

AppendableJoiner.Builder<T>

setPrefix(CharSequence prefix)

Sets the sequence of characters to be used at the beginning.

AppendableJoiner.Builder<T>

setSuffix(CharSequence suffix)

Sets the sequence of characters to be used at the end.

public AppendableJoiner<T> get()[source]

Gets a new instance of AppendableJoiner.

Specified by:

get in interface Supplier

public AppendableJoiner.Builder<T> setDelimiter(CharSequence delimiter)[source]

Sets the delimiter that separates each element.

Parameters:

delimiter – The delimiter that separates each element.

Returns:

this instance.

public AppendableJoiner.Builder<T> setElementAppender(FailableBiConsumer<Appendable, T, IOException> appender)[source]

Sets the consumer used to render each element of type T onto an Appendable.

Parameters:

appender – The consumer used to render each element of type T onto an Appendable.

Returns:

this instance.

public AppendableJoiner.Builder<T> setPrefix(CharSequence prefix)[source]

Sets the sequence of characters to be used at the beginning.

Parameters:

prefix – The sequence of characters to be used at the beginning.

Returns:

this instance.

public AppendableJoiner.Builder<T> setSuffix(CharSequence suffix)[source]

Sets the sequence of characters to be used at the end.

Parameters:

suffix – The sequence of characters to be used at the end.

Returns:

this instance.