Method: FatCore::Range#superset_of?

Defined in:
lib/fat_core/range.rb

#superset_of?(other) ⇒ Boolean

Return whether self contains other range, even if their boundaries touch.

Parameters:

  • other (Range)

    the contained range

Returns:

  • (Boolean)

    does self contain other

[View source]

292
293
294
# File 'lib/fat_core/range.rb', line 292

def superset_of?(other)
  min <= other.min && max >= other.max
end