Class MappingMongoConverter.ConversionContext
java.lang.Object
org.springframework.data.mongodb.core.convert.MappingMongoConverter.ConversionContext
- Enclosing class:
- MappingMongoConverter
Conversion context holding references to simple
MappingMongoConverter.ConversionContext.ValueConverter and MappingMongoConverter.ConversionContext.ContainerValueConverter.
Entrypoint for recursive conversion of Document and other types.- Since:
- 3.2
-
Method Summary
Modifier and TypeMethodDescription<S> Sconvert(Object source, TypeInformation<? extends S> typeHint) Converts a source object intotarget.forProperty(String name) org.springframework.data.mongodb.core.convert.ObjectPathgetPath()withPath(org.springframework.data.mongodb.core.convert.ObjectPath currentPath) Create a newMappingMongoConverter.ConversionContextwithcurrentPathapplied.
-
Method Details
-
convert
Converts a source object intotarget.- Parameters:
source- must not be null.typeHint- must not be null.- Returns:
- the converted object.
-
withPath
public MappingMongoConverter.ConversionContext withPath(org.springframework.data.mongodb.core.convert.ObjectPath currentPath) Create a newMappingMongoConverter.ConversionContextwithcurrentPathapplied.- Parameters:
currentPath- must not be null.- Returns:
- a new
MappingMongoConverter.ConversionContextwithcurrentPathapplied.
-
getPath
public org.springframework.data.mongodb.core.convert.ObjectPath getPath() -
forProperty
-