Class: NPR::Item
Overview
Topics accessed via the API are packaged as items with the following attributes:
-
id
- the topic ID -
number
- item number -
type
- what kind of content the topic represents, i.e. biography, a column, etc. -
slug
- short item descriptor -
additional_info
- extra info/summary about the target -
title
- the name of the topic
Instance Attribute Summary collapse
-
#additional_info ⇒ Object
(also: #info)
Returns the value of attribute additional_info.
-
#id ⇒ Object
Returns the value of attribute id.
-
#number ⇒ Object
Returns the value of attribute number.
-
#slug ⇒ Object
Returns the value of attribute slug.
-
#title ⇒ Object
Returns the value of attribute title.
-
#type ⇒ Object
Returns the value of attribute type.
Method Summary
Methods inherited from Content
Constructor Details
This class inherits a constructor from NPR::Content
Instance Attribute Details
#additional_info ⇒ Object Also known as: info
Returns the value of attribute additional_info.
12 13 14 |
# File 'lib/rubynpr/item.rb', line 12 def additional_info @additional_info end |
#id ⇒ Object
Returns the value of attribute id.
12 13 14 |
# File 'lib/rubynpr/item.rb', line 12 def id @id end |
#number ⇒ Object
Returns the value of attribute number.
12 13 14 |
# File 'lib/rubynpr/item.rb', line 12 def number @number end |
#slug ⇒ Object
Returns the value of attribute slug.
12 13 14 |
# File 'lib/rubynpr/item.rb', line 12 def slug @slug end |
#title ⇒ Object
Returns the value of attribute title.
12 13 14 |
# File 'lib/rubynpr/item.rb', line 12 def title @title end |
#type ⇒ Object
Returns the value of attribute type.
12 13 14 |
# File 'lib/rubynpr/item.rb', line 12 def type @type end |