root/lib/Proxy.py @ 1888
1 |
# Proxy object
|
---|---|
2 |
|
3 |
class Proxy: |
4 |
'''A proxy that forwards all accesses to an inner object'''
|
5 |
|
6 |
def __init__(self, inner): self.inner = inner |
7 |
|
8 |
def __getattr__(self, attr): return self.inner.__getattr__(attr) |
9 |
|
10 |
def __setattr__(self, attr, value): |
11 |
return self.inner.__setattr__(attr, value) |