/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.lightinit.hsdatagateway.modules.gateway.dao;

import com.lightinit.hsdatagateway.common.persistence.CrudDao;
import com.lightinit.hsdatagateway.common.persistence.annotation.MyBatisDao;
import com.lightinit.hsdatagateway.modules.gateway.entity.BizRoute;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 路由管理DAO接口
 * @Author yangrui
 * @version 2019-03-05
 */
@MyBatisDao
public interface BizRouteDao extends CrudDao<BizRoute> {

    /**
     * 根据上下文路径查询
     * @param contextPath
     * @return
     */
    BizRoute getByContextPath(@Param("contextPath") String contextPath);

    /**
     * 根据routeId修改路由信息
     * @param bizRoute
     */
    void updateByRouteId(BizRoute bizRoute);

    /**
     * api接口 查询路由信息
     * @param bizRoute
     * @return
     */
    List<BizRoute> findListByApi(BizRoute bizRoute);
}