swagger_aem 1.1.1 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +7 -4
- data/docs/CrxApi.md +45 -0
- data/docs/InstallStatus.md +8 -0
- data/docs/InstallStatusStatus.md +9 -0
- data/lib/swagger_aem.rb +3 -1
- data/lib/swagger_aem/api/console_api.rb +1 -1
- data/lib/swagger_aem/api/cq_api.rb +1 -1
- data/lib/swagger_aem/api/crx_api.rb +48 -1
- data/lib/swagger_aem/api/custom_api.rb +1 -1
- data/lib/swagger_aem/api/sling_api.rb +1 -1
- data/lib/swagger_aem/api_client.rb +2 -2
- data/lib/swagger_aem/api_error.rb +1 -1
- data/lib/swagger_aem/configuration.rb +1 -1
- data/lib/swagger_aem/models/install_status.rb +188 -0
- data/lib/swagger_aem/models/install_status_status.rb +197 -0
- data/lib/swagger_aem/version.rb +2 -2
- data/spec/api/console_api_spec.rb +2 -2
- data/spec/api/cq_api_spec.rb +2 -2
- data/spec/api/crx_api_spec.rb +13 -2
- data/spec/api/custom_api_spec.rb +2 -2
- data/spec/api/sling_api_spec.rb +2 -2
- data/spec/api_client_spec.rb +1 -1
- data/spec/configuration_spec.rb +1 -1
- data/spec/models/install_status_spec.rb +42 -0
- data/spec/models/install_status_status_spec.rb +48 -0
- data/spec/spec_helper.rb +1 -1
- data/swagger_aem.gemspec +3 -3
- metadata +18 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7372f178d09a14a526304f5c402cc3912a21d3d8
|
4
|
+
data.tar.gz: 7d5c1c71b7bcdedae4ffd856f0384b2fd06302b3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d3e7425ea8a8056cc7d8da5e20ef8aac9c5c847838ecd83c004440d7d4da5763747e70c2e4927ee0511701aa8c1759e764325ce392f3726d7bab83b951e093f9
|
7
|
+
data.tar.gz: 1cd077f0a069abc059413b7f59ab44c0479b1f84c10f7365adda93566001bed5a70cc6805d7c003ed428585722384479bbae6490820020572aeeb06ac61eb9df
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ Swagger AEM is an OpenAPI specification for Adobe Experience Manager (AEM) API
|
|
7
7
|
This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
|
8
8
|
|
9
9
|
- API version: 1.2.0
|
10
|
-
- Package version: 1.
|
10
|
+
- Package version: 1.2.0
|
11
11
|
- Build package: io.swagger.codegen.languages.RubyClientCodegen
|
12
12
|
For more information, please visit [http://shinesolutions.com](http://shinesolutions.com)
|
13
13
|
|
@@ -24,15 +24,15 @@ gem build swagger_aem.gemspec
|
|
24
24
|
Then either install the gem locally:
|
25
25
|
|
26
26
|
```shell
|
27
|
-
gem install ./swagger_aem-1.
|
27
|
+
gem install ./swagger_aem-1.2.0.gem
|
28
28
|
```
|
29
|
-
(for development, run `gem install --dev ./swagger_aem-1.
|
29
|
+
(for development, run `gem install --dev ./swagger_aem-1.2.0.gem` to install the development dependencies)
|
30
30
|
|
31
31
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
32
32
|
|
33
33
|
Finally add this to the Gemfile:
|
34
34
|
|
35
|
-
gem 'swagger_aem', '~> 1.
|
35
|
+
gem 'swagger_aem', '~> 1.2.0'
|
36
36
|
|
37
37
|
### Install from Git
|
38
38
|
|
@@ -87,6 +87,7 @@ Class | Method | HTTP request | Description
|
|
87
87
|
*SwaggerAemClient::ConsoleApi* | [**post_jmx_repository**](docs/ConsoleApi.md#post_jmx_repository) | **POST** /system/console/jmx/com.adobe.granite:type=Repository/op/{action} |
|
88
88
|
*SwaggerAemClient::CqApi* | [**get_login_page**](docs/CqApi.md#get_login_page) | **GET** /libs/granite/core/content/login.html |
|
89
89
|
*SwaggerAemClient::CqApi* | [**post_cq_actions**](docs/CqApi.md#post_cq_actions) | **POST** /.cqactions.html |
|
90
|
+
*SwaggerAemClient::CrxApi* | [**get_install_status**](docs/CrxApi.md#get_install_status) | **GET** /crx/packmgr/installstatus.jsp |
|
90
91
|
*SwaggerAemClient::CrxApi* | [**post_package_service**](docs/CrxApi.md#post_package_service) | **POST** /crx/packmgr/service.jsp |
|
91
92
|
*SwaggerAemClient::CrxApi* | [**post_package_service_json**](docs/CrxApi.md#post_package_service_json) | **POST** /crx/packmgr/service/.json/{path} |
|
92
93
|
*SwaggerAemClient::CrxApi* | [**post_package_update**](docs/CrxApi.md#post_package_update) | **POST** /crx/packmgr/update.jsp |
|
@@ -116,6 +117,8 @@ Class | Method | HTTP request | Description
|
|
116
117
|
|
117
118
|
## Documentation for Models
|
118
119
|
|
120
|
+
- [SwaggerAemClient::InstallStatus](docs/InstallStatus.md)
|
121
|
+
- [SwaggerAemClient::InstallStatusStatus](docs/InstallStatusStatus.md)
|
119
122
|
|
120
123
|
|
121
124
|
## Documentation for Authorization
|
data/docs/CrxApi.md
CHANGED
@@ -4,12 +4,57 @@ All URIs are relative to *http://localhost*
|
|
4
4
|
|
5
5
|
Method | HTTP request | Description
|
6
6
|
------------- | ------------- | -------------
|
7
|
+
[**get_install_status**](CrxApi.md#get_install_status) | **GET** /crx/packmgr/installstatus.jsp |
|
7
8
|
[**post_package_service**](CrxApi.md#post_package_service) | **POST** /crx/packmgr/service.jsp |
|
8
9
|
[**post_package_service_json**](CrxApi.md#post_package_service_json) | **POST** /crx/packmgr/service/.json/{path} |
|
9
10
|
[**post_package_update**](CrxApi.md#post_package_update) | **POST** /crx/packmgr/update.jsp |
|
10
11
|
[**post_set_password**](CrxApi.md#post_set_password) | **POST** /crx/explorer/ui/setpassword.jsp |
|
11
12
|
|
12
13
|
|
14
|
+
# **get_install_status**
|
15
|
+
> InstallStatus get_install_status
|
16
|
+
|
17
|
+
|
18
|
+
|
19
|
+
### Example
|
20
|
+
```ruby
|
21
|
+
# load the gem
|
22
|
+
require 'swagger_aem'
|
23
|
+
# setup authorization
|
24
|
+
SwaggerAemClient.configure do |config|
|
25
|
+
# Configure HTTP basic authorization: aemAuth
|
26
|
+
config.username = 'YOUR USERNAME'
|
27
|
+
config.password = 'YOUR PASSWORD'
|
28
|
+
end
|
29
|
+
|
30
|
+
api_instance = SwaggerAemClient::CrxApi.new
|
31
|
+
|
32
|
+
begin
|
33
|
+
result = api_instance.get_install_status
|
34
|
+
p result
|
35
|
+
rescue SwaggerAemClient::ApiError => e
|
36
|
+
puts "Exception when calling CrxApi->get_install_status: #{e}"
|
37
|
+
end
|
38
|
+
```
|
39
|
+
|
40
|
+
### Parameters
|
41
|
+
This endpoint does not need any parameter.
|
42
|
+
|
43
|
+
### Return type
|
44
|
+
|
45
|
+
[**InstallStatus**](InstallStatus.md)
|
46
|
+
|
47
|
+
### Authorization
|
48
|
+
|
49
|
+
[aemAuth](../README.md#aemAuth)
|
50
|
+
|
51
|
+
### HTTP request headers
|
52
|
+
|
53
|
+
- **Content-Type**: Not defined
|
54
|
+
- **Accept**: application/json
|
55
|
+
|
56
|
+
|
57
|
+
|
13
58
|
# **post_package_service**
|
14
59
|
> String post_package_service(cmd)
|
15
60
|
|
data/lib/swagger_aem.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -17,6 +17,8 @@ require 'swagger_aem/version'
|
|
17
17
|
require 'swagger_aem/configuration'
|
18
18
|
|
19
19
|
# Models
|
20
|
+
require 'swagger_aem/models/install_status'
|
21
|
+
require 'swagger_aem/models/install_status_status'
|
20
22
|
|
21
23
|
# APIs
|
22
24
|
require 'swagger_aem/api/console_api'
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -20,6 +20,53 @@ module SwaggerAemClient
|
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
22
|
|
23
|
+
#
|
24
|
+
#
|
25
|
+
# @param [Hash] opts the optional parameters
|
26
|
+
# @return [InstallStatus]
|
27
|
+
def get_install_status(opts = {})
|
28
|
+
data, _status_code, _headers = get_install_status_with_http_info(opts)
|
29
|
+
return data
|
30
|
+
end
|
31
|
+
|
32
|
+
#
|
33
|
+
#
|
34
|
+
# @param [Hash] opts the optional parameters
|
35
|
+
# @return [Array<(InstallStatus, Fixnum, Hash)>] InstallStatus data, response status code and response headers
|
36
|
+
def get_install_status_with_http_info(opts = {})
|
37
|
+
if @api_client.config.debugging
|
38
|
+
@api_client.config.logger.debug "Calling API: CrxApi.get_install_status ..."
|
39
|
+
end
|
40
|
+
# resource path
|
41
|
+
local_var_path = "/crx/packmgr/installstatus.jsp"
|
42
|
+
|
43
|
+
# query parameters
|
44
|
+
query_params = {}
|
45
|
+
|
46
|
+
# header parameters
|
47
|
+
header_params = {}
|
48
|
+
# HTTP header 'Accept' (if needed)
|
49
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
50
|
+
|
51
|
+
# form parameters
|
52
|
+
form_params = {}
|
53
|
+
|
54
|
+
# http body (model)
|
55
|
+
post_body = nil
|
56
|
+
auth_names = ['aemAuth']
|
57
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
58
|
+
:header_params => header_params,
|
59
|
+
:query_params => query_params,
|
60
|
+
:form_params => form_params,
|
61
|
+
:body => post_body,
|
62
|
+
:auth_names => auth_names,
|
63
|
+
:return_type => 'InstallStatus')
|
64
|
+
if @api_client.config.debugging
|
65
|
+
@api_client.config.logger.debug "API called: CrxApi#get_install_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
66
|
+
end
|
67
|
+
return data, status_code, headers
|
68
|
+
end
|
69
|
+
|
23
70
|
#
|
24
71
|
#
|
25
72
|
# @param cmd
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -280,7 +280,7 @@ module SwaggerAemClient
|
|
280
280
|
data = {}
|
281
281
|
form_params.each do |key, value|
|
282
282
|
case value
|
283
|
-
when File, Array, nil
|
283
|
+
when ::File, ::Array, nil
|
284
284
|
# let typhoeus handle File, Array and nil parameters
|
285
285
|
data[key] = value
|
286
286
|
else
|
@@ -0,0 +1,188 @@
|
|
1
|
+
=begin
|
2
|
+
#Adobe Experience Manager (AEM) API
|
3
|
+
|
4
|
+
#Swagger AEM is an OpenAPI specification for Adobe Experience Manager (AEM) API
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.2.0
|
7
|
+
Contact: opensource@shinesolutions.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module SwaggerAemClient
|
16
|
+
|
17
|
+
class InstallStatus
|
18
|
+
attr_accessor :status
|
19
|
+
|
20
|
+
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
22
|
+
def self.attribute_map
|
23
|
+
{
|
24
|
+
:'status' => :'status'
|
25
|
+
}
|
26
|
+
end
|
27
|
+
|
28
|
+
# Attribute type mapping.
|
29
|
+
def self.swagger_types
|
30
|
+
{
|
31
|
+
:'status' => :'InstallStatusStatus'
|
32
|
+
}
|
33
|
+
end
|
34
|
+
|
35
|
+
# Initializes the object
|
36
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
37
|
+
def initialize(attributes = {})
|
38
|
+
return unless attributes.is_a?(Hash)
|
39
|
+
|
40
|
+
# convert string to symbol for hash key
|
41
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
42
|
+
|
43
|
+
if attributes.has_key?(:'status')
|
44
|
+
self.status = attributes[:'status']
|
45
|
+
end
|
46
|
+
|
47
|
+
end
|
48
|
+
|
49
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
50
|
+
# @return Array for valid properies with the reasons
|
51
|
+
def list_invalid_properties
|
52
|
+
invalid_properties = Array.new
|
53
|
+
return invalid_properties
|
54
|
+
end
|
55
|
+
|
56
|
+
# Check to see if the all the properties in the model are valid
|
57
|
+
# @return true if the model is valid
|
58
|
+
def valid?
|
59
|
+
return true
|
60
|
+
end
|
61
|
+
|
62
|
+
# Checks equality by comparing each attribute.
|
63
|
+
# @param [Object] Object to be compared
|
64
|
+
def ==(o)
|
65
|
+
return true if self.equal?(o)
|
66
|
+
self.class == o.class &&
|
67
|
+
status == o.status
|
68
|
+
end
|
69
|
+
|
70
|
+
# @see the `==` method
|
71
|
+
# @param [Object] Object to be compared
|
72
|
+
def eql?(o)
|
73
|
+
self == o
|
74
|
+
end
|
75
|
+
|
76
|
+
# Calculates hash code according to all attributes.
|
77
|
+
# @return [Fixnum] Hash code
|
78
|
+
def hash
|
79
|
+
[status].hash
|
80
|
+
end
|
81
|
+
|
82
|
+
# Builds the object from hash
|
83
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
84
|
+
# @return [Object] Returns the model itself
|
85
|
+
def build_from_hash(attributes)
|
86
|
+
return nil unless attributes.is_a?(Hash)
|
87
|
+
self.class.swagger_types.each_pair do |key, type|
|
88
|
+
if type =~ /\AArray<(.*)>/i
|
89
|
+
# check to ensure the input is an array given that the the attribute
|
90
|
+
# is documented as an array but the input is not
|
91
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
92
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
93
|
+
end
|
94
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
95
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
96
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
97
|
+
end
|
98
|
+
|
99
|
+
self
|
100
|
+
end
|
101
|
+
|
102
|
+
# Deserializes the data based on type
|
103
|
+
# @param string type Data type
|
104
|
+
# @param string value Value to be deserialized
|
105
|
+
# @return [Object] Deserialized data
|
106
|
+
def _deserialize(type, value)
|
107
|
+
case type.to_sym
|
108
|
+
when :DateTime
|
109
|
+
DateTime.parse(value)
|
110
|
+
when :Date
|
111
|
+
Date.parse(value)
|
112
|
+
when :String
|
113
|
+
value.to_s
|
114
|
+
when :Integer
|
115
|
+
value.to_i
|
116
|
+
when :Float
|
117
|
+
value.to_f
|
118
|
+
when :BOOLEAN
|
119
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
120
|
+
true
|
121
|
+
else
|
122
|
+
false
|
123
|
+
end
|
124
|
+
when :Object
|
125
|
+
# generic object (usually a Hash), return directly
|
126
|
+
value
|
127
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
128
|
+
inner_type = Regexp.last_match[:inner_type]
|
129
|
+
value.map { |v| _deserialize(inner_type, v) }
|
130
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
131
|
+
k_type = Regexp.last_match[:k_type]
|
132
|
+
v_type = Regexp.last_match[:v_type]
|
133
|
+
{}.tap do |hash|
|
134
|
+
value.each do |k, v|
|
135
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
136
|
+
end
|
137
|
+
end
|
138
|
+
else # model
|
139
|
+
temp_model = SwaggerAemClient.const_get(type).new
|
140
|
+
temp_model.build_from_hash(value)
|
141
|
+
end
|
142
|
+
end
|
143
|
+
|
144
|
+
# Returns the string representation of the object
|
145
|
+
# @return [String] String presentation of the object
|
146
|
+
def to_s
|
147
|
+
to_hash.to_s
|
148
|
+
end
|
149
|
+
|
150
|
+
# to_body is an alias to to_hash (backward compatibility)
|
151
|
+
# @return [Hash] Returns the object in the form of hash
|
152
|
+
def to_body
|
153
|
+
to_hash
|
154
|
+
end
|
155
|
+
|
156
|
+
# Returns the object in the form of hash
|
157
|
+
# @return [Hash] Returns the object in the form of hash
|
158
|
+
def to_hash
|
159
|
+
hash = {}
|
160
|
+
self.class.attribute_map.each_pair do |attr, param|
|
161
|
+
value = self.send(attr)
|
162
|
+
next if value.nil?
|
163
|
+
hash[param] = _to_hash(value)
|
164
|
+
end
|
165
|
+
hash
|
166
|
+
end
|
167
|
+
|
168
|
+
# Outputs non-array value in the form of hash
|
169
|
+
# For object, use to_hash. Otherwise, just return the value
|
170
|
+
# @param [Object] value Any valid value
|
171
|
+
# @return [Hash] Returns the value in the form of hash
|
172
|
+
def _to_hash(value)
|
173
|
+
if value.is_a?(Array)
|
174
|
+
value.compact.map{ |v| _to_hash(v) }
|
175
|
+
elsif value.is_a?(Hash)
|
176
|
+
{}.tap do |hash|
|
177
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
178
|
+
end
|
179
|
+
elsif value.respond_to? :to_hash
|
180
|
+
value.to_hash
|
181
|
+
else
|
182
|
+
value
|
183
|
+
end
|
184
|
+
end
|
185
|
+
|
186
|
+
end
|
187
|
+
|
188
|
+
end
|
@@ -0,0 +1,197 @@
|
|
1
|
+
=begin
|
2
|
+
#Adobe Experience Manager (AEM) API
|
3
|
+
|
4
|
+
#Swagger AEM is an OpenAPI specification for Adobe Experience Manager (AEM) API
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.2.0
|
7
|
+
Contact: opensource@shinesolutions.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module SwaggerAemClient
|
16
|
+
|
17
|
+
class InstallStatusStatus
|
18
|
+
attr_accessor :finished
|
19
|
+
|
20
|
+
attr_accessor :item_count
|
21
|
+
|
22
|
+
|
23
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
24
|
+
def self.attribute_map
|
25
|
+
{
|
26
|
+
:'finished' => :'finished',
|
27
|
+
:'item_count' => :'itemCount'
|
28
|
+
}
|
29
|
+
end
|
30
|
+
|
31
|
+
# Attribute type mapping.
|
32
|
+
def self.swagger_types
|
33
|
+
{
|
34
|
+
:'finished' => :'BOOLEAN',
|
35
|
+
:'item_count' => :'Integer'
|
36
|
+
}
|
37
|
+
end
|
38
|
+
|
39
|
+
# Initializes the object
|
40
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
41
|
+
def initialize(attributes = {})
|
42
|
+
return unless attributes.is_a?(Hash)
|
43
|
+
|
44
|
+
# convert string to symbol for hash key
|
45
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
46
|
+
|
47
|
+
if attributes.has_key?(:'finished')
|
48
|
+
self.finished = attributes[:'finished']
|
49
|
+
end
|
50
|
+
|
51
|
+
if attributes.has_key?(:'itemCount')
|
52
|
+
self.item_count = attributes[:'itemCount']
|
53
|
+
end
|
54
|
+
|
55
|
+
end
|
56
|
+
|
57
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
58
|
+
# @return Array for valid properies with the reasons
|
59
|
+
def list_invalid_properties
|
60
|
+
invalid_properties = Array.new
|
61
|
+
return invalid_properties
|
62
|
+
end
|
63
|
+
|
64
|
+
# Check to see if the all the properties in the model are valid
|
65
|
+
# @return true if the model is valid
|
66
|
+
def valid?
|
67
|
+
return true
|
68
|
+
end
|
69
|
+
|
70
|
+
# Checks equality by comparing each attribute.
|
71
|
+
# @param [Object] Object to be compared
|
72
|
+
def ==(o)
|
73
|
+
return true if self.equal?(o)
|
74
|
+
self.class == o.class &&
|
75
|
+
finished == o.finished &&
|
76
|
+
item_count == o.item_count
|
77
|
+
end
|
78
|
+
|
79
|
+
# @see the `==` method
|
80
|
+
# @param [Object] Object to be compared
|
81
|
+
def eql?(o)
|
82
|
+
self == o
|
83
|
+
end
|
84
|
+
|
85
|
+
# Calculates hash code according to all attributes.
|
86
|
+
# @return [Fixnum] Hash code
|
87
|
+
def hash
|
88
|
+
[finished, item_count].hash
|
89
|
+
end
|
90
|
+
|
91
|
+
# Builds the object from hash
|
92
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
93
|
+
# @return [Object] Returns the model itself
|
94
|
+
def build_from_hash(attributes)
|
95
|
+
return nil unless attributes.is_a?(Hash)
|
96
|
+
self.class.swagger_types.each_pair do |key, type|
|
97
|
+
if type =~ /\AArray<(.*)>/i
|
98
|
+
# check to ensure the input is an array given that the the attribute
|
99
|
+
# is documented as an array but the input is not
|
100
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
101
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
102
|
+
end
|
103
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
104
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
105
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
106
|
+
end
|
107
|
+
|
108
|
+
self
|
109
|
+
end
|
110
|
+
|
111
|
+
# Deserializes the data based on type
|
112
|
+
# @param string type Data type
|
113
|
+
# @param string value Value to be deserialized
|
114
|
+
# @return [Object] Deserialized data
|
115
|
+
def _deserialize(type, value)
|
116
|
+
case type.to_sym
|
117
|
+
when :DateTime
|
118
|
+
DateTime.parse(value)
|
119
|
+
when :Date
|
120
|
+
Date.parse(value)
|
121
|
+
when :String
|
122
|
+
value.to_s
|
123
|
+
when :Integer
|
124
|
+
value.to_i
|
125
|
+
when :Float
|
126
|
+
value.to_f
|
127
|
+
when :BOOLEAN
|
128
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
129
|
+
true
|
130
|
+
else
|
131
|
+
false
|
132
|
+
end
|
133
|
+
when :Object
|
134
|
+
# generic object (usually a Hash), return directly
|
135
|
+
value
|
136
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
137
|
+
inner_type = Regexp.last_match[:inner_type]
|
138
|
+
value.map { |v| _deserialize(inner_type, v) }
|
139
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
140
|
+
k_type = Regexp.last_match[:k_type]
|
141
|
+
v_type = Regexp.last_match[:v_type]
|
142
|
+
{}.tap do |hash|
|
143
|
+
value.each do |k, v|
|
144
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
145
|
+
end
|
146
|
+
end
|
147
|
+
else # model
|
148
|
+
temp_model = SwaggerAemClient.const_get(type).new
|
149
|
+
temp_model.build_from_hash(value)
|
150
|
+
end
|
151
|
+
end
|
152
|
+
|
153
|
+
# Returns the string representation of the object
|
154
|
+
# @return [String] String presentation of the object
|
155
|
+
def to_s
|
156
|
+
to_hash.to_s
|
157
|
+
end
|
158
|
+
|
159
|
+
# to_body is an alias to to_hash (backward compatibility)
|
160
|
+
# @return [Hash] Returns the object in the form of hash
|
161
|
+
def to_body
|
162
|
+
to_hash
|
163
|
+
end
|
164
|
+
|
165
|
+
# Returns the object in the form of hash
|
166
|
+
# @return [Hash] Returns the object in the form of hash
|
167
|
+
def to_hash
|
168
|
+
hash = {}
|
169
|
+
self.class.attribute_map.each_pair do |attr, param|
|
170
|
+
value = self.send(attr)
|
171
|
+
next if value.nil?
|
172
|
+
hash[param] = _to_hash(value)
|
173
|
+
end
|
174
|
+
hash
|
175
|
+
end
|
176
|
+
|
177
|
+
# Outputs non-array value in the form of hash
|
178
|
+
# For object, use to_hash. Otherwise, just return the value
|
179
|
+
# @param [Object] value Any valid value
|
180
|
+
# @return [Hash] Returns the value in the form of hash
|
181
|
+
def _to_hash(value)
|
182
|
+
if value.is_a?(Array)
|
183
|
+
value.compact.map{ |v| _to_hash(v) }
|
184
|
+
elsif value.is_a?(Hash)
|
185
|
+
{}.tap do |hash|
|
186
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
187
|
+
end
|
188
|
+
elsif value.respond_to? :to_hash
|
189
|
+
value.to_hash
|
190
|
+
else
|
191
|
+
value
|
192
|
+
end
|
193
|
+
end
|
194
|
+
|
195
|
+
end
|
196
|
+
|
197
|
+
end
|
data/lib/swagger_aem/version.rb
CHANGED
@@ -6,10 +6,10 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
13
13
|
module SwaggerAemClient
|
14
|
-
VERSION = "1.
|
14
|
+
VERSION = "1.2.0"
|
15
15
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,7 +27,7 @@ describe 'ConsoleApi' do
|
|
27
27
|
end
|
28
28
|
|
29
29
|
describe 'test an instance of ConsoleApi' do
|
30
|
-
it 'should create an
|
30
|
+
it 'should create an instance of ConsoleApi' do
|
31
31
|
expect(@instance).to be_instance_of(SwaggerAemClient::ConsoleApi)
|
32
32
|
end
|
33
33
|
end
|
data/spec/api/cq_api_spec.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,7 +27,7 @@ describe 'CqApi' do
|
|
27
27
|
end
|
28
28
|
|
29
29
|
describe 'test an instance of CqApi' do
|
30
|
-
it 'should create an
|
30
|
+
it 'should create an instance of CqApi' do
|
31
31
|
expect(@instance).to be_instance_of(SwaggerAemClient::CqApi)
|
32
32
|
end
|
33
33
|
end
|
data/spec/api/crx_api_spec.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,11 +27,22 @@ describe 'CrxApi' do
|
|
27
27
|
end
|
28
28
|
|
29
29
|
describe 'test an instance of CrxApi' do
|
30
|
-
it 'should create an
|
30
|
+
it 'should create an instance of CrxApi' do
|
31
31
|
expect(@instance).to be_instance_of(SwaggerAemClient::CrxApi)
|
32
32
|
end
|
33
33
|
end
|
34
34
|
|
35
|
+
# unit tests for get_install_status
|
36
|
+
#
|
37
|
+
#
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @return [InstallStatus]
|
40
|
+
describe 'get_install_status test' do
|
41
|
+
it "should work" do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
35
46
|
# unit tests for post_package_service
|
36
47
|
#
|
37
48
|
#
|
data/spec/api/custom_api_spec.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,7 +27,7 @@ describe 'CustomApi' do
|
|
27
27
|
end
|
28
28
|
|
29
29
|
describe 'test an instance of CustomApi' do
|
30
|
-
it 'should create an
|
30
|
+
it 'should create an instance of CustomApi' do
|
31
31
|
expect(@instance).to be_instance_of(SwaggerAemClient::CustomApi)
|
32
32
|
end
|
33
33
|
end
|
data/spec/api/sling_api_spec.rb
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: 1.2.0
|
7
7
|
Contact: opensource@shinesolutions.com
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,7 +27,7 @@ describe 'SlingApi' do
|
|
27
27
|
end
|
28
28
|
|
29
29
|
describe 'test an instance of SlingApi' do
|
30
|
-
it 'should create an
|
30
|
+
it 'should create an instance of SlingApi' do
|
31
31
|
expect(@instance).to be_instance_of(SwaggerAemClient::SlingApi)
|
32
32
|
end
|
33
33
|
end
|
data/spec/api_client_spec.rb
CHANGED
data/spec/configuration_spec.rb
CHANGED
@@ -0,0 +1,42 @@
|
|
1
|
+
=begin
|
2
|
+
#Adobe Experience Manager (AEM) API
|
3
|
+
|
4
|
+
#Swagger AEM is an OpenAPI specification for Adobe Experience Manager (AEM) API
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.2.0
|
7
|
+
Contact: opensource@shinesolutions.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for SwaggerAemClient::InstallStatus
|
18
|
+
# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe 'InstallStatus' do
|
21
|
+
before do
|
22
|
+
# run before each test
|
23
|
+
@instance = SwaggerAemClient::InstallStatus.new
|
24
|
+
end
|
25
|
+
|
26
|
+
after do
|
27
|
+
# run after each test
|
28
|
+
end
|
29
|
+
|
30
|
+
describe 'test an instance of InstallStatus' do
|
31
|
+
it 'should create an instance of InstallStatus' do
|
32
|
+
expect(@instance).to be_instance_of(SwaggerAemClient::InstallStatus)
|
33
|
+
end
|
34
|
+
end
|
35
|
+
describe 'test attribute "status"' do
|
36
|
+
it 'should work' do
|
37
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
end
|
42
|
+
|
@@ -0,0 +1,48 @@
|
|
1
|
+
=begin
|
2
|
+
#Adobe Experience Manager (AEM) API
|
3
|
+
|
4
|
+
#Swagger AEM is an OpenAPI specification for Adobe Experience Manager (AEM) API
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.2.0
|
7
|
+
Contact: opensource@shinesolutions.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for SwaggerAemClient::InstallStatusStatus
|
18
|
+
# Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe 'InstallStatusStatus' do
|
21
|
+
before do
|
22
|
+
# run before each test
|
23
|
+
@instance = SwaggerAemClient::InstallStatusStatus.new
|
24
|
+
end
|
25
|
+
|
26
|
+
after do
|
27
|
+
# run after each test
|
28
|
+
end
|
29
|
+
|
30
|
+
describe 'test an instance of InstallStatusStatus' do
|
31
|
+
it 'should create an instance of InstallStatusStatus' do
|
32
|
+
expect(@instance).to be_instance_of(SwaggerAemClient::InstallStatusStatus)
|
33
|
+
end
|
34
|
+
end
|
35
|
+
describe 'test attribute "finished"' do
|
36
|
+
it 'should work' do
|
37
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
describe 'test attribute "item_count"' do
|
42
|
+
it 'should work' do
|
43
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
end
|
48
|
+
|
data/spec/spec_helper.rb
CHANGED
data/swagger_aem.gemspec
CHANGED
@@ -8,7 +8,7 @@
|
|
8
8
|
OpenAPI spec version: 1.2.0
|
9
9
|
Contact: opensource@shinesolutions.com
|
10
10
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
11
|
-
Swagger Codegen version: 2.
|
11
|
+
Swagger Codegen version: 2.3.0-SNAPSHOT
|
12
12
|
|
13
13
|
=end
|
14
14
|
|
@@ -28,9 +28,9 @@ Gem::Specification.new do |s|
|
|
28
28
|
s.required_ruby_version = ">= 2.0"
|
29
29
|
|
30
30
|
s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
|
31
|
-
s.add_runtime_dependency 'json', '~> 1
|
31
|
+
s.add_runtime_dependency 'json', '~> 2.1', '>= 2.1.0'
|
32
32
|
|
33
|
-
s.add_development_dependency 'rspec', '~> 3.
|
33
|
+
s.add_development_dependency 'rspec', '~> 3.6', '>= 3.6.0'
|
34
34
|
s.add_development_dependency 'vcr', '~> 3.0', '>= 3.0.1'
|
35
35
|
s.add_development_dependency 'webmock', '~> 1.24', '>= 1.24.3'
|
36
36
|
s.add_development_dependency 'autotest', '~> 4.4', '>= 4.4.6'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: swagger_aem
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shine Solutions
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-10-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -36,40 +36,40 @@ dependencies:
|
|
36
36
|
requirements:
|
37
37
|
- - ~>
|
38
38
|
- !ruby/object:Gem::Version
|
39
|
-
version: '1
|
39
|
+
version: '2.1'
|
40
40
|
- - '>='
|
41
41
|
- !ruby/object:Gem::Version
|
42
|
-
version: 1.
|
42
|
+
version: 2.1.0
|
43
43
|
type: :runtime
|
44
44
|
prerelease: false
|
45
45
|
version_requirements: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
47
|
- - ~>
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: '1
|
49
|
+
version: '2.1'
|
50
50
|
- - '>='
|
51
51
|
- !ruby/object:Gem::Version
|
52
|
-
version: 1.
|
52
|
+
version: 2.1.0
|
53
53
|
- !ruby/object:Gem::Dependency
|
54
54
|
name: rspec
|
55
55
|
requirement: !ruby/object:Gem::Requirement
|
56
56
|
requirements:
|
57
57
|
- - ~>
|
58
58
|
- !ruby/object:Gem::Version
|
59
|
-
version: '3.
|
59
|
+
version: '3.6'
|
60
60
|
- - '>='
|
61
61
|
- !ruby/object:Gem::Version
|
62
|
-
version: 3.
|
62
|
+
version: 3.6.0
|
63
63
|
type: :development
|
64
64
|
prerelease: false
|
65
65
|
version_requirements: !ruby/object:Gem::Requirement
|
66
66
|
requirements:
|
67
67
|
- - ~>
|
68
68
|
- !ruby/object:Gem::Version
|
69
|
-
version: '3.
|
69
|
+
version: '3.6'
|
70
70
|
- - '>='
|
71
71
|
- !ruby/object:Gem::Version
|
72
|
-
version: 3.
|
72
|
+
version: 3.6.0
|
73
73
|
- !ruby/object:Gem::Dependency
|
74
74
|
name: vcr
|
75
75
|
requirement: !ruby/object:Gem::Requirement
|
@@ -205,6 +205,8 @@ files:
|
|
205
205
|
- docs/CqApi.md
|
206
206
|
- docs/CrxApi.md
|
207
207
|
- docs/CustomApi.md
|
208
|
+
- docs/InstallStatus.md
|
209
|
+
- docs/InstallStatusStatus.md
|
208
210
|
- docs/SlingApi.md
|
209
211
|
- git_push.sh
|
210
212
|
- lib/swagger_aem.rb
|
@@ -216,6 +218,8 @@ files:
|
|
216
218
|
- lib/swagger_aem/api_client.rb
|
217
219
|
- lib/swagger_aem/api_error.rb
|
218
220
|
- lib/swagger_aem/configuration.rb
|
221
|
+
- lib/swagger_aem/models/install_status.rb
|
222
|
+
- lib/swagger_aem/models/install_status_status.rb
|
219
223
|
- lib/swagger_aem/version.rb
|
220
224
|
- spec/api/console_api_spec.rb
|
221
225
|
- spec/api/cq_api_spec.rb
|
@@ -224,6 +228,8 @@ files:
|
|
224
228
|
- spec/api/sling_api_spec.rb
|
225
229
|
- spec/api_client_spec.rb
|
226
230
|
- spec/configuration_spec.rb
|
231
|
+
- spec/models/install_status_spec.rb
|
232
|
+
- spec/models/install_status_status_spec.rb
|
227
233
|
- spec/spec_helper.rb
|
228
234
|
- swagger_aem.gemspec
|
229
235
|
homepage: https://github.com/shinesolutions/swagger-aem/tree/master/ruby
|
@@ -258,4 +264,6 @@ test_files:
|
|
258
264
|
- spec/api/sling_api_spec.rb
|
259
265
|
- spec/api_client_spec.rb
|
260
266
|
- spec/configuration_spec.rb
|
267
|
+
- spec/models/install_status_spec.rb
|
268
|
+
- spec/models/install_status_status_spec.rb
|
261
269
|
- spec/spec_helper.rb
|