Class AbstractMarkLogicConverter
- java.lang.Object
-
- io.github.malteseduck.springframework.data.marklogic.core.convert.AbstractMarkLogicConverter
-
- All Implemented Interfaces:
MarkLogicConverter
,org.springframework.data.convert.EntityConverter<MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty,Object,DocumentDescriptor>
,org.springframework.data.convert.EntityReader<Object,DocumentDescriptor>
,org.springframework.data.convert.EntityWriter<Object,DocumentDescriptor>
- Direct Known Subclasses:
JacksonMarkLogicConverter
public abstract class AbstractMarkLogicConverter extends Object implements MarkLogicConverter
-
-
Constructor Summary
Constructors Constructor Description AbstractMarkLogicConverter(org.springframework.data.mapping.context.MappingContext<? extends MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty> mappingContext)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract <R> R
doRead(Class<R> type, DocumentDescriptor source)
abstract void
doWrite(Object source, DocumentDescriptor sink)
org.springframework.core.convert.ConversionService
getConversionService()
List<String>
getDocumentUris(List<?> ids)
<T> List<String>
getDocumentUris(List<?> ids, Class<T> entityClass)
org.springframework.data.mapping.context.MappingContext<? extends MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty>
getMappingContext()
<R> R
read(Class<R> clazz, DocumentDescriptor doc)
<T> com.marklogic.client.query.QueryDefinition
wrapQuery(com.marklogic.client.query.StructuredQueryDefinition query, Class<T> entityClass)
void
write(Object source, DocumentDescriptor doc)
-
-
-
Constructor Detail
-
AbstractMarkLogicConverter
public AbstractMarkLogicConverter(org.springframework.data.mapping.context.MappingContext<? extends MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty> mappingContext)
-
-
Method Detail
-
getMappingContext
public org.springframework.data.mapping.context.MappingContext<? extends MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty> getMappingContext()
- Specified by:
getMappingContext
in interfaceorg.springframework.data.convert.EntityConverter<MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty,Object,DocumentDescriptor>
-
getConversionService
public org.springframework.core.convert.ConversionService getConversionService()
- Specified by:
getConversionService
in interfaceorg.springframework.data.convert.EntityConverter<MarkLogicPersistentEntity<?>,MarkLogicPersistentProperty,Object,DocumentDescriptor>
-
write
public void write(Object source, DocumentDescriptor doc)
- Specified by:
write
in interfaceorg.springframework.data.convert.EntityWriter<Object,DocumentDescriptor>
-
read
public <R> R read(Class<R> clazz, DocumentDescriptor doc)
- Specified by:
read
in interfaceorg.springframework.data.convert.EntityReader<Object,DocumentDescriptor>
-
getDocumentUris
public List<String> getDocumentUris(List<?> ids)
- Specified by:
getDocumentUris
in interfaceMarkLogicConverter
-
getDocumentUris
public <T> List<String> getDocumentUris(List<?> ids, Class<T> entityClass)
- Specified by:
getDocumentUris
in interfaceMarkLogicConverter
-
wrapQuery
public <T> com.marklogic.client.query.QueryDefinition wrapQuery(com.marklogic.client.query.StructuredQueryDefinition query, Class<T> entityClass)
- Specified by:
wrapQuery
in interfaceMarkLogicConverter
-
doRead
public abstract <R> R doRead(Class<R> type, DocumentDescriptor source)
- Specified by:
doRead
in interfaceMarkLogicConverter
-
doWrite
public abstract void doWrite(Object source, DocumentDescriptor sink)
- Specified by:
doWrite
in interfaceMarkLogicConverter
-
-