Class: Dropdown::Blog
- Inherits:
-
Object
- Object
- Dropdown::Blog
- Defined in:
- lib/dropdown/blog.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#posts ⇒ Object
readonly
Returns the value of attribute posts.
-
#reader ⇒ Object
readonly
Returns the value of attribute reader.
-
#source ⇒ Object
Returns the value of attribute source.
Instance Method Summary collapse
-
#initialize(source = nil, reader = Dropdown::Readers::FileReader.new) ⇒ Blog
constructor
A new instance of Blog.
Constructor Details
#initialize(source = nil, reader = Dropdown::Readers::FileReader.new) ⇒ Blog
Returns a new instance of Blog.
6 7 8 9 10 11 |
# File 'lib/dropdown/blog.rb', line 6 def initialize(source=nil, reader=Dropdown::Readers::FileReader.new) @source = source @reader = reader @posts = [] collect end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
3 4 5 |
# File 'lib/dropdown/blog.rb', line 3 def name @name end |
#posts ⇒ Object (readonly)
Returns the value of attribute posts.
4 5 6 |
# File 'lib/dropdown/blog.rb', line 4 def posts @posts end |
#reader ⇒ Object (readonly)
Returns the value of attribute reader.
4 5 6 |
# File 'lib/dropdown/blog.rb', line 4 def reader @reader end |
#source ⇒ Object
Returns the value of attribute source.
3 4 5 |
# File 'lib/dropdown/blog.rb', line 3 def source @source end |