package cn.reghao.oss.storeapi.dto;

import cn.reghao.jutil.jdk.store.LocalStore;
import lombok.Getter;
import lombok.NoArgsConstructor;

import java.io.Serializable;

/**
 * @author reghao
 * @date 2024-03-04 17:12:21
 */
@NoArgsConstructor
@Getter
public class StoreDiskDto implements Serializable {
    private static final long serialVersionUID = 1L;

    private String diskDir;
    private Long total;
    private Long avail;

    public StoreDiskDto(LocalStore localStore) {
        this.diskDir = localStore.getDiskDir();
        this.total = localStore.getTotal();
        this.avail = localStore.getAvailable();
    }
}
