Skip to content

Commit 30fcf8e

Browse files
Merge pull request #22 from kaferi/master
Update to v19.9
2 parents e6ed3b2 + a1c4b84 commit 30fcf8e

File tree

2 files changed

+484
-468
lines changed

2 files changed

+484
-468
lines changed

src/main/java/com/aspose/asposecloudpdf/ApiClient.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -531,6 +531,22 @@ public String escapeString(String str) {
531531
return str;
532532
}
533533
}
534+
535+
/**
536+
* Escape the given string to be used as URL segment value.
537+
*
538+
* @param str String to be escaped
539+
* @return Escaped string
540+
*/
541+
public String escapePathSegmentString(String str) {
542+
try {
543+
return URLEncoder.encode(str, "utf8")
544+
.replaceAll("\\+", "%20")
545+
.replaceAll("%2F", "/");
546+
} catch (UnsupportedEncodingException e) {
547+
return str;
548+
}
549+
}
534550

535551
/**
536552
* Deserialize response body to Java object, according to the return type and

0 commit comments

Comments
 (0)