Module: MetaTags::Controller::ClassMethods

Defined in:
lib/meta_tags/controller.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#meta_tagsObject

Returns the value of attribute meta_tags.



7
8
9
# File 'lib/meta_tags/controller.rb', line 7

def meta_tags
  @meta_tags
end

#model_nameObject

Returns the value of attribute model_name.



7
8
9
# File 'lib/meta_tags/controller.rb', line 7

def model_name
  @model_name
end

#modifier_blockObject

Returns the value of attribute modifier_block.



7
8
9
# File 'lib/meta_tags/controller.rb', line 7

def modifier_block
  @modifier_block
end

Instance Method Details

#meta_tags_defaults(options) ⇒ Object



9
10
11
# File 'lib/meta_tags/controller.rb', line 9

def meta_tags_defaults(options)
  @meta_tags = Container.new(options)
end

#meta_tags_from(model_name = nil, &block) ⇒ Object



13
14
15
16
# File 'lib/meta_tags/controller.rb', line 13

def meta_tags_from(model_name = nil, &block)
  @model_name = model_name && model_name.to_s
  @modifier_block = block_given? ? block : nil
end