Class GraphQLDiscountCodeNonApplicableErrorBuilder
java.lang.Object
com.commercetools.api.models.error.GraphQLDiscountCodeNonApplicableErrorBuilder
- All Implemented Interfaces:
Builder<GraphQLDiscountCodeNonApplicableError>
public class GraphQLDiscountCodeNonApplicableErrorBuilder
extends Object
implements Builder<GraphQLDiscountCodeNonApplicableError>
GraphQLDiscountCodeNonApplicableErrorBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
GraphQLDiscountCodeNonApplicableError graphQLDiscountCodeNonApplicableError = GraphQLDiscountCodeNonApplicableError.builder()
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionError-specific additional fields.build()
builds GraphQLDiscountCodeNonApplicableError with checking for non-null required valuesbuilds GraphQLDiscountCodeNonApplicableError without checking for non-null required valuesdiscountCode
(String discountCode) Discount Code passed to the Cart.discountCodeId
(String discountCodeId) Unique identifier of the Discount Code.Discount Code passed to the Cart.Unique identifier of the Discount Code."DoesNotExist"
or"TimeRangeNonApplicable"
Date and time (UTC) from which the Discount Code is valid.Date and time (UTC) the Discount Code validity check was last performed.Date and time (UTC) until which the Discount Code is valid.Error-specific additional fields.of()
factory method for an instance of GraphQLDiscountCodeNonApplicableErrorBuilderof
(GraphQLDiscountCodeNonApplicableError template) create builder for GraphQLDiscountCodeNonApplicableError instance"DoesNotExist"
or"TimeRangeNonApplicable"
validFrom
(ZonedDateTime validFrom) Date and time (UTC) from which the Discount Code is valid.validityCheckTime
(ZonedDateTime validityCheckTime) Date and time (UTC) the Discount Code validity check was last performed.validUntil
(ZonedDateTime validUntil) Date and time (UTC) until which the Discount Code is valid.Error-specific additional fields.
-
Constructor Details
-
GraphQLDiscountCodeNonApplicableErrorBuilder
public GraphQLDiscountCodeNonApplicableErrorBuilder()
-
-
Method Details
-
values
Error-specific additional fields.
- Parameters:
values
- properties to be set- Returns:
- Builder
-
addValue
Error-specific additional fields.
- Parameters:
key
- property namevalue
- property value- Returns:
- Builder
-
discountCode
Discount Code passed to the Cart.
- Parameters:
discountCode
- value to be set- Returns:
- Builder
-
reason
"DoesNotExist"
or"TimeRangeNonApplicable"
- Parameters:
reason
- value to be set- Returns:
- Builder
-
discountCodeId
Unique identifier of the Discount Code.
- Parameters:
discountCodeId
- value to be set- Returns:
- Builder
-
validFrom
Date and time (UTC) from which the Discount Code is valid.
- Parameters:
validFrom
- value to be set- Returns:
- Builder
-
validUntil
Date and time (UTC) until which the Discount Code is valid.
- Parameters:
validUntil
- value to be set- Returns:
- Builder
-
validityCheckTime
public GraphQLDiscountCodeNonApplicableErrorBuilder validityCheckTime(@Nullable ZonedDateTime validityCheckTime) Date and time (UTC) the Discount Code validity check was last performed.
- Parameters:
validityCheckTime
- value to be set- Returns:
- Builder
-
getValues
Error-specific additional fields.
- Returns:
- pattern properties
-
getDiscountCode
Discount Code passed to the Cart.
- Returns:
- discountCode
-
getReason
"DoesNotExist"
or"TimeRangeNonApplicable"
- Returns:
- reason
-
getDiscountCodeId
Unique identifier of the Discount Code.
- Returns:
- discountCodeId
-
getValidFrom
Date and time (UTC) from which the Discount Code is valid.
- Returns:
- validFrom
-
getValidUntil
Date and time (UTC) until which the Discount Code is valid.
- Returns:
- validUntil
-
getValidityCheckTime
Date and time (UTC) the Discount Code validity check was last performed.
- Returns:
- validityCheckTime
-
build
builds GraphQLDiscountCodeNonApplicableError with checking for non-null required values- Specified by:
build
in interfaceBuilder<GraphQLDiscountCodeNonApplicableError>
- Returns:
- GraphQLDiscountCodeNonApplicableError
-
buildUnchecked
builds GraphQLDiscountCodeNonApplicableError without checking for non-null required values- Returns:
- GraphQLDiscountCodeNonApplicableError
-
of
factory method for an instance of GraphQLDiscountCodeNonApplicableErrorBuilder- Returns:
- builder
-
of
public static GraphQLDiscountCodeNonApplicableErrorBuilder of(GraphQLDiscountCodeNonApplicableError template) create builder for GraphQLDiscountCodeNonApplicableError instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-