package com.zhongshu.card.server.core.model.upLoadFile.oss;


import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.zhongshu.card.server.core.model.upLoadFile.ObjectStorageType;
import lombok.Getter;

@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "_type")
@JsonSubTypes({
        @JsonSubTypes.Type(value = ALiObjectStorage.class, name = "ALiObjectStorage"),  //阿里云
        @JsonSubTypes.Type(value = TencentObjectStorage.class, name = "TencentObjectStorage"), //腾讯云
        @JsonSubTypes.Type(value = HuaweiObjectStorage.class, name = "HuaweiObjectStorage"),  //阿里云
        @JsonSubTypes.Type(value = PlatformStoreObjectStorage.class, name = "PlatformStoreObjectStorage"),
})
public abstract class SuperObjectStorage {

    //令牌过期时间
    @Getter
    private int stsDurationSeconds = 3600;

    /**
     * 类型
     *
     * @return
     */
    public abstract ObjectStorageType storageType();


}
