Skip to content

Commit dc01950

Browse files
committed
Release Aspose.Cells Cloud SDK 21.8
1 parent c0dd630 commit dc01950

16 files changed

+571
-38
lines changed

README.md

+3-4
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,10 @@ Python Cloud SDK wraps Aspose.Cells REST API so you could seamlessly integrate M
2121
- Convert worksheets to PDF, XPS & SVG formats.
2222
- Inter-convert files to popular Excel formats.
2323

24-
## Feature & Enhancements in Version 21.7
24+
## Feature & Enhancements in Version 21.8
2525

26-
- Fix search API.
27-
- Fix split API.
28-
- Fix update metadata API.
26+
- Improvement for getting list object Api.
27+
- Add import Api
2928

3029
## Read & Write Spreadsheet Formats
3130

asposecellscloud/__init__.py

+1
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@
177177
from .models.import_data_task_parameter import ImportDataTaskParameter
178178
from .models.import_double_array_option import ImportDoubleArrayOption
179179
from .models.import_int_array_option import ImportIntArrayOption
180+
from .models.import_picture_option import ImportPictureOption
180181
from .models.import_string_array_option import ImportStringArrayOption
181182
from .models.legend_response import LegendResponse
182183
from .models.line_format import LineFormat

asposecellscloud/api_client.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ def __init__(self, host=None, header_name=None, header_value=None, cookie=None):
8383
self.host = host
8484
self.cookie = cookie
8585
# Set default User-Agent.
86-
self.user_agent = 'Swagger-Codegen/21.7/python'
86+
self.user_agent = 'Swagger-Codegen/21.8/python'
8787

8888
@property
8989
def user_agent(self):

asposecellscloud/apis/cells_api.py

