Class: Twitter::Media::VideoInfo
- Includes:
- Memoizable
- Defined in:
- lib/twitter/media/video_info.rb
Instance Attribute Summary collapse
-
#aspect_ratio ⇒ Array<Integer]
readonly
Array<Integer].
- #duration_millis ⇒ Integer readonly
Attributes inherited from Base
Instance Method Summary collapse
-
#variants ⇒ Array<Twitter::Variant>
Returns an array of video variants.
Methods inherited from Base
#[], attr_reader, define_attribute_method, define_predicate_method, define_uri_method, display_uri_attr_reader, #initialize, object_attr_reader, predicate_attr_reader, uri_attr_reader
Methods included from Utils
Constructor Details
This class inherits a constructor from Twitter::Base
Instance Attribute Details
#aspect_ratio ⇒ Array<Integer] (readonly)
Returns Array<Integer].
10 11 12 |
# File 'lib/twitter/media/video_info.rb', line 10 def aspect_ratio @aspect_ratio end |
#duration_millis ⇒ Integer (readonly)
13 14 15 |
# File 'lib/twitter/media/video_info.rb', line 13 def duration_millis @duration_millis end |
Instance Method Details
#variants ⇒ Array<Twitter::Variant>
Returns an array of video variants
18 19 20 21 22 |
# File 'lib/twitter/media/video_info.rb', line 18 def variants @attrs.fetch(:variants, []).collect do |variant| Variant.new(variant) end end |