groupdocs_viewer_cloud 18.11 → 19.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (111) hide show
  1. checksums.yaml +4 -4
  2. data/lib/groupdocs_viewer_cloud.rb +27 -32
  3. data/lib/groupdocs_viewer_cloud/api/file_api.rb +729 -0
  4. data/lib/groupdocs_viewer_cloud/api/folder_api.rb +694 -0
  5. data/lib/groupdocs_viewer_cloud/api/storage_api.rb +541 -0
  6. data/lib/groupdocs_viewer_cloud/api/viewer_api.rb +232 -5069
  7. data/lib/groupdocs_viewer_cloud/api_client.rb +5 -5
  8. data/lib/groupdocs_viewer_cloud/api_error.rb +6 -6
  9. data/lib/groupdocs_viewer_cloud/configuration.rb +4 -4
  10. data/lib/groupdocs_viewer_cloud/models/attachment_info.rb +22 -34
  11. data/lib/groupdocs_viewer_cloud/models/{html_page.rb → attachment_view.rb} +39 -33
  12. data/lib/groupdocs_viewer_cloud/models/cad_options.rb +44 -65
  13. data/lib/groupdocs_viewer_cloud/models/{font_family.rb → delete_view_options.rb} +25 -17
  14. data/lib/groupdocs_viewer_cloud/models/{reorder_options.rb → disc_usage.rb} +42 -34
  15. data/lib/groupdocs_viewer_cloud/models/email_options.rb +23 -25
  16. data/lib/groupdocs_viewer_cloud/models/{image_page_collection.rb → error.rb} +46 -40
  17. data/lib/groupdocs_viewer_cloud/models/{outlook_options.rb → error_details.rb} +40 -17
  18. data/lib/groupdocs_viewer_cloud/models/field_label.rb +20 -12
  19. data/lib/groupdocs_viewer_cloud/models/{transform_options_base.rb → file_info.rb} +49 -21
  20. data/lib/groupdocs_viewer_cloud/models/{html_attachment_page_collection.rb → file_version.rb} +91 -40
  21. data/lib/groupdocs_viewer_cloud/models/{page_info_collection.rb → file_versions.rb} +26 -18
  22. data/lib/groupdocs_viewer_cloud/models/{font_collection.rb → files_list.rb} +26 -18
  23. data/lib/groupdocs_viewer_cloud/models/{image_page.rb → files_upload_result.rb} +36 -24
  24. data/lib/groupdocs_viewer_cloud/models/format.rb +30 -22
  25. data/lib/groupdocs_viewer_cloud/models/{format_collection.rb → formats_result.rb} +19 -11
  26. data/lib/groupdocs_viewer_cloud/models/html_options.rb +108 -209
  27. data/lib/groupdocs_viewer_cloud/models/html_resource.rb +234 -0
  28. data/lib/groupdocs_viewer_cloud/models/image_options.rb +129 -163
  29. data/lib/groupdocs_viewer_cloud/models/{attachment_collection.rb → info_result.rb} +32 -32
  30. data/lib/groupdocs_viewer_cloud/models/{rotate_options.rb → object_exist.rb} +42 -34
  31. data/lib/groupdocs_viewer_cloud/models/page_info.rb +48 -55
  32. data/lib/groupdocs_viewer_cloud/models/{pdf_file_info.rb → page_view.rb} +53 -38
  33. data/lib/groupdocs_viewer_cloud/models/{project_options.rb → project_management_options.rb} +39 -21
  34. data/lib/groupdocs_viewer_cloud/models/render_options.rb +92 -146
  35. data/lib/groupdocs_viewer_cloud/models/resource.rb +30 -22
  36. data/lib/groupdocs_viewer_cloud/models/{row_info.rb → row.rb} +65 -37
  37. data/lib/groupdocs_viewer_cloud/models/{cells_options.rb → spreadsheet_options.rb} +95 -67
  38. data/lib/groupdocs_viewer_cloud/models/{attachment.rb → storage_exist.rb} +30 -27
  39. data/lib/groupdocs_viewer_cloud/models/{image_attachment_page_collection.rb → storage_file.rb} +66 -40
  40. data/lib/groupdocs_viewer_cloud/models/{document_info.rb → view_options.rb} +99 -105
  41. data/lib/groupdocs_viewer_cloud/models/{html_page_collection.rb → view_result.rb} +43 -33
  42. data/lib/groupdocs_viewer_cloud/models/watermark.rb +35 -22
  43. data/lib/groupdocs_viewer_cloud/version.rb +2 -2
  44. metadata +27 -110
  45. data/lib/groupdocs_viewer_cloud/models/document_info_options.rb +0 -358
  46. data/lib/groupdocs_viewer_cloud/models/file_response.rb +0 -196
  47. data/lib/groupdocs_viewer_cloud/models/pdf_file_options.rb +0 -358
  48. data/lib/groupdocs_viewer_cloud/models/pdf_options.rb +0 -236
  49. data/lib/groupdocs_viewer_cloud/models/render_options_base.rb +0 -358
  50. data/lib/groupdocs_viewer_cloud/models/requests/html_create_attachment_pages_cache_request.rb +0 -65
  51. data/lib/groupdocs_viewer_cloud/models/requests/html_create_pages_cache_from_content_request.rb +0 -65
  52. data/lib/groupdocs_viewer_cloud/models/requests/html_create_pages_cache_from_url_request.rb +0 -65
  53. data/lib/groupdocs_viewer_cloud/models/requests/html_create_pages_cache_request.rb +0 -61
  54. data/lib/groupdocs_viewer_cloud/models/requests/html_create_pdf_file_from_content_request.rb +0 -65
  55. data/lib/groupdocs_viewer_cloud/models/requests/html_create_pdf_file_from_url_request.rb +0 -65
  56. data/lib/groupdocs_viewer_cloud/models/requests/html_create_pdf_file_request.rb +0 -61
  57. data/lib/groupdocs_viewer_cloud/models/requests/html_delete_attachment_pages_cache_request.rb +0 -57
  58. data/lib/groupdocs_viewer_cloud/models/requests/html_delete_pages_cache_request.rb +0 -53
  59. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachment_info_request.rb +0 -65
  60. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachment_info_with_options_request.rb +0 -61
  61. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachment_page_request.rb +0 -109
  62. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachment_page_resource_request.rb +0 -65
  63. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachment_pages_request.rb +0 -113
  64. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachment_request.rb +0 -61
  65. data/lib/groupdocs_viewer_cloud/models/requests/html_get_attachments_request.rb +0 -57
  66. data/lib/groupdocs_viewer_cloud/models/requests/html_get_document_info_from_content_request.rb +0 -61
  67. data/lib/groupdocs_viewer_cloud/models/requests/html_get_document_info_from_url_request.rb +0 -69
  68. data/lib/groupdocs_viewer_cloud/models/requests/html_get_document_info_from_url_with_options_request.rb +0 -61
  69. data/lib/groupdocs_viewer_cloud/models/requests/html_get_document_info_request.rb +0 -65
  70. data/lib/groupdocs_viewer_cloud/models/requests/html_get_document_info_with_options_request.rb +0 -57
  71. data/lib/groupdocs_viewer_cloud/models/requests/html_get_page_request.rb +0 -101
  72. data/lib/groupdocs_viewer_cloud/models/requests/html_get_page_resource_request.rb +0 -61
  73. data/lib/groupdocs_viewer_cloud/models/requests/html_get_pages_from_url_request.rb +0 -109
  74. data/lib/groupdocs_viewer_cloud/models/requests/html_get_pages_request.rb +0 -105
  75. data/lib/groupdocs_viewer_cloud/models/requests/html_get_pdf_file_from_url_request.rb +0 -77
  76. data/lib/groupdocs_viewer_cloud/models/requests/html_get_pdf_file_request.rb +0 -73
  77. data/lib/groupdocs_viewer_cloud/models/requests/html_get_zip_with_attachment_pages_request.rb +0 -113
  78. data/lib/groupdocs_viewer_cloud/models/requests/html_get_zip_with_pages_request.rb +0 -105
  79. data/lib/groupdocs_viewer_cloud/models/requests/html_transform_pages_request.rb +0 -57
  80. data/lib/groupdocs_viewer_cloud/models/requests/image_create_attachment_pages_cache_request.rb +0 -65
  81. data/lib/groupdocs_viewer_cloud/models/requests/image_create_pages_cache_from_content_request.rb +0 -65
  82. data/lib/groupdocs_viewer_cloud/models/requests/image_create_pages_cache_from_url_request.rb +0 -65
  83. data/lib/groupdocs_viewer_cloud/models/requests/image_create_pages_cache_request.rb +0 -61
  84. data/lib/groupdocs_viewer_cloud/models/requests/image_create_pdf_file_from_content_request.rb +0 -65
  85. data/lib/groupdocs_viewer_cloud/models/requests/image_create_pdf_file_from_url_request.rb +0 -65
  86. data/lib/groupdocs_viewer_cloud/models/requests/image_create_pdf_file_request.rb +0 -61
  87. data/lib/groupdocs_viewer_cloud/models/requests/image_delete_attachment_pages_cache_request.rb +0 -57
  88. data/lib/groupdocs_viewer_cloud/models/requests/image_delete_pages_cache_request.rb +0 -53
  89. data/lib/groupdocs_viewer_cloud/models/requests/image_get_attachment_info_request.rb +0 -69
  90. data/lib/groupdocs_viewer_cloud/models/requests/image_get_attachment_info_with_options_request.rb +0 -61
  91. data/lib/groupdocs_viewer_cloud/models/requests/image_get_attachment_page_request.rb +0 -105
  92. data/lib/groupdocs_viewer_cloud/models/requests/image_get_attachment_pages_request.rb +0 -109
  93. data/lib/groupdocs_viewer_cloud/models/requests/image_get_attachment_request.rb +0 -61
  94. data/lib/groupdocs_viewer_cloud/models/requests/image_get_attachments_request.rb +0 -57
  95. data/lib/groupdocs_viewer_cloud/models/requests/image_get_document_info_from_content_request.rb +0 -61
  96. data/lib/groupdocs_viewer_cloud/models/requests/image_get_document_info_from_url_request.rb +0 -73
  97. data/lib/groupdocs_viewer_cloud/models/requests/image_get_document_info_from_url_with_options_request.rb +0 -61
  98. data/lib/groupdocs_viewer_cloud/models/requests/image_get_document_info_request.rb +0 -69
  99. data/lib/groupdocs_viewer_cloud/models/requests/image_get_document_info_with_options_request.rb +0 -57
  100. data/lib/groupdocs_viewer_cloud/models/requests/image_get_page_request.rb +0 -97
  101. data/lib/groupdocs_viewer_cloud/models/requests/image_get_pages_from_url_request.rb +0 -105
  102. data/lib/groupdocs_viewer_cloud/models/requests/image_get_pages_request.rb +0 -101
  103. data/lib/groupdocs_viewer_cloud/models/requests/image_get_pdf_file_from_url_request.rb +0 -77
  104. data/lib/groupdocs_viewer_cloud/models/requests/image_get_pdf_file_request.rb +0 -73
  105. data/lib/groupdocs_viewer_cloud/models/requests/image_get_zip_with_attachment_pages_request.rb +0 -109
  106. data/lib/groupdocs_viewer_cloud/models/requests/image_get_zip_with_pages_request.rb +0 -101
  107. data/lib/groupdocs_viewer_cloud/models/requests/image_transform_pages_request.rb +0 -57
  108. data/lib/groupdocs_viewer_cloud/models/resource_url.rb +0 -206
  109. data/lib/groupdocs_viewer_cloud/models/slides_options.rb +0 -206
  110. data/lib/groupdocs_viewer_cloud/models/tile.rb +0 -236
  111. data/lib/groupdocs_viewer_cloud/models/words_options.rb +0 -216
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # --------------------------------------------------------------------------------------------------------------------
3
3
  # <copyright company="Aspose Pty Ltd" file="image_options.rb">
