Skip to content

Commit 64e10fa

Browse files
authored
Merge pull request #62 from aspose-pdf-cloud/develop
update to 23.10
2 parents 8957d39 + 9f7c969 commit 64e10fa

File tree

12 files changed

+472
-56
lines changed

12 files changed

+472
-56
lines changed

README.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,23 @@ XLS, XLSX, PPTX, DOC, DOCX, MobiXML, JPEG, EMF, PNG, BMP, GIF, TIFF, Text
3030
## Read PDF Formats
3131
MHT, PCL, PS, XSLFO, MD
3232

33-
## Enhancements in Version 23.9
34-
- Support to convert password protected PDF documents to PDFA.
33+
## Enhancements in Version 23.10
34+
- Support of reading common info of password protected PDF in GetDocument API.
35+
- Support stamp password protected document using DeleteDocumentStamps API method.
36+
- Support stamp password protected document using DeleteStamp API method.
37+
- Support stamp password protected document using PostDocumentPageNumberStamps API method.
38+
- Support stamp password protected document using PostPageImageStamps API method.
39+
- Support stamp password protected document using PostPageTextStamps API method.
40+
- Support stamp password protected document using GetPageStamps API method.
41+
- Support stamp password protected document using GetDocumentStamps API method.
42+
- Support stamp password protected document using PostPagePdfPageStamps API method.
43+
- Support stamp password protected document using DeletePageStamps API method.
44+
- Develop a method to add an attachment file to a PDF document.
3545
- A new version of Aspose.PDF Cloud was prepared using the latest version of Aspose.PDF for .NET.
3646

37-
## Bugs fixed in Version 23.9
38-
- Rotate Property not working with FreeTextAnnotation.
39-
- PutAnnotationsFlatten not working correctly when passing multiple annotation types.
47+
## Bugs fixed in Version 23.10
48+
- Aspose.PDF Cloud PostFlattenDocument API Issue.
49+
- The GetPages API throws timeout error for PDF files larger than 10 Mb.
4050

4151
## Requirements.
4252
Python 2.7 and 3.4+

asposepdfcloud/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
from .models.annotation_type import AnnotationType
3737
from .models.antialiasing_processing_type import AntialiasingProcessingType
3838
from .models.aspose_response import AsposeResponse
39+
from .models.attachment_info import AttachmentInfo
3940
from .models.border import Border
4041
from .models.border_corner_style import BorderCornerStyle
4142
from .models.border_effect import BorderEffect

asposepdfcloud/api_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ def __init__(self, app_key, app_sid, host=None):
8383
self.rest_client = RESTClientObject()
8484
self.default_headers = {}
8585
self.default_headers['x-aspose-client'] = 'python sdk'
86-
self.default_headers['x-aspose-client-version'] = '23.9.0'
86+
self.default_headers['x-aspose-client-version'] = '23.10.0'
8787

8888
self.app_key = app_key
8989
self.app_sid = app_sid

asposepdfcloud/apis/pdf_api.py

Lines changed: 164 additions & 9 deletions
Large diffs are not rendered by default.

asposepdfcloud/configuration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,5 +199,5 @@ def to_debug_report(self):
199199
"OS: {env}\n"\
200200
"Python Version: {pyversion}\n"\
201201
"Version of the API: 3.0\n"\
202-
"SDK Package Version: 23.9.0".\
202+
"SDK Package Version: 23.10.0".\
203203
format(env=sys.platform, pyversion=sys.version)

