package jp.agentec.sinaburocast.service;

import java.util.List;

import org.seasar.framework.container.annotation.tiger.Component;
import org.seasar.framework.container.annotation.tiger.InstanceType;

import jp.agentec.sinaburocast.entity.Prefecture;

@Component(instance=InstanceType.SINGLETON)
public class PrefectureService extends AbstractService<Prefecture> {

    public Prefecture findById(Integer prefectureId) {
        return select().id(prefectureId).getSingleResult();
    }

    public List<Prefecture> findAllOrderById() {
        return select().orderBy("prefectureId asc").getResultList();
    }
}