lib/scrivito/attribute_collection.rb in scrivito_sdk-0.50.1 vs lib/scrivito/attribute_collection.rb in scrivito_sdk-0.60.0.rc1

- old
+ new

@@ -4,10 +4,11 @@ # exactly as an Array, so methods like `#each`, `#select` etc. are available. It is not necessary # to manually create an {Scrivito::AttributeCollection}, because a simple Array with attributes # can be used instead. # # @api public + # @deprecated class AttributeCollection include Enumerable extend Forwardable # Initializes an attribute collection for an obj class. @@ -20,16 +21,18 @@ @attributes = attributes end # Yields successive attributes of the collection. Implements the {Enumerable} interface. # @api public + # @deprecated def_delegators :@attributes, :each # # Finds an attribute in this collection by its name. # # @api public + # @deprecated # # @param [String] name the name of the attribute # @return [Scrivito::Attribute] if there is an attribute with name +name+ # @return [nil] if there is no attribute with name +name+ # @@ -40,9 +43,10 @@ end # Adds an attribute to this collection and updates the obj class. # # @api public + # @deprecated # # See {Scrivito::ObjClass#attributes} for example of how to add an attribute. # # @param [Scrivito::Attribute, Hash] attribute The attribute to add. Can be either an attribute # instance or an attribute property hash.