com.github.xiaoyuge5201.props.CloopenSMSProperties Maven / Gradle / Ivy
The newest version!
package com.github.xiaoyuge5201.props;
import org.springframework.boot.context.properties.ConfigurationProperties;
import java.time.Duration;
/**
* 容联云---短信配置
*/
@ConfigurationProperties("sms.cloopen")
public class CloopenSMSProperties {
/**
* 短信服务器地址
*/
private String smsServer = "app.cloopen.com";
/**
* 短信服务器端口
*/
private String serverPort = "8883";
/**
* 云通讯主账号名Sid
*/
private String sid;
/**
* 云通讯令牌Token
*/
private String token;
/**
* 云通讯Appid
*/
private String appId;
private boolean enable = true;
/**
* 连接过期时间
*/
private Duration connectionTimeout = Duration.ofSeconds(120);
public String getSmsServer() {
return smsServer;
}
public void setSmsServer(String smsServer) {
this.smsServer = smsServer;
}
public String getServerPort() {
return serverPort;
}
public void setServerPort(String serverPort) {
this.serverPort = serverPort;
}
public String getSid() {
return sid;
}
public void setSid(String sid) {
this.sid = sid;
}
public String getToken() {
return token;
}
public void setToken(String token) {
this.token = token;
}
public String getAppId() {
return appId;
}
public void setAppId(String appId) {
this.appId = appId;
}
public Duration getConnectionTimeout() {
return connectionTimeout;
}
public void setConnectionTimeout(Duration connectionTimeout) {
this.connectionTimeout = connectionTimeout;
}
public boolean isEnable() {
return enable;
}
public void setEnable(boolean enable) {
this.enable = enable;
}
@Override
public String toString() {
return "CloopenSMSProperties{" +
"smsServer='" + smsServer + '\'' +
", serverPort='" + serverPort + '\'' +
", sid='" + sid + '\'' +
", token='" + token + '\'' +
", appId='" + appId + '\'' +
", enable=" + enable +
", connectionTimeout=" + connectionTimeout +
'}';
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy