MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / strictly_right_of

Method strictly_right_of

lib/sqlalchemy/dialects/postgresql/ranges.py:383–396  ·  view source on GitHub ↗

Determine whether this range is completely to the right of `other`.

(self, other: Range[_T])

Source from the content-addressed store, hash-verified

381 __lshift__ = strictly_left_of
382
383 def strictly_right_of(self, other: Range[_T]) -> bool:
384 "Determine whether this range is completely to the right of `other`."
385
386 # Empty ranges are neither to left nor to the right of any other range
387 if self.empty or other.empty:
388 return False
389
390 slower = self.lower
391 slower_b = self.bounds[0]
392 oupper = other.upper
393 oupper_b = other.bounds[1]
394
395 # Check whether this lower edge is greater than other's upper end
396 return self._compare_edges(slower, slower_b, oupper, oupper_b) > 0
397
398 __rshift__ = strictly_right_of
399

Callers 3

Calls 1

_compare_edgesMethod · 0.95

Tested by 2