Class: Twitter::MediaFactory

Inherits:
Factory
  • Object
show all
Defined in:
lib/twitter/media_factory.rb

Class Method Summary collapse

Class Method Details

.fetch_or_new(attrs = {}) ⇒ Twitter::Media

Instantiates a new media object

Parameters:

  • attrs (Hash) (defaults to: {})

Returns:

Raises:

  • (ArgumentError)

    Error raised when supplied argument is missing a :type key.



12
13
14
# File 'lib/twitter/media_factory.rb', line 12

def self.fetch_or_new(attrs={})
  super(:type, Twitter::Media, attrs)
end