Class: Stratify::GitHub::Presenter
- Inherits:
-
Object
- Object
- Stratify::GitHub::Presenter
- Includes:
- ActionView::Helpers::UrlHelper
- Defined in:
- lib/stratify-github/presenter.rb
Instance Method Summary collapse
-
#initialize(activity) ⇒ Presenter
constructor
A new instance of Presenter.
- #text ⇒ Object
- #to_html ⇒ Object
Constructor Details
#initialize(activity) ⇒ Presenter
Returns a new instance of Presenter.
9 10 11 |
# File 'lib/stratify-github/presenter.rb', line 9 def initialize(activity) @activity = activity end |
Instance Method Details
#text ⇒ Object
13 14 15 16 |
# File 'lib/stratify-github/presenter.rb', line 13 def text clazz = Stratify::GitHub::Event.const_get(@activity.event_type) return clazz.text(@activity) end |
#to_html ⇒ Object
18 19 20 |
# File 'lib/stratify-github/presenter.rb', line 18 def to_html linkify_urls(text) end |