public static final class ListMatchingResourcesResponse.Builder extends Object
ListMatchingResourcesResponse
.
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 |
---|---|
ListMatchingResourcesResponse.Builder |
addAllResources(Iterable<? extends Resource> elements)
Adds elements to
resources list. |
ListMatchingResourcesResponse |
build()
Builds a new
ListMatchingResourcesResponse . |
ListMatchingResourcesResponse.Builder |
from(ListMatchingResourcesResponse instance)
Fill a builder with attribute values from the provided
ListMatchingResourcesResponse instance. |
ListMatchingResourcesResponse.Builder |
resource(Resource... elements)
Adds elements to
resources list. |
ListMatchingResourcesResponse.Builder |
resource(Resource element)
Adds one element to
resources list. |
ListMatchingResourcesResponse.Builder |
resources(Iterable<? extends Resource> elements)
Sets or replaces all elements for
resources list. |
public final ListMatchingResourcesResponse.Builder from(ListMatchingResourcesResponse instance)
ListMatchingResourcesResponse
instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.
Collection elements and entries will be added, not replaced.instance
- The instance from which to copy valuesthis
builder for use in a chained invocationpublic final ListMatchingResourcesResponse.Builder resource(Resource element)
resources
list.element
- A resources elementthis
builder for use in a chained invocationpublic final ListMatchingResourcesResponse.Builder resource(Resource... elements)
resources
list.elements
- An array of resources elementsthis
builder for use in a chained invocationpublic final ListMatchingResourcesResponse.Builder resources(Iterable<? extends Resource> elements)
resources
list.elements
- An iterable of resources elementsthis
builder for use in a chained invocationpublic final ListMatchingResourcesResponse.Builder addAllResources(Iterable<? extends Resource> elements)
resources
list.elements
- An iterable of resources elementsthis
builder for use in a chained invocationpublic ListMatchingResourcesResponse build()
ListMatchingResourcesResponse
.IllegalStateException
- if any required attributes are missingCopyright © 2018 Pivotal Software, Inc.. All rights reserved.