4
- # Copyright (c) 2003-2018 Aspose Pty Ltd
4
+ # Copyright (c) 2003-2019 Aspose Pty Ltd
5
5
  # </copyright>
6
6
  # <summary>
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -28,68 +28,38 @@
28
28
  require 'date'
29
29
 
30
30
  module GroupDocsViewerCloud
31
- # Provides options for rendering document as image.
31
+ # Options for rendering document into image
32
32
  class ImageOptions
33
33
 
34
- # Allows to specify document password in case when document is password-protected.
35
- attr_accessor :password
34
+ # Page number from which rendering should be started
35
+ attr_accessor :start_page_number
36
36
 
37
- # Allows to specify attachment password in case when attachment is password-protected.
38
- attr_accessor :attachment_password
37
+ # Count pages which should be rendered
38
+ attr_accessor :count_pages_to_render
39
39
 
40
- # Enables document text extraction. For rendering document as image only.
41
- attr_accessor :extract_text
40
+ # Default font name may be specified in following cases: - You want to generally specify the default font to fall back on, if particular font in the document cannot be found during rendering. - Your document uses fonts, that contain non-English characters and you want to make sure any missing font is replaced with one that has the same character set available.
41
+ attr_accessor :default_font_name
42
+
43
+ # Default encoding for the plain text files such as .csv, .txt and .eml files when encoding is not specified in header
44
+ attr_accessor :default_encoding
42
45
 
