问题
I'm creating a Compact Framework 3.5 application, which is the client side of an older Java webapp. The communication protocol between both sides is REST+JSON.
Serialization of the POJOs to JSON is not a matter since the POJOs already exist. But instead of rewriting from scratch a C# version of all the POJOs sources to be able to deserialize the JSON client-side, I would prefer a generation using some tools. Or at least, do the conversion manually with a "standardized" method.
Do you know some tools that would match these needs ? Or some manual method ?
Thanks by advance
Fabien
回答1:
I think it really depends on what you have
- If you have a WADL than there are probably tools that can generate classes from it.
- If you have XSD's of the request and response objects you can also generate C# classes from it.
- You can try using tools that convert java to C#
来源:https://stackoverflow.com/questions/11241666/conversion-from-pojo-to-poco