package com.sunyard.chsm.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sunyard.chsm.model.dto.KeyInfoDTO;

import java.io.InputStream;
import java.util.List;

/**
 * @author liulu
 * @since 2024/10/23
 */
public interface KeyInfoService {

    Page<KeyInfoDTO.KeyView> selectPageList(KeyInfoDTO.Query query);

    KeyInfoDTO.KeyView selectById(Long id);

    Long save(KeyInfoDTO.KeySave save);

    void update(KeyInfoDTO.KeyUpdate update);

    byte[] backupKey(KeyInfoDTO.Backup backup);

    String recoveryKey(InputStream is);

    String createCsr(KeyInfoDTO.CreateCsr createCsr);

    void enableKey(List<Long> ids);

    void disableKey(List<Long> ids);

    void archiveKey(List<Long> ids);

    void destroyKey(List<Long> ids);
}
