Class: Thredded::EmailTransformer::Base

Inherits:
Object
  • Object
show all
Includes:
Helpers
Defined in:
lib/thredded/email_transformer/base.rb

Direct Known Subclasses

Onebox, Spoiler

Defined Under Namespace

Modules: ClassMethods

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Helpers

#anchor, #paragraph

Constructor Details

#initialize(doc) ⇒ Base

Returns a new instance of Base.

Parameters:

  • doc (Nokogiri::HTML::Document)

31
32
33
# File 'lib/thredded/email_transformer/base.rb', line 31

def initialize(doc)
  @doc = doc
end

Instance Attribute Details

#docNokogiri::HTML::Document (readonly)

Returns:

  • (Nokogiri::HTML::Document)

28
29
30
# File 'lib/thredded/email_transformer/base.rb', line 28

def doc
  @doc
end

Class Method Details

.inherited(base) ⇒ Object


35
36
37
# File 'lib/thredded/email_transformer/base.rb', line 35

def self.inherited(base)
  base.extend ClassMethods
end