use of com.zhouzifei.tool.config.XmlyFileProperties in project simpleFS by shengdingbox.
the class XMLYApiClient method init.
@Override
public XMLYApiClient init(FileProperties fileProperties) {
final XmlyFileProperties xmlyFileProperties = fileProperties.getXmly();
String xmlyCookie = xmlyFileProperties.getCookies();
if (StringUtils.isEmpty(xmlyCookie)) {
// if(!(Boolean) jsonObject.get("success")){
throw new ServiceException("[" + this.storageType + "]初始化失败");
// }
// final JSONObject data = (JSONObject)jsonObject.get("data");
// final Object token1 = data.get("token");
// XMLYApiClient.token = (String) token1;
} else {
XMLYApiClient.token = "1&_token=" + xmlyCookie + ";&" + xmlyCookie;
}
return this;
}
Aggregations