43
- # Enables document comments rendering.
46
+ # When enabled comments will be rendered to the output.
44
47
  attr_accessor :render_comments
45
48
 
46
- # Enables rendering of document hidden pages, sheets or slides.
49
+ # When enabled hidden pages, sheets or slides will be rendered to the output
47
50
  attr_accessor :render_hidden_pages
48
51
 
49
- # Transforms to apply. Available transforms [\"Rotate\",\"Reorder\",\"AddPrintAction\"]. 1. Rotate - pages will be rotated on angle if angle was set before. 2. Reorder - for rendering document as PDF only. Pages will be ordered according to rearrangements made before. 3. AddPrintAction - for rendering document as PDF only. An JavaScript action will be added which opens print dialog when PDF document is opened.
50
- attr_accessor :transforms
51
-
52
- # The name of the default font. Default font name may be specified in following cases: - You want to generally specify the default font to fall back on, if particular font in the document cannot be found during rendering. - Your document uses fonts, that contain non-English characters and you want to make sure any missing font is replaced with one that has the same character set available.
53
- attr_accessor :default_font_name
54
-
55
- # Allows to specify watermark.
56
- attr_accessor :watermark
52
+ # Rendering options for Spreadsheet file formats. Spreadsheet file formats include files with extensions: .xls, .xlsx, .xlsm, .xlsb, .csv, .ods, .ots, .xltx, .xltm, .tsv
53
+ attr_accessor :spreadsheet_options
57
54
 
