Skip to content

Commit b5fa35e

Browse files
Merge remote-tracking branch 'origin/master' into release
2 parents 055cd27 + 0f3cf77 commit b5fa35e

File tree

387 files changed

+3761
-3474
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

387 files changed

+3761
-3474
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,4 @@ Settings/servercreds.json
2929

3030
# VS Code
3131
.vs/*
32+
.vscode

Jenkinsfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ def runtests(directory)
2626
sh 'git clean -fdx'
2727

2828
if (needToBuild) {
29-
withCredentials([usernamePassword(credentialsId: '6839cbe8-39fa-40c0-86ce-90706f0bae5d', passwordVariable: 'AppKey', usernameVariable: 'AppSid')]) {
29+
withCredentials([usernamePassword(credentialsId: '6839cbe8-39fa-40c0-86ce-90706f0bae5d', passwordVariable: 'ClientSecret', usernameVariable: 'ClientId')]) {
3030
sh 'mkdir -p Settings'
31-
sh 'echo "{\\"AppSid\\": \\"$AppSid\\",\\"AppKey\\": \\"$AppKey\\", \\"BaseUrl\\": \\"$apiUrl\\", \\"Debug\\" : \\"$debugMode\\" }}" > Settings/servercreds.json'
31+
sh 'echo "{\\"ClientId\\": \\"$ClientId\\",\\"ClientSecret\\": \\"$ClientSecret\\", \\"BaseUrl\\": \\"$apiUrl\\", \\"Debug\\" : \\"$debugMode\\" }}" > Settings/servercreds.json'
3232
}
3333
}
3434
}

JenkinsfileRelease

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ node('words-linux') {
2323
stage('1:checkout'){
2424
if (params.StartFromStep.toInteger() < 2) {
2525
checkout([$class: 'GitSCM', branches: [[name: '*/release']], doGenerateSubmoduleConfigurations: false, extensions: [[$class: 'LocalBranch', localBranch: "**"]], submoduleCfg: [], userRemoteConfigs: [[credentialsId: '361885ba-9425-4230-950e-0af201d90547', url: 'https://git.auckland.dynabic.com/words-cloud/words-cloud-java.git']]])
26-
withCredentials([usernamePassword(credentialsId: '6839cbe8-39fa-40c0-86ce-90706f0bae5d', passwordVariable: 'AppKey', usernameVariable: 'AppSid')]) {
26+
withCredentials([usernamePassword(credentialsId: '6839cbe8-39fa-40c0-86ce-90706f0bae5d', passwordVariable: 'ClientSecret', usernameVariable: 'ClientId')]) {
2727
sh 'git checkout release'
2828
sh 'mkdir -p Settings'
29-
sh 'echo "{\\"AppSid\\": \\"$AppSid\\",\\"AppKey\\": \\"$AppKey\\", \\"BaseUrl\\": \\"https://auckland-words-cloud-staging.dynabic.com\\"}" > Settings/servercreds.json'
29+
sh 'echo "{\\"ClientId\\": \\"$ClientId\\",\\"ClientSecret\\": \\"$ClientSecret\\", \\"BaseUrl\\": \\"https://auckland-words-cloud-staging.dynabic.com\\"}" > Settings/servercreds.json'
3030
sh "git config user.email \"[email protected]\""
3131
sh "git config user.name \"jenkins\""
3232
}
@@ -41,9 +41,9 @@ node('words-linux') {
4141
withCredentials([usernamePassword(credentialsId: '361885ba-9425-4230-950e-0af201d90547', passwordVariable: 'gitPass', usernameVariable: 'gitUsername')]) {
4242
docker.image('maven:3.6.2-jdk-8').inside{
4343
stage('deploy'){
44-
withCredentials([usernamePassword(credentialsId: '6839cbe8-39fa-40c0-86ce-90706f0bae5d', passwordVariable: 'AppKey', usernameVariable: 'AppSid')]) {
44+
withCredentials([usernamePassword(credentialsId: '6839cbe8-39fa-40c0-86ce-90706f0bae5d', passwordVariable: 'ClientSecret', usernameVariable: 'ClientId')]) {
4545
sh 'mkdir -p Settings'
46-
sh 'echo "{\\"AppSid\\": \\"$AppSid\\",\\"AppKey\\": \\"$AppKey\\", \\"BaseUrl\\": \\"$testServerUrl\\"}" > Settings/servercreds.json'
46+
sh 'echo "{\\"ClientId\\": \\"$ClientId\\",\\"ClientSecret\\": \\"$ClientSecret\\", \\"BaseUrl\\": \\"$testServerUrl\\"}" > Settings/servercreds.json'
4747
}
4848
sh 'cat wordsSettings.xml'
4949
sh "mvn --settings wordsSettings.xml deploy -Dmaven.javadoc.skip=true -DcheckModificationExcludeList=wordsSettings.xml,Settings/servercreds.json"

README.md

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,17 @@ This repository contains Aspose.Words Cloud SDK for Java source code. This SDK a
1313
* Watermarks and protection
1414
* Full read & write access to Document Object Model, including sections, paragraphs, text, images, tables, headers/footers and many others
1515

16+
## Enhancements in Version 20.11
17+
18+
- In configuration json file appSid / appKey has been replaced to clientId / clientSecret.
19+
- In Words API initialization methods clientId parameter precedes clientSecret parameter.
20+
21+
22+
## Enhancements in Version 20.10
23+
24+
- Internal API changes.
25+
26+
1627
## Enhancements in Version 20.9
1728

1829
- Added Batch API feature
@@ -101,7 +112,7 @@ Add this dependency to your project's POM:
101112
<dependency>
102113
<groupId>com.aspose</groupId>
103114
<artifactId>aspose-words-cloud</artifactId>
104-
<version>20.10.0</version>
115+
<version>20.11.0</version>
105116
</dependency>
106117
</dependencies>
107118
```
@@ -112,7 +123,7 @@ Add this dependency to your project's POM:
112123
// Start README example
113124

114125
// if baseUrl is null, WordsApi uses default https://api.aspose.cloud
115-
WordsApi wordsApi = new WordsApi(appSid, appKey, baseUrl);
126+
WordsApi wordsApi = new WordsApi(clientId, clientSecret, baseUrl);
116127

117128
String localPath = PathUtil.get(localFolder, fileName);
118129
String remotePath = PathUtil.get(remoteFolder, remoteName);

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<artifactId>aspose-words-cloud</artifactId>
55
<packaging>jar</packaging>
66
<name>AsposeWordsCloud</name>
7-
<version>20.10.0</version>
7+
<version>20.11.0</version>
88
<url>https://www.aspose.cloud/</url>
99
<description>Aspose Words Java SDK</description>
1010
<scm>

src/main/java/com/aspose/words/cloud/ApiClient.java

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public class ApiClient {
5656
private String apiVersion = "v4.0";
5757
private String baseUrl = "https://api.aspose.cloud";
5858
private String basePath = baseUrl + "/" + apiVersion;
59-
private String clientVersion = "20.10";
59+
private String clientVersion = "20.11";
6060
private boolean debugging = false;
6161
private Map<String, String> defaultHeaderMap = new HashMap<String, String>();
6262
private String tempFolderPath = null;
@@ -70,13 +70,13 @@ public class ApiClient {
7070

7171
private String accessToken;
7272
private String refreshToken;
73-
private String appKey;
74-
private String appSid;
73+
private String ClientSecret;
74+
private String clientId;
7575

76-
public ApiClient(String appSid, String appKey, String baseUrl) {
76+
public ApiClient(String clientId, String clientSecret, String baseUrl) {
7777
this();
78-
this.appSid = appSid;
79-
this.appKey = appKey;
78+
this.clientId = clientId;
79+
this.ClientSecret = clientSecret;
8080
if (baseUrl != null) {
8181
this.setBaseUrl(baseUrl);
8282
}
@@ -92,7 +92,7 @@ public ApiClient() {
9292
json = new JSON();
9393

9494
// Set default User-Agent.
95-
setUserAgent("Swagger-Codegen/1.0.0/java");
95+
setUserAgent("Swagger-Codegen/1.0.0/java");
9696
addDefaultHeader("x-aspose-client", "java sdk");
9797
addDefaultHeader("x-aspose-client-version", clientVersion);
9898
setConnectTimeout(5 * 60 * 1000);
@@ -102,7 +102,7 @@ public ApiClient() {
102102
/**
103103
* Get NotAuth http code
104104
*
105-
* @return App Key
105+
* @return NotAuth http code
106106
*/
107107
public Integer getNotAuthCode() {
108108
return notAuthCode;
@@ -111,49 +111,49 @@ public Integer getNotAuthCode() {
111111
/**
112112
* Get BadRequest http code
113113
*
114-
* @return App Key
114+
* @return BadRequest http code
115115
*/
116116
public Integer getBadRequestCode() {
117117
return badRequestCode;
118118
}
119119

120-
/**
121-
* Get App Key
120+
/**
121+
* Get client ID
122122
*
123-
* @return App Key
123+
* @return client ID
124124
*/
125-
public String getAppKey() {
126-
return appKey;
125+
public String getClientId() {
126+
return clientId;
127127
}
128128

129129
/**
130-
* Set App Key
130+
* Set client ID
131131
*
132-
* @param appKey App Key
132+
* @param clientId client ID
133133
* @return An instance of OkHttpClient
134134
*/
135-
public ApiClient setAppKey(String appKey) {
136-
this.appKey = appKey;
135+
public ApiClient setClientId(String clientId) {
136+
this.clientId = clientId;
137137
return this;
138138
}
139139

140-
/**
141-
* Get App Sid
140+
/**
141+
* Get client secret
142142
*
143-
* @return App Sid
143+
* @return client secret
144144
*/
145-
public String getAppSid() {
146-
return appSid;
145+
public String getClientSecret() {
146+
return ClientSecret;
147147
}
148148

149149
/**
150-
* Set App Sid
150+
* Set client secret
151151
*
152-
* @param appSid App Sid
152+
* @param clientSecret client secret
153153
* @return An instance of OkHttpClient
154154
*/
155-
public ApiClient setAppSid(String appSid) {
156-
this.appSid = appSid;
155+
public ApiClient setClientSecret(String clientSecret) {
156+
this.ClientSecret = clientSecret;
157157
return this;
158158
}
159159

@@ -1125,8 +1125,8 @@ public void requestToken() throws ApiException {
11251125
try {
11261126
RequestBody requestBody = new FormEncodingBuilder()
11271127
.addEncoded("grant_type", "client_credentials")
1128-
.addEncoded("client_id", getAppSid())
1129-
.addEncoded("client_secret", getAppKey())
1128+
.addEncoded("client_id", getClientId())
1129+
.addEncoded("client_secret", getClientSecret())
11301130
.build();
11311131

11321132
String url = baseUrl + "/connect/token";

0 commit comments

Comments
 (0)