|
@@ -5,15 +5,16 @@ import org.springframework.stereotype.Component;
|
|
|
|
|
|
@Component
|
|
|
public class UpYunProperty {
|
|
|
+
|
|
|
+ @Value("${$upyun.site.1.domain}")
|
|
|
+ protected String domain;
|
|
|
+
|
|
|
@Value("${$upyun.site.1.bucketName}")
|
|
|
protected String bucketName;
|
|
|
|
|
|
@Value("${$upyun.site.1.userName}")
|
|
|
protected String userName;
|
|
|
|
|
|
- @Value("${$upyun.site.1.domain}")
|
|
|
- protected String domain;
|
|
|
-
|
|
|
@Value("${$upyun.site.1.password}")
|
|
|
protected String password;
|
|
|
|
|
@@ -35,8 +36,25 @@ public class UpYunProperty {
|
|
|
@Value("${upyun.zipDirectory}")
|
|
|
private String zipDirectory;
|
|
|
|
|
|
+ @Value("${question.reduplicate.similarity}")
|
|
|
+ private Double reduplicateSimilarity;
|
|
|
+
|
|
|
+ public String getDomain() {
|
|
|
+ if (domain != null) {
|
|
|
+ return domain.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setDomain(String domain) {
|
|
|
+ this.domain = domain;
|
|
|
+ }
|
|
|
+
|
|
|
public String getBucketName() {
|
|
|
- return bucketName;
|
|
|
+ if (bucketName != null) {
|
|
|
+ return bucketName.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setBucketName(String bucketName) {
|
|
@@ -44,23 +62,21 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getUserName() {
|
|
|
- return userName;
|
|
|
+ if (userName != null) {
|
|
|
+ return userName.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setUserName(String userName) {
|
|
|
this.userName = userName;
|
|
|
}
|
|
|
|
|
|
- public String getDomain() {
|
|
|
- return domain;
|
|
|
- }
|
|
|
-
|
|
|
- public void setDomain(String domain) {
|
|
|
- this.domain = domain;
|
|
|
- }
|
|
|
-
|
|
|
public String getPassword() {
|
|
|
- return password;
|
|
|
+ if (password != null) {
|
|
|
+ return password.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setPassword(String password) {
|
|
@@ -68,7 +84,10 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getUploadPath() {
|
|
|
- return uploadPath;
|
|
|
+ if (uploadPath != null) {
|
|
|
+ return uploadPath.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setUploadPath(String uploadPath) {
|
|
@@ -76,7 +95,10 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getRadioUploadPath() {
|
|
|
- return radioUploadPath;
|
|
|
+ if (radioUploadPath != null) {
|
|
|
+ return radioUploadPath.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setRadioUploadPath(String radioUploadPath) {
|
|
@@ -84,7 +106,10 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getRadioType() {
|
|
|
- return radioType;
|
|
|
+ if (radioType != null) {
|
|
|
+ return radioType.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setRadioType(String radioType) {
|
|
@@ -92,7 +117,10 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getAudioMaxsize() {
|
|
|
- return audioMaxsize;
|
|
|
+ if (audioMaxsize != null) {
|
|
|
+ return audioMaxsize.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setAudioMaxsize(String audioMaxsize) {
|
|
@@ -100,7 +128,10 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getDownloadDirectory() {
|
|
|
- return downloadDirectory;
|
|
|
+ if (downloadDirectory != null) {
|
|
|
+ return downloadDirectory.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setDownloadDirectory(String downloadDirectory) {
|
|
@@ -108,10 +139,22 @@ public class UpYunProperty {
|
|
|
}
|
|
|
|
|
|
public String getZipDirectory() {
|
|
|
- return zipDirectory;
|
|
|
+ if (zipDirectory != null) {
|
|
|
+ return zipDirectory.trim();
|
|
|
+ }
|
|
|
+ return "";
|
|
|
}
|
|
|
|
|
|
public void setZipDirectory(String zipDirectory) {
|
|
|
this.zipDirectory = zipDirectory;
|
|
|
}
|
|
|
+
|
|
|
+ public Double getReduplicateSimilarity() {
|
|
|
+ return reduplicateSimilarity;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setReduplicateSimilarity(Double reduplicateSimilarity) {
|
|
|
+ this.reduplicateSimilarity = reduplicateSimilarity;
|
|
|
+ }
|
|
|
+
|
|
|
}
|