58
- # The Spreadsheet documents rendering options.
59
- attr_accessor :cells_options
60
-
61
- # The CAD documents rendering options.
55
+ # Rendering options for CAD file formats. CAD file formats include files with extensions: .dwg, .dxf, .dgn, .ifc, .stl
62
56
  attr_accessor :cad_options
63
57
 
64
- # The Email documents rendering options.
58
+ # Rendering options for Email file formats. Email file formats include files with extensions: .msg, .eml, .emlx, .ifc, .stl
65
59
  attr_accessor :email_options
66
60
 
67
- # The Text documents rendering options.
68
- attr_accessor :words_options
69
-
70
- # The PDF documents rendering options.
71
- attr_accessor :pdf_options
72
-
73
- # The Presentation documents rendering options.
74
- attr_accessor :slides_options
75
-
76
- # The Microsoft Project documents rendering options.
77
- attr_accessor :project_options
78
-
79
- # The Outlook Data File document (PST/OST) rendering options.
80
- attr_accessor :outlook_options
81
-
82
- # Allows to specify document page number as starting page to render.
83
- attr_accessor :start_page_number
84
-
85
- # Allows to specify count of document pages to render.
86
- attr_accessor :count_pages
87
-
88
- # Allows to set image format (png, jpg, bmp). Default value is png.
89
- attr_accessor :format
90
-
91
- # Allows to specify quality when rendering as JPG. Valid values are between 1 and 100. Default value is 90.
92
- attr_accessor :quality
61
+ # Rendering options for Project file formats. Project file formats include files with extensions: .mpt, .mpp
62
+ attr_accessor :project_management_options
93
63
 
94
64
  # Allows to specify output image width. Specify image width in case when you want to change output image dimensions. When Width has value and Height value is 0 then Height value will be calculated to save image proportions.
95
65
  attr_accessor :width
@@ -97,59 +67,49 @@ module GroupDocsViewerCloud
97
67
  # Allows to specify output image height. Specify image height in case when you want to change output image dimensions. When Height has value and Width value is 0 then Width value will be calculated to save image proportions.
98
68
  attr_accessor :height
99
69
 
70
+ # When enabled Viewer will extract text when it's possible (e.g. raster formats don't have text layer) and return it in the viewing result. This option might be useful when you want to add selectable text layer over the image.
71
+ attr_accessor :extract_text
72
+
73
+ # Allows to specify quality when rendering as JPG. Valid values are between 1 and 100. Default value is 90.
74
+ attr_accessor :jpeg_quality
75
+
100
76
  # Attribute mapping from ruby-style variable name to JSON key.
101
77
  def self.attribute_map
