package cn.reghao.oss.store.model.po;

import cn.reghao.jutil.jdk.db.BaseObject;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

/**
 * @author reghao
 * @date 2022-11-24 10:25:18
 */
@NoArgsConstructor
@AllArgsConstructor
@Setter
@Getter
public class DataBlock extends BaseObject<Integer> {
    private String contentId;
    private int index;
    private String blockId;
    private String host;
    private String baseDir;
    private String relativeDir;
    private String absolutePath;
    private long size;
    private long start;
    private long end;
    @Deprecated
    private String objectId;

    public DataBlock(String contentId, int index, String blockId, String absolutePath, long size) {
        this.contentId = contentId;
        this.index = index;
        this.blockId = blockId;
        this.absolutePath = absolutePath;
        this.size = size;
    }
}
