lib/lotus/validations.rb in lotus-validations-0.2.0 vs lib/lotus/validations.rb in lotus-validations-0.2.1
- old
+ new
@@ -30,11 +30,11 @@
# Lotus::Validations and it is included in a class or module, this passes
# the attributes from the module to the base.
#
# @param base [Class] the target action
#
- # @since x.x.x
+ # @since 0.1.0
# @api private
#
# @see http://www.ruby-doc.org/core/Module.html#method-i-included
#
# @example
@@ -382,28 +382,28 @@
#
# @param blk [Proc] a block
# @yieldparam attribute [Symbol] the name of the attribute
# @yieldparam value [Object,nil] the value of the attribute
#
- # @since x.x.x
+ # @since 0.2.0
def each(&blk)
to_h.each(&blk)
end
# Returns a Hash with the defined attributes as symbolized keys, and their
# relative values.
#
# @return [Hash]
#
- # @since x.x.x
+ # @since 0.1.0
def to_h
@attributes.dup
end
private
# The set of user defined attributes.
#
- # @since x.x.x
+ # @since 0.1.0
# @api private
#
# @see Lotus::Validations::ClassMethods#attributes
def defined_attributes
self.class.__send__(:attributes)