lib/virtus/value_object.rb
# Define and include a module that provides Value Object semantics
#
# Included module will have #inspect, #eql?, #== and #hash
# methods whose definition is based on the _keys_ argument
#
# @example
#   virtus_class.equalizer
#
# @return [Equalizer]
#   An Equalizer module which defines #inspect, #eql?, #== and #hash
#   for instances of this class
#
# @api public
Define and include a module that provides Value Object semantics
Included module will have #inspect, #eql?, #== and #hash
methods whose definition is based on the _keys_ argument
Define and include a module that provides Value Object semantics Included module will have #inspect #eql? # == and #hash methods whose definition is based on the _keys_ argument
def equalizer
        @equalizer ||=
          begin
            equalizer = Equalizer.new(name || inspect)
            include equalizer
            equalizer
          end
      end
def equalizer @equalizer ||= begin equalizer = Equalizer . new ( name || inspect ) include equalizer equalizer end end
Define and include a module that provides Value Object semantics
Included module will have #inspect, #eql?, #== and #hash
methods whose definition is based on the _keys_ argument
Define and include a module that provides Value Object semantics Included module will have #inspect #eql? # == and #hash methods whose definition is based on the _keys_ argument
An Equalizer module which defines #inspect, #eql?, #== and #hash for instances of this class
An Equalizer module which defines #inspect #eql? # == and #hash for instances of this class
Equalizer
example
None
api
None