mux_ruby 3.15.0 → 3.17.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (83) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/README.md +4 -4
  4. data/docs/AbridgedVideoView.md +3 -1
  5. data/docs/CreateAssetRequest.md +3 -1
  6. data/docs/CreateLiveStreamRequest.md +2 -0
  7. data/docs/CreatePlaybackIDRequest.md +3 -1
  8. data/docs/CreatePlaybackRestrictionRequest.md +3 -1
  9. data/docs/CreateUploadRequest.md +1 -1
  10. data/docs/DRMConfiguration.md +18 -0
  11. data/docs/DRMConfigurationResponse.md +18 -0
  12. data/docs/DRMConfigurationsApi.md +153 -0
  13. data/docs/DeliveryReport.md +2 -0
  14. data/docs/GenerateTrackSubtitlesResponse.md +1 -1
  15. data/docs/ListDRMConfigurationsResponse.md +18 -0
  16. data/docs/MetricsApi.md +8 -8
  17. data/docs/PlaybackID.md +3 -1
  18. data/docs/PlaybackRestriction.md +3 -1
  19. data/docs/PlaybackRestrictionsApi.md +73 -0
  20. data/docs/UpdateLiveStreamNewAssetSettings.md +18 -0
  21. data/docs/UpdateLiveStreamRequest.md +3 -1
  22. data/docs/UpdateUserAgentRestrictionRequest.md +20 -0
  23. data/docs/UserAgentRestrictionRequest.md +20 -0
  24. data/docs/UserAgentRestrictionSettings.md +20 -0
  25. data/docs/VideoView.md +13 -1
  26. data/gen/generator-config.json +1 -1
  27. data/lib/mux_ruby/api/drm_configurations_api.rb +148 -0
  28. data/lib/mux_ruby/api/metrics_api.rb +14 -14
  29. data/lib/mux_ruby/api/playback_restrictions_api.rb +71 -0
  30. data/lib/mux_ruby/models/abridged_video_view.rb +14 -5
  31. data/lib/mux_ruby/models/create_asset_request.rb +14 -2
  32. data/lib/mux_ruby/models/create_live_stream_request.rb +13 -1
  33. data/lib/mux_ruby/models/create_playback_id_request.rb +14 -4
  34. data/lib/mux_ruby/models/create_playback_restriction_request.rb +13 -4
  35. data/lib/mux_ruby/models/create_upload_request.rb +1 -0
  36. data/lib/mux_ruby/models/delivery_report.rb +23 -1
  37. data/lib/mux_ruby/models/drm_configuration.rb +219 -0
  38. data/lib/mux_ruby/models/drm_configuration_response.rb +218 -0
  39. data/lib/mux_ruby/models/generate_track_subtitles_response.rb +4 -2
  40. data/lib/mux_ruby/models/list_drm_configurations_response.rb +220 -0
  41. data/lib/mux_ruby/models/playback_id.rb +14 -4
  42. data/lib/mux_ruby/models/playback_policy.rb +1 -0
  43. data/lib/mux_ruby/models/playback_restriction.rb +13 -4
  44. data/lib/mux_ruby/models/update_live_stream_new_asset_settings.rb +254 -0
  45. data/lib/mux_ruby/models/update_live_stream_request.rb +13 -4
  46. data/lib/mux_ruby/models/update_user_agent_restriction_request.rb +233 -0
  47. data/lib/mux_ruby/models/user_agent_restriction_request.rb +234 -0
  48. data/lib/mux_ruby/models/user_agent_restriction_settings.rb +234 -0
  49. data/lib/mux_ruby/models/video_view.rb +66 -4
  50. data/lib/mux_ruby/version.rb +1 -1
  51. data/lib/mux_ruby.rb +8 -0
  52. data/spec/api/drm_configurations_api_spec.rb +60 -0
  53. data/spec/models/drm_configuration_response_spec.rb +34 -0
  54. data/spec/models/drm_configuration_spec.rb +34 -0
  55. data/spec/models/list_drm_configurations_response_spec.rb +34 -0
  56. data/spec/models/update_live_stream_new_asset_settings_spec.rb +38 -0
  57. data/spec/models/update_user_agent_restriction_request_spec.rb +40 -0
  58. data/spec/models/user_agent_restriction_request_spec.rb +40 -0
  59. data/spec/models/user_agent_restriction_settings_spec.rb +40 -0
  60. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/byebug-11.1.3/byebug/byebug.so +0 -0
  61. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/byebug-11.1.3/gem_make.out +6 -6
  62. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/ffi-1.16.3/ffi_c.so +0 -0
  63. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/ffi-1.16.3/gem_make.out +6 -6
  64. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/ffi-1.16.3/mkmf.log +18 -18
  65. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/jaro_winkler-1.5.4/gem_make.out +14 -14
  66. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/jaro_winkler-1.5.4/jaro_winkler/jaro_winkler_ext.so +0 -0
  67. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/psych-4.0.4/gem_make.out +6 -6
  68. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/psych-4.0.4/mkmf.log +4 -4
  69. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/psych-4.0.4/psych.so +0 -0
  70. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/stringio-3.0.2/gem_make.out +6 -6
  71. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/stringio-3.0.2/mkmf.log +2 -2
  72. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/stringio-3.0.2/stringio.so +0 -0
  73. data/vendor/bundle/ruby/3.2.0/gems/byebug-11.1.3/ext/byebug/Makefile +3 -3
  74. data/vendor/bundle/ruby/3.2.0/gems/byebug-11.1.3/lib/byebug/byebug.so +0 -0
  75. data/vendor/bundle/ruby/3.2.0/gems/ffi-1.16.3/ext/ffi_c/Makefile +3 -3
  76. data/vendor/bundle/ruby/3.2.0/gems/ffi-1.16.3/lib/ffi_c.so +0 -0
  77. data/vendor/bundle/ruby/3.2.0/gems/jaro_winkler-1.5.4/ext/jaro_winkler/Makefile +3 -3
  78. data/vendor/bundle/ruby/3.2.0/gems/jaro_winkler-1.5.4/lib/jaro_winkler/jaro_winkler_ext.so +0 -0
  79. data/vendor/bundle/ruby/3.2.0/gems/psych-4.0.4/ext/psych/Makefile +3 -3
  80. data/vendor/bundle/ruby/3.2.0/gems/psych-4.0.4/lib/psych.so +0 -0
  81. data/vendor/bundle/ruby/3.2.0/gems/stringio-3.0.2/ext/stringio/Makefile +3 -3
  82. data/vendor/bundle/ruby/3.2.0/gems/stringio-3.0.2/lib/stringio.so +0 -0
  83. metadata +185 -153
@@ -0,0 +1,218 @@
1
+ =begin
2
+ #Mux API
3
+
4
+ #Mux is how developers build online video. This API encompasses both Mux Video and Mux Data functionality to help you build your video-related projects better and faster than ever before.
5
+
6
+ The version of the OpenAPI document: v1
7
+ Contact: devex@mux.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.1
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module MuxRuby
17
+ class DRMConfigurationResponse
18
+ attr_accessor :data
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'data' => :'data'
24
+ }
25
+ end
26
+
27
+ # Returns all the JSON keys this model knows about
28
+ def self.acceptable_attributes
29
+ attribute_map.values
30
+ end
31
+
32
+ # Attribute type mapping.
33
+ def self.openapi_types
34
+ {
35
+ :'data' => :'DRMConfiguration'
36
+ }
37
+ end
38
+
39
+ # List of attributes with nullable: true
40
+ def self.openapi_nullable
41
+ Set.new([
42
+ ])
43
+ end
44
+
45
+ # Initializes the object
46
+ # @param [Hash] attributes Model attributes in the form of hash
47
+ def initialize(attributes = {})
48
+ if (!attributes.is_a?(Hash))
49
+ fail ArgumentError, "The input argument (attributes) must be a hash in `MuxRuby::DRMConfigurationResponse` initialize method"
50
+ end
51
+
52
+ # check to see if the attribute exists and convert string to symbol for hash key
53
+ attributes = attributes.each_with_object({}) { |(k, v), h|
54
+ if (!self.class.attribute_map.key?(k.to_sym))
55
+ fail ArgumentError, "`#{k}` is not a valid attribute in `MuxRuby::DRMConfigurationResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ end
57
+ h[k.to_sym] = v
58
+ }
59
+
60
+ if attributes.key?(:'data')
61
+ self.data = attributes[:'data']
62
+ end
63
+ end
64
+
65
+ # Show invalid properties with the reasons. Usually used together with valid?
66
+ # @return Array for valid properties with the reasons
67
+ def list_invalid_properties
68
+ invalid_properties = Array.new
69
+ invalid_properties
70
+ end
71
+
72
+ # Check to see if the all the properties in the model are valid
73
+ # @return true if the model is valid
74
+ def valid?
75
+ true
76
+ end
77
+
78
+ # Checks equality by comparing each attribute.
79
+ # @param [Object] Object to be compared
80
+ def ==(o)
81
+ return true if self.equal?(o)
82
+ self.class == o.class &&
83
+ data == o.data
84
+ end
85
+
86
+ # @see the `==` method
87
+ # @param [Object] Object to be compared
88
+ def eql?(o)
89
+ self == o
90
+ end
91
+
92
+ # Calculates hash code according to all attributes.
93
+ # @return [Integer] Hash code
94
+ def hash
95
+ [data].hash
96
+ end
97
+
98
+ # Builds the object from hash
99
+ # @param [Hash] attributes Model attributes in the form of hash
100
+ # @return [Object] Returns the model itself
101
+ def self.build_from_hash(attributes)
102
+ new.build_from_hash(attributes)
103
+ end
104
+
105
+ # Builds the object from hash
106
+ # @param [Hash] attributes Model attributes in the form of hash
107
+ # @return [Object] Returns the model itself
108
+ def build_from_hash(attributes)
109
+ return nil unless attributes.is_a?(Hash)
110
+ self.class.openapi_types.each_pair do |key, type|
111
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
112
+ self.send("#{key}=", nil)
113
+ elsif type =~ /\AArray<(.*)>/i
114
+ # check to ensure the input is an array given that the attribute
115
+ # is documented as an array but the input is not
116
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
117
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
118
+ end
119
+ elsif !attributes[self.class.attribute_map[key]].nil?
120
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
121
+ end
122
+ end
123
+
124
+ self
125
+ end
126
+
127
+ # Deserializes the data based on type
128
+ # @param string type Data type
129
+ # @param string value Value to be deserialized
130
+ # @return [Object] Deserialized data
131
+ def _deserialize(type, value)
132
+ case type.to_sym
133
+ when :Time
134
+ Time.parse(value)
135
+ when :Date
136
+ Date.parse(value)
137
+ when :String
138
+ value.to_s
139
+ when :Integer
140
+ value.to_i
141
+ when :Float
142
+ value.to_f
143
+ when :Boolean
144
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
145
+ true
146
+ else
147
+ false
148
+ end
149
+ when :Object
150
+ # generic object (usually a Hash), return directly
151
+ value
152
+ when /\AArray<(?<inner_type>.+)>\z/
153
+ inner_type = Regexp.last_match[:inner_type]
154
+ value.map { |v| _deserialize(inner_type, v) }
155
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
156
+ k_type = Regexp.last_match[:k_type]
157
+ v_type = Regexp.last_match[:v_type]
158
+ {}.tap do |hash|
159
+ value.each do |k, v|
160
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
161
+ end
162
+ end
163
+ else # model
164
+ # models (e.g. Pet) or oneOf
165
+ klass = MuxRuby.const_get(type)
166
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
167
+ end
168
+ end
169
+
170
+ # Returns the string representation of the object
171
+ # @return [String] String presentation of the object
172
+ def to_s
173
+ to_hash.to_s
174
+ end
175
+
176
+ # to_body is an alias to to_hash (backward compatibility)
177
+ # @return [Hash] Returns the object in the form of hash
178
+ def to_body
179
+ to_hash
180
+ end
181
+
182
+ # Returns the object in the form of hash
183
+ # @return [Hash] Returns the object in the form of hash
184
+ def to_hash
185
+ hash = {}
186
+ self.class.attribute_map.each_pair do |attr, param|
187
+ value = self.send(attr)
188
+ if value.nil?
189
+ is_nullable = self.class.openapi_nullable.include?(attr)
190
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
191
+ end
192
+
193
+ hash[param] = _to_hash(value)
194
+ end
195
+ hash
196
+ end
197
+
198
+ # Outputs non-array value in the form of hash
199
+ # For object, use to_hash. Otherwise, just return the value
200
+ # @param [Object] value Any valid value
201
+ # @return [Hash] Returns the value in the form of hash
202
+ def _to_hash(value)
203
+ if value.is_a?(Array)
204
+ value.compact.map { |v| _to_hash(v) }
205
+ elsif value.is_a?(Hash)
206
+ {}.tap do |hash|
207
+ value.each { |k, v| hash[k] = _to_hash(v) }
208
+ end
209
+ elsif value.respond_to? :to_hash
210
+ value.to_hash
211
+ else
212
+ value
213
+ end
214
+ end
215
+
216
+ end
217
+
218
+ end
@@ -32,7 +32,7 @@ module MuxRuby
32
32
  # Attribute type mapping.
