Sha256: d5c88e542b7b16fd2d0f75f3faaaf80c71a0036873d331a6702550cfd87c8733
Contents?: true
Size: 518 Bytes
Versions: 11
Compression:
Stored size: 518 Bytes
Contents
module Scrivito # # This class represents a collection of meta data attributes. # # @api beta # class MetaDataCollection def initialize(attributes) @attributes = ActiveSupport::HashWithIndifferentAccess.new(attributes) end # # Find value of a meta data attribute. # # @api beta # @param name [Symbol, String] the name of the meta data attribute. # @return [String, Array, Fixnum, Date, nil] meta data attribute value if found or +nil+ otherwise. def [](name) @attributes[name] end end end
Version data entries
11 entries across 11 versions & 1 rubygems