102
78
  {
103
- :'password' => :'password',
104
- :'attachment_password' => :'attachmentPassword',
105
- :'extract_text' => :'extractText',
106
- :'render_comments' => :'renderComments',
107
- :'render_hidden_pages' => :'renderHiddenPages',
108
- :'transforms' => :'transforms',
109
- :'default_font_name' => :'defaultFontName',
110
- :'watermark' => :'watermark',
111
- :'cells_options' => :'cellsOptions',
112
- :'cad_options' => :'cadOptions',
113
- :'email_options' => :'emailOptions',
114
- :'words_options' => :'wordsOptions',
115
- :'pdf_options' => :'pdfOptions',
116
- :'slides_options' => :'slidesOptions',
117
- :'project_options' => :'projectOptions',
118
- :'outlook_options' => :'outlookOptions',
119
- :'start_page_number' => :'startPageNumber',
120
- :'count_pages' => :'countPages',
121
- :'format' => :'format',
122
- :'quality' => :'quality',
123
- :'width' => :'width',
124
- :'height' => :'height'
79
+ :'start_page_number' => :'StartPageNumber',
80
+ :'count_pages_to_render' => :'CountPagesToRender',
81
+ :'default_font_name' => :'DefaultFontName',
82
+ :'default_encoding' => :'DefaultEncoding',
83
+ :'render_comments' => :'RenderComments',
84
+ :'render_hidden_pages' => :'RenderHiddenPages',
85
+ :'spreadsheet_options' => :'SpreadsheetOptions',
86
+ :'cad_options' => :'CadOptions',
87
+ :'email_options' => :'EmailOptions',
88
+ :'project_management_options' => :'ProjectManagementOptions',
89
+ :'width' => :'Width',
90
+ :'height' => :'Height',
91
+ :'extract_text' => :'ExtractText',
92
+ :'jpeg_quality' => :'JpegQuality'
125
93
  }
126
94
  end
127
95
 
128
96
  # Attribute type mapping.
129
97
  def self.swagger_types
130
98
  {
131
- :'password' => :'String',
132
- :'attachment_password' => :'String',
133
- :'extract_text' => :'BOOLEAN',
99
+ :'start_page_number' => :'Integer',
100
+ :'count_pages_to_render' => :'Integer',
101
+ :'default_font_name' => :'String',
102
+ :'default_encoding' => :'String',
134
103
  :'render_comments' => :'BOOLEAN',
135
104
  :'render_hidden_pages' => :'BOOLEAN',
136
- :'transforms' => :'Array<String>',
137
- :'default_font_name' => :'String',
138
- :'watermark' => :'Watermark',
139
- :'cells_options' => :'CellsOptions',
105
+ :'spreadsheet_options' => :'SpreadsheetOptions',
140
106
  :'cad_options' => :'CadOptions',
141
107
  :'email_options' => :'EmailOptions',
142
- :'words_options' => :'WordsOptions',
143
- :'pdf_options' => :'PdfOptions',
144
- :'slides_options' => :'SlidesOptions',
145
- :'project_options' => :'ProjectOptions',
146
- :'outlook_options' => :'OutlookOptions',
147
- :'start_page_number' => :'Integer',
148
- :'count_pages' => :'Integer',
149
- :'format' => :'String',
150
- :'quality' => :'Integer',
108
+ :'project_management_options' => :'ProjectManagementOptions',
151
109
  :'width' => :'Integer',
152
- :'height' => :'Integer'
110
+ :'height' => :'Integer',
111
+ :'extract_text' => :'BOOLEAN',
112
+ :'jpeg_quality' => :'Integer'
153
113
  }
154
114
  end
155
115
 
@@ -161,108 +121,114 @@ module GroupDocsViewerCloud
161
121
  # convert string to symbol for hash key
162
122
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
163
123
 
164
- if attributes.key?(:'password')
165
- self.password = attributes[:'password']
124
+ if attributes.key?(:'StartPageNumber')
125
+ self.start_page_number = attributes[:'StartPageNumber']
166
126
  end
167
127
 
168
- if attributes.key?(:'attachmentPassword')
169
- self.attachment_password = attributes[:'attachmentPassword']
128
+ if attributes.key?(:'CountPagesToRender')
129
+ self.count_pages_to_render = attributes[:'CountPagesToRender']
170
130
  end
171
131
 
172
- if attributes.key?(:'extractText')
173
- self.extract_text = attributes[:'extractText']
132
+ if attributes.key?(:'DefaultFontName')
133
+ self.default_font_name = attributes[:'DefaultFontName']
174
134
  end
175
135
 
176
- if attributes.key?(:'renderComments')
177
- self.render_comments = attributes[:'renderComments']
136
+ if attributes.key?(:'DefaultEncoding')
137
+ self.default_encoding = attributes[:'DefaultEncoding']
178
138
  end
179
139
 
180
- if attributes.key?(:'renderHiddenPages')
181
- self.render_hidden_pages = attributes[:'renderHiddenPages']
140
+ if attributes.key?(:'RenderComments')
141
+ self.render_comments = attributes[:'RenderComments']
182
142
  end
183
143
 
