|
package com.ekexiu.portal.dao;
import java.sql.Connection;
import java.sql.SQLException;
import java.util.List;
import org.jfw.apt.annotation.Nullable;
import org.jfw.apt.orm.annotation.dao.DAO;
import org.jfw.apt.orm.annotation.dao.method.From;
import org.jfw.apt.orm.annotation.dao.method.operator.DeleteWith;
import org.jfw.apt.orm.annotation.dao.method.operator.Insert;
import org.jfw.apt.orm.annotation.dao.method.operator.SelectList;
import org.jfw.apt.orm.annotation.dao.method.operator.SelectOne;
import org.jfw.apt.orm.annotation.dao.method.operator.Update;
import org.jfw.apt.orm.annotation.dao.method.operator.UpdateWith;
import org.jfw.apt.orm.annotation.dao.param.Set;
import com.ekexiu.portal.po.Resource;
@DAO
public abstract class ResourceDao {
@Insert
public abstract int insert(Connection con,Resource resource) throws SQLException;
@Update
public abstract int update(Connection con,Resource resource) throws SQLException;
@UpdateWith
@From(Resource.class)
public abstract int updateSubject(Connection con, String resourceId, @Set String subject) throws SQLException;
@UpdateWith
@From(Resource.class)
public abstract int updateIndustry(Connection con, String resourceId, @Set String industry) throws SQLException;
@UpdateWith
@From(Resource.class)
public abstract int updateDescp(Connection con, String resourceId, @Set String descp) throws SQLException;
@UpdateWith
@From(Resource.class)
public abstract int updateHopePayMethod(Connection con, String resourceId, @Set String hopePayMethod) throws SQLException;
@UpdateWith
@From(Resource.class)
public abstract int updateCooperationNotes(Connection con,String resourceId,@Set String cooperationNotes) throws SQLException;
@Nullable
@SelectOne
public abstract Resource query(Connection con, String resourceId) throws SQLException;
@SelectList
public abstract List<Resource> query(Connection con) throws SQLException;
@SelectList
public abstract List<Resource> queryPro(Connection con, String professorId) throws SQLException;
@DeleteWith
@From(Resource.class)
public abstract int delete(Connection con, String resourceId) throws SQLException;
}
|