33
33
  def self.openapi_types
34
34
  {
35
- :'data' => :'Track'
35
+ :'data' => :'Array<Track>'
36
36
  }
37
37
  end
38
38
 
@@ -58,7 +58,9 @@ module MuxRuby
58
58
  }
59
59
 
60
60
  if attributes.key?(:'data')
61
- self.data = attributes[:'data']
61
+ if (value = attributes[:'data']).is_a?(Array)
62
+ self.data = value
63
+ end
62
64
  end
63
65
  end
64
66
 
@@ -0,0 +1,220 @@
1
+ =begin
2
+ #Mux API
3
+
4
+ #Mux is how developers build online video. This API encompasses both Mux Video and Mux Data functionality to help you build your video-related projects better and faster than ever before.
5
+
6
+ The version of the OpenAPI document: v1
7
+ Contact: devex@mux.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.1
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module MuxRuby
17
+ class ListDRMConfigurationsResponse
18
+ attr_accessor :data
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'data' => :'data'
24
+ }
25
+ end
26
+
27
+ # Returns all the JSON keys this model knows about
28
+ def self.acceptable_attributes
29
+ attribute_map.values
30
+ end
31
+
32
+ # Attribute type mapping.
33
+ def self.openapi_types
34
+ {
35
+ :'data' => :'Array<DRMConfiguration>'
36
+ }
37
+ end
38
+
39
+ # List of attributes with nullable: true
40
+ def self.openapi_nullable
41
+ Set.new([
42
+ ])
43
+ end
44
+
45
+ # Initializes the object
46
+ # @param [Hash] attributes Model attributes in the form of hash
47
+ def initialize(attributes = {})
48
+ if (!attributes.is_a?(Hash))
49
+ fail ArgumentError, "The input argument (attributes) must be a hash in `MuxRuby::ListDRMConfigurationsResponse` initialize method"
50
+ end
51
+
52
+ # check to see if the attribute exists and convert string to symbol for hash key
53
+ attributes = attributes.each_with_object({}) { |(k, v), h|
54
+ if (!self.class.attribute_map.key?(k.to_sym))
55
+ fail ArgumentError, "`#{k}` is not a valid attribute in `MuxRuby::ListDRMConfigurationsResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ end
57
+ h[k.to_sym] = v
58
+ }
59
+
60
+ if attributes.key?(:'data')
61
+ if (value = attributes[:'data']).is_a?(Array)
62
+ self.data = value
63
+ end
64
+ end
65
+ end
66
+
67
+ # Show invalid properties with the reasons. Usually used together with valid?
68
+ # @return Array for valid properties with the reasons
69
+ def list_invalid_properties
70
+ invalid_properties = Array.new
71
+ invalid_properties
72
+ end
73
+
74
+ # Check to see if the all the properties in the model are valid
75
+ # @return true if the model is valid
76
+ def valid?
77
+ true
78
+ end
79
+
80
+ # Checks equality by comparing each attribute.
81
+ # @param [Object] Object to be compared
82
+ def ==(o)
83
+ return true if self.equal?(o)
84
+ self.class == o.class &&
85
+ data == o.data
86
+ end
87
+
88
+ # @see the `==` method
89
+ # @param [Object] Object to be compared
90
+ def eql?(o)
91
+ self == o
92
+ end
93
+
94
+ # Calculates hash code according to all attributes.
95
+ # @return [Integer] Hash code
96
+ def hash
97
+ [data].hash
98
+ end
99
+
100
+ # Builds the object from hash
101
+ # @param [Hash] attributes Model attributes in the form of hash
102
+ # @return [Object] Returns the model itself
103
+ def self.build_from_hash(attributes)
104
+ new.build_from_hash(attributes)
105
+ end
106
+
107
+ # Builds the object from hash
108
+ # @param [Hash] attributes Model attributes in the form of hash
109
+ # @return [Object] Returns the model itself
110
+ def build_from_hash(attributes)
111
+ return nil unless attributes.is_a?(Hash)
112
+ self.class.openapi_types.each_pair do |key, type|
113
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
114
+ self.send("#{key}=", nil)
115
+ elsif type =~ /\AArray<(.*)>/i
116
+ # check to ensure the input is an array given that the attribute
117
+ # is documented as an array but the input is not
118
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
119
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
120
+ end
121
+ elsif !attributes[self.class.attribute_map[key]].nil?
122
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
123
+ end
124
+ end
125
+
126
+ self
127
+ end
128
+
129
+ # Deserializes the data based on type
130
+ # @param string type Data type
131
+ # @param string value Value to be deserialized
132
+ # @return [Object] Deserialized data
133
+ def _deserialize(type, value)
134
+ case type.to_sym
135
+ when :Time
136
+ Time.parse(value)
137
+ when :Date
138
+ Date.parse(value)
139
+ when :String
140
+ value.to_s
141
+ when :Integer
142
+ value.to_i
143
+ when :Float
144
+ value.to_f
145
+ when :Boolean
146
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
147
+ true
148
+ else
149
+ false
150
+ end
151
+ when :Object
152
+ # generic object (usually a Hash), return directly
153
+ value
154
+ when /\AArray<(?<inner_type>.+)>\z/
155
+ inner_type = Regexp.last_match[:inner_type]
156
+ value.map { |v| _deserialize(inner_type, v) }
157
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
158
+ k_type = Regexp.last_match[:k_type]
159
+ v_type = Regexp.last_match[:v_type]
160
+ {}.tap do |hash|
161
+ value.each do |k, v|
162
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
163
+ end
164
+ end
165
+ else # model
166
+ # models (e.g. Pet) or oneOf
167
+ klass = MuxRuby.const_get(type)
168
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
169
+ end
170
+ end
171
+
172
+ # Returns the string representation of the object
173
+ # @return [String] String presentation of the object
174
+ def to_s
175
+ to_hash.to_s
176
+ end
177
+
178
+ # to_body is an alias to to_hash (backward compatibility)
179
+ # @return [Hash] Returns the object in the form of hash
180
+ def to_body
181
+ to_hash
182
+ end
183
+
184
+ # Returns the object in the form of hash
185
+ # @return [Hash] Returns the object in the form of hash
186
+ def to_hash
187
+ hash = {}
188
+ self.class.attribute_map.each_pair do |attr, param|
189
+ value = self.send(attr)
190
+ if value.nil?
191
+ is_nullable = self.class.openapi_nullable.include?(attr)
192
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
193
+ end
194
+
195
+ hash[param] = _to_hash(value)
196
+ end
197
+ hash
198
+ end
199
+
200
+ # Outputs non-array value in the form of hash
201
+ # For object, use to_hash. Otherwise, just return the value
202
+ # @param [Object] value Any valid value
203
+ # @return [Hash] Returns the value in the form of hash
204
+ def _to_hash(value)
205
+ if value.is_a?(Array)
206
+ value.compact.map { |v| _to_hash(v) }
207
+ elsif value.is_a?(Hash)
208
+ {}.tap do |hash|
209
+ value.each { |k, v| hash[k] = _to_hash(v) }
210
+ end
211
+ elsif value.respond_to? :to_hash
212
+ value.to_hash
213
+ else
214
+ value
215
+ end
216
+ end
217
+
218
+ end
219
+
220
+ end
@@ -20,11 +20,15 @@ module MuxRuby
20
20
 
