Object
Initializes a new TrendResults object
@param attrs [Hash] @return [Twitter::TrendResults]
# File lib/twitter/trend_results.rb, line 22 def initialize(attrs = {}) @attrs = attrs @collection = @attrs.fetch(:trends, []).collect do |trend| Trend.new(trend) end end
Time when the object was created on Twitter
@return [Time]
# File lib/twitter/trend_results.rb, line 32 def as_of Time.parse(@attrs[:as_of]) unless @attrs[:as_of].nil? end
# File lib/twitter/trend_results.rb, line 37 def as_of? !!@attrs[:as_of] end
@return [Twitter::Place, NullObject]
# File lib/twitter/trend_results.rb, line 43 def location location? ? Place.new(@attrs[:locations].first) : NullObject.new end
Generated with the Darkfish Rdoc Generator 2.