public static final class ImmutableTypeCheckPredicate.Builder<T> extends Object
ImmutableTypeCheckPredicate.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
| Modifier and Type | Method and Description |
|---|---|
ImmutableTypeCheckPredicate<T> |
build()
Builds a new
ImmutableTypeCheckPredicate. |
ImmutableTypeCheckPredicate.Builder<T> |
check(Predicate<T> check)
Initializes the value for the
check attribute. |
ImmutableTypeCheckPredicate.Builder<T> |
from(TypeCheckPredicate<T> instance)
Fill a builder with attribute values from the provided
TypeCheckPredicate instance. |
ImmutableTypeCheckPredicate.Builder<T> |
typeClass(Class<T> typeClass)
Initializes the value for the
typeClass attribute. |
public final ImmutableTypeCheckPredicate.Builder<T> from(TypeCheckPredicate<T> instance)
TypeCheckPredicate instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final ImmutableTypeCheckPredicate.Builder<T> typeClass(Class<T> typeClass)
typeClass attribute.typeClass - The value for typeClassthis builder for use in a chained invocationpublic final ImmutableTypeCheckPredicate.Builder<T> check(Predicate<T> check)
check attribute.check - The value for checkthis builder for use in a chained invocationpublic ImmutableTypeCheckPredicate<T> build()
ImmutableTypeCheckPredicate.IllegalStateException - if any required attributes are missingCopyright © 2021. All rights reserved.