Parent

Methods

Included Modules

Files

Jekyll::Layout

Attributes

content[RW]

Gets/Sets the content of this layout.

data[RW]

Gets/Sets the Hash that holds the metadata for this layout.

ext[RW]

Gets/Sets the extension of this layout.

name[R]

Gets the name of this layout.

site[R]

Gets the Site object.

Public Class Methods

new(site, base, name) click to toggle source

Initialize a new Layout.

site - The Site. base - The String path to the source. name - The String filename of the post file.

# File lib/jekyll/layout.rb, line 25
def initialize(site, base, name)
  @site = site
  @base = base
  @name = name

  self.data = {}

  self.process(name)
  self.read_yaml(base, name)
end

Public Instance Methods

process(name) click to toggle source

Extract information from the layout filename.

name - The String filename of the layout file.

Returns nothing.

# File lib/jekyll/layout.rb, line 41
def process(name)
  self.ext = File.extname(name)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.