+10-6
Original file line numberDiff line numberDiff line change
@@ -8100,9 +8100,10 @@ def cells_list_objects_get_worksheet_list_object(self, name, sheet_name, listobj
81008100
:param str name: Document name. (required)
81018101
:param str sheet_name: The worksheet name. (required)
81028102
:param int listobjectindex: list object index. (required)
8103+
:param str format: export format.
81038104
:param str folder: Document's folder.
81048105
:param str storage_name: storage name.
8105-
:return: ListObjectResponse
8106+
:return: file
81068107
If the method is called asynchronously,
81078108
returns the request thread.
81088109
"""
@@ -8130,14 +8131,15 @@ def cells_list_objects_get_worksheet_list_object_with_http_info(self, name, shee
81308131
:param str name: Document name. (required)
81318132
:param str sheet_name: The worksheet name. (required)
81328133
:param int listobjectindex: list object index. (required)
8134+
:param str format: export format.
81338135
:param str folder: Document's folder.
81348136
:param str storage_name: storage name.
8135-
:return: ListObjectResponse
8137+
:return: file
81368138
If the method is called asynchronously,
81378139
returns the request thread.
81388140
"""
81398141

8140-
all_params = ['name', 'sheet_name', 'listobjectindex', 'folder', 'storage_name']
8142+
all_params = ['name', 'sheet_name', 'listobjectindex', 'format', 'folder', 'storage_name']
81418143
all_params.append('callback')
81428144
all_params.append('_return_http_data_only')
81438145
all_params.append('_preload_content')
@@ -8174,6 +8176,8 @@ def cells_list_objects_get_worksheet_list_object_with_http_info(self, name, shee
81748176
path_params['listobjectindex'] = params['listobjectindex']
81758177

81768178
query_params = []
8179+
if 'format' in params:
8180+
query_params.append(('format', params['format']))
81778181
if 'folder' in params:
81788182
query_params.append(('folder', params['folder']))
81798183
if 'storage_name' in params:
@@ -8203,7 +8207,7 @@ def cells_list_objects_get_worksheet_list_object_with_http_info(self, name, shee
82038207
body=body_params,
82048208
post_params=form_params,
82058209
files=local_var_files,
8206-
response_type='ListObjectResponse',
8210+
response_type='file',
82078211
auth_settings=auth_settings,
82088212
callback=params.get('callback'),
82098213
_return_http_data_only=params.get('_return_http_data_only'),
@@ -26535,7 +26539,7 @@ def cells_workbook_put_convert_workbook_with_http_info(self, file, **kwargs):
2653526539
for filename , filecontext in params['file'].items():
2653626540
local_var_files[filename] = filecontext
2653726541
else:
26538-
local_var_files['File'] = params['file']
26542+
local_var_files['file'] = params['file']
2653926543

2654026544

2654126545
body_params = None
@@ -33719,7 +33723,7 @@ def upload_file_with_http_info(self, path, file, **kwargs):
3371933723
for filename , filecontext in params['file'].items():
3372033724
local_var_files[filename] = filecontext
3372133725
else:
33722-
local_var_files['File'] = params['file']
33726+
local_var_files['file'] = params['file']
3372333727

3372433728

3372533729
body_params = None

asposecellscloud/apis/lite_cells_api.py

+116
Original file line numberDiff line numberDiff line change
@@ -663,6 +663,122 @@ def post_export_with_http_info(self, file, object_type, format, **kwargs):
663663
_request_timeout=params.get('_request_timeout'),
664664
collection_formats=collection_formats)
665665

666+
def post_import(self, file, import_data, **kwargs):
667+
"""
668+
This method makes a synchronous HTTP request by default. To make an
669+
asynchronous HTTP request, please define a `callback` function
670+
to be invoked when receiving the response.
671+
>>> def callback_function(response):
672+
>>> pprint(response)
673+
>>>
674+
>>> thread = api.post_import(file, import_data, callback=callback_function)
675+
676+
:param callback function: The callback function
677+
for asynchronous request. (optional)
678+
:param file file: File to upload (required)
679+
:param ImportOption import_data: (required)
680+
:return: FilesResult
681+
If the method is called asynchronously,
682+
returns the request thread.
683+
"""
684+
kwargs['_return_http_data_only'] = True
685+
self.check_access_token()
686+
if kwargs.get('callback'):
687+
return self.post_import_with_http_info(file, import_data, **kwargs)
688+
else:
689+
(data) = self.post_import_with_http_info(file, import_data, **kwargs)
690+
return data
691+
692+
def post_import_with_http_info(self, file, import_data, **kwargs):
693+
"""
694+
This method makes a synchronous HTTP request by default. To make an
695+
asynchronous HTTP request, please define a `callback` function
696+
to be invoked when receiving the response.
697+
>>> def callback_function(response):
698+
>>> pprint(response)
699+
>>>
700+
>>> thread = api.post_import_with_http_info(file, import_data, callback=callback_function)
701+
702+
:param callback function: The callback function
703+
for asynchronous request. (optional)
704+
:param file file: File to upload (required)
705+
:param ImportOption import_data: (required)
706+
:return: FilesResult
707+
If the method is called asynchronously,
708+
returns the request thread.
709+
"""
710+
711+
all_params = ['file', 'import_data']
712+
all_params.append('callback')
713+
all_params.append('_return_http_data_only')
714+
all_params.append('_preload_content')
715+
all_params.append('_request_timeout')
716+
717+
params = locals()
718+
for key, val in iteritems(params['kwargs']):
719+
if key not in all_params:
720+
raise TypeError(
721+
"Got an unexpected keyword argument '%s'"
722+
" to method post_import" % key
723+
)
724+
params[key] = val
725+
del params['kwargs']
726+
# verify the required parameter 'file' is set
727+
if ('file' not in params) or (params['file'] is None):
728+
raise ValueError("Missing the required parameter `file` when calling `post_import`")
729+
# verify the required parameter 'import_data' is set
730+
if ('import_data' not in params) or (params['import_data'] is None):
731+
raise ValueError("Missing the required parameter `import_data` when calling `post_import`")
732+
733+
734+
collection_formats = {}
735+
736+
path_params = {}
737+
738+
query_params = []
739+
740+
header_params = {}
741+
742+
form_params = []
743+
local_var_files = {}
744+
if 'file' in params:
745+
746+
if isinstance(params['file'],dict):
747+
for filename , filecontext in params['file'].items():
748+
local_var_files[filename] = filecontext
749+
else:
750+
local_var_files['file'] = params['file']
751+
752+
753+
body_params = None
754+
if 'import_data' in params:
755+
body_params = params['import_data']
756+
# HTTP header `Accept`
757+
header_params['Accept'] = self.api_client.\
758+
select_header_accept(['application/json'])
759+
760+
# HTTP header `Content-Type`
761+
header_params['Content-Type'] = self.api_client.\
762+
select_header_content_type(['multipart/form-data'])
763+
764+
# Authentication setting
765+
auth_settings = []
766+
767+
return self.api_client.call_api('/cells/import', 'POST',
768+
path_params,
769+
query_params,
770+
header_params,
771+
body=body_params,
772+
post_params=form_params,
773+
files=local_var_files,
774+
response_type='FilesResult',
775+
auth_settings=auth_settings,
776+
callback=params.get('callback'),
777+
_return_http_data_only=params.get('_return_http_data_only'),
778+
_preload_content=params.get('_preload_content', True),
779+
_request_timeout=params.get('_request_timeout'),
780+
collection_formats=collection_formats)
781+
666782
def post_merge(self, file, **kwargs):
667783
"""
668784
This method makes a synchronous HTTP request by default. To make an

asposecellscloud/configuration.py

+2-4
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,6 @@ def __init__(self):
101101

102102
# Proxy URL
103103
self.proxy = None
104-
# self.proxy = 'https://127.0.0.1:8888'
105-
# self.ssl_ca_cert = 'C://projects//FiddlerRoot.pem'
106104
# Safe chars for path_param
107105
self.safe_chars_for_path_param = '/'
108106

@@ -256,6 +254,6 @@ def to_debug_report(self):
256254
return "Python SDK Debug Report:\n"\
257255
"OS: {env}\n"\
258256
"Python Version: {pyversion}\n"\
259-
"Version of the API: 21.7\n"\
260-
"SDK Package Version: 21.7".\
257+
"Version of the API: 3.0\n"\
258+
"SDK Package Version: 21.8".\
261259
format(env=sys.platform, pyversion=sys.version)

asposecellscloud/models/__init__.py

+1
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@
177177
from .import_data_task_parameter import ImportDataTaskParameter
178178
from .import_double_array_option import ImportDoubleArrayOption
179179
from .import_int_array_option import ImportIntArrayOption
180+
from .import_picture_option import ImportPictureOption
180181
from .import_string_array_option import ImportStringArrayOption
181182
from .legend_response import LegendResponse
182183
from .line_format import LineFormat

asposecellscloud/models/access_token_response.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ class AccessTokenResponse(object):
5252
}
5353

5454
attribute_map = {
55-
'expires': '.expires',
55+
'expires': 'expires',
5656
'access_token': 'access_token',
57-
'issued': '.issued',
57+
'issued': 'issued',
5858
'client_refresh_token_life_time_in_minutes': 'clientRefreshTokenLifeTimeInMinutes',
5959
'expires_in': 'expires_in',
6060
'token_type': 'token_type',

asposecellscloud/models/conditional_formatting_value.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class ConditionalFormattingValue(object):
4343
swagger_types = {
4444
'is_gte': 'bool',
4545
'type': 'str',
46-
'value': 'object'
46+
'value': 'str'
4747
}
4848

4949
attribute_map = {
@@ -139,7 +139,7 @@ def value(self):
139139
Get or set the value of this conditional formatting value object. It should be used in conjunction with Type.
140140
141141
:return: The value of this ConditionalFormattingValue.
142-
:rtype: object
142+
:rtype: str
143143
"""
144144
return self.container['value']
145145

@@ -150,7 +150,7 @@ def value(self, value):
150150
Get or set the value of this conditional formatting value object. It should be used in conjunction with Type.
151151
152152
:param value: The value of this ConditionalFormattingValue.
153-
:type: object
153+
:type: str
154154
"""
155155

156156
self.container['value'] = value

asposecellscloud/models/custom_filter.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class CustomFilter(object):
4242
"""
4343
swagger_types = {
4444
'filter_operator_type': 'str',
45-
'criteria': 'object'
45+
'criteria': 'str'
4646
}
4747

4848
attribute_map = {
@@ -108,7 +108,7 @@ def criteria(self):
108108
Gets the criteria of this CustomFilter.
109109
110110
:return: The criteria of this CustomFilter.
111-
:rtype: object
111+
:rtype: str
112112
"""
113113
return self.container['criteria']
114114

@@ -118,7 +118,7 @@ def criteria(self, criteria):
118118
Sets the criteria of this CustomFilter.
119119
120120
:param criteria: The criteria of this CustomFilter.
121-
:type: object
121+
:type: str
122122
"""
123123

124124
self.container['criteria'] = criteria

asposecellscloud/models/dynamic_filter.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ class DynamicFilter(object):
4242
"""
4343
swagger_types = {
4444
'dynamic_filter_type': 'str',
45-
'max_value': 'object',
46-
'value': 'object'
45+
'max_value': 'int',
46+
'value': 'int'
4747
}
4848

4949
attribute_map = {
@@ -113,7 +113,7 @@ def max_value(self):
113113
Gets the max_value of this DynamicFilter.
114114
115115
:return: The max_value of this DynamicFilter.
116-
:rtype: object
116+
:rtype: int
117117
"""
118118
return self.container['max_value']
119119

@@ -123,7 +123,7 @@ def max_value(self, max_value):
123123
Sets the max_value of this DynamicFilter.
124124
125125
:param max_value: The max_value of this DynamicFilter.
126-
:type: object
126+
:type: int
127127
"""
128128

129129
self.container['max_value'] = max_value
@@ -134,7 +134,7 @@ def value(self):
134134
Gets the value of this DynamicFilter.
135135
136136
:return: The value of this DynamicFilter.
137-
:rtype: object
137+
:rtype: int
138138
"""
139139
return self.container['value']
140140

@@ -144,7 +144,7 @@ def value(self, value):
144144
Sets the value of this DynamicFilter.
145145
146146
:param value: The value of this DynamicFilter.
147-
:type: object
147+
:type: int
148148
"""
149149

150150
self.container['value'] = value

0 commit comments

Comments
 (0)