Skip to content
instance method

Hash#>=

[A, B] (::Hash[A, B]) -> bool
self >= other_hash → true or false

Returns true if the entries of self are a superset of the entries of other_hash, false otherwise:

Example
h0 = {foo: 0, bar: 1, baz: 2}
h1 = {foo: 0, bar: 1}
h0 >= h1 # => true
h0 >= h0 # => true
h1 >= h0 # => false

See Hash Inclusion.

Raises TypeError if other_hash is not a hash and cannot be converted to a hash.

Related: see Methods for Comparing.

See also #> #[] #== #[]= also in 4.1 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0