rdclass. Return < 0 if self < other in the DNSSEC ordering,
0 if self == other, and > 0 if self > other.
"""
-
raise NotImplementedError
def __eq__(self, other):
return NotImplemented
if self.rdclass != other.rdclass or \
self.rdtype != other.rdtype:
- return dns.util.cmp((self.rdclass, self.rdtype), (other.rdclass, other.rdtype))
+ return (self.rdclass, self.rdtype) < (other.rdclass, other.rdtype)
return self._cmp(other) < 0
def __le__(self, other):
return NotImplemented
if self.rdclass != other.rdclass or \
self.rdtype != other.rdtype:
- return dns.util.cmp((self.rdclass, self.rdtype), (other.rdclass, other.rdtype))
+ return (self.rdclass, self.rdtype) <= (other.rdclass, other.rdtype)
return self._cmp(other) <= 0
def __ge__(self, other):
return NotImplemented
if self.rdclass != other.rdclass or \
self.rdtype != other.rdtype:
- return dns.util.cmp((self.rdclass, self.rdtype), (other.rdclass, other.rdtype))
+ return (self.rdclass, self.rdtype) >= (other.rdclass, other.rdtype)
return self._cmp(other) >= 0
def __gt__(self, other):
return NotImplemented
if self.rdclass != other.rdclass or \
self.rdtype != other.rdtype:
- return dns.util.cmp((self.rdclass, self.rdtype), (other.rdclass, other.rdtype))
+ return (self.rdclass, self.rdtype) > (other.rdclass, other.rdtype)
return self._cmp(other) > 0
def __hash__(self):