⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 soccerleagueservice.java

📁 在线足球社区
💻 JAVA
字号:
package com.pandahome.struts.service;

import java.sql.SQLException;

import com.pandahome.struts.domain.League;
import com.pandahome.struts.soccerLeagueDao.Dao;

public class SoccerLeagueService {
	private Dao dao;

	public SoccerLeagueService() {
		dao = new Dao();
	}

	/*
	 * 调用SoccerLeagueDAO中的selectLeague方法,返回League对象
	 */
	public League getLeague(String season, String year) throws SQLException {
		return dao.selectLeague(season, year);
	}

	/*
	 * 调用SoccerLeagueDAO中的insert方法,插入一条记录
	 */
	public League createLeague(String season, String year, String title)
			throws SQLException {
		League league = dao.selectLeague(season, year);
		league = dao.insert(league);
		return league;
	}
}

⌨️ 快捷键说明

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