package com.yonge.mongodb.service;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

import com.yonge.mongodb.PageInfo;
import com.yonge.mongodb.QueryInfo;

public interface BaseServiceWithMongo<PK, T extends Serializable> {

	public T get(PK id);
	
	public long update(PK id, T bean);
	
	public long delete(final PK id);
	
	public void insert(T bean);
	
	public List<T> findAll(Map<String, Object> params);
	
	public PageInfo<T> queryPage(QueryInfo queryInfo);
	
	public long queryCount(Map<String, Object> params);
}
