com.zopen.aliyun.vod.dto.AliyunVodStsResp Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zopen-ato-starter Show documentation
Show all versions of zopen-ato-starter Show documentation
Alibaba Tencent And Others For Spring Boot.
package com.zopen.aliyun.vod.dto;
import com.aliyuncs.sts.model.v20150401.AssumeRoleResponse;
import com.zopen.ato.properties.AliyunVodProperties;
/**
* STS临时AK
*
* @author [email protected]
* @since 2020/5/20
*/
public class AliyunVodStsResp {
private String regionId = AliyunVodProperties.REGION_ID;
private String securityToken;
private String accessKeyId;
private String accessKeySecret;
public AliyunVodStsResp(AssumeRoleResponse assumeRoleResponse) {
if (assumeRoleResponse != null && assumeRoleResponse.getCredentials() != null) {
this.securityToken = assumeRoleResponse.getCredentials().getSecurityToken();
this.accessKeyId = assumeRoleResponse.getCredentials().getAccessKeyId();
this.accessKeySecret = assumeRoleResponse.getCredentials().getAccessKeySecret();
}
}
public String getSecurityToken() {
return securityToken;
}
public String getRegionId() {
return regionId;
}
public void setRegionId(String regionId) {
this.regionId = regionId;
}
public void setSecurityToken(String securityToken) {
this.securityToken = securityToken;
}
public String getAccessKeyId() {
return accessKeyId;
}
public void setAccessKeyId(String accessKeyId) {
this.accessKeyId = accessKeyId;
}
public String getAccessKeySecret() {
return accessKeySecret;
}
public void setAccessKeySecret(String accessKeySecret) {
this.accessKeySecret = accessKeySecret;
}
}