X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=sfa%2Ftrust%2Frights.py;h=1b8baa4f4ec556bcf5bac26408edd2a1ff0a649f;hb=f2282434e40e06365e0fdd3f9bc273a793f41235;hp=eb0bb74720b4b48bbc0c95d21f43c4a92857e634;hpb=b7d6a80faf23cb019c74e65c2264e215446f84a3;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 == []