package com.microservices.pms.productLibrary.service;


import com.microservices.pms.productLibrary.domain.PmsProductLibraryComponent;
import com.microservices.pms.productLibrary.domain.PmsProductLibraryRepositories;
import com.microservices.pms.productLibrary.domain.vo.NexusAssetResultDataVo;

import java.util.List;

/**
 * @author OTTO
 */
public interface IPmsProductLibraryAsyncService {
    /**
     * 遍历制品库制品文件列表,同步制品数据
     *
     * @param repo                        制品库
     * @param pmsProductLibraryComponents 制品列表
     */
    void syncNexusMavenRepoComponent(PmsProductLibraryRepositories repo, List<PmsProductLibraryComponent> pmsProductLibraryComponents);

    /**
     * 异步将制品库制品移入到产品库中
     *
     * @param productRepo                产品库
     * @param repo                       制品库
     * @param nexusAssetResultDataVoList 制品列表
     */
    void asyncAddCommonAssetToProductRepo(PmsProductLibraryRepositories productRepo, PmsProductLibraryRepositories repo, List<NexusAssetResultDataVo> nexusAssetResultDataVoList);

    /**
     * 同步制品库制品到快照库
     *
     * @param repo         制品库
     * @param snapshotRepo 快照库
     */
    void syncRepoToSnapshotRepo(PmsProductLibraryRepositories repo, PmsProductLibraryRepositories snapshotRepo);
}
