本文整理了Java中org.mongodb.morphia.Morphia.fromDBObject()
方法的一些代码示例,展示了Morphia.fromDBObject()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Morphia.fromDBObject()
方法的具体详情如下:
包路径:org.mongodb.morphia.Morphia
类名称:Morphia
方法名:fromDBObject
[英]Creates an entity and populates its state based on the dbObject given. This method is primarily an internal method. Reliance on this method may break your application in future releases.
[中]根据给定的dbObject创建实体并填充其状态。这种方法主要是一种内部方法。在未来的版本中,依赖此方法可能会破坏您的应用程序。
代码示例来源:origin: querydsl/querydsl
@Override
public K apply(DBObject dbObject) {
return morphia.fromDBObject(datastore, entityType, dbObject, cache);
}
}, new MorphiaSerializer(morphia));
代码示例来源:origin: com.mysema.querydsl/querydsl-mongodb
@Override
public K apply(DBObject dbObject) {
return morphia.fromDBObject(entityType, dbObject, cache);
}
}, new MorphiaSerializer(morphia));
代码示例来源:origin: org.mongodb.morphia/morphia
/**
* Creates an entity and populates its state based on the dbObject given. This method is primarily an internal method. Reliance on
* this method may break your application in future releases.
*
* @param <T> type of the entity
* @param datastore the Datastore to use when fetching this reference
* @param entityClass type to create
* @param dbObject the object state to use
* @return the newly created and populated entity
*/
public <T> T fromDBObject(final Datastore datastore, final Class<T> entityClass, final DBObject dbObject) {
return fromDBObject(datastore, entityClass, dbObject, mapper.createEntityCache());
}
内容来源于网络,如有侵权,请联系作者删除!