Sha256: e791202aecd0c8c9cec44652175d386c3b32bbe873bdb2e168797e8c60da7de4
Contents?: true
Size: 536 Bytes
Versions: 1
Compression:
Stored size: 536 Bytes
Contents
module Ninsho # Responsible for handling ninsho mappings and routes configuration # The required value in ninsho_on is actually not used internally, but it's # inflected to find all other values. # class RoutesDrawer #:nodoc: attr_reader :singular_name, :klass, :resource def initialize(name) @resource = name.to_s @singular_name = name.to_s.singularize @klass = Ninsho.ref(@singular_name.classify) end # Gives the class the mapping points to. def to @klass.get end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ninsho-0.0.1 | lib/ninsho/routes_drawer.rb |