Class: OpenCongress::OCBlogPost

Inherits:
OpenCongressObject show all
Defined in:
lib/opencongress/blog_post.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from OpenCongressObject

construct_url, hash2get, make_call, parse_supporting_results

Constructor Details

#initialize(params) ⇒ OCBlogPost

Returns a new instance of OCBlogPost.



9
10
11
12
13
# File 'lib/opencongress/blog_post.rb', line 9

def initialize(params)
  params.each do |key, value|
    instance_variable_set("@#{key}", value) if OCBlogPost.instance_methods.include? key
  end      
end

Instance Attribute Details

#average_ratingObject

Returns the value of attribute average_rating.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def average_rating
  @average_rating
end

#dateObject

Returns the value of attribute date.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def date
  @date
end

#excerptObject

Returns the value of attribute excerpt.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def excerpt
  @excerpt
end

#sourceObject

Returns the value of attribute source.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def source
  @source
end

#source_urlObject

Returns the value of attribute source_url.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def source_url
  @source_url
end

#titleObject

Returns the value of attribute title.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def title
  @title
end

#urlObject

Returns the value of attribute url.



6
7
8
# File 'lib/opencongress/blog_post.rb', line 6

def url
  @url
end