On this page

BackgroundInitializer.Builder

public static class org.apache.commons.lang3.concurrent.BackgroundInitializer.Builder<I extends BackgroundInitializer<T>, T> extends AbstractConcurrentInitializer.AbstractBuilder<I, T, BackgroundInitializer.Builder<I, T>, Exception>[source]

Builds a new instance.

Parameters:
  • <T> – The type of results supplied by this builder.

  • <I> – The type of the initializer managed by this builder.

Since:

3.14.0

Constructors

Builder()

Constructs a new instance.

public Builder()[source]

Constructs a new instance.

Methods

get()

Supplies an object

setExternalExecutor(ExecutorService)

Sets the external executor service for executing tasks.

@SuppressWarnings({"unchecked"}) @Override public I get()[source]

Supplies an object

Returns:

A result

public BackgroundInitializer.Builder<I, T> setExternalExecutor(ExecutorService externalExecutor)[source]

Sets the external executor service for executing tasks. null is a permitted value.

See also:

org.apache.commons.lang3.concurrent.BackgroundInitializer#setExternalExecutor(ExecutorService)

Parameters:

externalExecutor – The ExecutorService to be used.

Returns:

this instance.