electiveinfoserviceimpl.java

来自「Spring+hibernate学生在线选课系统」· Java 代码 · 共 61 行

JAVA
61
字号
/*
 * Created on 2006-1-21
 *
 * TODO To change the template for this generated file go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
package org.mmxbb.schoolelective.service.impl;

import java.util.List;

import org.mmxbb.schoolelective.dao.ElectiveinfoDao;
import org.mmxbb.schoolelective.model.Electiveinfo;
import org.mmxbb.schoolelective.service.ElectiveinfoService;


/**
 * @author mmx
 *
 * TODO To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
public class ElectiveinfoServiceImpl implements ElectiveinfoService {
	  
			
	
	   private ElectiveinfoDao electiveinfoDao;
    
	   //set Dao   在业务逻辑实现的地方要set一下用到的dao
	   public void setElectiveinfoDao(ElectiveinfoDao electiveinfoDao){
	        this.electiveinfoDao = electiveinfoDao;
	    }
		    
	   public List getAllElectiveinfo() {
		       return electiveinfoDao.findAll();
		
	   }
	   
	   
       public List getSpecElectiveinfo(String query){
       		   return electiveinfoDao.find(query);
       }
	
	    public Electiveinfo getElectiveinfo(String id) {
		        return electiveinfoDao.load(id);
		    }
		    
	    public void updateElectiveinfo(Electiveinfo electiveinfo) {
	        
	    	electiveinfoDao.update(electiveinfo);
		    }
        public void deleteElectiveinfo(String id) {
        	electiveinfoDao.delete(id);
            }
        public void createElectiveinfo(Electiveinfo electiveinfo) {
        	electiveinfoDao.save(electiveinfo);
		    }
		
	 
		 
	}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?