|
Spring Data Document | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.data.mongodb.core.QueryMapper
public class QueryMapper
A helper class to encapsulate any modifications of a Query object before it gets submitted to the database.
Constructor Summary | |
---|---|
QueryMapper(MongoConverter converter)
Creates a new QueryMapper with the given MongoConverter . |
Method Summary | |
---|---|
Object |
convertId(Object id)
Converts the given raw id value into either ObjectId or String . |
DBObject |
getMappedObject(DBObject query,
MongoPersistentEntity<?> entity)
Replaces the property keys used in the given DBObject with the appropriate keys by using the
PersistentEntity metadata. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public QueryMapper(MongoConverter converter)
QueryMapper
with the given MongoConverter
.
converter
- must not be null.Method Detail |
---|
public DBObject getMappedObject(DBObject query, MongoPersistentEntity<?> entity)
DBObject
with the appropriate keys by using the
PersistentEntity
metadata.
query
- entity
-
public Object convertId(Object id)
ObjectId
or String
.
id
-
|
Spring Data Document | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |