telestream_cloud_qc 2.0.0 → 2.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (75) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +48 -1
  3. data/docs/Alert.md +2 -2
  4. data/docs/Container.md +1 -1
  5. data/docs/InlineResponse200.md +9 -0
  6. data/docs/InlineResponse422.md +8 -0
  7. data/docs/Job.md +10 -0
  8. data/docs/JobData.md +1 -0
  9. data/docs/JobDetails.md +2 -0
  10. data/docs/JobDetailsResult.md +1 -0
  11. data/docs/Project.md +1 -1
  12. data/docs/QcApi.md +129 -26
  13. data/docs/Summary.md +13 -0
  14. data/docs/SynchronizationEvent.md +10 -0
  15. data/docs/Template.md +12 -0
  16. data/docs/VideoStream.md +1 -1
  17. data/lib/telestream_cloud_qc.rb +7 -2
  18. data/lib/telestream_cloud_qc/api/qc_api.rb +119 -15
  19. data/lib/telestream_cloud_qc/api_client.rb +2 -2
  20. data/lib/telestream_cloud_qc/api_error.rb +2 -2
  21. data/lib/telestream_cloud_qc/configuration.rb +3 -3
  22. data/lib/telestream_cloud_qc/models/alert.rb +4 -4
  23. data/lib/telestream_cloud_qc/models/audio_stream.rb +2 -2
  24. data/lib/telestream_cloud_qc/models/container.rb +3 -3
  25. data/lib/telestream_cloud_qc/models/data.rb +2 -2
  26. data/lib/telestream_cloud_qc/models/data_1.rb +2 -2
  27. data/lib/telestream_cloud_qc/models/extra_file.rb +2 -2
  28. data/lib/telestream_cloud_qc/models/inline_response_200.rb +197 -0
  29. data/lib/telestream_cloud_qc/models/inline_response_422.rb +188 -0
  30. data/lib/telestream_cloud_qc/models/job.rb +95 -5
  31. data/lib/telestream_cloud_qc/models/job_data.rb +16 -6
  32. data/lib/telestream_cloud_qc/models/job_details.rb +26 -6
  33. data/lib/telestream_cloud_qc/models/job_details_result.rb +17 -6
  34. data/lib/telestream_cloud_qc/models/jobs_collection.rb +2 -2
  35. data/lib/telestream_cloud_qc/models/media.rb +2 -2
  36. data/lib/telestream_cloud_qc/models/options.rb +2 -2
  37. data/lib/telestream_cloud_qc/models/project.rb +6 -4
  38. data/lib/telestream_cloud_qc/models/proxy.rb +2 -2
  39. data/lib/telestream_cloud_qc/models/summary.rb +236 -0
  40. data/lib/telestream_cloud_qc/models/synchronization_event.rb +206 -0
  41. data/lib/telestream_cloud_qc/models/template.rb +228 -0
  42. data/lib/telestream_cloud_qc/models/upload_session.rb +2 -2
  43. data/lib/telestream_cloud_qc/models/video_stream.rb +3 -3
  44. data/lib/telestream_cloud_qc/models/video_upload_body.rb +2 -2
  45. data/lib/telestream_cloud_qc/uploader.rb +12 -0
  46. data/lib/telestream_cloud_qc/version.rb +3 -3
  47. data/spec/api/qc_api_spec.rb +26 -2
  48. data/spec/api_client_spec.rb +2 -2
  49. data/spec/configuration_spec.rb +2 -2
  50. data/spec/models/alert_spec.rb +2 -2
  51. data/spec/models/audio_stream_spec.rb +2 -2
  52. data/spec/models/container_spec.rb +2 -2
  53. data/spec/models/data_1_spec.rb +2 -2
  54. data/spec/models/data_spec.rb +2 -2
  55. data/spec/models/extra_file_spec.rb +2 -2
  56. data/spec/models/inline_response_200_spec.rb +48 -0
  57. data/spec/models/inline_response_422_spec.rb +42 -0
  58. data/spec/models/job_data_spec.rb +8 -2
  59. data/spec/models/job_details_result_spec.rb +8 -2
  60. data/spec/models/job_details_spec.rb +14 -2
  61. data/spec/models/job_spec.rb +63 -3
  62. data/spec/models/jobs_collection_spec.rb +2 -2
  63. data/spec/models/media_spec.rb +2 -2
  64. data/spec/models/options_spec.rb +2 -2
  65. data/spec/models/project_spec.rb +2 -2
  66. data/spec/models/proxy_spec.rb +2 -2
  67. data/spec/models/summary_spec.rb +72 -0
  68. data/spec/models/synchronization_event_spec.rb +54 -0
  69. data/spec/models/template_spec.rb +66 -0
  70. data/spec/models/upload_session_spec.rb +2 -2
  71. data/spec/models/video_stream_spec.rb +2 -2
  72. data/spec/models/video_upload_body_spec.rb +2 -2
  73. data/spec/spec_helper.rb +2 -2
  74. data/telestream_cloud_qc.gemspec +2 -2
  75. metadata +35 -15
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -19,12 +19,16 @@ module TelestreamCloud::Qc
19
19
 
20
20
  attr_accessor :url
21
21
 
22
+ # Payload is an arbitrary text of length 256 or shorter that you can store along the Media. It is typically used to retain an association with one of your own DB record ID.
23
+ attr_accessor :payload
24
+
22
25
 
23
26
  # Attribute mapping from ruby-style variable name to JSON key.
24
27
  def self.attribute_map
25
28
  {
26
29
  :'options' => :'options',
27
- :'url' => :'url'
30
+ :'url' => :'url',
31
+ :'payload' => :'payload'
28
32
  }
29
33
  end
30
34
 
@@ -32,7 +36,8 @@ module TelestreamCloud::Qc
32
36
  def self.swagger_types
33
37
  {
34
38
  :'options' => :'Options',
35
- :'url' => :'String'
39
+ :'url' => :'String',
40
+ :'payload' => :'String'
36
41
  }
37
42
  end
38
43
 
@@ -52,6 +57,10 @@ module TelestreamCloud::Qc
52
57
  self.url = attributes[:'url']
53
58
  end
54
59
 
60
+ if attributes.has_key?(:'payload')
61
+ self.payload = attributes[:'payload']
62
+ end
63
+
55
64
  end
56
65
 
57
66
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -73,7 +82,8 @@ module TelestreamCloud::Qc
73
82
  return true if self.equal?(o)
74
83
  self.class == o.class &&
75
84
  options == o.options &&
76
- url == o.url
85
+ url == o.url &&
86
+ payload == o.payload
77
87
  end
78
88
 
79
89
  # @see the `==` method
@@ -85,7 +95,7 @@ module TelestreamCloud::Qc
85
95
  # Calculates hash code according to all attributes.
86
96
  # @return [Fixnum] Hash code
87
97
  def hash
88
- [options, url].hash
98
+ [options, url, payload].hash
89
99
  end
90
100
 
91
101
  # Builds the object from hash
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -19,12 +19,18 @@ module TelestreamCloud::Qc
19
19
 
20
20
  attr_accessor :result
21
21
 
22
+ attr_accessor :synchronization_events
23
+
24
+ attr_accessor :summary
25
+
22
26
 
23
27
  # Attribute mapping from ruby-style variable name to JSON key.
24
28
  def self.attribute_map
25
29
  {
26
30
  :'media' => :'media',
27
- :'result' => :'result'
31
+ :'result' => :'result',
32
+ :'synchronization_events' => :'synchronization_events',
33
+ :'summary' => :'summary'
28
34
  }
29
35
  end
30
36
 
@@ -32,7 +38,9 @@ module TelestreamCloud::Qc
32
38
  def self.swagger_types
33
39
  {
34
40
  :'media' => :'Array<Media>',
35
- :'result' => :'JobDetailsResult'
41
+ :'result' => :'JobDetailsResult',
42
+ :'synchronization_events' => :'Array<SynchronizationEvent>',
43
+ :'summary' => :'Summary'
36
44
  }
37
45
  end
38
46
 
@@ -54,6 +62,16 @@ module TelestreamCloud::Qc
54
62
  self.result = attributes[:'result']
55
63
  end
56
64
 
65
+ if attributes.has_key?(:'synchronization_events')
66
+ if (value = attributes[:'synchronization_events']).is_a?(Array)
67
+ self.synchronization_events = value
68
+ end
69
+ end
70
+
71
+ if attributes.has_key?(:'summary')
72
+ self.summary = attributes[:'summary']
73
+ end
74
+
57
75
  end
58
76
 
59
77
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -75,7 +93,9 @@ module TelestreamCloud::Qc
75
93
  return true if self.equal?(o)
76
94
  self.class == o.class &&
77
95
  media == o.media &&
78
- result == o.result
96
+ result == o.result &&
97
+ synchronization_events == o.synchronization_events &&
98
+ summary == o.summary
79
99
  end
80
100
 
81
101
  # @see the `==` method
@@ -87,7 +107,7 @@ module TelestreamCloud::Qc
87
107
  # Calculates hash code according to all attributes.
88
108
  # @return [Fixnum] Hash code
89
109
  def hash
90
- [media, result].hash
110
+ [media, result, synchronization_events, summary].hash
91
111
  end
92
112
 
93
113
  # Builds the object from hash
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -17,18 +17,22 @@ module TelestreamCloud::Qc
17
17
  class JobDetailsResult
18
18
  attr_accessor :alerts
19
19
 
20
+ attr_accessor :reports
21
+
20
22
 
21
23
  # Attribute mapping from ruby-style variable name to JSON key.
22
24
  def self.attribute_map
23
25
  {
24
- :'alerts' => :'alerts'
26
+ :'alerts' => :'alerts',
27
+ :'reports' => :'reports'
25
28
  }
26
29
  end
27
30
 
28
31
  # Attribute type mapping.
29
32
  def self.swagger_types
30
33
  {
31
- :'alerts' => :'Array<Alert>'
34
+ :'alerts' => :'Array<Alert>',
35
+ :'reports' => :'Array<String>'
32
36
  }
33
37
  end
34
38
 
@@ -46,6 +50,12 @@ module TelestreamCloud::Qc
46
50
  end
47
51
  end
48
52
 
53
+ if attributes.has_key?(:'reports')
54
+ if (value = attributes[:'reports']).is_a?(Array)
55
+ self.reports = value
56
+ end
57
+ end
58
+
49
59
  end
50
60
 
51
61
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -66,7 +76,8 @@ module TelestreamCloud::Qc
66
76
  def ==(o)
67
77
  return true if self.equal?(o)
68
78
  self.class == o.class &&
69
- alerts == o.alerts
79
+ alerts == o.alerts &&
80
+ reports == o.reports
70
81
  end
71
82
 
72
83
  # @see the `==` method
@@ -78,7 +89,7 @@ module TelestreamCloud::Qc
78
89
  # Calculates hash code according to all attributes.
79
90
  # @return [Fixnum] Hash code
80
91
  def hash
81
- [alerts].hash
92
+ [alerts, reports].hash
82
93
  end
83
94
 
84
95
  # Builds the object from hash
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -70,7 +70,7 @@ module TelestreamCloud::Qc
70
70
  :'name' => :'String',
71
71
  :'status' => :'String',
72
72
  :'template' => :'String',
73
- :'options' => :'String'
73
+ :'options' => :'Hash<String, Object>'
74
74
  }
75
75
  end
76
76
 
@@ -99,7 +99,9 @@ module TelestreamCloud::Qc
99
99
  end
100
100
 
101
101
  if attributes.has_key?(:'options')
102
- self.options = attributes[:'options']
102
+ if (value = attributes[:'options']).is_a?(Hash)
103
+ self.options = value
104
+ end
103
105
  end
104
106
 
105
107
  end
@@ -3,10 +3,10 @@
3
3
 
4
4
  #QC API
5
5
 
