/**
 * Multimud Helper.
 * 
 * Copyright (C) 2009 Benjamin Lerman<br>
 * Copyright (C) 2009 Jacques ???
 * 
 * This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free
 * Software Foundation, either version 3 of the License, or (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
 */
package net.ambre.multimud_helper.dao;

import net.ambre.multimud_helper.bean.Skill;
import net.ambre.multimud_helper.bean.SkillLevel;
import net.ambre.multimud_helper.bean.Trainer;
import net.ambre.multimud_helper.bean.Zone;

/**
 * DAO to access trainers.
 */
public interface TrainerDAO {

    /**
     * return the {@link Skill} object having the given skill name. This method creates and persists a new {@link Skill} if no such skill already
     * exists.
     * 
     * @param skillName the name of the {@link Skill}.
     * @return the {@link Skill} corresponding to the given name.
     */
    public Skill getSkill(String skillName);

    /**
     * return the {@link Zone} object having the given zone name. This method creates and persists a new {@link Zone} if no such zone already exists.
     * 
     * @param zoneName the name of the {@link Zone}.
     * @return the {@link Zone} corresponding to the given name.
     */
    public Zone getZone(String zoneName);

    /**
     * add a {@link Skill} to the skills that the trainer teach.
     * 
     * @param trainer the {@link Trainer} to add the {@link Skill} to.
     * @param skill the {@link Skill} to add.
     * @param minLevel the minimal level the trainer teach.
     * @param maxLevel the maximal level the trainer teach.
     */
    public void addSkill(Trainer trainer, Skill skill, SkillLevel minLevel, SkillLevel maxLevel);
}