21
21
  attr_accessor :policy
22
22
 
23
+ # The DRM configuration used by this playback ID. Must only be set when `policy` is set to `drm`.
24
+ attr_accessor :drm_configuration_id
25
+
23
26
  # Attribute mapping from ruby-style variable name to JSON key.
24
27
  def self.attribute_map
25
28
  {
26
29
  :'id' => :'id',
27
- :'policy' => :'policy'
30
+ :'policy' => :'policy',
31
+ :'drm_configuration_id' => :'drm_configuration_id'
28
32
  }
29
33
  end
30
34
 
@@ -37,7 +41,8 @@ module MuxRuby
37
41
  def self.openapi_types
38
42
  {
39
43
  :'id' => :'String',
40
- :'policy' => :'PlaybackPolicy'
44
+ :'policy' => :'PlaybackPolicy',
45
+ :'drm_configuration_id' => :'String'
41
46
  }
42
47
  end
43
48
 
@@ -69,6 +74,10 @@ module MuxRuby
69
74
  if attributes.key?(:'policy')
70
75
  self.policy = attributes[:'policy']
71
76
  end
77
+
78
+ if attributes.key?(:'drm_configuration_id')
79
+ self.drm_configuration_id = attributes[:'drm_configuration_id']
80
+ end
72
81
  end
