Interface ToDocumentValueConvertContextExtension<T>
- Type Parameters:
T
- The type of extended contexts.
- All Known Subinterfaces:
ToDocumentFieldValueConvertContextExtension<T>
- All Known Implementing Classes:
HibernateOrmExtension
public interface ToDocumentValueConvertContextExtension<T>
An extension to
ToDocumentValueConvertContext
, allowing to access non-standard context
specific to a given mapper.
WARNING: while this type is API, because instances should be manipulated by users,
all of its methods are considered SPIs and therefore should never be called or implemented directly by users.
In short, users are only expected to get instances of this type from an API (SomeExtension.get()
)
and pass it to another API.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionextendOptional
(ToDocumentValueConvertContext original, BackendMappingContext mappingContext) Attempt to extend a given context, returning an emptyOptional
in case of failure.
-
Method Details
-
extendOptional
Optional<T> extendOptional(ToDocumentValueConvertContext original, BackendMappingContext mappingContext) Attempt to extend a given context, returning an emptyOptional
in case of failure.WARNING: this method is not API, see comments at the type level.
- Parameters:
original
- The original, non-extendedToDocumentValueConvertContext
.mappingContext
- ABackendMappingContext
.- Returns:
- An optional containing the extended context (
ToDocumentValueConvertContextExtension
) in case of success, or an empty optional otherwise.
-