From: <hen...@gm...> - 2004-10-19 20:20:16
|
Hi, I was looking how serialize/deserialize the proxieds objects generated by a#, and the simplest thing that I thought is to implement the ISerializable interface on each generated proxy (or only for the types marked with the [SerializableAttribute] or wich implements the ISerializable interface). They'll point to a ProxySerializationHelper, or something like that, to handles the deserialization(rebuilding the proxy with the expecteds interfaces, mixins, etc), so that way we'll only need to serialize some fields. But looking the fields, I found some issues: - The mixins, generally, has a field 'object proxy', who can't be serialized. How to recover the state of this field after the serialization? I thought in (re)invoke the SetProxy method. - The target object is encapsulated by the InvocationHandler, who contains others fields like AspectDefinition, Matchers, etc. Serialize only the target and reconstruct the the InvocationHandler in deserialization? Or serialize the InvocationHandler(except the AspectEngine field) and all the aspects? - How to recover the correct AspectEngine instance? Thoughts? Others strategies? --=20 Cheers, Henry Concei=E7=E3o |