Changeset 4692a16
- Timestamp:
- Nov 30, 2010 4:49:07 PM (14 years ago)
- Branches:
- axis_example, compt_changes, info-ops, master
- Children:
- dee164e
- Parents:
- 1f6a573
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
fedd/federation/emulab_access.py
r1f6a573 r4692a16 337 337 checked. If cmp is None, the choices are sorted by priority. 338 338 """ 339 # NB: comparison order reversed so numerically larger priorities are340 # checked first.341 def prio_cmp(a, b):342 return cmp(b.priority, a.priority)343 344 339 345 340 # Import request credentials into this (clone later??) … … 348 343 self.auth.save() 349 344 350 c = compare or prio_cmp 345 # NB: in the default case (the else), the comparison order is reversed 346 # so numerically larger priorities are checked first. 347 if compare: c = compare 348 else: c = lambda(a, b): cmp(b,a) 349 351 350 if filter: f = filter 352 351 else: f = lambda(x): True
Note: See TracChangeset
for help on using the changeset viewer.