73
82
 
74
83
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -90,7 +99,8 @@ module MuxRuby
90
99
  return true if self.equal?(o)
91
100
  self.class == o.class &&
92
101
  id == o.id &&
93
- policy == o.policy
102
+ policy == o.policy &&
103
+ drm_configuration_id == o.drm_configuration_id
94
104
  end
95
105
 
96
106
  # @see the `==` method
@@ -102,7 +112,7 @@ module MuxRuby
102
112
  # Calculates hash code according to all attributes.
103
113
  # @return [Integer] Hash code
104
114
  def hash
105
- [id, policy].hash
115
+ [id, policy, drm_configuration_id].hash
106
116
  end
107
117
 
108
118
  # Builds the object from hash
@@ -17,6 +17,7 @@ module MuxRuby
17
17
  class PlaybackPolicy
18
18
  PUBLIC = "public".freeze
19
19
  SIGNED = "signed".freeze
20
+ DRM = "drm".freeze
20
21
 
21
22
  # Builds the enum from string
22
23
  # @param [String] The enum value in the form of the string
@@ -26,13 +26,16 @@ module MuxRuby
26
26
 
27
27
  attr_accessor :referrer
28
28
 
29
+ attr_accessor :user_agent
30
+
29
31
  # Attribute mapping from ruby-style variable name to JSON key.
