Class ProductSelectionProductPagedQueryResponseBuilder
- All Implemented Interfaces:
Builder<ProductSelectionProductPagedQueryResponse>
Example to create an instance using the builder pattern
ProductSelectionProductPagedQueryResponse productSelectionProductPagedQueryResponse = ProductSelectionProductPagedQueryResponse.builder()
.limit(0.3)
.offset(0.3)
.count(0.3)
.plusResults(resultsBuilder -> resultsBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReferences to Products that are assigned to the ProductSelection.build()
builds ProductSelectionProductPagedQueryResponse with checking for non-null required valuesbuilds ProductSelectionProductPagedQueryResponse without checking for non-null required valuesActual number of results returned.getCount()
Actual number of results returned.getLimit()
Number of results requested.Number of elements skipped.References to Products that are assigned to the ProductSelection.getTotal()
Total number of results matching the query.Number of results requested.of()
factory method for an instance of ProductSelectionProductPagedQueryResponseBuilderof
(ProductSelectionProductPagedQueryResponse template) create builder for ProductSelectionProductPagedQueryResponse instanceNumber of elements skipped.plusResults
(AssignedProductReference... results) References to Products that are assigned to the ProductSelection.References to Products that are assigned to the ProductSelection.results
(AssignedProductReference... results) References to Products that are assigned to the ProductSelection.results
(List<AssignedProductReference> results) References to Products that are assigned to the ProductSelection.References to Products that are assigned to the ProductSelection.Total number of results matching the query.References to Products that are assigned to the ProductSelection.
-
Constructor Details
-
ProductSelectionProductPagedQueryResponseBuilder
public ProductSelectionProductPagedQueryResponseBuilder()
-
-
Method Details
-
limit
Number of results requested.
- Parameters:
limit
- value to be set- Returns:
- Builder
-
offset
Number of elements skipped.
- Parameters:
offset
- value to be set- Returns:
- Builder
-
count
Actual number of results returned.
- Parameters:
count
- value to be set- Returns:
- Builder
-
total
Total number of results matching the query. This number is an estimation that is not strongly consistent. Unlike other endpoints, the Product Selection endpoint does not return this field by default. To get
total
, pass the query parameterwithTotal
set totrue
. When the results are filtered with a Query Predicate,total
is subject to a limit.- Parameters:
total
- value to be set- Returns:
- Builder
-
results
public ProductSelectionProductPagedQueryResponseBuilder results(AssignedProductReference... results) References to Products that are assigned to the ProductSelection.
- Parameters:
results
- value to be set- Returns:
- Builder
-
results
public ProductSelectionProductPagedQueryResponseBuilder results(List<AssignedProductReference> results) References to Products that are assigned to the ProductSelection.
- Parameters:
results
- value to be set- Returns:
- Builder
-
plusResults
public ProductSelectionProductPagedQueryResponseBuilder plusResults(AssignedProductReference... results) References to Products that are assigned to the ProductSelection.
- Parameters:
results
- value to be set- Returns:
- Builder
-
plusResults
public ProductSelectionProductPagedQueryResponseBuilder plusResults(Function<AssignedProductReferenceBuilder, AssignedProductReferenceBuilder> builder) References to Products that are assigned to the ProductSelection.
- Parameters:
builder
- function to build the results value- Returns:
- Builder
-
withResults
public ProductSelectionProductPagedQueryResponseBuilder withResults(Function<AssignedProductReferenceBuilder, AssignedProductReferenceBuilder> builder) References to Products that are assigned to the ProductSelection.
- Parameters:
builder
- function to build the results value- Returns:
- Builder
-
addResults
public ProductSelectionProductPagedQueryResponseBuilder addResults(Function<AssignedProductReferenceBuilder, AssignedProductReference> builder) References to Products that are assigned to the ProductSelection.
- Parameters:
builder
- function to build the results value- Returns:
- Builder
-
setResults
public ProductSelectionProductPagedQueryResponseBuilder setResults(Function<AssignedProductReferenceBuilder, AssignedProductReference> builder) References to Products that are assigned to the ProductSelection.
- Parameters:
builder
- function to build the results value- Returns:
- Builder
-
getLimit
Number of results requested.
- Returns:
- limit
-
getOffset
Number of elements skipped.
- Returns:
- offset
-
getCount
Actual number of results returned.
- Returns:
- count
-
getTotal
Total number of results matching the query. This number is an estimation that is not strongly consistent. Unlike other endpoints, the Product Selection endpoint does not return this field by default. To get
total
, pass the query parameterwithTotal
set totrue
. When the results are filtered with a Query Predicate,total
is subject to a limit.- Returns:
- total
-
getResults
References to Products that are assigned to the ProductSelection.
- Returns:
- results
-
build
builds ProductSelectionProductPagedQueryResponse with checking for non-null required values- Specified by:
build
in interfaceBuilder<ProductSelectionProductPagedQueryResponse>
- Returns:
- ProductSelectionProductPagedQueryResponse
-
buildUnchecked
builds ProductSelectionProductPagedQueryResponse without checking for non-null required values- Returns:
- ProductSelectionProductPagedQueryResponse
-
of
factory method for an instance of ProductSelectionProductPagedQueryResponseBuilder- Returns:
- builder
-
of
public static ProductSelectionProductPagedQueryResponseBuilder of(ProductSelectionProductPagedQueryResponse template) create builder for ProductSelectionProductPagedQueryResponse instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-