Class: Perron::Resource::Separator

Inherits:
Object
  • Object
show all
Defined in:
lib/perron/resource/separator.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(content) ⇒ Separator

Returns a new instance of Separator.



8
9
10
# File 'lib/perron/resource/separator.rb', line 8

def initialize(content)
  parsed(content)
end

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content.



6
7
8
# File 'lib/perron/resource/separator.rb', line 6

def content
  @content
end

Instance Method Details

#frontmatterObject



12
13
14
15
16
# File 'lib/perron/resource/separator.rb', line 12

def frontmatter
  @frontmatter_with_dot_access ||= ActiveSupport::OrderedOptions.new.tap do |options|
    @frontmatter.each { |key, value| options[key] = value }
  end
end