##// END OF EJS Templates
abstractsmartset: default implementation for `ascending` and `descending`...
Pierre-Yves David -
r22713:f5f51872 default
parent child Browse files
Show More
@@ -2226,7 +2226,7 b' class abstractsmartset(object):'
2226 """Sorts the set in ascending order (in place).
2226 """Sorts the set in ascending order (in place).
2227
2227
2228 This is part of the mandatory API for smartset."""
2228 This is part of the mandatory API for smartset."""
2229 raise NotImplementedError()
2229 self.sort()
2230
2230
2231 def isdescending(self):
2231 def isdescending(self):
2232 """True if the set will iterate in descending order"""
2232 """True if the set will iterate in descending order"""
@@ -2236,7 +2236,7 b' class abstractsmartset(object):'
2236 """Sorts the set in descending order (in place).
2236 """Sorts the set in descending order (in place).
2237
2237
2238 This is part of the mandatory API for smartset."""
2238 This is part of the mandatory API for smartset."""
2239 raise NotImplementedError()
2239 self.sort(reverse=True)
2240
2240
2241 def min(self):
2241 def min(self):
2242 """return the minimum element in the set"""
2242 """return the minimum element in the set"""
General Comments 0
You need to be logged in to leave comments. Login now