package com.yunfeiyun.agmp.common.framework.config.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

@Configuration
@ConfigurationProperties(prefix = "policy.upload.ossconfig")
public class OSSProperties {

    public int ossType;
    public ossCloud ossCloud;

    public int getOssType() {
        return ossType;
    }

    public OSSProperties.ossCloud getOssCloud() {
        return ossCloud;
    }

    public void setOssCloud(OSSProperties.ossCloud ossCloud) {
        this.ossCloud = ossCloud;
    }

    public void setOssType(int ossType) {
        this.ossType = ossType;
    }

    public static class ossCloud {
        public aliYun aliYun;
        public qCloud qCloud;

        @Override
        public String toString() {
            return "ossCloud{" +
                    "aliYun=" + aliYun +
                    ", qCloud=" + qCloud +
                    '}';
        }

        public OSSProperties.aliYun getAliYun() {
            return aliYun;
        }

        public void setAliYun(OSSProperties.aliYun aliYun) {
            this.aliYun = aliYun;
        }

        public OSSProperties.qCloud getqCloud() {
            return qCloud;
        }

        public void setqCloud(OSSProperties.qCloud qCloud) {
            this.qCloud = qCloud;
        }

    }


    public static class aliYun {
        public int accessType;
        public String aliyunDomain;
        public String aliyunPrefix;
        public String aliyunEndPoint;
        public String aliyunAccessKeyId;
        public String aliyunAccessKeySecret;
        public String aliyunBucketName;

        public int getAccessType() {
            return accessType;
        }

        public void setAccessType(int accessType) {
            this.accessType = accessType;
        }

        public String getAliyunDomain() {
            return aliyunDomain;
        }

        public void setAliyunDomain(String aliyunDomain) {
            this.aliyunDomain = aliyunDomain;
        }

        public String getAliyunPrefix() {
            return aliyunPrefix;
        }

        public void setAliyunPrefix(String aliyunPrefix) {
            this.aliyunPrefix = aliyunPrefix;
        }

        public String getAliyunEndPoint() {
            return aliyunEndPoint;
        }

        public void setAliyunEndPoint(String aliyunEndPoint) {
            this.aliyunEndPoint = aliyunEndPoint;
        }

        public String getAliyunAccessKeyId() {
            return aliyunAccessKeyId;
        }

        public void setAliyunAccessKeyId(String aliyunAccessKeyId) {
            this.aliyunAccessKeyId = aliyunAccessKeyId;
        }

        public String getAliyunAccessKeySecret() {
            return aliyunAccessKeySecret;
        }

        public void setAliyunAccessKeySecret(String aliyunAccessKeySecret) {
            this.aliyunAccessKeySecret = aliyunAccessKeySecret;
        }

        public String getAliyunBucketName() {
            return aliyunBucketName;
        }

        public void setAliyunBucketName(String aliyunBucketName) {
            this.aliyunBucketName = aliyunBucketName;
        }

        @Override
        public String toString() {
            return "aliYun{" +
                    "accessType=" + accessType +
                    ", aliyunDomain='" + aliyunDomain + '\'' +
                    ", aliyunPrefix='" + aliyunPrefix + '\'' +
                    ", aliyunEndPoint='" + aliyunEndPoint + '\'' +
                    ", aliyunAccessKeyId='" + aliyunAccessKeyId + '\'' +
                    ", aliyunAccessKeySecret='" + aliyunAccessKeySecret + '\'' +
                    ", aliyunBucketName='" + aliyunBucketName + '\'' +
                    '}';
        }
    }

    public static class qCloud {
        public String qcloudDomain;
        public String qcloudPrefix;
        public String qcloudSecretId;
        public String qcloudSecretKey;
        public String qcloudBucketName;

        public String getQcloudDomain() {
            return qcloudDomain;
        }

        public void setQcloudDomain(String qcloudDomain) {
            this.qcloudDomain = qcloudDomain;
        }

        public String getQcloudPrefix() {
            return qcloudPrefix;
        }

        public void setQcloudPrefix(String qcloudPrefix) {
            this.qcloudPrefix = qcloudPrefix;
        }

        public String getQcloudSecretId() {
            return qcloudSecretId;
        }

        public void setQcloudSecretId(String qcloudSecretId) {
            this.qcloudSecretId = qcloudSecretId;
        }

        public String getQcloudSecretKey() {
            return qcloudSecretKey;
        }

        public void setQcloudSecretKey(String qcloudSecretKey) {
            this.qcloudSecretKey = qcloudSecretKey;
        }

        public String getQcloudBucketName() {
            return qcloudBucketName;
        }

        public void setQcloudBucketName(String qcloudBucketName) {
            this.qcloudBucketName = qcloudBucketName;
        }

        @Override
        public String toString() {
            return "qCloud{" +
                    "qcloudDomain='" + qcloudDomain + '\'' +
                    ", qcloudPrefix='" + qcloudPrefix + '\'' +
                    ", qcloudSecretId='" + qcloudSecretId + '\'' +
                    ", qcloudSecretKey='" + qcloudSecretKey + '\'' +
                    ", qcloudBucketName='" + qcloudBucketName + '\'' +
                    '}';
        }
    }


    @Override
    public String toString() {
        return "OSSProperties{" +
                "ossType=" + ossType +
                ", ossCloud=" + ossCloud +
                '}';
    }
}
