Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to create a resolver for StreamJsonRpc and AOT systems #555

Closed
kurtcz opened this issue Aug 16, 2019 · 2 comments
Closed

How to create a resolver for StreamJsonRpc and AOT systems #555

kurtcz opened this issue Aug 16, 2019 · 2 comments
Labels

Comments

@kurtcz
Copy link

kurtcz commented Aug 16, 2019

I would like to ask how I may add support for StreamJsonRpc classes (JsonRequest, JsonResult, ...) for AOT systems such as iOS. The classes are decorated with [DataContract] attribute and on iOS require an AOT generated resolver/formatter.

AFAIK the mpc tool does not support these as of now and the existing typelss / contractless / standard resolvers do not work on iOS (Operation is not supported on this platform). I hope there will be a way other than checking out the repository and editing the classes manually :-)

Thank you for any pointers/suggestions!

@AArnott
Copy link
Collaborator

AArnott commented Aug 24, 2019

mpc supporting [DataContract] attributes is pegged for future work: #554 (comment)

You can serialize any type without modifying it by writing your own formatter for it, as documented in the README: https://github.com/neuecc/MessagePack-CSharp#resolvers

@AArnott
Copy link
Collaborator

AArnott commented Dec 6, 2019

StreamJsonRpc 2.3 includes a built-in MessagePackFormatter now.

@AArnott AArnott closed this as completed Dec 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants