package com.trade.service.filestorage.dto;

import com.trade.service.filestorage.entity.TFileStorage;

/**
 * 文件摘要信息
 */
public class FileAbstractDto {

    /**
     * 文件id
     */
    private Long id;
    /**
     * 文件名称
     */
    private String originalName;
    /**
     * 文件类型
     */
    private String fileType;
    /**
     * 文件后缀
     */
    private String fileSuffix;

    public FileAbstractDto(TFileStorage fileStorage ) {
        if (fileStorage!= null){
            this.id = fileStorage.getId();
            this.originalName = fileStorage.getOriginalName();
            this.fileType = fileStorage.getFileType();
            this.fileSuffix = fileStorage.getFileSuffix();
        }
    }

    public FileAbstractDto() {
    }

    public FileAbstractDto(Long id, String originalName, String fileType, String fileSuffix) {
        this.id = id;
        this.originalName = originalName;
        this.fileType = fileType;
        this.fileSuffix = fileSuffix;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getOriginalName() {
        return originalName;
    }

    public void setOriginalName(String originalName) {
        this.originalName = originalName;
    }

    public String getFileType() {
        return fileType;
    }

    public void setFileType(String fileType) {
        this.fileType = fileType;
    }

    public String getFileSuffix() {
        return fileSuffix;
    }

    public void setFileSuffix(String fileSuffix) {
        this.fileSuffix = fileSuffix;
    }
}
