Registry / utility / equatable

equatable

JSON →
library0.7.0rbrubygemsunverified

Provides equality comparison methods for objects based on their attributes by generating implementations for the ==, eql?, hash and inspect methods.

gem install equatable
INSTALL
IMPORT
SIG · EQUATABLE
E
equatable
utilityrubyv0.7.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Equatable
require 'equatable'

Include Equatable in a class to get attribute-based equality.

require 'equatable' class Point include Equatable attr_reader :x, :y def initialize(x, y) @x = x @y = y end end p1 = Point.new(1, 2) p2 = Point.new(1, 2) p1 == p2 # => true
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.7.0latest on RubyGems
Audit
Dependencies

No dependency data recorded yet.

Agent activity
2 hits · last 30 days
node
2
Resources
equatable — gem install equatable · libregistry