Skip to content

Commit 458b140

Browse files
Merge pull request #4 from kaferi/master
Updated to v18.9
2 parents ffc1b6e + 76078bb commit 458b140

File tree

94 files changed

+4271
-2903
lines changed

Some content is hidden

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

94 files changed

+4271
-2903
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "asposepdfcloud",
3-
"version": "18.7.2",
3+
"version": "18.9.0",
44
"description": "Aspose.PDF Cloud SDK",
55
"homepage": "https://products.aspose.cloud/pdf/cloud",
66
"author": {

src/api/api.ts

Lines changed: 2618 additions & 1521 deletions
Large diffs are not rendered by default.

src/auth.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export class OAuth implements IAuthentication {
7171
const requestOptions: request.Options = {
7272
method: "POST",
7373
json: true,
74-
uri: configuration.baseUrl.replace("/v1.1", "") + "/oauth2/token",
74+
uri: configuration.baseUrl.replace("/v2.0", "") + "/oauth2/token",
7575
form: {
7676
grant_type: "client_credentials",
7777
client_id: configuration.appSID,
@@ -93,7 +93,7 @@ export class OAuth implements IAuthentication {
9393
const requestOptions: request.Options = {
9494
method: "POST",
9595
json: true,
96-
uri: configuration.baseUrl.replace("/v1.1", "") + "/oauth2/token",
96+
uri: configuration.baseUrl.replace("/v2.0", "") + "/oauth2/token",
9797
form: {
9898
grant_type: "refresh_token",
9999
refresh_token: this.refreshToken,

src/models/annotation.ts

Lines changed: 76 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,16 @@
1919
*
2020
*/
2121

22-
import { Color } from "./color";
22+
import { VerticalAlignment } from "./verticalAlignment";
23+
import { HorizontalAlignment } from "./horizontalAlignment";
24+
import { RectanglePdf } from "./rectanglePdf";
25+
import { AnnotationFlags } from "./annotationFlags";
2326
import { LinkElement } from "./linkElement";
2427

2528
/**
2629
* Provides annotation.
2730
*/
2831
export class Annotation extends LinkElement {
29-
/**
30-
* Get the annotation color.
31-
*/
32-
'color': Color;
3332
/**
3433
* Get the annotation content.
3534
*/
@@ -50,15 +49,42 @@ export class Annotation extends LinkElement {
5049
* The date and time when the annotation was last modified.
5150
*/
5251
'modified': string;
52+
/**
53+
* Gets ID of the annotation.
54+
*/
55+
'id': string;
56+
/**
57+
* Gets Flags of the annotation.
58+
*/
59+
'flags': Array<AnnotationFlags>;
60+
/**
61+
* Gets Name of the annotation.
62+
*/
63+
'name': string;
64+
/**
65+
* Gets Rect of the annotation.
66+
*/
67+
'rect': RectanglePdf;
68+
/**
69+
* Gets PageIndex of the annotation.
70+
*/
71+
'pageIndex': number;
72+
/**
73+
* Gets ZIndex of the annotation.
74+
*/
75+
'zIndex': number;
76+
/**
77+
* Gets HorizontalAlignment of the annotation.
78+
*/
79+
'horizontalAlignment': HorizontalAlignment;
80+
/**
81+
* Gets VerticalAlignment of the annotation.
82+
*/
83+
'verticalAlignment': VerticalAlignment;
5384

5485
static discriminator = undefined;
5586

5687
static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [
57-
{
58-
"name": "color",
59-
"baseName": "Color",
60-
"type": "Color"
61-
},
6288
{
6389
"name": "contents",
6490
"baseName": "Contents",
@@ -83,6 +109,46 @@ export class Annotation extends LinkElement {
83109
"name": "modified",
84110
"baseName": "Modified",
85111
"type": "string"
112+
},
113+
{
114+
"name": "id",
115+
"baseName": "Id",
116+
"type": "string"
117+
},
118+
{
119+
"name": "flags",
120+
"baseName": "Flags",
121+
"type": "Array<AnnotationFlags>"
122+
},
123+
{
124+
"name": "name",
125+
"baseName": "Name",
126+
"type": "string"
127+
},
128+
{
129+
"name": "rect",
130+
"baseName": "Rect",
131+
"type": "RectanglePdf"
132+
},
133+
{
134+
"name": "pageIndex",
135+
"baseName": "PageIndex",
136+
"type": "number"
137+
},
138+
{
139+
"name": "zIndex",
140+
"baseName": "ZIndex",
141+
"type": "number"
142+
},
143+
{
144+
"name": "horizontalAlignment",
145+
"baseName": "HorizontalAlignment",
146+
"type": "HorizontalAlignment"
147+
},
148+
{
149+
"name": "verticalAlignment",
150+
"baseName": "VerticalAlignment",
151+
"type": "VerticalAlignment"
86152
} ];
87153

88154
static getAttributeTypeMap() {

src/models/annotationFlags.ts

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
/**
2+
*
3+
* Copyright (c) 2018 Aspose.PDF Cloud
4+
* Permission is hereby granted, free of charge, to any person obtaining a copy
5+
* of this software and associated documentation files (the "Software"), to deal
6+
* in the Software without restriction, including without limitation the rights
7+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8+
* copies of the Software, and to permit persons to whom the Software is
9+
* furnished to do so, subject to the following conditions:
10+
* The above copyright notice and this permission notice shall be included in all
11+
* copies or substantial portions of the Software.
12+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18+
* SOFTWARE.
19+
*
20+
*/
21+
22+
export enum AnnotationFlags {
23+
Default = 'Default',
24+
Invisible = 'Invisible',
25+
Hidden = 'Hidden',
26+
Print = 'Print',
27+
NoZoom = 'NoZoom',
28+
NoRotate = 'NoRotate',
29+
NoView = 'NoView',
30+
ReadOnly = 'ReadOnly',
31+
Locked = 'Locked',
32+
ToggleNoView = 'ToggleNoView',
33+
LockedContents = 'LockedContents',
34+
}

src/models/annotationInfo.ts

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
/**
2+
*
3+
* Copyright (c) 2018 Aspose.PDF Cloud
4+
* Permission is hereby granted, free of charge, to any person obtaining a copy
5+
* of this software and associated documentation files (the "Software"), to deal
6+
* in the Software without restriction, including without limitation the rights
7+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8+
* copies of the Software, and to permit persons to whom the Software is
9+
* furnished to do so, subject to the following conditions:
10+
* The above copyright notice and this permission notice shall be included in all
11+
* copies or substantial portions of the Software.
12+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18+
* SOFTWARE.
19+
*
20+
*/
21+
22+
import { AnnotationType } from "./annotationType";
23+
import { Annotation } from "./annotation";
24+
25+
/**
26+
* Provides annotation.
27+
*/
28+
export class AnnotationInfo extends Annotation {
29+
/**
30+
* Gets annotation type.
31+
*/
32+
'annotationType': AnnotationType;
33+
34+
static discriminator = undefined;
35+
36+
static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [
37+
{
38+
"name": "annotationType",
39+
"baseName": "AnnotationType",
40+
"type": "AnnotationType"
41+
} ];
42+
43+
static getAttributeTypeMap() {
44+
return super.getAttributeTypeMap().concat(AnnotationInfo.attributeTypeMap);
45+
}
46+
}
47+
48+

src/models/annotationState.ts

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
/**
2+
*
3+
* Copyright (c) 2018 Aspose.PDF Cloud
4+
* Permission is hereby granted, free of charge, to any person obtaining a copy
5+
* of this software and associated documentation files (the "Software"), to deal
6+
* in the Software without restriction, including without limitation the rights
7+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8+
* copies of the Software, and to permit persons to whom the Software is
9+
* furnished to do so, subject to the following conditions:
10+
* The above copyright notice and this permission notice shall be included in all
11+
* copies or substantial portions of the Software.
12+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18+
* SOFTWARE.
19+
*
20+
*/
21+
22+
export enum AnnotationState {
23+
Undefined = 'Undefined',
24+
Marked = 'Marked',
25+
Unmarked = 'Unmarked',
26+
Accepted = 'Accepted',
27+
Rejected = 'Rejected',
28+
Cancelled = 'Cancelled',
29+
Completed = 'Completed',
30+
None = 'None',
31+
}

src/models/annotationType.ts

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
/**
2+
*
3+
* Copyright (c) 2018 Aspose.PDF Cloud
4+
* Permission is hereby granted, free of charge, to any person obtaining a copy
5+
* of this software and associated documentation files (the "Software"), to deal
6+
* in the Software without restriction, including without limitation the rights
7+
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8+
* copies of the Software, and to permit persons to whom the Software is
9+
* furnished to do so, subject to the following conditions:
10+
* The above copyright notice and this permission notice shall be included in all
11+
* copies or substantial portions of the Software.
12+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18+
* SOFTWARE.
19+
*
20+
*/
21+
22+
export enum AnnotationType {
23+
Text = 'Text',
24+
Circle = 'Circle',
25+
Polygon = 'Polygon',
26+
PolyLine = 'PolyLine',
27+
Line = 'Line',
28+
Square = 'Square',
29+
FreeText = 'FreeText',
30+
Highlight = 'Highlight',
31+
Underline = 'Underline',
32+
Squiggly = 'Squiggly',
33+
StrikeOut = 'StrikeOut',
34+
Caret = 'Caret',
35+
Ink = 'Ink',
36+
Link = 'Link',
37+
Popup = 'Popup',
38+
FileAttachment = 'FileAttachment',
39+
Sound = 'Sound',
40+
Movie = 'Movie',
41+
Screen = 'Screen',
42+
Widget = 'Widget',
43+
Watermark = 'Watermark',
44+
TrapNet = 'TrapNet',
45+
PrinterMark = 'PrinterMark',
46+
Redaction = 'Redaction',
47+
Stamp = 'Stamp',
48+
RichMedia = 'RichMedia',
49+
Unknown = 'Unknown',
50+
PDF3D = 'PDF3D',
51+
}

src/models/annotations.ts renamed to src/models/annotationsInfo.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,25 +19,26 @@
1919
*
2020
*/
2121

22+
import { AnnotationInfo } from "./annotationInfo";
2223
import { LinkElement } from "./linkElement";
2324

2425
/**
2526
* List of annotations.
2627
*/
27-
export class Annotations extends LinkElement {
28-
'list': Array<LinkElement>;
28+
export class AnnotationsInfo extends LinkElement {
29+
'list': Array<AnnotationInfo>;
2930

3031
static discriminator = undefined;
3132

3233
static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [
3334
{
3435
"name": "list",
3536
"baseName": "List",
36-
"type": "Array<LinkElement>"
37+
"type": "Array<AnnotationInfo>"
3738
} ];
3839

3940
static getAttributeTypeMap() {
40-
return super.getAttributeTypeMap().concat(Annotations.attributeTypeMap);
41+
return super.getAttributeTypeMap().concat(AnnotationsInfo.attributeTypeMap);
4142
}
4243
}
4344

src/models/annotationsResponse.ts renamed to src/models/annotationsInfoResponse.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,23 +19,23 @@
1919
*
2020
*/
2121

22-
import { Annotations } from "./annotations";
23-
import { SaaSposeResponse } from "./saaSposeResponse";
22+
import { AnnotationsInfo } from "./annotationsInfo";
23+
import { AsposeResponse } from "./asposeResponse";
2424

25-
export class AnnotationsResponse extends SaaSposeResponse {
26-
'annotations': Annotations;
25+
export class AnnotationsInfoResponse extends AsposeResponse {
26+
'annotations': AnnotationsInfo;
2727

2828
static discriminator = undefined;
2929

3030
static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [
3131
{
3232
"name": "annotations",
3333
"baseName": "Annotations",
34-
"type": "Annotations"
34+
"type": "AnnotationsInfo"
3535
} ];
3636

3737
static getAttributeTypeMap() {
38-
return super.getAttributeTypeMap().concat(AnnotationsResponse.attributeTypeMap);
38+
return super.getAttributeTypeMap().concat(AnnotationsInfoResponse.attributeTypeMap);
3939
}
4040
}
4141

0 commit comments

Comments
 (0)