cloudmersive-image-recognition-api-client 1.4.3 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/README.md +19 -16
- data/cloudmersive-image-recognition-api-client.gemspec +3 -3
- data/docs/ArtisticApi.md +2 -2
- data/docs/ConvertApi.md +13 -13
- data/docs/DrawTextInstance.md +1 -1
- data/docs/EditApi.md +188 -23
- data/docs/FaceApi.md +20 -20
- data/docs/FaceLocateResponse.md +1 -1
- data/docs/FilterApi.md +11 -11
- data/docs/ImageMetadata.md +2 -0
- data/docs/InfoApi.md +5 -5
- data/docs/NsfwApi.md +4 -4
- data/docs/RecognizeApi.md +17 -17
- data/docs/ResizeApi.md +10 -10
- data/lib/cloudmersive-image-recognition-api-client.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/api/artistic_api.rb +6 -7
- data/lib/cloudmersive-image-recognition-api-client/api/convert_api.rb +35 -42
- data/lib/cloudmersive-image-recognition-api-client/api/edit_api.rb +215 -59
- data/lib/cloudmersive-image-recognition-api-client/api/face_api.rb +39 -46
- data/lib/cloudmersive-image-recognition-api-client/api/filter_api.rb +36 -44
- data/lib/cloudmersive-image-recognition-api-client/api/info_api.rb +12 -14
- data/lib/cloudmersive-image-recognition-api-client/api/nsfw_api.rb +8 -9
- data/lib/cloudmersive-image-recognition-api-client/api/recognize_api.rb +41 -49
- data/lib/cloudmersive-image-recognition-api-client/api/resize_api.rb +20 -22
- data/lib/cloudmersive-image-recognition-api-client/api_client.rb +11 -9
- data/lib/cloudmersive-image-recognition-api-client/api_error.rb +1 -1
- data/lib/cloudmersive-image-recognition-api-client/configuration.rb +2 -2
- data/lib/cloudmersive-image-recognition-api-client/models/age_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/color_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/detected_license_plate.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/detected_object.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/dominant_color_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/draw_polygon_instance.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/draw_polygon_request.rb +9 -13
- data/lib/cloudmersive-image-recognition-api-client/models/draw_rectangle_instance.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/draw_rectangle_request.rb +9 -13
- data/lib/cloudmersive-image-recognition-api-client/models/draw_text_instance.rb +8 -11
- data/lib/cloudmersive-image-recognition-api-client/models/draw_text_request.rb +9 -13
- data/lib/cloudmersive-image-recognition-api-client/models/face.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_compare_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_locate_response.rb +19 -21
- data/lib/cloudmersive-image-recognition-api-client/models/face_locate_with_landmarks_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_match.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_point.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/face_with_landmarks.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/find_symbol_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/fine_text_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/fine_text_item.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/gender_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/image_description_response.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/image_metadata.rb +28 -11
- data/lib/cloudmersive-image-recognition-api-client/models/image_metadata_exif_value.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/nsfw_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/object_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/person_with_age.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/person_with_gender.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/polygon_point.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/recognition_outcome.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/text_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/text_item.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/models/vehicle_license_plate_detection_result.rb +7 -10
- data/lib/cloudmersive-image-recognition-api-client/version.rb +2 -2
- data/spec/api/artistic_api_spec.rb +2 -2
- data/spec/api/convert_api_spec.rb +9 -9
- data/spec/api/edit_api_spec.rb +51 -15
- data/spec/api/face_api_spec.rb +12 -12
- data/spec/api/filter_api_spec.rb +10 -10
- data/spec/api/info_api_spec.rb +4 -4
- data/spec/api/nsfw_api_spec.rb +3 -3
- data/spec/api/recognize_api_spec.rb +12 -12
- data/spec/api/resize_api_spec.rb +7 -7
- data/spec/api_client_spec.rb +52 -35
- data/spec/configuration_spec.rb +9 -9
- data/spec/models/age_detection_result_spec.rb +4 -5
- data/spec/models/color_result_spec.rb +4 -5
- data/spec/models/detected_license_plate_spec.rb +8 -9
- data/spec/models/detected_object_spec.rb +7 -8
- data/spec/models/dominant_color_result_spec.rb +3 -4
- data/spec/models/draw_polygon_instance_spec.rb +5 -6
- data/spec/models/draw_polygon_request_spec.rb +4 -5
- data/spec/models/draw_rectangle_instance_spec.rb +8 -9
- data/spec/models/draw_rectangle_request_spec.rb +4 -5
- data/spec/models/draw_text_instance_spec.rb +9 -10
- data/spec/models/draw_text_request_spec.rb +4 -5
- data/spec/models/face_compare_response_spec.rb +5 -6
- data/spec/models/face_locate_response_spec.rb +9 -10
- data/spec/models/face_locate_with_landmarks_response_spec.rb +5 -6
- data/spec/models/face_match_spec.rb +7 -8
- data/spec/models/face_point_spec.rb +3 -4
- data/spec/models/face_spec.rb +5 -6
- data/spec/models/face_with_landmarks_spec.rb +14 -15
- data/spec/models/find_symbol_result_spec.rb +7 -8
- data/spec/models/fine_text_detection_result_spec.rb +4 -5
- data/spec/models/fine_text_item_spec.rb +12 -13
- data/spec/models/gender_detection_result_spec.rb +4 -5
- data/spec/models/image_description_response_spec.rb +5 -6
- data/spec/models/image_metadata_exif_value_spec.rb +4 -5
- data/spec/models/image_metadata_spec.rb +21 -10
- data/spec/models/nsfw_result_spec.rb +4 -5
- data/spec/models/object_detection_result_spec.rb +4 -5
- data/spec/models/person_with_age_spec.rb +5 -6
- data/spec/models/person_with_gender_spec.rb +4 -5
- data/spec/models/polygon_point_spec.rb +3 -4
- data/spec/models/recognition_outcome_spec.rb +3 -4
- data/spec/models/text_detection_result_spec.rb +4 -5
- data/spec/models/text_item_spec.rb +5 -6
- data/spec/models/vehicle_license_plate_detection_result_spec.rb +4 -5
- data/spec/spec_helper.rb +1 -1
- metadata +2 -2
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -24,7 +24,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
24
24
|
# Number of objects detected in the scene
|
25
25
|
attr_accessor :object_count
|
26
26
|
|
27
|
-
|
28
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
29
28
|
def self.attribute_map
|
30
29
|
{
|
@@ -49,7 +48,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
49
48
|
return unless attributes.is_a?(Hash)
|
50
49
|
|
51
50
|
# convert string to symbol for hash key
|
52
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
51
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
53
52
|
|
54
53
|
if attributes.has_key?(:'Successful')
|
55
54
|
self.successful = attributes[:'Successful']
|
@@ -64,20 +63,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
64
63
|
if attributes.has_key?(:'ObjectCount')
|
65
64
|
self.object_count = attributes[:'ObjectCount']
|
66
65
|
end
|
67
|
-
|
68
66
|
end
|
69
67
|
|
70
68
|
# Show invalid properties with the reasons. Usually used together with valid?
|
71
69
|
# @return Array for valid properties with the reasons
|
72
70
|
def list_invalid_properties
|
73
71
|
invalid_properties = Array.new
|
74
|
-
|
72
|
+
invalid_properties
|
75
73
|
end
|
76
74
|
|
77
75
|
# Check to see if the all the properties in the model are valid
|
78
76
|
# @return true if the model is valid
|
79
77
|
def valid?
|
80
|
-
|
78
|
+
true
|
81
79
|
end
|
82
80
|
|
83
81
|
# Checks equality by comparing each attribute.
|
@@ -109,10 +107,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
109
107
|
return nil unless attributes.is_a?(Hash)
|
110
108
|
self.class.swagger_types.each_pair do |key, type|
|
111
109
|
if type =~ /\AArray<(.*)>/i
|
112
|
-
# check to ensure the input is an array given that the
|
110
|
+
# check to ensure the input is an array given that the attribute
|
113
111
|
# is documented as an array but the input is not
|
114
112
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
115
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
113
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
116
114
|
end
|
117
115
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
118
116
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -194,7 +192,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
194
192
|
# @return [Hash] Returns the value in the form of hash
|
195
193
|
def _to_hash(value)
|
196
194
|
if value.is_a?(Array)
|
197
|
-
value.compact.map{ |v| _to_hash(v) }
|
195
|
+
value.compact.map { |v| _to_hash(v) }
|
198
196
|
elsif value.is_a?(Hash)
|
199
197
|
{}.tap do |hash|
|
200
198
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -207,5 +205,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
207
205
|
end
|
208
206
|
|
209
207
|
end
|
210
|
-
|
211
208
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -26,7 +26,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
26
26
|
|
27
27
|
attr_accessor :age
|
28
28
|
|
29
|
-
|
30
29
|
# Attribute mapping from ruby-style variable name to JSON key.
|
31
30
|
def self.attribute_map
|
32
31
|
{
|
@@ -53,7 +52,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
53
52
|
return unless attributes.is_a?(Hash)
|
54
53
|
|
55
54
|
# convert string to symbol for hash key
|
56
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
55
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
57
56
|
|
58
57
|
if attributes.has_key?(:'FaceLocation')
|
59
58
|
self.face_location = attributes[:'FaceLocation']
|
@@ -70,20 +69,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
70
69
|
if attributes.has_key?(:'Age')
|
71
70
|
self.age = attributes[:'Age']
|
72
71
|
end
|
73
|
-
|
74
72
|
end
|
75
73
|
|
76
74
|
# Show invalid properties with the reasons. Usually used together with valid?
|
77
75
|
# @return Array for valid properties with the reasons
|
78
76
|
def list_invalid_properties
|
79
77
|
invalid_properties = Array.new
|
80
|
-
|
78
|
+
invalid_properties
|
81
79
|
end
|
82
80
|
|
83
81
|
# Check to see if the all the properties in the model are valid
|
84
82
|
# @return true if the model is valid
|
85
83
|
def valid?
|
86
|
-
|
84
|
+
true
|
87
85
|
end
|
88
86
|
|
89
87
|
# Checks equality by comparing each attribute.
|
@@ -116,10 +114,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
116
114
|
return nil unless attributes.is_a?(Hash)
|
117
115
|
self.class.swagger_types.each_pair do |key, type|
|
118
116
|
if type =~ /\AArray<(.*)>/i
|
119
|
-
# check to ensure the input is an array given that the
|
117
|
+
# check to ensure the input is an array given that the attribute
|
120
118
|
# is documented as an array but the input is not
|
121
119
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
122
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
120
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
123
121
|
end
|
124
122
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
125
123
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -201,7 +199,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
201
199
|
# @return [Hash] Returns the value in the form of hash
|
202
200
|
def _to_hash(value)
|
203
201
|
if value.is_a?(Array)
|
204
|
-
value.compact.map{ |v| _to_hash(v) }
|
202
|
+
value.compact.map { |v| _to_hash(v) }
|
205
203
|
elsif value.is_a?(Hash)
|
206
204
|
{}.tap do |hash|
|
207
205
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -214,5 +212,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
214
212
|
end
|
215
213
|
|
216
214
|
end
|
217
|
-
|
218
215
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -24,7 +24,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
24
24
|
# The person's identified gender; possible values are \"Male\", \"Female\" and \"Unknown\"
|
25
25
|
attr_accessor :gender_class
|
26
26
|
|
27
|
-
|
28
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
29
28
|
def self.attribute_map
|
30
29
|
{
|
@@ -49,7 +48,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
49
48
|
return unless attributes.is_a?(Hash)
|
50
49
|
|
51
50
|
# convert string to symbol for hash key
|
52
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
51
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
53
52
|
|
54
53
|
if attributes.has_key?(:'FaceLocation')
|
55
54
|
self.face_location = attributes[:'FaceLocation']
|
@@ -62,20 +61,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
62
61
|
if attributes.has_key?(:'GenderClass')
|
63
62
|
self.gender_class = attributes[:'GenderClass']
|
64
63
|
end
|
65
|
-
|
66
64
|
end
|
67
65
|
|
68
66
|
# Show invalid properties with the reasons. Usually used together with valid?
|
69
67
|
# @return Array for valid properties with the reasons
|
70
68
|
def list_invalid_properties
|
71
69
|
invalid_properties = Array.new
|
72
|
-
|
70
|
+
invalid_properties
|
73
71
|
end
|
74
72
|
|
75
73
|
# Check to see if the all the properties in the model are valid
|
76
74
|
# @return true if the model is valid
|
77
75
|
def valid?
|
78
|
-
|
76
|
+
true
|
79
77
|
end
|
80
78
|
|
81
79
|
# Checks equality by comparing each attribute.
|
@@ -107,10 +105,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
107
105
|
return nil unless attributes.is_a?(Hash)
|
108
106
|
self.class.swagger_types.each_pair do |key, type|
|
109
107
|
if type =~ /\AArray<(.*)>/i
|
110
|
-
# check to ensure the input is an array given that the
|
108
|
+
# check to ensure the input is an array given that the attribute
|
111
109
|
# is documented as an array but the input is not
|
112
110
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
113
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
111
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
114
112
|
end
|
115
113
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
116
114
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -192,7 +190,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
192
190
|
# @return [Hash] Returns the value in the form of hash
|
193
191
|
def _to_hash(value)
|
194
192
|
if value.is_a?(Array)
|
195
|
-
value.compact.map{ |v| _to_hash(v) }
|
193
|
+
value.compact.map { |v| _to_hash(v) }
|
196
194
|
elsif value.is_a?(Hash)
|
197
195
|
{}.tap do |hash|
|
198
196
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -205,5 +203,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
205
203
|
end
|
206
204
|
|
207
205
|
end
|
208
|
-
|
209
206
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -21,7 +21,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
21
21
|
# Y location in pixels of this point in the polygon
|
22
22
|
attr_accessor :y
|
23
23
|
|
24
|
-
|
25
24
|
# Attribute mapping from ruby-style variable name to JSON key.
|
26
25
|
def self.attribute_map
|
27
26
|
{
|
@@ -44,7 +43,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
44
43
|
return unless attributes.is_a?(Hash)
|
45
44
|
|
46
45
|
# convert string to symbol for hash key
|
47
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
46
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
48
47
|
|
49
48
|
if attributes.has_key?(:'X')
|
50
49
|
self.x = attributes[:'X']
|
@@ -53,20 +52,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
53
52
|
if attributes.has_key?(:'Y')
|
54
53
|
self.y = attributes[:'Y']
|
55
54
|
end
|
56
|
-
|
57
55
|
end
|
58
56
|
|
59
57
|
# Show invalid properties with the reasons. Usually used together with valid?
|
60
58
|
# @return Array for valid properties with the reasons
|
61
59
|
def list_invalid_properties
|
62
60
|
invalid_properties = Array.new
|
63
|
-
|
61
|
+
invalid_properties
|
64
62
|
end
|
65
63
|
|
66
64
|
# Check to see if the all the properties in the model are valid
|
67
65
|
# @return true if the model is valid
|
68
66
|
def valid?
|
69
|
-
|
67
|
+
true
|
70
68
|
end
|
71
69
|
|
72
70
|
# Checks equality by comparing each attribute.
|
@@ -97,10 +95,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
97
95
|
return nil unless attributes.is_a?(Hash)
|
98
96
|
self.class.swagger_types.each_pair do |key, type|
|
99
97
|
if type =~ /\AArray<(.*)>/i
|
100
|
-
# check to ensure the input is an array given that the
|
98
|
+
# check to ensure the input is an array given that the attribute
|
101
99
|
# is documented as an array but the input is not
|
102
100
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
103
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
101
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
104
102
|
end
|
105
103
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
106
104
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -182,7 +180,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
182
180
|
# @return [Hash] Returns the value in the form of hash
|
183
181
|
def _to_hash(value)
|
184
182
|
if value.is_a?(Array)
|
185
|
-
value.compact.map{ |v| _to_hash(v) }
|
183
|
+
value.compact.map { |v| _to_hash(v) }
|
186
184
|
elsif value.is_a?(Hash)
|
187
185
|
{}.tap do |hash|
|
188
186
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -195,5 +193,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
195
193
|
end
|
196
194
|
|
197
195
|
end
|
198
|
-
|
199
196
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -21,7 +21,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
21
21
|
# English language description of the image
|
22
22
|
attr_accessor :description
|
23
23
|
|
24
|
-
|
25
24
|
# Attribute mapping from ruby-style variable name to JSON key.
|
26
25
|
def self.attribute_map
|
27
26
|
{
|
@@ -44,7 +43,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
44
43
|
return unless attributes.is_a?(Hash)
|
45
44
|
|
46
45
|
# convert string to symbol for hash key
|
47
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
46
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
48
47
|
|
49
48
|
if attributes.has_key?(:'ConfidenceScore')
|
50
49
|
self.confidence_score = attributes[:'ConfidenceScore']
|
@@ -53,20 +52,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
53
52
|
if attributes.has_key?(:'Description')
|
54
53
|
self.description = attributes[:'Description']
|
55
54
|
end
|
56
|
-
|
57
55
|
end
|
58
56
|
|
59
57
|
# Show invalid properties with the reasons. Usually used together with valid?
|
60
58
|
# @return Array for valid properties with the reasons
|
61
59
|
def list_invalid_properties
|
62
60
|
invalid_properties = Array.new
|
63
|
-
|
61
|
+
invalid_properties
|
64
62
|
end
|
65
63
|
|
66
64
|
# Check to see if the all the properties in the model are valid
|
67
65
|
# @return true if the model is valid
|
68
66
|
def valid?
|
69
|
-
|
67
|
+
true
|
70
68
|
end
|
71
69
|
|
72
70
|
# Checks equality by comparing each attribute.
|
@@ -97,10 +95,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
97
95
|
return nil unless attributes.is_a?(Hash)
|
98
96
|
self.class.swagger_types.each_pair do |key, type|
|
99
97
|
if type =~ /\AArray<(.*)>/i
|
100
|
-
# check to ensure the input is an array given that the
|
98
|
+
# check to ensure the input is an array given that the attribute
|
101
99
|
# is documented as an array but the input is not
|
102
100
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
103
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
101
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
104
102
|
end
|
105
103
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
106
104
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -182,7 +180,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
182
180
|
# @return [Hash] Returns the value in the form of hash
|
183
181
|
def _to_hash(value)
|
184
182
|
if value.is_a?(Array)
|
185
|
-
value.compact.map{ |v| _to_hash(v) }
|
183
|
+
value.compact.map { |v| _to_hash(v) }
|
186
184
|
elsif value.is_a?(Hash)
|
187
185
|
{}.tap do |hash|
|
188
186
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -195,5 +193,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
195
193
|
end
|
196
194
|
|
197
195
|
end
|
198
|
-
|
199
196
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -24,7 +24,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
24
24
|
# Count of text items found in the input image
|
25
25
|
attr_accessor :text_items_count
|
26
26
|
|
27
|
-
|
28
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
29
28
|
def self.attribute_map
|
30
29
|
{
|
@@ -49,7 +48,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
49
48
|
return unless attributes.is_a?(Hash)
|
50
49
|
|
51
50
|
# convert string to symbol for hash key
|
52
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
51
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
53
52
|
|
54
53
|
if attributes.has_key?(:'Successful')
|
55
54
|
self.successful = attributes[:'Successful']
|
@@ -64,20 +63,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
64
63
|
if attributes.has_key?(:'TextItemsCount')
|
65
64
|
self.text_items_count = attributes[:'TextItemsCount']
|
66
65
|
end
|
67
|
-
|
68
66
|
end
|
69
67
|
|
70
68
|
# Show invalid properties with the reasons. Usually used together with valid?
|
71
69
|
# @return Array for valid properties with the reasons
|
72
70
|
def list_invalid_properties
|
73
71
|
invalid_properties = Array.new
|
74
|
-
|
72
|
+
invalid_properties
|
75
73
|
end
|
76
74
|
|
77
75
|
# Check to see if the all the properties in the model are valid
|
78
76
|
# @return true if the model is valid
|
79
77
|
def valid?
|
80
|
-
|
78
|
+
true
|
81
79
|
end
|
82
80
|
|
83
81
|
# Checks equality by comparing each attribute.
|
@@ -109,10 +107,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
109
107
|
return nil unless attributes.is_a?(Hash)
|
110
108
|
self.class.swagger_types.each_pair do |key, type|
|
111
109
|
if type =~ /\AArray<(.*)>/i
|
112
|
-
# check to ensure the input is an array given that the
|
110
|
+
# check to ensure the input is an array given that the attribute
|
113
111
|
# is documented as an array but the input is not
|
114
112
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
115
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
113
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
116
114
|
end
|
117
115
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
118
116
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -194,7 +192,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
194
192
|
# @return [Hash] Returns the value in the form of hash
|
195
193
|
def _to_hash(value)
|
196
194
|
if value.is_a?(Array)
|
197
|
-
value.compact.map{ |v| _to_hash(v) }
|
195
|
+
value.compact.map { |v| _to_hash(v) }
|
198
196
|
elsif value.is_a?(Hash)
|
199
197
|
{}.tap do |hash|
|
200
198
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -207,5 +205,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
207
205
|
end
|
208
206
|
|
209
207
|
end
|
210
|
-
|
211
208
|
end
|
@@ -6,7 +6,7 @@
|
|
6
6
|
OpenAPI spec version: v1
|
7
7
|
|
8
8
|
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
-
Swagger Codegen version: 2.
|
9
|
+
Swagger Codegen version: 2.4.14
|
10
10
|
|
11
11
|
=end
|
12
12
|
|
@@ -27,7 +27,6 @@ module CloudmersiveImageRecognitionApiClient
|
|
27
27
|
# Height in pixels of the text item
|
28
28
|
attr_accessor :height
|
29
29
|
|
30
|
-
|
31
30
|
# Attribute mapping from ruby-style variable name to JSON key.
|
32
31
|
def self.attribute_map
|
33
32
|
{
|
@@ -54,7 +53,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
54
53
|
return unless attributes.is_a?(Hash)
|
55
54
|
|
56
55
|
# convert string to symbol for hash key
|
57
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
56
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
58
57
|
|
59
58
|
if attributes.has_key?(:'LeftX')
|
60
59
|
self.left_x = attributes[:'LeftX']
|
@@ -71,20 +70,19 @@ module CloudmersiveImageRecognitionApiClient
|
|
71
70
|
if attributes.has_key?(:'Height')
|
72
71
|
self.height = attributes[:'Height']
|
73
72
|
end
|
74
|
-
|
75
73
|
end
|
76
74
|
|
77
75
|
# Show invalid properties with the reasons. Usually used together with valid?
|
78
76
|
# @return Array for valid properties with the reasons
|
79
77
|
def list_invalid_properties
|
80
78
|
invalid_properties = Array.new
|
81
|
-
|
79
|
+
invalid_properties
|
82
80
|
end
|
83
81
|
|
84
82
|
# Check to see if the all the properties in the model are valid
|
85
83
|
# @return true if the model is valid
|
86
84
|
def valid?
|
87
|
-
|
85
|
+
true
|
88
86
|
end
|
89
87
|
|
90
88
|
# Checks equality by comparing each attribute.
|
@@ -117,10 +115,10 @@ module CloudmersiveImageRecognitionApiClient
|
|
117
115
|
return nil unless attributes.is_a?(Hash)
|
118
116
|
self.class.swagger_types.each_pair do |key, type|
|
119
117
|
if type =~ /\AArray<(.*)>/i
|
120
|
-
# check to ensure the input is an array given that the
|
118
|
+
# check to ensure the input is an array given that the attribute
|
121
119
|
# is documented as an array but the input is not
|
122
120
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
123
|
-
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) }
|
121
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
124
122
|
end
|
125
123
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
126
124
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
@@ -202,7 +200,7 @@ module CloudmersiveImageRecognitionApiClient
|
|
202
200
|
# @return [Hash] Returns the value in the form of hash
|
203
201
|
def _to_hash(value)
|
204
202
|
if value.is_a?(Array)
|
205
|
-
value.compact.map{ |v| _to_hash(v) }
|
203
|
+
value.compact.map { |v| _to_hash(v) }
|
206
204
|
elsif value.is_a?(Hash)
|
207
205
|
{}.tap do |hash|
|
208
206
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -215,5 +213,4 @@ module CloudmersiveImageRecognitionApiClient
|
|
215
213
|
end
|
216
214
|
|
217
215
|
end
|
218
|
-
|
219
216
|
end
|