package com.brframework.webapppatch.service;

import com.brframework.commoncms.core.cms.Select;
import com.brframework.commoncms.core.cms.Selector;
import com.brframework.commondb.core.EntityService;
import com.brframework.webapppatch.entity.PatchBranch;

/**
 * 分支
 * @author xu
 * @date 2019/11/14 10:29
 */
public interface PatchBranchService extends EntityService<PatchBranch, Long, Object>, Selector<String, Select> {

    /** cms select */
    String SELECT_APP_PATCH_BRANCH = "SELECT_APP_PATCH_BRANCH";

    /**
     * 更新分支信息
     * @param id
     * @param os
     * @param brandName
     * @param branchDetail
     */
    void updateBranch(Long id, String os, String brandName, String branchDetail);

    /**
     * 更新分支基础包
     * @param brandName     分支名
     * @param packageUrl    基础包下载地址
     */
    void updateBasePackage(String brandName, String packageUrl);

    /**
     * 创建分支
     * @param os
     * @param brandName
     * @param branchDetail
     */
    void createBranch(String os, String brandName, String branchDetail);

    /**
     * 通过分支名查找分支
     * @param branchName
     */
    PatchBranch findByBranchName(String branchName);
}
