public class LocalDateTimeCalendarConverter extends AbstractTypeConverter<LocalDateTime,Calendar>
Calendar
type and the new LocalDateTime
.
In combination with the ODataField
annotation this can be used to expose fields of OData value which would be
exposed as Calendar
as LocalDateTime
.
Constructor and Description |
---|
LocalDateTimeCalendarConverter() |
Modifier and Type | Method and Description |
---|---|
ConvertedObject<LocalDateTime> |
fromDomainNonNull(Calendar domainObject)
Actual converter implementation from a domain-specific object to an arbitrary type.
|
Class<Calendar> |
getDomainType()
Getter for an class object of the domain-specific type.
|
Class<LocalDateTime> |
getType()
Getter for an class object of the type to convert from/to the domain-specific counterpart.
|
ConvertedObject<Calendar> |
toDomainNonNull(LocalDateTime object)
Actual converter implementation from an arbitrary object to its domain-specific counterpart.
|
fromDomain, toDomain
@Nonnull public ConvertedObject<Calendar> toDomainNonNull(@Nonnull LocalDateTime object)
AbstractTypeConverter
toDomainNonNull
in class AbstractTypeConverter<LocalDateTime,Calendar>
object
- The object to transform to its domain-specific counterpart.@Nonnull public ConvertedObject<LocalDateTime> fromDomainNonNull(@Nonnull Calendar domainObject)
AbstractTypeConverter
fromDomainNonNull
in class AbstractTypeConverter<LocalDateTime,Calendar>
domainObject
- The domain-specific object to transform.@Nonnull public Class<LocalDateTime> getType()
TypeConverter
T
.@Nonnull public Class<Calendar> getDomainType()
TypeConverter
DomainT
.Copyright © 2021 SAP SE. All rights reserved.