asposepdfcloud/models/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
from .annotation_type import AnnotationType
3737
from .antialiasing_processing_type import AntialiasingProcessingType
3838
from .aspose_response import AsposeResponse
39+
from .attachment_info import AttachmentInfo
3940
from .border import Border
4041
from .border_corner_style import BorderCornerStyle
4142
from .border_effect import BorderEffect
Lines changed: 229 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,229 @@
1+
# coding: utf-8
2+
3+
"""
4+
Aspose.PDF Cloud API Reference
5+
6+
7+
Copyright (c) 2023 Aspose.PDF Cloud
8+
Permission is hereby granted, free of charge, to any person obtaining a copy
9+
of this software and associated documentation files (the "Software"), to deal
10+
in the Software without restriction, including without limitation the rights
11+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12+
copies of the Software, and to permit persons to whom the Software is
13+
furnished to do so, subject to the following conditions:
14+
The above copyright notice and this permission notice shall be included in all
15+
copies or substantial portions of the Software.
16+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22+
SOFTWARE.
23+
24+
25+
26+
OpenAPI spec version: 3.0
27+
28+
"""
29+
30+
31+
from pprint import pformat
32+
from six import iteritems
33+
import re
34+
35+
36+
class AttachmentInfo(object):
37+
"""
38+
NOTE: This class is auto generated by the swagger code generator program.
39+
Do not edit the class manually.
40+
"""
41+
42+
43+
"""
44+
Attributes:
45+
swagger_types (dict): The key is attribute name
46+
and the value is attribute type.
47+
attribute_map (dict): The key is attribute name
48+
and the value is json key in definition.
49+
"""
50+
swagger_types = {
51+
'path': 'str',
52+
'description': 'str',
53+
'name': 'str',
54+
'mime_type': 'str'
55+
}
56+
57+
attribute_map = {
58+
'path': 'Path',
59+
'description': 'Description',
60+
'name': 'Name',
61+
'mime_type': 'MimeType'
62+
}
63+
64+
def __init__(self, path=None, description=None, name=None, mime_type=None):
65+
"""
66+
AttachmentInfo - a model defined in Swagger
67+
"""
68+
69+
self._path = None
70+
self._description = None
71+
self._name = None
72+
self._mime_type = None
73+
74+
self.path = path
75+
if description is not None:
76+
self.description = description
77+
if name is not None:
78+
self.name = name
79+
if mime_type is not None:
80+
self.mime_type = mime_type
81+
82+
@property
83+
def path(self):
84+
"""
85+
Gets the path of this AttachmentInfo.
86+
Attachment file path.
87+
88+
:return: The path of this AttachmentInfo.
89+
:rtype: str
90+
"""
91+
return self._path
92+
93+
@path.setter
94+
def path(self, path):
95+
"""
96+
Sets the path of this AttachmentInfo.
97+
Attachment file path.
98+
99+
:param path: The path of this AttachmentInfo.
100+
:type: str
101+
"""
102+
if path is None:
103+
raise ValueError("Invalid value for `path`, must not be `None`")
104+
if path is not None and len(path) < 1:
105+
raise ValueError("Invalid value for `path`, length must be greater than or equal to `1`")
106+
107+
self._path = path
108+
109+
@property
110+
def description(self):
111+
"""
112+
Gets the description of this AttachmentInfo.
113+
Attachment file description.
114+
115+
:return: The description of this AttachmentInfo.
116+
:rtype: str
117+
"""
118+
return self._description
119+
120+
@description.setter
121+
def description(self, description):
122+
"""
123+
Sets the description of this AttachmentInfo.
124+
Attachment file description.
125+
126+
:param description: The description of this AttachmentInfo.
127+
:type: str
128+
"""
129+
130+
self._description = description
131+
132+
@property
133+
def name(self):
134+
"""
135+
Gets the name of this AttachmentInfo.
136+
Attachment file name.
137+
138+
:return: The name of this AttachmentInfo.
139+
:rtype: str
140+
"""
141+
return self._name
142+
143+
@name.setter
144+
def name(self, name):
145+
"""
146+
Sets the name of this AttachmentInfo.
147+
Attachment file name.
148+
149+
:param name: The name of this AttachmentInfo.
150+
:type: str
151+
"""
152+
153+
self._name = name
154+
155+
@property
156+
def mime_type(self):
157+
"""
158+
Gets the mime_type of this AttachmentInfo.
159+
Attachment file MIME type.
160+
161+
:return: The mime_type of this AttachmentInfo.
162+
:rtype: str
163+
"""
164+
return self._mime_type
165+
166+
@mime_type.setter
167+
def mime_type(self, mime_type):
168+
"""
169+
Sets the mime_type of this AttachmentInfo.
170+
Attachment file MIME type.
171+
172+
:param mime_type: The mime_type of this AttachmentInfo.
173+
:type: str
174+
"""
175+
176+
self._mime_type = mime_type
177+
178+
def to_dict(self):
179+
"""
180+
Returns the model properties as a dict
181+
"""
182+
result = {}
183+
184+
for attr, _ in iteritems(self.swagger_types):
185+
value = getattr(self, attr)
186+
if isinstance(value, list):
187+
result[attr] = list(map(
188+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
189+
value
190+
))
191+
elif hasattr(value, "to_dict"):
192+
result[attr] = value.to_dict()
193+
elif isinstance(value, dict):
194+
result[attr] = dict(map(
195+
lambda item: (item[0], item[1].to_dict())
196+
if hasattr(item[1], "to_dict") else item,
197+
value.items()
198+
))
199+
else:
200+
result[attr] = value
201+
202+
return result
203+
204+
def to_str(self):
205+
"""
206+
Returns the string representation of the model
207+
"""
208+
return pformat(self.to_dict())
209+
210+
def __repr__(self):
211+
"""
212+
For `print` and `pprint`
213+
"""
214+
return self.to_str()
215+
216+
def __eq__(self, other):
217+
"""
218+
Returns true if both objects are equal
219+
"""
220+
if not isinstance(other, AttachmentInfo):
221+
return False
222+
223+
return self.__dict__ == other.__dict__
224+
225+
def __ne__(self, other):
226+
"""
227+
Returns true if both objects are not equal
228+
"""
229+
return not self == other