184
- if attributes.key?(:'transforms')
185
- if (value = attributes[:'transforms']).is_a?(Array)
186
- self.transforms = value
187
- end
144
+ if attributes.key?(:'RenderHiddenPages')
145
+ self.render_hidden_pages = attributes[:'RenderHiddenPages']
188
146
  end
189
147
 
190
- if attributes.key?(:'defaultFontName')
191
- self.default_font_name = attributes[:'defaultFontName']
148
+ if attributes.key?(:'SpreadsheetOptions')
149
+ self.spreadsheet_options = attributes[:'SpreadsheetOptions']
192
150
  end
193
151
 
194
- if attributes.key?(:'watermark')
195
- self.watermark = attributes[:'watermark']
152
+ if attributes.key?(:'CadOptions')
153
+ self.cad_options = attributes[:'CadOptions']
196
154
  end
197
155
 
198
- if attributes.key?(:'cellsOptions')
199
- self.cells_options = attributes[:'cellsOptions']
156
+ if attributes.key?(:'EmailOptions')
157
+ self.email_options = attributes[:'EmailOptions']
200
158
  end
201
159
 
202
- if attributes.key?(:'cadOptions')
203
- self.cad_options = attributes[:'cadOptions']
160
+ if attributes.key?(:'ProjectManagementOptions')
161
+ self.project_management_options = attributes[:'ProjectManagementOptions']
204
162
  end
205
163
 
206
- if attributes.key?(:'emailOptions')
207
- self.email_options = attributes[:'emailOptions']
164
+ if attributes.key?(:'Width')
165
+ self.width = attributes[:'Width']
208
166
  end
209
167
 
210
- if attributes.key?(:'wordsOptions')
211
- self.words_options = attributes[:'wordsOptions']
168
+ if attributes.key?(:'Height')
169
+ self.height = attributes[:'Height']
212
170
  end
213
171
 
214
- if attributes.key?(:'pdfOptions')
215
- self.pdf_options = attributes[:'pdfOptions']
172
+ if attributes.key?(:'ExtractText')
173
+ self.extract_text = attributes[:'ExtractText']
216
174
  end
217
175
 
218
- if attributes.key?(:'slidesOptions')
219
- self.slides_options = attributes[:'slidesOptions']
176
+ if attributes.key?(:'JpegQuality')
177
+ self.jpeg_quality = attributes[:'JpegQuality']
220
178
  end
221
179
 
222
- if attributes.key?(:'projectOptions')
223
- self.project_options = attributes[:'projectOptions']
224
- end
180
+ end
225
181
 
226
- if attributes.key?(:'outlookOptions')
227
- self.outlook_options = attributes[:'outlookOptions']
182
+ # Show invalid properties with the reasons. Usually used together with valid?
183
+ # @return Array for valid properies with the reasons
184
+ def list_invalid_properties
185
+ invalid_properties = []
186
+ if @start_page_number.nil?
187
+ invalid_properties.push("invalid value for 'start_page_number', start_page_number cannot be nil.")
228
188
  end
229
189
 
230
- if attributes.key?(:'startPageNumber')
231
- self.start_page_number = attributes[:'startPageNumber']
190
+ if @count_pages_to_render.nil?
191
+ invalid_properties.push("invalid value for 'count_pages_to_render', count_pages_to_render cannot be nil.")
232
192
  end
233
193
 
234
- if attributes.key?(:'countPages')
235
- self.count_pages = attributes[:'countPages']
194
+ if @render_comments.nil?
195
+ invalid_properties.push("invalid value for 'render_comments', render_comments cannot be nil.")
236
196
  end
237
197
 
238
- if attributes.key?(:'format')
239
- self.format = attributes[:'format']
198
+ if @render_hidden_pages.nil?
199
+ invalid_properties.push("invalid value for 'render_hidden_pages', render_hidden_pages cannot be nil.")
240
200
  end
241
201
 
242
- if attributes.key?(:'quality')
243
- self.quality = attributes[:'quality']
202
+ if @width.nil?
203
+ invalid_properties.push("invalid value for 'width', width cannot be nil.")
244
204
  end
245
205
 
246
- if attributes.key?(:'width')
247
- self.width = attributes[:'width']
206
+ if @height.nil?
207
+ invalid_properties.push("invalid value for 'height', height cannot be nil.")
248
208
  end
249
209
 
250
- if attributes.key?(:'height')
251
- self.height = attributes[:'height']
210
+ if @extract_text.nil?
211
+ invalid_properties.push("invalid value for 'extract_text', extract_text cannot be nil.")
252
212
  end
253
213
 
254
- end
214
+ if @jpeg_quality.nil?
215
+ invalid_properties.push("invalid value for 'jpeg_quality', jpeg_quality cannot be nil.")
216
+ end
255
217
 
