Interface CustomerReference
- All Superinterfaces:
Identifiable<Customer>
,IdentifiableObjHolder<Customer>
,Reference
,ReferenceMixin
public interface CustomerReference
extends Reference, Identifiable<Customer>, IdentifiableObjHolder<Customer>
Reference to a Customer.
Example to create an instance using the builder pattern
CustomerReference customerReference = CustomerReference.builder()
.id("{id}")
.build()
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic CustomerReferenceBuilder
builder()
builder factory method for CustomerReferencestatic CustomerReferenceBuilder
builder
(CustomerReference template) create builder for CustomerReference instancestatic CustomerReference
deepCopy
(CustomerReference template) factory method to create a deep copy of CustomerReference@NotNull String
getId()
Unique identifier of the referenced Customer.@Valid Customer
getObj()
Contains the representation of the expanded Customer.static CustomerReference
of()
factory methodstatic CustomerReference
of
(CustomerReference template) factory method to create a shallow copy CustomerReferencevoid
Unique identifier of the referenced Customer.void
Contains the representation of the expanded Customer.static com.fasterxml.jackson.core.type.TypeReference<CustomerReference>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withCustomerReference
(Function<CustomerReference, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.common.Reference
getTypeId, withReference
Methods inherited from interface com.commercetools.api.models.common.ReferenceMixin
toResourceIdentifier
-
Field Details
-
CUSTOMER
discriminator value for CustomerReference- See Also:
-
-
Method Details
-
getObj
Contains the representation of the expanded Customer. Only present in responses to requests with Reference Expansion for Customers.
- Specified by:
getObj
in interfaceIdentifiableObjHolder<Customer>
- Returns:
- obj
-
getId
Unique identifier of the referenced Customer.
- Specified by:
getId
in interfaceIdentifiable<Customer>
- Specified by:
getId
in interfaceReference
- Specified by:
getId
in interfaceReferenceMixin
- Returns:
- id
-
setObj
Contains the representation of the expanded Customer. Only present in responses to requests with Reference Expansion for Customers.
- Parameters:
obj
- value to be set
-
setId
Unique identifier of the referenced Customer.
-
of
factory method- Returns:
- instance of CustomerReference
-
of
factory method to create a shallow copy CustomerReference- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of CustomerReference- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for CustomerReference- Returns:
- builder
-
builder
create builder for CustomerReference instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withCustomerReference
accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-