class MiHash

Attributes

c[RW]
r[RW]

Public Class Methods

new(r,c) click to toggle source
# File lib/matrc/mihash.rb, line 5
def initialize(r,c)
  @r, @c = r, c
end

Public Instance Methods

==(other) click to toggle source
# File lib/matrc/mihash.rb, line 17
def ==(other)
 self.class === other and
   other.c == @c and
   other.r == @r
end
eql?(other) click to toggle source
# File lib/matrc/mihash.rb, line 9
def eql?(other)
  (@r == other.r) && (@c == other.c)
end
hash() click to toggle source
# File lib/matrc/mihash.rb, line 13
def hash 
  @r.hash ^ @c.hash
end