阅读背景:

在命名空间版本化时,将xml序列化为适当的对象的最佳方法是什么?

来源:互联网 

My question is the following.

我的问题如下。

I have xml that is versioned by a namespace. I want to serialize this received xml into the appropriate object, but the only way I know to do this means I have to process the xml two times. First to discover the namespace, and then in order to serialize to the object of the proper type based on the discovered namespace. This seems dreadfully inefficient to me, and there must be some way using generics or something to get the appropriate type of object back without an 'if namespace == x then serialze to that' check.I hav




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: