Interface DateField
- All Superinterfaces:
CustomField
A field with a date value.
Example to create an instance using the builder pattern
DateField dateField = DateField.builder()
.value(LocalDate.parse("2022-01-01"))
.build()
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic DateFieldBuilder
builder()
builder factory method for DateFieldstatic DateFieldBuilder
create builder for DateField instancecopyDeep()
static DateField
factory method to create a deep copy of DateField@NotNull LocalDate
getValue()
A date in the formatYYYY-MM-DD
.static DateField
of()
factory methodstatic DateField
factory method to create a shallow copy DateFieldvoid
A date in the formatYYYY-MM-DD
.static com.fasterxml.jackson.core.type.TypeReference<DateField>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withDateField
(Function<DateField, T> helper) accessor map functionMethods inherited from interface com.commercetools.importapi.models.customfields.CustomField
getType, withCustomField
-
Field Details
-
DATE
discriminator value for DateField- See Also:
-
-
Method Details
-
getValue
A date in the format
YYYY-MM-DD
.- Returns:
- value
-
setValue
A date in the format
YYYY-MM-DD
.- Parameters:
value
- value to be set
-
of
factory method- Returns:
- instance of DateField
-
of
factory method to create a shallow copy DateField- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
copyDeep
DateField copyDeep()- Specified by:
copyDeep
in interfaceCustomField
-
deepCopy
factory method to create a deep copy of DateField- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for DateField- Returns:
- builder
-
builder
create builder for DateField instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withDateField
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
-