Skip to content

Commit f2bbe7a

Browse files
committed
Updated sources
1 parent 01ad85d commit f2bbe7a

73 files changed

Lines changed: 145 additions & 218 deletions

Some content is hidden

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

Gemfile.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: .
33
specs:
4-
groupdocs_viewer_cloud (20.5)
4+
groupdocs_viewer_cloud (21.3)
55
addressable (~> 2.5.0, >= 2.5.0)
66
faraday (~> 0.14.0)
77
mimemagic (~> 0.3.2)
@@ -13,7 +13,7 @@ GEM
1313
public_suffix (>= 2.0.2, < 4.0)
1414
faraday (0.14.0)
1515
multipart-post (>= 1.2, < 3)
16-
mimemagic (0.3.4)
16+
mimemagic (0.3.5)
1717
minitest (5.14.0)
1818
multipart-post (2.1.1)
1919
public_suffix (3.1.1)

LICENSE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2003-2020 Aspose Pty Ltd
3+
Copyright (c) 2003-2019 Aspose Pty Ltd
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal
@@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1818
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
1919
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2020
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21-
SOFTWARE.
21+
SOFTWARE.

README.md

Lines changed: 31 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,53 @@
1-
![](https://img.shields.io/badge/api-v2.0-lightgrey) ![Gem](https://img.shields.io/gem/v/groupdocs_viewer_cloud) ![Gem](https://img.shields.io/gem/dt/groupdocs_viewer_cloud) [![GitHub license](https://img.shields.io/github/license/groupdocs-viewer-cloud/groupdocs-viewer-cloud-dotnet)](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-dotnet/blob/master/LICENSE)
1+
# GroupDocs.Viewer Cloud Ruby SDK
2+
Ruby gem for communicating with the GroupDocs.Viewer Cloud API
23

3-
# Ruby SDK to View Documents in the Cloud
4+
## Installation
45

5-
[GroupDocs.Viewer Cloud SDK for Ruby](https://products.groupdocs.cloud/viewer/ruby) wraps GroupDocs.Viewer RESTful APIs so you may integrate Document Viewing features in your own apps with zero initial cost.
6-
7-
GroupDocs.Viewer REST API allows the developers to view & render a number of files formats including Word documents, Excel spreadsheets, PowerPoint presentations, PDF, OpenDocument formats, emails, CAD files & images.
8-
9-
## Document Viewer Services in REST
10-
11-
- 90+ supported file formats.
12-
- View documents as PDF, HTML or images.
13-
- Render documents as raster & vector images.
14-
- Render documents with comments & notes.
15-
- Flip or rotate documents pages at 90, 180 or 270 degrees.
16-
- Reorder document pages.
17-
- Render hidden, consecutive or selected document pages.
18-
- Watermark PDF, image or HTML output pages.
19-
- Render with custom fonts as well as replace any missing fonts.
20-
- Load password-protected documents.
21-
- Extract attachment information such as attachment count & names.
22-
- Extract document information like file format, page count, size and visibility, text coordinates, and so on.
23-
- Integrated storage API.
24-
25-
Check out the [Developer's Guide](https://docs.groupdocs.cloud/viewer/developer-guide/) to know more about GroupDocs.Viewer REST API.
26-
27-
## Microsoft File Formats
28-
29-
**Microsoft Word:** DOC, DOCM, DOCX, DOT, DOTM, DOTX\
30-
**Microsoft Excel:** XLS, XLSX, XLSB, XLSM\
31-
**Microsoft PowerPoint:** PPTX, PPTM, PPT, PPSX, PPSM, PPS, POTX, POTM\
32-
**Microsoft Project:** MPP, MPT\
33-
**Microsoft Outlook:** MSG, OST, PST\
34-
**Microsoft Visio:** VDW, VDX, VSD, VSDM, VSDX, VSS, VSSM, VSSX, VST, VSTM, VSTX, VSX, VTX\
35-
**Microsoft OneNote:** ONE
36-
37-
## Other Formats
38-
39-
**Page Layout Formats:** PDF, XPS, TEX\
40-
**OpenDocument:** ODT, OTT, ODS, OTS, ODP, OTP\
41-
**CAD:** DNG, DWF, DWG, DXF, IDC, STL\
42-
**Images:** BMP, CGM, DCM, DJVU, EMP, EPS, GIF, ICO, JP2, JPG, ODG, PCL, PNG, PS, PSD, SVG, TIFF, WEBP, WMF\
43-
**Web:** HTML, MHT, MHTML\
44-
**Emails:** EML, EMLX\
45-
**eBooks:** EPUB, MOBI\
46-
**Others:** TXT, RTF, CSV, TSV
47-
48-
## Get Started with GroupDocs.Viewer Cloud SDK for Ruby
49-
50-
First create an account at [GroupDocs for Cloud](https://dashboard.groupdocs.cloud/) and get your application information. Next, install the GEM as follows.
6+
A gem of groupdocs_viewer_cloud is available at [rubygems.org](https://rubygems.org). You can install it with:
517

528
```shell
539
gem install groupdocs_viewer_cloud
5410
```
5511

56-
Copy the following into your GEM and run `bundle install` to add the dependency.
12+
To add dependency to your app copy following into your Gemfile and run `bundle install`:
5713

5814
```
59-
gem "groupdocs_viewer_cloud", "~> 20.5"
15+
gem "groupdocs_viewer_cloud", "~> 21.3"
6016
```
6117

62-
## Render N Consecutive Pages of DOCX as HTML
18+
## Getting Started
6319

20+
Please follow the [installation](#installation) procedure and then run the following code:
6421
```ruby
65-
# For complete examples and data files, please go to https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-ruby-samples
22+
# Load the gem
6623
require 'groupdocs_viewer_cloud'
6724

68-
# Get Client Id and Client Secret from https://dashboard.groupdocs.cloud
69-
$my_client_id = ""
70-
$my_client_secret = ""
71-
72-
# Create instance of the API
73-
$configuration = GroupDocsViewerCloud::Configuration.new($my_client_id, $my_client_secret)
74-
apiInstance = GroupDocsViewerCloud::ViewApi.from_config($configuration)
25+
# Get your app_sid and app_key at https://dashboard.groupdocs.cloud (free registration is required).
26+
app_sid = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX"
27+
app_key = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
7528

76-
viewOptions = GroupDocsViewerCloud::ViewOptions.new
77-
viewOptions.file_info = GroupDocsViewerCloud::FileInfo.new
78-
viewOptions.file_info.file_path = "SampleFiles/sample.docx"
79-
viewOptions.view_format = "HTML"
80-
viewOptions.render_options = GroupDocsViewerCloud::HtmlOptions.new
81-
viewOptions.render_options.start_page_number = 1
82-
viewOptions.render_options.count_pages_to_render = 2
29+
# Create instance of the API class
30+
api = GroupDocsViewerCloud::InfoApi.from_keys(app_sid, app_key)
8331

84-
request = GroupDocsViewerCloud::CreateViewRequest.new(viewOptions)
85-
response = apiInstance.create_view(request)
32+
# Retrieve supported file-formats
33+
response = api.get_supported_file_formats
8634

35+
# Print out supported file-formats
36+
puts("Supported file-formats:")
37+
response.formats.each do |format|
38+
puts("#{format.file_format} (#{format.extension})")
39+
end
8740
```
8841

89-
## GroupDocs.Viewer Cloud SDKs in Popular Languages
42+
## Licensing
43+
GroupDocs.Viewer Cloud Ruby SDK licensed under [MIT License](LICENSE).
9044

91-
| .NET | Java | PHP | Python | Ruby | Node.js | Android |
92-
|---|---|---|---|---|---|---|
93-
| [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-dotnet) | [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-java) | [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-php) | [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-python) | [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-ruby) | [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-node) | [GitHub](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-android) |
94-
| [NuGet](https://www.nuget.org/packages/GroupDocs.Viewer-Cloud/) | [Maven](https://repository.groupdocs.cloud/webapp/#/artifacts/browse/tree/General/repo/com/groupdocs/groupdocs-viewer-cloud) | [Composer](https://packagist.org/packages/groupdocscloud/groupdocs-viewer-cloud) | [PIP](https://pypi.org/project/groupdocs-viewer-cloud/) | [GEM](https://rubygems.org/gems/groupdocs_viewer_cloud) | [NPM](https://www.npmjs.com/package/groupdocs-viewer-cloud) | [Maven](https://repository.groupdocs.cloud/webapp/#/artifacts/browse/tree/General/repo/com/groupdocs/groupdocs-viewer-cloud-android) |
45+
## Resources
46+
+ [**Website**](https://www.groupdocs.cloud)
47+
+ [**Product Home**](https://products.groupdocs.cloud/viewer)
48+
+ [**Documentation**](https://docs.groupdocs.cloud/display/viewercloud/Home)
49+
+ [**Free Support Forum**](https://forum.groupdocs.cloud/c/viewer)
50+
+ [**Blog**](https://blog.groupdocs.cloud/category/viewer)
9551

96-
[Home](https://www.groupdocs.cloud/) | [Product Page](https://products.groupdocs.cloud/viewer/ruby) | [Documentation](https://docs.groupdocs.cloud/viewer/) | [Live Demo](https://products.groupdocs.app/viewer/total) | [API Reference](https://apireference.groupdocs.cloud/viewer/) | [Code Samples](https://github.com/groupdocs-viewer-cloud/groupdocs-viewer-cloud-ruby-samples) | [Blog](https://blog.groupdocs.cloud/category/viewer/) | [Free Support](https://forum.groupdocs.cloud/c/viewer) | [Free Trial](https://dashboard.groupdocs.cloud)
52+
## Contact Us
53+
Your feedback is very important to us. Please feel free to contact us using our [Support Forums](https://forum.groupdocs.cloud/c/viewer).

lib/groupdocs_viewer_cloud.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# ------------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="groupdocs_viewer_cloud.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy

lib/groupdocs_viewer_cloud/api/file_api.rb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -----------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="file.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -449,7 +449,7 @@ def upload_file_with_http_info(request)
449449
#
450450
# --------------------------------------------------------------------------------------------------------------------
451451
# <copyright company="Aspose Pty Ltd" file="copy_file_request.rb">
452-
# Copyright (c) 2003-2020 Aspose Pty Ltd
452+
# Copyright (c) 2003-2021 Aspose Pty Ltd
453453
# </copyright>
454454
# <summary>
455455
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -510,7 +510,7 @@ def initialize(src_path, dest_path, src_storage_name = nil, dest_storage_name =
510510
#
511511
# --------------------------------------------------------------------------------------------------------------------
512512
# <copyright company="Aspose Pty Ltd" file="delete_file_request.rb">
513-
# Copyright (c) 2003-2020 Aspose Pty Ltd
513+
# Copyright (c) 2003-2021 Aspose Pty Ltd
514514
# </copyright>
515515
# <summary>
516516
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -563,7 +563,7 @@ def initialize(path, storage_name = nil, version_id = nil)
563563
#
564564
# --------------------------------------------------------------------------------------------------------------------
565565
# <copyright company="Aspose Pty Ltd" file="download_file_request.rb">
566-
# Copyright (c) 2003-2020 Aspose Pty Ltd
566+
# Copyright (c) 2003-2021 Aspose Pty Ltd
567567
# </copyright>
568568
# <summary>
569569
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -616,7 +616,7 @@ def initialize(path, storage_name = nil, version_id = nil)
616616
#
617617
# --------------------------------------------------------------------------------------------------------------------
618618
# <copyright company="Aspose Pty Ltd" file="move_file_request.rb">
619-
# Copyright (c) 2003-2020 Aspose Pty Ltd
619+
# Copyright (c) 2003-2021 Aspose Pty Ltd
620620
# </copyright>
621621
# <summary>
622622
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -677,7 +677,7 @@ def initialize(src_path, dest_path, src_storage_name = nil, dest_storage_name =
677677
#
678678
# --------------------------------------------------------------------------------------------------------------------
679679
# <copyright company="Aspose Pty Ltd" file="upload_file_request.rb">
680-
# Copyright (c) 2003-2020 Aspose Pty Ltd
680+
# Copyright (c) 2003-2021 Aspose Pty Ltd
681681
# </copyright>
682682
# <summary>
683683
# Permission is hereby granted, free of charge, to any person obtaining a copy

lib/groupdocs_viewer_cloud/api/folder_api.rb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -----------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="folder.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -430,7 +430,7 @@ def move_folder_with_http_info(request)
430430
#
431431
# --------------------------------------------------------------------------------------------------------------------
432432
# <copyright company="Aspose Pty Ltd" file="copy_folder_request.rb">
433-
# Copyright (c) 2003-2020 Aspose Pty Ltd
433+
# Copyright (c) 2003-2021 Aspose Pty Ltd
434434
# </copyright>
435435
# <summary>
436436
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -487,7 +487,7 @@ def initialize(src_path, dest_path, src_storage_name = nil, dest_storage_name =
487487
#
488488
# --------------------------------------------------------------------------------------------------------------------
489489
# <copyright company="Aspose Pty Ltd" file="create_folder_request.rb">
490-
# Copyright (c) 2003-2020 Aspose Pty Ltd
490+
# Copyright (c) 2003-2021 Aspose Pty Ltd
491491
# </copyright>
492492
# <summary>
493493
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -536,7 +536,7 @@ def initialize(path, storage_name = nil)
536536
#
537537
# --------------------------------------------------------------------------------------------------------------------
538538
# <copyright company="Aspose Pty Ltd" file="delete_folder_request.rb">
539-
# Copyright (c) 2003-2020 Aspose Pty Ltd
539+
# Copyright (c) 2003-2021 Aspose Pty Ltd
540540
# </copyright>
541541
# <summary>
542542
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -589,7 +589,7 @@ def initialize(path, storage_name = nil, recursive = nil)
589589
#
590590
# --------------------------------------------------------------------------------------------------------------------
591591
# <copyright company="Aspose Pty Ltd" file="get_files_list_request.rb">
592-
# Copyright (c) 2003-2020 Aspose Pty Ltd
592+
# Copyright (c) 2003-2021 Aspose Pty Ltd
593593
# </copyright>
594594
# <summary>
595595
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -638,7 +638,7 @@ def initialize(path, storage_name = nil)
638638
#
639639
# --------------------------------------------------------------------------------------------------------------------
640640
# <copyright company="Aspose Pty Ltd" file="move_folder_request.rb">
641-
# Copyright (c) 2003-2020 Aspose Pty Ltd
641+
# Copyright (c) 2003-2021 Aspose Pty Ltd
642642
# </copyright>
643643
# <summary>
644644
# Permission is hereby granted, free of charge, to any person obtaining a copy

lib/groupdocs_viewer_cloud/api/info_api.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -----------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="info.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -222,7 +222,7 @@ def get_supported_file_formats_with_http_info()
222222
#
223223
# --------------------------------------------------------------------------------------------------------------------
224224
# <copyright company="Aspose Pty Ltd" file="get_info_request.rb">
225-
# Copyright (c) 2003-2020 Aspose Pty Ltd
225+
# Copyright (c) 2003-2021 Aspose Pty Ltd
226226
# </copyright>
227227
# <summary>
228228
# Permission is hereby granted, free of charge, to any person obtaining a copy

lib/groupdocs_viewer_cloud/api/storage_api.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -----------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="storage.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -350,7 +350,7 @@ def storage_exists_with_http_info(request)
350350
#
351351
# --------------------------------------------------------------------------------------------------------------------
352352
# <copyright company="Aspose Pty Ltd" file="get_disc_usage_request.rb">
353-
# Copyright (c) 2003-2020 Aspose Pty Ltd
353+
# Copyright (c) 2003-2021 Aspose Pty Ltd
354354
# </copyright>
355355
# <summary>
356356
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -395,7 +395,7 @@ def initialize(storage_name = nil)
395395
#
396396
# --------------------------------------------------------------------------------------------------------------------
397397
# <copyright company="Aspose Pty Ltd" file="get_file_versions_request.rb">
398-
# Copyright (c) 2003-2020 Aspose Pty Ltd
398+
# Copyright (c) 2003-2021 Aspose Pty Ltd
399399
# </copyright>
400400
# <summary>
401401
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -444,7 +444,7 @@ def initialize(path, storage_name = nil)
444444
#
445445
# --------------------------------------------------------------------------------------------------------------------
446446
# <copyright company="Aspose Pty Ltd" file="object_exists_request.rb">
447-
# Copyright (c) 2003-2020 Aspose Pty Ltd
447+
# Copyright (c) 2003-2021 Aspose Pty Ltd
448448
# </copyright>
449449
# <summary>
450450
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -497,7 +497,7 @@ def initialize(path, storage_name = nil, version_id = nil)
497497
#
498498
# --------------------------------------------------------------------------------------------------------------------
499499
# <copyright company="Aspose Pty Ltd" file="storage_exists_request.rb">
500-
# Copyright (c) 2003-2020 Aspose Pty Ltd
500+
# Copyright (c) 2003-2021 Aspose Pty Ltd
501501
# </copyright>
502502
# <summary>
503503
# Permission is hereby granted, free of charge, to any person obtaining a copy

lib/groupdocs_viewer_cloud/api/view_api.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -----------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="view.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -224,7 +224,7 @@ def delete_view_with_http_info(request)
224224
#
225225
# --------------------------------------------------------------------------------------------------------------------
226226
# <copyright company="Aspose Pty Ltd" file="create_view_request.rb">
227-
# Copyright (c) 2003-2020 Aspose Pty Ltd
227+
# Copyright (c) 2003-2021 Aspose Pty Ltd
228228
# </copyright>
229229
# <summary>
230230
# Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -269,7 +269,7 @@ def initialize(view_options)
269269
#
270270
# --------------------------------------------------------------------------------------------------------------------
271271
# <copyright company="Aspose Pty Ltd" file="delete_view_request.rb">
272-
# Copyright (c) 2003-2020 Aspose Pty Ltd
272+
# Copyright (c) 2003-2021 Aspose Pty Ltd
273273
# </copyright>
274274
# <summary>
275275
# Permission is hereby granted, free of charge, to any person obtaining a copy

lib/groupdocs_viewer_cloud/api_client.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -----------------------------------------------------------------------------------
22
# <copyright company="Aspose Pty Ltd" file="api_client.rb">
3-
# Copyright (c) 2003-2020 Aspose Pty Ltd
3+
# Copyright (c) 2003-2021 Aspose Pty Ltd
44
# </copyright>
55
# <summary>
66
# Permission is hereby granted, free of charge, to any person obtaining a copy

0 commit comments

Comments
 (0)