X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=sfa%2Ftrust%2Frights.py;h=1b8baa4f4ec556bcf5bac26408edd2a1ff0a649f;hb=aae6c396c5161b2ba3debe2af8609f344dbb2c6e;hp=eb0bb74720b4b48bbc0c95d21f43c4a92857e634;hpb=b9ae62cc0463f168771bf3d4ebf348bb920acb4f;p=sfa.git diff --git a/sfa/trust/rights.py b/sfa/trust/rights.py index eb0bb747..1b8baa4f 100644 --- a/sfa/trust/rights.py +++ b/sfa/trust/rights.py @@ -94,6 +94,8 @@ class Right: self.kind = kind self.delegate = delegate + def __repr__ (self): return ""%self.kind + ## # Test to see if this right object is allowed to perform an operation. # Returns True if the operation is allowed, False otherwise. @@ -148,6 +150,8 @@ class Rights: if string: self.load_from_string(string) + def __repr__ (self): return "[" + " ".join( ["%s"%r for r in self.rights]) + "]" + def is_empty(self): return self.rights == []