
io.leopard.data.mongo.Mongo Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of leopard-mongo Show documentation
Show all versions of leopard-mongo Show documentation
MongoDB操作,基于mongo-java-driver封装,简化MongoDB操作.
package io.leopard.data.mongo;
import java.util.List;
import com.mongodb.DBCollection;
import com.mongodb.DBCursor;
import com.mongodb.DBObject;
import com.mongodb.gridfs.GridFS;
public interface Mongo {
boolean insert(Object bean);
T query();
boolean remove(DBObject ref);
boolean remove(String fieldName, Object value);
List find(DBObject ref, Class clazz, int start, int size);
boolean drop();
boolean truncate();
List find(IFind find, Class clazz);
boolean update(DBObject q, DBObject o);
GridFS getGridFS(String type);
public static interface IFind {
DBCursor find(DBCollection collection);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy