private GridFSDBFile findGridFSDBFile ( EntityMetadata entityMetadata , Object key ) { String id = ( ( AbstractAttribute ) entityMetadata . getIdAttribute ( ) ) . getJPAColumnName ( ) ; DBObject query = new BasicDBObject ( "metadata." + id , key ) ; KunderaGridFS gfs = new KunderaGridFS ( mongoDb , entityMetadata . getTableName ( ) ) ; return gfs . findOne ( query ) ; }
Find GRIDFSDBFile .