256
- # Show invalid properties with the reasons. Usually used together with valid?
257
- # @return Array for valid properies with the reasons
258
- def list_invalid_properties
259
- invalid_properties = []
260
218
  return invalid_properties
261
219
  end
262
220
 
263
221
  # Check to see if the all the properties in the model are valid
264
222
  # @return true if the model is valid
265
223
  def valid?
224
+ return false if @start_page_number.nil?
225
+ return false if @count_pages_to_render.nil?
226
+ return false if @render_comments.nil?
227
+ return false if @render_hidden_pages.nil?
228
+ return false if @width.nil?
229
+ return false if @height.nil?
230
+ return false if @extract_text.nil?
231
+ return false if @jpeg_quality.nil?
266
232
  return true
267
233
  end
268
234
 
@@ -271,28 +237,20 @@ module GroupDocsViewerCloud
271
237
  def ==(other)
272
238
  return true if self.equal?(other)
273
239
  self.class == other.class &&
274
- password == other.password &&
275
- attachment_password == other.attachment_password &&
276
- extract_text == other.extract_text &&
240
+ start_page_number == other.start_page_number &&
241
+ count_pages_to_render == other.count_pages_to_render &&
242
+ default_font_name == other.default_font_name &&
243
+ default_encoding == other.default_encoding &&
277
244
  render_comments == other.render_comments &&
278
245
  render_hidden_pages == other.render_hidden_pages &&
279
- transforms == other.transforms &&
280
- default_font_name == other.default_font_name &&
281
- watermark == other.watermark &&
282
- cells_options == other.cells_options &&
246
+ spreadsheet_options == other.spreadsheet_options &&
283
247
  cad_options == other.cad_options &&
284
248
  email_options == other.email_options &&
285
- words_options == other.words_options &&
286
- pdf_options == other.pdf_options &&
287
- slides_options == other.slides_options &&
288
- project_options == other.project_options &&
289
- outlook_options == other.outlook_options &&
290
- start_page_number == other.start_page_number &&
291
- count_pages == other.count_pages &&
292
- format == other.format &&
293
- quality == other.quality &&
249
+ project_management_options == other.project_management_options &&
294
250
  width == other.width &&
295
- height == other.height
251
+ height == other.height &&
252
+ extract_text == other.extract_text &&
253
+ jpeg_quality == other.jpeg_quality
296
254
  end
297
255
 
298
256
  # @see the `==` method
@@ -304,7 +262,13 @@ module GroupDocsViewerCloud
304
262
  # Calculates hash code according to all attributes.
305
263
  # @return [Fixnum] Hash code
306
264
  def hash
307
- [password, attachment_password, extract_text, render_comments, render_hidden_pages, transforms, default_font_name, watermark, cells_options, cad_options, email_options, words_options, pdf_options, slides_options, project_options, outlook_options, start_page_number, count_pages, format, quality, width, height].hash
265
+ [start_page_number, count_pages_to_render, default_font_name, default_encoding, render_comments, render_hidden_pages, spreadsheet_options, cad_options, email_options, project_management_options, width, height, extract_text, jpeg_quality].hash
266
+ end
267
+
268
+ # Downcases first letter.
269
+ # @return downcased string
270
+ def uncap(str)
271
+ str[0, 1].downcase + str[1..-1]
308
272
  end
309
273
 
310
274
  # Builds the object from hash
@@ -313,14 +277,16 @@ module GroupDocsViewerCloud
313
277
  def build_from_hash(attributes)
314
278
  return nil unless attributes.is_a?(Hash)
315
279
  self.class.swagger_types.each_pair do |key, type|
280
+ pname = uncap(self.class.attribute_map[key]).intern
281
+ value = attributes[pname]
316
282
  if type =~ /\AArray<(.*)>/i
317
283
  # check to ensure the input is an array given that the the attribute
318
- # is documented as an array but the input is not
319
- if attributes[self.class.attribute_map[key]].is_a?(Array)
320
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
284
+ # is documented as an array but the input is not
285
+ if value.is_a?(Array)
286
+ self.send("#{key}=", value.map { |v| _deserialize($1, v) })
321
287
  end
322
- elsif !attributes[self.class.attribute_map[key]].nil?
323
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
288
+ elsif !value.nil?
289
+ self.send("#{key}=", _deserialize(type, value))
324
290
  end
325
291
  # or else data not found in attributes(hash), not an issue as the data can be optional
326
292
  end
@@ -1,7 +1,7 @@
1
1
  #
2
2
  # --------------------------------------------------------------------------------------------------------------------
