TechTalk Genome v4.2

<StaticProxy> Element

Specifies manually implemented (as opposed to code-generated) proxy classes for the type.

<Type name=" type ">
<StaticProxy type=" proxy-type " pinnedType=" pinned-proxy-type " />
A class specifying a non-abstract persistent type.
A type specifying the class to be used for context-unbound proxies.
A type specifying the class to be used for context-bound proxies.


With the <StaticProxy> element , custom proxy types implemented by the developer can be used as context-bound or unbound proxies. The proxy-type and the pinned-proxy-type have to implement the IObjectProxy interface of Genome .

Proxy classes have two responsibilities:
The proxy has to identify the referred object and it has to provide the comparison operation for two objects by implementing the Object.Equals method. This is done by storing and comparing the identity provided by the object identity provider of the type family.
The proxy also has to establish the connection between the caller of the members of the type and Context where the state of the object is stored. This second task of managing state access varies between pinned and context-unbound proxies.
For context-unbound proxies, the current context of the thread must always be chosen.
For proxies bound to a specific context (called pinned proxies), the context the proxy is pinned to has to be used.
To establish a connection, proxies have to implement persistent properties to access state in the correct context.


Type: TechTalk.Genome.Mapping.StaticProxyXmlData

Assembly: TechTalk.Genome.dll

Version: 4.2.11

Editions: Professional, Evaluation, Express

Database Platforms: Microsoft SQL Server 2000, Microsoft SQL Server 2005, Oracle 9i Release 2, Oracle 10g Release 2

See Also

Proxy Providers | <CodeGeneratedProxy> Element | Context.Pin<S> | Context.Unpin<S>