package cn.reghao.tnb.sb.multi.mybatis.mapper.one;

import cn.reghao.tnb.sb.multi.mybatis.model.one.DataBlock;
import cn.reghao.jutil.jdk.web.db.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author reghao
 * @date 2024-12-21 19:22:41
 */
public interface DataBlockMapper extends BaseMapper<DataBlock> {
    void deleteDataBlocks();

    void updateSetDelete(String contentId);
    void updatePath(@Param("id") int id, @Param("absolutePath") String absolutePath);
    void updateReplica(@Param("id") int id, @Param("replica") int replica);

    DataBlock findByContentId(String contentId);
    List<DataBlock> findByDeleted();
    List<DataBlock> findByDisk();
}