3
- # <copyright company="Aspose Pty Ltd" file="attachment_collection.rb">
4
- # Copyright (c) 2003-2018 Aspose Pty Ltd
3
+ # <copyright company="Aspose Pty Ltd" file="info_result.rb">
4
+ # Copyright (c) 2003-2019 Aspose Pty Ltd
5
5
  # </copyright>
6
6
  # <summary>
7
7
  # Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -28,33 +28,28 @@
28
28
  require 'date'
29
29
 
30
30
  module GroupDocsViewerCloud
31
- # Describes attachments.
32
- class AttachmentCollection
31
+ # View result information
32
+ class InfoResult
33
33
 
34
- # File name.
35
- attr_accessor :file_name
34
+ # View result pages
35
+ attr_accessor :pages
36
36
 
37
- # File folder.
38
- attr_accessor :folder
39
-
40
- # Attachments list.
37
+ # Attachments
41
38
  attr_accessor :attachments
42
39
 
43
40
  # Attribute mapping from ruby-style variable name to JSON key.
44
41
  def self.attribute_map
45
42
  {
46
- :'file_name' => :'fileName',
47
- :'folder' => :'folder',
48
- :'attachments' => :'attachments'
43
+ :'pages' => :'Pages',
44
+ :'attachments' => :'Attachments'
49
45
  }
50
46
  end
51
47
 
52
48
  # Attribute type mapping.
53
49
  def self.swagger_types
54
50
  {
55
- :'file_name' => :'String',
56
- :'folder' => :'String',
57
- :'attachments' => :'Array<Attachment>'
51
+ :'pages' => :'Array<PageInfo>',
52
+ :'attachments' => :'Array<AttachmentInfo>'
58
53
  }
59
54
  end
60
55
 
@@ -66,16 +61,14 @@ module GroupDocsViewerCloud
66
61
  # convert string to symbol for hash key
67
62
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
68
63
 
69
- if attributes.key?(:'fileName')
70
- self.file_name = attributes[:'fileName']
71
- end
72
-
73
- if attributes.key?(:'folder')
74
- self.folder = attributes[:'folder']
64
+ if attributes.key?(:'Pages')
65
+ if (value = attributes[:'Pages']).is_a?(Array)
66
+ self.pages = value
67
+ end
75
68
  end
76
69
 
77
- if attributes.key?(:'attachments')
78
- if (value = attributes[:'attachments']).is_a?(Array)
70
+ if attributes.key?(:'Attachments')
71
+ if (value = attributes[:'Attachments']).is_a?(Array)
79
72
  self.attachments = value
80
73
  end
81
74
  end
@@ -100,8 +93,7 @@ module GroupDocsViewerCloud
100
93
  def ==(other)
101
94
  return true if self.equal?(other)
102
95
  self.class == other.class &&
103
- file_name == other.file_name &&
104
- folder == other.folder &&
96
+ pages == other.pages &&
105
97
  attachments == other.attachments
106
98
  end
107
99
 
@@ -114,7 +106,13 @@ module GroupDocsViewerCloud
114
106
  # Calculates hash code according to all attributes.
115
107
  # @return [Fixnum] Hash code
116
108
  def hash
117
- [file_name, folder, attachments].hash
109
+ [pages, attachments].hash
110
+ end
111
+
112
+ # Downcases first letter.
113
+ # @return downcased string
114
+ def uncap(str)
115
+ str[0, 1].downcase + str[1..-1]
118
116
  end
119
117
 
120
118
  # Builds the object from hash
@@ -123,14 +121,16 @@ module GroupDocsViewerCloud
123
121
  def build_from_hash(attributes)
124
122
  return nil unless attributes.is_a?(Hash)
125
123
  self.class.swagger_types.each_pair do |key, type|
124
+ pname = uncap(self.class.attribute_map[key]).intern
125
+ value = attributes[pname]
126
126
  if type =~ /\AArray<(.*)>/i
127
127
  # check to ensure the input is an array given that the the attribute
128
- # is documented as an array but the input is not
129
- if attributes[self.class.attribute_map[key]].is_a?(Array)
130
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
128
+ # is documented as an array but the input is not
129
+ if value.is_a?(Array)
130
+ self.send("#{key}=", value.map { |v| _deserialize($1, v) })
131
131
  end
132
- elsif !attributes[self.class.attribute_map[key]].nil?
133
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
132
+ elsif !value.nil?
133
+ self.send("#{key}=", _deserialize(type, value))
134
134
  end
135
135
  # or else data not found in attributes(hash), not an issue as the data can be optional
136
136
  end