this code here is not related to proxies.
in this exclusion policy I am dealing with PHPCR node instances which should not be serialized (also they contain references to connects etc) and also preventing serialization of parent documents.