30
32
  def self.attribute_map
31
33
  {
32
34
  :'id' => :'id',
33
35
  :'created_at' => :'created_at',
34
36
  :'updated_at' => :'updated_at',
35
- :'referrer' => :'referrer'
37
+ :'referrer' => :'referrer',
38
+ :'user_agent' => :'user_agent'
36
39
  }
37
40
  end
38
41
 
@@ -47,7 +50,8 @@ module MuxRuby
47
50
  :'id' => :'String',
48
51
  :'created_at' => :'String',
49
52
  :'updated_at' => :'String',
50
- :'referrer' => :'ReferrerDomainRestriction'
53
+ :'referrer' => :'ReferrerDomainRestriction',
54
+ :'user_agent' => :'UserAgentRestrictionSettings'
51
55
  }
52
56
  end
53
57
 
@@ -87,6 +91,10 @@ module MuxRuby
87
91
  if attributes.key?(:'referrer')
88
92
  self.referrer = attributes[:'referrer']
89
93
  end
94
+
95
+ if attributes.key?(:'user_agent')
96
+ self.user_agent = attributes[:'user_agent']
97
+ end
90
98
  end
91
99
 
92
100
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -110,7 +118,8 @@ module MuxRuby
110
118
  id == o.id &&
111
119
  created_at == o.created_at &&
112
120
  updated_at == o.updated_at &&
113
- referrer == o.referrer
121
+ referrer == o.referrer &&
122
+ user_agent == o.user_agent
114
123
  end
115
124
 
116
125
  # @see the `==` method
@@ -122,7 +131,7 @@ module MuxRuby
122
131
  # Calculates hash code according to all attributes.
123
132
  # @return [Integer] Hash code
124
133
  def hash
125
- [id, created_at, updated_at, referrer].hash
134
+ [id, created_at, updated_at, referrer, user_agent].hash
126
135
  end
127
136
 
128
137
  # Builds the object from hash