def __new__(cls, source, *p, **n):
        '''
        return the cached proxy or create a one and add it to cache.
        '''
        res = cls._getcached(source)
        if res == None and hasattr(cls, '__proxy_cache__') \
                and cls.__proxy_cache__ != None:
            obj = super(CachedProxy, cls).__new__(cls, source, *p, **n)
            cls._setcache(source, obj)
            return obj
        return super(CachedProxy, cls).__new__(cls, source, *p, **n)

        return the cached proxy or create a one and add it to cache.
        
recipes/Python/305308_mixins_for_proxy_construction/recipe-305308.py