Class: SeemsRateable::Builder

Inherits:
Object
  • Object
show all
Includes:
ActionView::Helpers::TagHelper
Defined in:
lib/seems_rateable/builder.rb,
lib/seems_rateable/builder/html_options.rb

Defined Under Namespace

Classes: HtmlOptions

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(rateable, options) ⇒ Builder

Returns a new instance of Builder.



13
14
15
# File 'lib/seems_rateable/builder.rb', line 13

def initialize(rateable, options)
  @rateable, @options = rateable, options
end

Instance Attribute Details

#optionsObject (readonly)

Returns the value of attribute options.



7
8
9
# File 'lib/seems_rateable/builder.rb', line 7

def options
  @options
end

#rateableObject (readonly)

Returns the value of attribute rateable.



7
8
9
# File 'lib/seems_rateable/builder.rb', line 7

def rateable
  @rateable
end

Class Method Details

.build(rateable, options) ⇒ Object



9
10
11
# File 'lib/seems_rateable/builder.rb', line 9

def self.build(rateable, options)
  new(rateable, options).build
end

Instance Method Details

#buildObject



17
18
19
# File 'lib/seems_rateable/builder.rb', line 17

def build
   :div, nil, html_options
end