6
- OpenAPI spec version: 2.0.0
6
+ OpenAPI spec version: 2.0.3
7
7
  Contact: cloudsupport@telestream.net
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.3.0
9
+ Swagger Codegen version: 2.3.1
10
10
 
11
11
  =end
12
12
 
@@ -0,0 +1,236 @@
1
+ =begin
2
+ #Qc API
3
+
4
+ #QC API
5
+
6
+ OpenAPI spec version: 2.0.3
7
+ Contact: cloudsupport@telestream.net
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.3.1
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module TelestreamCloud::Qc
16
+
17
+ class Summary
18
+ # Total number of synchronization detection events considered for summary.
19
+ attr_accessor :num_sync_events
20
+
21
+ attr_accessor :avsync_analysis
22
+
23
+ attr_accessor :avsync_inference
24
+
25
+ # Confidence of avsync_inference and avsync_analysis. 'confidence' is a value between 0 and 100. confidence >= 90 - Very high confidence. 80 <= confidence < 90 - High confidence. 70 <= confidence < 80 - Should be reviewed by human.
26
+ attr_accessor :confidence
27
+
28
+ # Skew estimate in #frames; Skew is the number of frames that audio is delayed to the video
29
+ attr_accessor :skew
30
+
31
+ attr_accessor :total_length
32
+
33
+
34
+ # Attribute mapping from ruby-style variable name to JSON key.
35
+ def self.attribute_map
36
+ {
37
+ :'num_sync_events' => :'num_sync_events',
38
+ :'avsync_analysis' => :'avsync_analysis',
39
+ :'avsync_inference' => :'avsync_inference',
40
+ :'confidence' => :'confidence',
41
+ :'skew' => :'skew',
42
+ :'total_length' => :'total_length'
43
+ }
44
+ end
45
+
46
+ # Attribute type mapping.
47
+ def self.swagger_types
48
+ {
49
+ :'num_sync_events' => :'Integer',
50
+ :'avsync_analysis' => :'String',
51
+ :'avsync_inference' => :'String',
52
+ :'confidence' => :'Float',
53
+ :'skew' => :'Integer',
54
+ :'total_length' => :'Float'
55
+ }
56
+ end
57
+
58
+ # Initializes the object
59
+ # @param [Hash] attributes Model attributes in the form of hash
60
+ def initialize(attributes = {})
61
+ return unless attributes.is_a?(Hash)
62
+
63
+ # convert string to symbol for hash key
64
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
65
+
66
+ if attributes.has_key?(:'num_sync_events')
67
+ self.num_sync_events = attributes[:'num_sync_events']
68
+ end
69
+
70
+ if attributes.has_key?(:'avsync_analysis')
71
+ self.avsync_analysis = attributes[:'avsync_analysis']
72
+ end
73
+
74
+ if attributes.has_key?(:'avsync_inference')
75
+ self.avsync_inference = attributes[:'avsync_inference']
76
+ end
77
+
78
+ if attributes.has_key?(:'confidence')
79
+ self.confidence = attributes[:'confidence']
80
+ end
81
+
82
+ if attributes.has_key?(:'skew')
83
+ self.skew = attributes[:'skew']
84
+ end
85
+
86
+ if attributes.has_key?(:'total_length')
87
+ self.total_length = attributes[:'total_length']
88
+ end
89
+
90
+ end
91
+
92
+ # Show invalid properties with the reasons. Usually used together with valid?
93
+ # @return Array for valid properties with the reasons
94
+ def list_invalid_properties
95
+ invalid_properties = Array.new
96
+ return invalid_properties
97
+ end
98
+
99
+ # Check to see if the all the properties in the model are valid
100
+ # @return true if the model is valid
101
+ def valid?
102
+ return true
103
+ end
104
+
105
+ # Checks equality by comparing each attribute.
106
+ # @param [Object] Object to be compared
107
+ def ==(o)
108
+ return true if self.equal?(o)
109
+ self.class == o.class &&
110
+ num_sync_events == o.num_sync_events &&
111
+ avsync_analysis == o.avsync_analysis &&
112
+ avsync_inference == o.avsync_inference &&
113
+ confidence == o.confidence &&
114
+ skew == o.skew &&
115
+ total_length == o.total_length
116
+ end
117
+
118
+ # @see the `==` method
119
+ # @param [Object] Object to be compared
120
+ def eql?(o)
121
+ self == o
122
+ end
123
+
124
+ # Calculates hash code according to all attributes.
125
+ # @return [Fixnum] Hash code
126
+ def hash
127
+ [num_sync_events, avsync_analysis, avsync_inference, confidence, skew, total_length].hash
128
+ end
129
+
130
+ # Builds the object from hash
131
+ # @param [Hash] attributes Model attributes in the form of hash
132
+ # @return [Object] Returns the model itself
133
+ def build_from_hash(attributes)
134
+ return nil unless attributes.is_a?(Hash)
135
+ self.class.swagger_types.each_pair do |key, type|
136
+ if type =~ /\AArray<(.*)>/i
137
+ # check to ensure the input is an array given that the the attribute
138
+ # is documented as an array but the input is not
139
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
140
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
141
+ end
142
+ elsif !attributes[self.class.attribute_map[key]].nil?
143
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
144
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
145
+ end
146
+
147
+ self
148
+ end
149
+
150
+ # Deserializes the data based on type
151
+ # @param string type Data type
152
+ # @param string value Value to be deserialized
153
+ # @return [Object] Deserialized data
154
+ def _deserialize(type, value)
155
+ case type.to_sym
156
+ when :DateTime
157
+ DateTime.parse(value)
158
+ when :Date
159
+ Date.parse(value)
160
+ when :String
161
+ value.to_s
162
+ when :Integer
163
+ value.to_i
164
+ when :Float
165
+ value.to_f
166
+ when :BOOLEAN
167
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
168
+ true
169
+ else
170
+ false
171
+ end
172
+ when :Object
173
+ # generic object (usually a Hash), return directly
174
+ value
175
+ when /\AArray<(?<inner_type>.+)>\z/
176
+ inner_type = Regexp.last_match[:inner_type]
177
+ value.map { |v| _deserialize(inner_type, v) }
178
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
179
+ k_type = Regexp.last_match[:k_type]
180
+ v_type = Regexp.last_match[:v_type]
181
+ {}.tap do |hash|
182
+ value.each do |k, v|
183
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
184
+ end
185
+ end
186
+ else # model
187
+ temp_model = TelestreamCloud::Qc.const_get(type).new
188
+ temp_model.build_from_hash(value)
189
+ end
190
+ end
191
+
192
+ # Returns the string representation of the object
193
+ # @return [String] String presentation of the object
194
+ def to_s
195
+ to_hash.to_s
196
+ end
197
+
198
+ # to_body is an alias to to_hash (backward compatibility)
199
+ # @return [Hash] Returns the object in the form of hash
200
+ def to_body
201
+ to_hash
202
+ end
203
+
204
+ # Returns the object in the form of hash
205
+ # @return [Hash] Returns the object in the form of hash
206
+ def to_hash
207
+ hash = {}
208
+ self.class.attribute_map.each_pair do |attr, param|
209
+ value = self.send(attr)
210
+ next if value.nil?
211
+ hash[param] = _to_hash(value)
212
+ end
213
+ hash
214
+ end
215
+
216
+ # Outputs non-array value in the form of hash
217
+ # For object, use to_hash. Otherwise, just return the value
218
+ # @param [Object] value Any valid value
219
+ # @return [Hash] Returns the value in the form of hash
220
+ def _to_hash(value)
221
+ if value.is_a?(Array)
222
+ value.compact.map{ |v| _to_hash(v) }
223
+ elsif value.is_a?(Hash)
224
+ {}.tap do |hash|
225
+ value.each { |k, v| hash[k] = _to_hash(v) }
226
+ end
227
+ elsif value.respond_to? :to_hash
228
+ value.to_hash
229
+ else
230
+ value
231
+ end
232
+ end
233
+
234
+ end
235
+
236
+ end