Sha256: ffc27b009a9bf22342d72821cea72848eb7210023d83e8d83e3cf6ec73d2354b

Contents?: true

Size: 348 Bytes

Versions: 4

Compression:

Stored size: 348 Bytes

Contents

# encoding: UTF-8

class Spontaneous::Site
  module Level
    extend Spontaneous::Concern

    module ClassMethods
      def at_depth(level)
        case level
        when 0, :root
          Spontaneous::Site.root
        when 1, :section
          Spontaneous::Site.root.at_depth(1)
        end
      end
    end # ClassMethods
  end # Level
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
spontaneous-0.2.0.beta4 lib/spontaneous/site/level.rb
spontaneous-0.2.0.beta3 lib/spontaneous/site/level.rb
spontaneous-0.2.0.beta2 lib/spontaneous/site/level.rb
spontaneous-0.2.0.beta1 lib/spontaneous/site/level.rb