Sha256: 155114c0a11a88bb6a3ddd21c38f15385d81005bb8d2811c1aa9e4a08576dc9a

Contents?: true

Size: 326 Bytes

Versions: 1

Compression:

Stored size: 326 Bytes

Contents

module JSONModel
  module Naming
    extend ActiveSupport::Concern
  
    module ClassMethods
      def name
        unless @name
          @name = schema['name']
          this = self
          @name.define_singleton_method(:constantize) do
            this
          end
        end
        @name
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jsonmodel-0.0.1 lib/jsonmodel/naming.rb