asposepdfcloud/models/page.py

Lines changed: 1 addition & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -50,32 +50,27 @@ class Page(object):
5050
swagger_types = {
5151
'links': 'list[Link]',
5252
'id': 'int',
53-
'images': 'Images',
5453
'rectangle': 'Rectangle'
5554
}
5655

5756
attribute_map = {
5857
'links': 'Links',
5958
'id': 'Id',
60-
'images': 'Images',
6159
'rectangle': 'Rectangle'
6260
}
6361

64-
def __init__(self, links=None, id=None, images=None, rectangle=None):
62+
def __init__(self, links=None, id=None, rectangle=None):
6563
"""
6664
Page - a model defined in Swagger
6765
"""
6866

6967
self._links = None
7068
self._id = None
71-
self._images = None
7269
self._rectangle = None
7370

7471
if links is not None:
7572
self.links = links
7673
self.id = id
77-
if images is not None:
78-
self.images = images
7974
if rectangle is not None:
8075
self.rectangle = rectangle
8176

@@ -127,29 +122,6 @@ def id(self, id):
127122

128123
self._id = id
129124

130-
@property
131-
def images(self):
132-
"""
133-
Gets the images of this Page.
134-
Page's images
135-
136-
:return: The images of this Page.
137-
:rtype: Images
138-
"""
139-
return self._images
140-
141-
@images.setter
142-
def images(self, images):
143-
"""
144-
Sets the images of this Page.
145-
Page's images
146-
147-
:param images: The images of this Page.
148-
:type: Images
149-
"""
150-
151-
self._images = images
152-
153125
@property
154126
def rectangle(self):
155127
"""

docs/AttachmentInfo.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# AttachmentInfo
2+
Attachment Info.
3+
4+
## Properties
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**path** | **str** | Attachment file path. |
8+
**description** | **str** | Attachment file description. | [optional]
9+
**name** | **str** | Attachment file name. | [optional]
10+
**mime_type** | **str** | Attachment file MIME type. | [optional]
11+
12+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
13+
14+

docs/Page.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
77
**links** | [**list[Link]**](Link.md) | Link to the document. | [optional]
88
**id** | **int** | Page&#39;s id. |
9-
**images** | [**Images**](Images.md) | Page&#39;s images | [optional]
109
**rectangle** | [**Rectangle**](Rectangle.md) | Page&#39;s rectangle | [optional]
1110

1211
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

0 commit comments

Comments
 (0)