Class: Ansa::News
- Inherits:
-
Object
- Object
- Ansa::News
- Defined in:
- lib/ansa/news.rb
Overview
Base class representing a news
Instance Method Summary collapse
-
#date ⇒ Time
The date of the news.
-
#description ⇒ String
The description of the news.
-
#initialize(title, description, date, link) ⇒ News
constructor
A new instance of News.
-
#link ⇒ String
The link of the news.
-
#title ⇒ String
The title of the news.
Constructor Details
#initialize(title, description, date, link) ⇒ News
Returns a new instance of News.
6 7 8 9 10 11 |
# File 'lib/ansa/news.rb', line 6 def initialize(title, description, date, link) @title = title @description = description @date = date @link = link end |
Instance Method Details
#date ⇒ Time
Returns the date of the news.
24 25 26 |
# File 'lib/ansa/news.rb', line 24 def date @date end |
#description ⇒ String
Returns the description of the news.
19 20 21 |
# File 'lib/ansa/news.rb', line 19 def description @description end |
#link ⇒ String
Returns the link of the news.
29 30 31 |
# File 'lib/ansa/news.rb', line 29 def link @link end |
#title ⇒ String
Returns the title of the news.
14 15 16 |
# File 'lib/ansa/news.rb', line 14 def title @title end |