rose-nielsen-sdk 0.0.2 → 0.0.6
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 +60 -18
- data/lib/{cypress_test_api → swagger_petstore}/api_helper.rb +2 -2
- data/lib/swagger_petstore/client.rb +84 -0
- data/lib/{cypress_test_api → swagger_petstore}/configuration.rb +41 -17
- data/lib/{cypress_test_api → swagger_petstore}/controllers/base_controller.rb +2 -2
- data/lib/swagger_petstore/controllers/pet_controller.rb +206 -0
- data/lib/swagger_petstore/controllers/store_controller.rb +94 -0
- data/lib/swagger_petstore/controllers/user_controller.rb +165 -0
- data/lib/{cypress_test_api → swagger_petstore}/exceptions/api_exception.rb +2 -2
- data/lib/swagger_petstore/exceptions/o_auth_provider_exception.rb +64 -0
- data/lib/swagger_petstore/http/auth/api_key.rb +42 -0
- data/lib/swagger_petstore/http/auth/http_basic.rb +50 -0
- data/lib/swagger_petstore/http/auth/petstore_auth.rb +98 -0
- data/lib/{cypress_test_api → swagger_petstore}/http/http_call_back.rb +2 -2
- data/lib/{cypress_test_api → swagger_petstore}/http/http_method_enum.rb +2 -2
- data/lib/{cypress_test_api → swagger_petstore}/http/http_request.rb +2 -2
- data/lib/{cypress_test_api → swagger_petstore}/http/http_response.rb +2 -2
- data/lib/{cypress_test_api → swagger_petstore}/http/proxy_settings.rb +2 -2
- data/lib/{cypress_test_api/models/message2.rb → swagger_petstore/models/api_response.rb} +24 -14
- data/lib/{cypress_test_api → swagger_petstore}/models/base_model.rb +2 -2
- data/lib/{cypress_test_api/models/item_response.rb → swagger_petstore/models/category.rb} +10 -19
- data/lib/{cypress_test_api/models/deer.rb → swagger_petstore/models/category2.rb} +21 -18
- data/lib/swagger_petstore/models/content_type_enum.rb +20 -0
- data/lib/swagger_petstore/models/o_auth_provider_error_enum.rb +45 -0
- data/lib/swagger_petstore/models/o_auth_scope_petstore_auth_enum.rb +23 -0
- data/lib/swagger_petstore/models/o_auth_token.rb +96 -0
- data/lib/swagger_petstore/models/order.rb +120 -0
- data/lib/swagger_petstore/models/pet.rb +117 -0
- data/lib/swagger_petstore/models/pet_request.rb +117 -0
- data/lib/swagger_petstore/models/status1_enum.rb +26 -0
- data/lib/swagger_petstore/models/status2_enum.rb +26 -0
- data/lib/{cypress_test_api → swagger_petstore}/models/status_enum.rb +9 -9
- data/lib/swagger_petstore/models/store_order_request.rb +120 -0
- data/lib/{cypress_test_api/models/response_http404.rb → swagger_petstore/models/tag.rb} +18 -9
- data/lib/swagger_petstore/models/user.rb +132 -0
- data/lib/swagger_petstore/models/user_request.rb +132 -0
- data/lib/{cypress_test_api → swagger_petstore}/utilities/date_time_helper.rb +2 -2
- data/lib/{cypress_test_api → swagger_petstore}/utilities/file_wrapper.rb +2 -2
- data/lib/swagger_petstore.rb +62 -0
- data/test/controllers/controller_test_base.rb +13 -5
- data/test/controllers/test_store_controller.rb +31 -0
- data/test/http_response_catcher.rb +2 -2
- metadata +40 -33
- data/lib/cypress_test_api/client.rb +0 -47
- data/lib/cypress_test_api/controllers/api_controller.rb +0 -102
- data/lib/cypress_test_api/models/custom_enum.rb +0 -26
- data/lib/cypress_test_api/models/item.rb +0 -166
- data/lib/cypress_test_api/models/lion.rb +0 -68
- data/lib/cypress_test_api/models/message.rb +0 -68
- data/lib/cypress_test_api/models/multiple_arrays_request.rb +0 -70
- data/lib/cypress_test_api/models/nac_tag.rb +0 -265
- data/lib/cypress_test_api/models/o_auth_scope_o_auth_acg_enum.rb +0 -29
- data/lib/cypress_test_api/models/response_http400.rb +0 -62
- data/lib/cypress_test_api/models/status11_enum.rb +0 -26
- data/lib/cypress_test_api/models/status1_enum.rb +0 -26
- data/lib/cypress_test_api/models/tokens_request.rb +0 -60
- data/lib/cypress_test_api.rb +0 -55
- data/test/controllers/test_api_controller.rb +0 -40
@@ -1,166 +0,0 @@
|
|
1
|
-
# cypress_test_api
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v3.0
|
4
|
-
# ( https://www.apimatic.io ).
|
5
|
-
|
6
|
-
require 'date'
|
7
|
-
module CypressTestApi
|
8
|
-
# Item Model.
|
9
|
-
class Item < BaseModel
|
10
|
-
SKIP = Object.new
|
11
|
-
private_constant :SKIP
|
12
|
-
|
13
|
-
# TODO: Write general description for this method
|
14
|
-
# @return [UUID | String]
|
15
|
-
attr_accessor :id
|
16
|
-
|
17
|
-
# TODO: Write general description for this method
|
18
|
-
# @return [String]
|
19
|
-
attr_accessor :name
|
20
|
-
|
21
|
-
# TODO: Write general description for this method
|
22
|
-
# @return [Date]
|
23
|
-
attr_accessor :date
|
24
|
-
|
25
|
-
# TODO: Write general description for this method
|
26
|
-
# @return [DateTime]
|
27
|
-
attr_accessor :date_time
|
28
|
-
|
29
|
-
# TODO: Write general description for this method
|
30
|
-
# @return [Float]
|
31
|
-
attr_accessor :decimal
|
32
|
-
|
33
|
-
# TODO: Write general description for this method
|
34
|
-
# @return [Integer]
|
35
|
-
attr_accessor :long
|
36
|
-
|
37
|
-
# TODO: Write general description for this method
|
38
|
-
# @return [TrueClass | FalseClass]
|
39
|
-
attr_accessor :bool
|
40
|
-
|
41
|
-
# TODO: Write general description for this method
|
42
|
-
# @return [CustomEnum]
|
43
|
-
attr_accessor :custom_enum
|
44
|
-
|
45
|
-
# TODO: Write general description for this method
|
46
|
-
# @return [StatusEnum]
|
47
|
-
attr_accessor :status
|
48
|
-
|
49
|
-
# A generic JSON object
|
50
|
-
# @return [Object]
|
51
|
-
attr_accessor :json_object
|
52
|
-
|
53
|
-
# A generic JSON object
|
54
|
-
# @return [Object]
|
55
|
-
attr_accessor :animal
|
56
|
-
|
57
|
-
# A generic JSON object
|
58
|
-
# @return [Hash[String, Message]]
|
59
|
-
attr_accessor :map
|
60
|
-
|
61
|
-
# A mapping from model property names to API property names.
|
62
|
-
def self.names
|
63
|
-
@_hash = {} if @_hash.nil?
|
64
|
-
@_hash['id'] = 'id'
|
65
|
-
@_hash['name'] = 'name'
|
66
|
-
@_hash['date'] = 'date'
|
67
|
-
@_hash['date_time'] = 'dateTime'
|
68
|
-
@_hash['decimal'] = 'decimal'
|
69
|
-
@_hash['long'] = 'long'
|
70
|
-
@_hash['bool'] = 'bool'
|
71
|
-
@_hash['custom_enum'] = 'CustomEnum'
|
72
|
-
@_hash['status'] = 'status'
|
73
|
-
@_hash['json_object'] = 'jsonObject'
|
74
|
-
@_hash['animal'] = 'Animal'
|
75
|
-
@_hash['map'] = 'Map'
|
76
|
-
@_hash
|
77
|
-
end
|
78
|
-
|
79
|
-
# An array for optional fields
|
80
|
-
def self.optionals
|
81
|
-
%w[
|
82
|
-
status
|
83
|
-
]
|
84
|
-
end
|
85
|
-
|
86
|
-
# An array for nullable fields
|
87
|
-
def self.nullables
|
88
|
-
[]
|
89
|
-
end
|
90
|
-
|
91
|
-
def initialize(id = nil, name = nil, date = nil, date_time = nil,
|
92
|
-
decimal = nil, long = nil, bool = nil, custom_enum = nil,
|
93
|
-
json_object = nil, animal = nil, map = nil, status = SKIP)
|
94
|
-
@id = id
|
95
|
-
@name = name
|
96
|
-
@date = date
|
97
|
-
@date_time = date_time
|
98
|
-
@decimal = decimal
|
99
|
-
@long = long
|
100
|
-
@bool = bool
|
101
|
-
@custom_enum = custom_enum
|
102
|
-
@status = status unless status == SKIP
|
103
|
-
@json_object = json_object
|
104
|
-
@animal = animal
|
105
|
-
@map = map
|
106
|
-
end
|
107
|
-
|
108
|
-
# Creates an instance of the object from a hash.
|
109
|
-
def self.from_hash(hash)
|
110
|
-
return nil unless hash
|
111
|
-
|
112
|
-
# Extract variables from the hash.
|
113
|
-
id = hash.key?('id') ? hash['id'] : nil
|
114
|
-
name = hash.key?('name') ? hash['name'] : nil
|
115
|
-
date = hash.key?('date') ? hash['date'] : nil
|
116
|
-
date_time = if hash.key?('dateTime')
|
117
|
-
(DateTimeHelper.from_rfc3339(hash['dateTime']) if hash['dateTime'])
|
118
|
-
end
|
119
|
-
decimal = hash.key?('decimal') ? hash['decimal'] : nil
|
120
|
-
long = hash.key?('long') ? hash['long'] : nil
|
121
|
-
bool = hash.key?('bool') ? hash['bool'] : nil
|
122
|
-
custom_enum = hash.key?('CustomEnum') ? hash['CustomEnum'] : nil
|
123
|
-
json_object = hash.key?('jsonObject') ? hash['jsonObject'] : nil
|
124
|
-
animal = hash.key?('Animal') ? hash['Animal'] : nil
|
125
|
-
map = Message.from_hash(hash['Map']) if hash['Map']
|
126
|
-
|
127
|
-
map = nil unless hash.key?('Map')
|
128
|
-
status = hash.key?('status') ? hash['status'] : SKIP
|
129
|
-
|
130
|
-
# Create object from extracted values.
|
131
|
-
Item.new(id,
|
132
|
-
name,
|
133
|
-
date,
|
134
|
-
date_time,
|
135
|
-
decimal,
|
136
|
-
long,
|
137
|
-
bool,
|
138
|
-
custom_enum,
|
139
|
-
json_object,
|
140
|
-
animal,
|
141
|
-
map,
|
142
|
-
status)
|
143
|
-
end
|
144
|
-
|
145
|
-
def to_custom_date_time
|
146
|
-
DateTimeHelper.to_rfc3339(date_time)
|
147
|
-
end
|
148
|
-
|
149
|
-
# Provides a human-readable string representation of the object.
|
150
|
-
def to_s
|
151
|
-
class_name = self.class.name.split('::').last
|
152
|
-
"<#{class_name} id: #{@id}, name: #{@name}, date: #{@date}, date_time: #{@date_time},"\
|
153
|
-
" decimal: #{@decimal}, long: #{@long}, bool: #{@bool}, custom_enum: #{@custom_enum},"\
|
154
|
-
" status: #{@status}, json_object: #{@json_object}, animal: #{@animal}, map: #{@map}>"
|
155
|
-
end
|
156
|
-
|
157
|
-
# Provides a debugging-friendly string with detailed object information.
|
158
|
-
def inspect
|
159
|
-
class_name = self.class.name.split('::').last
|
160
|
-
"<#{class_name} id: #{@id.inspect}, name: #{@name.inspect}, date: #{@date.inspect},"\
|
161
|
-
" date_time: #{@date_time.inspect}, decimal: #{@decimal.inspect}, long: #{@long.inspect},"\
|
162
|
-
" bool: #{@bool.inspect}, custom_enum: #{@custom_enum.inspect}, status: #{@status.inspect},"\
|
163
|
-
" json_object: #{@json_object.inspect}, animal: #{@animal.inspect}, map: #{@map.inspect}>"
|
164
|
-
end
|
165
|
-
end
|
166
|
-
end
|
@@ -1,68 +0,0 @@
|
|
1
|
-
# cypress_test_api
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v3.0
|
4
|
-
# ( https://www.apimatic.io ).
|
5
|
-
|
6
|
-
module CypressTestApi
|
7
|
-
# Lion Model.
|
8
|
-
class Lion < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# TODO: Write general description for this method
|
13
|
-
# @return [String]
|
14
|
-
attr_accessor :id
|
15
|
-
|
16
|
-
# TODO: Write general description for this method
|
17
|
-
# @return [String]
|
18
|
-
attr_accessor :type
|
19
|
-
|
20
|
-
# A mapping from model property names to API property names.
|
21
|
-
def self.names
|
22
|
-
@_hash = {} if @_hash.nil?
|
23
|
-
@_hash['id'] = 'id'
|
24
|
-
@_hash['type'] = 'type'
|
25
|
-
@_hash
|
26
|
-
end
|
27
|
-
|
28
|
-
# An array for optional fields
|
29
|
-
def self.optionals
|
30
|
-
[]
|
31
|
-
end
|
32
|
-
|
33
|
-
# An array for nullable fields
|
34
|
-
def self.nullables
|
35
|
-
[]
|
36
|
-
end
|
37
|
-
|
38
|
-
def initialize(id = nil, type = nil)
|
39
|
-
@id = id
|
40
|
-
@type = type
|
41
|
-
end
|
42
|
-
|
43
|
-
# Creates an instance of the object from a hash.
|
44
|
-
def self.from_hash(hash)
|
45
|
-
return nil unless hash
|
46
|
-
|
47
|
-
# Extract variables from the hash.
|
48
|
-
id = hash.key?('id') ? hash['id'] : nil
|
49
|
-
type = hash.key?('type') ? hash['type'] : nil
|
50
|
-
|
51
|
-
# Create object from extracted values.
|
52
|
-
Lion.new(id,
|
53
|
-
type)
|
54
|
-
end
|
55
|
-
|
56
|
-
# Provides a human-readable string representation of the object.
|
57
|
-
def to_s
|
58
|
-
class_name = self.class.name.split('::').last
|
59
|
-
"<#{class_name} id: #{@id}, type: #{@type}>"
|
60
|
-
end
|
61
|
-
|
62
|
-
# Provides a debugging-friendly string with detailed object information.
|
63
|
-
def inspect
|
64
|
-
class_name = self.class.name.split('::').last
|
65
|
-
"<#{class_name} id: #{@id.inspect}, type: #{@type.inspect}>"
|
66
|
-
end
|
67
|
-
end
|
68
|
-
end
|
@@ -1,68 +0,0 @@
|
|
1
|
-
# cypress_test_api
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v3.0
|
4
|
-
# ( https://www.apimatic.io ).
|
5
|
-
|
6
|
-
module CypressTestApi
|
7
|
-
# Message Model.
|
8
|
-
class Message < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# TODO: Write general description for this method
|
13
|
-
# @return [Integer]
|
14
|
-
attr_accessor :code
|
15
|
-
|
16
|
-
# TODO: Write general description for this method
|
17
|
-
# @return [String]
|
18
|
-
attr_accessor :text
|
19
|
-
|
20
|
-
# A mapping from model property names to API property names.
|
21
|
-
def self.names
|
22
|
-
@_hash = {} if @_hash.nil?
|
23
|
-
@_hash['code'] = 'code'
|
24
|
-
@_hash['text'] = 'text'
|
25
|
-
@_hash
|
26
|
-
end
|
27
|
-
|
28
|
-
# An array for optional fields
|
29
|
-
def self.optionals
|
30
|
-
[]
|
31
|
-
end
|
32
|
-
|
33
|
-
# An array for nullable fields
|
34
|
-
def self.nullables
|
35
|
-
[]
|
36
|
-
end
|
37
|
-
|
38
|
-
def initialize(code = nil, text = nil)
|
39
|
-
@code = code
|
40
|
-
@text = text
|
41
|
-
end
|
42
|
-
|
43
|
-
# Creates an instance of the object from a hash.
|
44
|
-
def self.from_hash(hash)
|
45
|
-
return nil unless hash
|
46
|
-
|
47
|
-
# Extract variables from the hash.
|
48
|
-
code = hash.key?('code') ? hash['code'] : nil
|
49
|
-
text = hash.key?('text') ? hash['text'] : nil
|
50
|
-
|
51
|
-
# Create object from extracted values.
|
52
|
-
Message.new(code,
|
53
|
-
text)
|
54
|
-
end
|
55
|
-
|
56
|
-
# Provides a human-readable string representation of the object.
|
57
|
-
def to_s
|
58
|
-
class_name = self.class.name.split('::').last
|
59
|
-
"<#{class_name} code: #{@code}, text: #{@text}>"
|
60
|
-
end
|
61
|
-
|
62
|
-
# Provides a debugging-friendly string with detailed object information.
|
63
|
-
def inspect
|
64
|
-
class_name = self.class.name.split('::').last
|
65
|
-
"<#{class_name} code: #{@code.inspect}, text: #{@text.inspect}>"
|
66
|
-
end
|
67
|
-
end
|
68
|
-
end
|
@@ -1,70 +0,0 @@
|
|
1
|
-
# cypress_test_api
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v3.0
|
4
|
-
# ( https://www.apimatic.io ).
|
5
|
-
|
6
|
-
module CypressTestApi
|
7
|
-
# MultipleArraysRequest Model.
|
8
|
-
class MultipleArraysRequest < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# An array containing items of type string
|
13
|
-
# @return [Array[String]]
|
14
|
-
attr_accessor :array1
|
15
|
-
|
16
|
-
# An array containing items of type integer
|
17
|
-
# @return [Array[Integer]]
|
18
|
-
attr_accessor :array2
|
19
|
-
|
20
|
-
# A mapping from model property names to API property names.
|
21
|
-
def self.names
|
22
|
-
@_hash = {} if @_hash.nil?
|
23
|
-
@_hash['array1'] = 'Array1'
|
24
|
-
@_hash['array2'] = 'Array2'
|
25
|
-
@_hash
|
26
|
-
end
|
27
|
-
|
28
|
-
# An array for optional fields
|
29
|
-
def self.optionals
|
30
|
-
%w[
|
31
|
-
array2
|
32
|
-
]
|
33
|
-
end
|
34
|
-
|
35
|
-
# An array for nullable fields
|
36
|
-
def self.nullables
|
37
|
-
[]
|
38
|
-
end
|
39
|
-
|
40
|
-
def initialize(array1 = nil, array2 = SKIP)
|
41
|
-
@array1 = array1
|
42
|
-
@array2 = array2 unless array2 == SKIP
|
43
|
-
end
|
44
|
-
|
45
|
-
# Creates an instance of the object from a hash.
|
46
|
-
def self.from_hash(hash)
|
47
|
-
return nil unless hash
|
48
|
-
|
49
|
-
# Extract variables from the hash.
|
50
|
-
array1 = hash.key?('Array1') ? hash['Array1'] : nil
|
51
|
-
array2 = hash.key?('Array2') ? hash['Array2'] : SKIP
|
52
|
-
|
53
|
-
# Create object from extracted values.
|
54
|
-
MultipleArraysRequest.new(array1,
|
55
|
-
array2)
|
56
|
-
end
|
57
|
-
|
58
|
-
# Provides a human-readable string representation of the object.
|
59
|
-
def to_s
|
60
|
-
class_name = self.class.name.split('::').last
|
61
|
-
"<#{class_name} array1: #{@array1}, array2: #{@array2}>"
|
62
|
-
end
|
63
|
-
|
64
|
-
# Provides a debugging-friendly string with detailed object information.
|
65
|
-
def inspect
|
66
|
-
class_name = self.class.name.split('::').last
|
67
|
-
"<#{class_name} array1: #{@array1.inspect}, array2: #{@array2.inspect}>"
|
68
|
-
end
|
69
|
-
end
|
70
|
-
end
|
@@ -1,265 +0,0 @@
|
|
1
|
-
# cypress_test_api
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v3.0
|
4
|
-
# ( https://www.apimatic.io ).
|
5
|
-
|
6
|
-
module CypressTestApi
|
7
|
-
# NacTag Model.
|
8
|
-
class NacTag < BaseModel
|
9
|
-
SKIP = Object.new
|
10
|
-
private_constant :SKIP
|
11
|
-
|
12
|
-
# can be set to true to allow the override by usermac result
|
13
|
-
# @return [TrueClass | FalseClass]
|
14
|
-
attr_accessor :allow_usermac_override
|
15
|
-
|
16
|
-
# can be set to true to allow the override by usermac result
|
17
|
-
# @return [Float]
|
18
|
-
attr_accessor :created_time
|
19
|
-
|
20
|
-
# if `type`==`egress_vlan_names`, list of egress vlans to return
|
21
|
-
# @return [Array[String]]
|
22
|
-
attr_accessor :egress_vlan_names
|
23
|
-
|
24
|
-
# if `type`==`gbp_tag`
|
25
|
-
# @return [Integer]
|
26
|
-
attr_accessor :gbp_tag
|
27
|
-
|
28
|
-
# if `type`==`gbp_tag`
|
29
|
-
# @return [UUID | String]
|
30
|
-
attr_accessor :id
|
31
|
-
|
32
|
-
# if `type`==`gbp_tag`
|
33
|
-
# @return [NacTag]
|
34
|
-
attr_accessor :match
|
35
|
-
|
36
|
-
# This field is applicable only when `type`==`match`
|
37
|
-
# * `false`: means it is sufficient to match any of the values (i.e.,
|
38
|
-
# match-any behavior)
|
39
|
-
# * `true`: means all values should be matched (i.e., match-all behavior)
|
40
|
-
# Currently it makes sense to set this field to `true` only if the
|
41
|
-
# `match`==`idp_role` or `match`==`usermac_label`'
|
42
|
-
# @return [TrueClass | FalseClass]
|
43
|
-
attr_accessor :match_all
|
44
|
-
|
45
|
-
# This field is applicable only when `type`==`match`
|
46
|
-
# * `false`: means it is sufficient to match any of the values (i.e.,
|
47
|
-
# match-any behavior)
|
48
|
-
# * `true`: means all values should be matched (i.e., match-all behavior)
|
49
|
-
# Currently it makes sense to set this field to `true` only if the
|
50
|
-
# `match`==`idp_role` or `match`==`usermac_label`'
|
51
|
-
# @return [Float]
|
52
|
-
attr_accessor :modified_time
|
53
|
-
|
54
|
-
# This field is applicable only when `type`==`match`
|
55
|
-
# * `false`: means it is sufficient to match any of the values (i.e.,
|
56
|
-
# match-any behavior)
|
57
|
-
# * `true`: means all values should be matched (i.e., match-all behavior)
|
58
|
-
# Currently it makes sense to set this field to `true` only if the
|
59
|
-
# `match`==`idp_role` or `match`==`usermac_label`'
|
60
|
-
# @return [String]
|
61
|
-
attr_accessor :name
|
62
|
-
|
63
|
-
# This field is applicable only when `type`==`match`
|
64
|
-
# * `false`: means it is sufficient to match any of the values (i.e.,
|
65
|
-
# match-any behavior)
|
66
|
-
# * `true`: means all values should be matched (i.e., match-all behavior)
|
67
|
-
# Currently it makes sense to set this field to `true` only if the
|
68
|
-
# `match`==`idp_role` or `match`==`usermac_label`'
|
69
|
-
# @return [UUID | String]
|
70
|
-
attr_accessor :org_id
|
71
|
-
|
72
|
-
# if `type`==`radius_attrs`, user can specify a list of one or more standard
|
73
|
-
# attributes in the field "radius_attrs".
|
74
|
-
# It is the responsibility of the user to provide a syntactically correct
|
75
|
-
# string, otherwise it may not work as expected.
|
76
|
-
# Note that it is allowed to have more than one radius_attrs in the result
|
77
|
-
# of a given rule.
|
78
|
-
# @return [Array[String]]
|
79
|
-
attr_accessor :radius_attrs
|
80
|
-
|
81
|
-
# if `type`==`radius_group`
|
82
|
-
# @return [String]
|
83
|
-
attr_accessor :radius_group
|
84
|
-
|
85
|
-
# if `type`==`radius_vendor_attrs`, user can specify a list of one or more
|
86
|
-
# vendor-specific attributes in the field "radius_vendor_attrs".
|
87
|
-
# It is the responsibility of the user to provide a syntactically correct
|
88
|
-
# string, otherwise it may not work as expected.
|
89
|
-
# Note that it is allowed to have more than one radius_vendor_attrs in the
|
90
|
-
# result of a given rule.
|
91
|
-
# @return [Array[String]]
|
92
|
-
attr_accessor :radius_vendor_attrs
|
93
|
-
|
94
|
-
# if `type`==`session_timeout, in seconds
|
95
|
-
# @return [Integer]
|
96
|
-
attr_accessor :session_timeout
|
97
|
-
|
98
|
-
# if `type`==`session_timeout, in seconds
|
99
|
-
# @return [NacTag]
|
100
|
-
attr_accessor :type
|
101
|
-
|
102
|
-
# if `type`==`session_timeout, in seconds
|
103
|
-
# @return [NacTag]
|
104
|
-
attr_accessor :username_attr
|
105
|
-
|
106
|
-
# if `type`==`match`
|
107
|
-
# @return [Array[String]]
|
108
|
-
attr_accessor :values
|
109
|
-
|
110
|
-
# if `type`==`vlan`
|
111
|
-
# @return [String]
|
112
|
-
attr_accessor :vlan
|
113
|
-
|
114
|
-
# A mapping from model property names to API property names.
|
115
|
-
def self.names
|
116
|
-
@_hash = {} if @_hash.nil?
|
117
|
-
@_hash['allow_usermac_override'] = 'allow_usermac_override'
|
118
|
-
@_hash['created_time'] = 'created_time'
|
119
|
-
@_hash['egress_vlan_names'] = 'egress_vlan_names'
|
120
|
-
@_hash['gbp_tag'] = 'gbp_tag'
|
121
|
-
@_hash['id'] = 'id'
|
122
|
-
@_hash['match'] = 'match'
|
123
|
-
@_hash['match_all'] = 'match_all'
|
124
|
-
@_hash['modified_time'] = 'modified_time'
|
125
|
-
@_hash['name'] = 'name'
|
126
|
-
@_hash['org_id'] = 'org_id'
|
127
|
-
@_hash['radius_attrs'] = 'radius_attrs'
|
128
|
-
@_hash['radius_group'] = 'radius_group'
|
129
|
-
@_hash['radius_vendor_attrs'] = 'radius_vendor_attrs'
|
130
|
-
@_hash['session_timeout'] = 'session_timeout'
|
131
|
-
@_hash['type'] = 'type'
|
132
|
-
@_hash['username_attr'] = 'username_attr'
|
133
|
-
@_hash['values'] = 'values'
|
134
|
-
@_hash['vlan'] = 'vlan'
|
135
|
-
@_hash
|
136
|
-
end
|
137
|
-
|
138
|
-
# An array for optional fields
|
139
|
-
def self.optionals
|
140
|
-
%w[
|
141
|
-
allow_usermac_override
|
142
|
-
created_time
|
143
|
-
egress_vlan_names
|
144
|
-
gbp_tag
|
145
|
-
id
|
146
|
-
match
|
147
|
-
match_all
|
148
|
-
modified_time
|
149
|
-
org_id
|
150
|
-
radius_attrs
|
151
|
-
radius_group
|
152
|
-
radius_vendor_attrs
|
153
|
-
session_timeout
|
154
|
-
username_attr
|
155
|
-
values
|
156
|
-
vlan
|
157
|
-
]
|
158
|
-
end
|
159
|
-
|
160
|
-
# An array for nullable fields
|
161
|
-
def self.nullables
|
162
|
-
[]
|
163
|
-
end
|
164
|
-
|
165
|
-
def initialize(name = nil, type = nil, allow_usermac_override = false,
|
166
|
-
created_time = SKIP, egress_vlan_names = SKIP,
|
167
|
-
gbp_tag = SKIP, id = SKIP, match = SKIP, match_all = false,
|
168
|
-
modified_time = SKIP, org_id = SKIP, radius_attrs = SKIP,
|
169
|
-
radius_group = SKIP, radius_vendor_attrs = SKIP,
|
170
|
-
session_timeout = SKIP, username_attr = SKIP, values = SKIP,
|
171
|
-
vlan = SKIP)
|
172
|
-
@allow_usermac_override = allow_usermac_override unless allow_usermac_override == SKIP
|
173
|
-
@created_time = created_time unless created_time == SKIP
|
174
|
-
@egress_vlan_names = egress_vlan_names unless egress_vlan_names == SKIP
|
175
|
-
@gbp_tag = gbp_tag unless gbp_tag == SKIP
|
176
|
-
@id = id unless id == SKIP
|
177
|
-
@match = match unless match == SKIP
|
178
|
-
@match_all = match_all unless match_all == SKIP
|
179
|
-
@modified_time = modified_time unless modified_time == SKIP
|
180
|
-
@name = name
|
181
|
-
@org_id = org_id unless org_id == SKIP
|
182
|
-
@radius_attrs = radius_attrs unless radius_attrs == SKIP
|
183
|
-
@radius_group = radius_group unless radius_group == SKIP
|
184
|
-
@radius_vendor_attrs = radius_vendor_attrs unless radius_vendor_attrs == SKIP
|
185
|
-
@session_timeout = session_timeout unless session_timeout == SKIP
|
186
|
-
@type = type
|
187
|
-
@username_attr = username_attr unless username_attr == SKIP
|
188
|
-
@values = values unless values == SKIP
|
189
|
-
@vlan = vlan unless vlan == SKIP
|
190
|
-
end
|
191
|
-
|
192
|
-
# Creates an instance of the object from a hash.
|
193
|
-
def self.from_hash(hash)
|
194
|
-
return nil unless hash
|
195
|
-
|
196
|
-
# Extract variables from the hash.
|
197
|
-
name = hash.key?('name') ? hash['name'] : nil
|
198
|
-
type = NacTag.from_hash(hash['type']) if hash['type']
|
199
|
-
allow_usermac_override = hash['allow_usermac_override'] ||= false
|
200
|
-
created_time = hash.key?('created_time') ? hash['created_time'] : SKIP
|
201
|
-
egress_vlan_names =
|
202
|
-
hash.key?('egress_vlan_names') ? hash['egress_vlan_names'] : SKIP
|
203
|
-
gbp_tag = hash.key?('gbp_tag') ? hash['gbp_tag'] : SKIP
|
204
|
-
id = hash.key?('id') ? hash['id'] : SKIP
|
205
|
-
match = NacTag.from_hash(hash['match']) if hash['match']
|
206
|
-
match_all = hash['match_all'] ||= false
|
207
|
-
modified_time = hash.key?('modified_time') ? hash['modified_time'] : SKIP
|
208
|
-
org_id = hash.key?('org_id') ? hash['org_id'] : SKIP
|
209
|
-
radius_attrs = hash.key?('radius_attrs') ? hash['radius_attrs'] : SKIP
|
210
|
-
radius_group = hash.key?('radius_group') ? hash['radius_group'] : SKIP
|
211
|
-
radius_vendor_attrs =
|
212
|
-
hash.key?('radius_vendor_attrs') ? hash['radius_vendor_attrs'] : SKIP
|
213
|
-
session_timeout =
|
214
|
-
hash.key?('session_timeout') ? hash['session_timeout'] : SKIP
|
215
|
-
username_attr = NacTag.from_hash(hash['username_attr']) if hash['username_attr']
|
216
|
-
values = hash.key?('values') ? hash['values'] : SKIP
|
217
|
-
vlan = hash.key?('vlan') ? hash['vlan'] : SKIP
|
218
|
-
|
219
|
-
# Create object from extracted values.
|
220
|
-
NacTag.new(name,
|
221
|
-
type,
|
222
|
-
allow_usermac_override,
|
223
|
-
created_time,
|
224
|
-
egress_vlan_names,
|
225
|
-
gbp_tag,
|
226
|
-
id,
|
227
|
-
match,
|
228
|
-
match_all,
|
229
|
-
modified_time,
|
230
|
-
org_id,
|
231
|
-
radius_attrs,
|
232
|
-
radius_group,
|
233
|
-
radius_vendor_attrs,
|
234
|
-
session_timeout,
|
235
|
-
username_attr,
|
236
|
-
values,
|
237
|
-
vlan)
|
238
|
-
end
|
239
|
-
|
240
|
-
# Provides a human-readable string representation of the object.
|
241
|
-
def to_s
|
242
|
-
class_name = self.class.name.split('::').last
|
243
|
-
"<#{class_name} allow_usermac_override: #{@allow_usermac_override}, created_time:"\
|
244
|
-
" #{@created_time}, egress_vlan_names: #{@egress_vlan_names}, gbp_tag: #{@gbp_tag}, id:"\
|
245
|
-
" #{@id}, match: #{@match}, match_all: #{@match_all}, modified_time: #{@modified_time},"\
|
246
|
-
" name: #{@name}, org_id: #{@org_id}, radius_attrs: #{@radius_attrs}, radius_group:"\
|
247
|
-
" #{@radius_group}, radius_vendor_attrs: #{@radius_vendor_attrs}, session_timeout:"\
|
248
|
-
" #{@session_timeout}, type: #{@type}, username_attr: #{@username_attr}, values: #{@values},"\
|
249
|
-
" vlan: #{@vlan}>"
|
250
|
-
end
|
251
|
-
|
252
|
-
# Provides a debugging-friendly string with detailed object information.
|
253
|
-
def inspect
|
254
|
-
class_name = self.class.name.split('::').last
|
255
|
-
"<#{class_name} allow_usermac_override: #{@allow_usermac_override.inspect}, created_time:"\
|
256
|
-
" #{@created_time.inspect}, egress_vlan_names: #{@egress_vlan_names.inspect}, gbp_tag:"\
|
257
|
-
" #{@gbp_tag.inspect}, id: #{@id.inspect}, match: #{@match.inspect}, match_all:"\
|
258
|
-
" #{@match_all.inspect}, modified_time: #{@modified_time.inspect}, name: #{@name.inspect},"\
|
259
|
-
" org_id: #{@org_id.inspect}, radius_attrs: #{@radius_attrs.inspect}, radius_group:"\
|
260
|
-
" #{@radius_group.inspect}, radius_vendor_attrs: #{@radius_vendor_attrs.inspect},"\
|
261
|
-
" session_timeout: #{@session_timeout.inspect}, type: #{@type.inspect}, username_attr:"\
|
262
|
-
" #{@username_attr.inspect}, values: #{@values.inspect}, vlan: #{@vlan.inspect}>"
|
263
|
-
end
|
264
|
-
end
|
265
|
-
end
|
@@ -1,29 +0,0 @@
|
|
1
|
-
# cypress_test_api
|
2
|
-
#
|
3
|
-
# This file was automatically generated by APIMATIC v3.0
|
4
|
-
# ( https://www.apimatic.io ).
|
5
|
-
|
6
|
-
module CypressTestApi
|
7
|
-
# OAuth 2 scopes supported by the API
|
8
|
-
class OAuthScopeOAuthACGEnum
|
9
|
-
O_AUTH_SCOPE_O_AUTH_ACG_ENUM = [
|
10
|
-
# TODO: Write general description for ENUM_FILE_REQUESTSREAD
|
11
|
-
ENUM_FILE_REQUESTSREAD = 'file_requests.read'.freeze,
|
12
|
-
|
13
|
-
# TODO: Write general description for ZAHRA
|
14
|
-
ZAHRA = 'zahra'.freeze,
|
15
|
-
|
16
|
-
# TODO: Write general description for TEST1
|
17
|
-
TEST1 = 'test1'.freeze,
|
18
|
-
|
19
|
-
# TODO: Write general description for SELECTION
|
20
|
-
SELECTION = 'selection'.freeze
|
21
|
-
].freeze
|
22
|
-
|
23
|
-
def self.validate(value)
|
24
|
-
return false if value.nil?
|
25
|
-
|
26
|
-
O_AUTH_SCOPE_O_AUTH_ACG_ENUM.include?(value)
|
27
|
-
end
|
28
|
-
end
|
29
|
-
end
|