Module: JSI::FingerprintHash

Included in:
Base, JSON::Node, Schema
Defined in:
lib/jsi/util.rb

Instance Method Summary collapse

Instance Method Details

#==(other) ⇒ Object Also known as: eql?



85
86
87
# File 'lib/jsi/util.rb', line 85

def ==(other)
  object_id == other.object_id || (other.respond_to?(:fingerprint) && other.fingerprint == self.fingerprint)
end

#hashObject



91
92
93
# File 'lib/jsi/util.rb', line 91

def hash
  fingerprint.hash
end