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

Codable XML Support #9

Open
chrisballinger opened this issue Oct 16, 2019 · 3 comments
Open

Codable XML Support #9

chrisballinger opened this issue Oct 16, 2019 · 3 comments

Comments

@chrisballinger
Copy link

Howdy! Glad to see someone is working on a Swift NIO XMPP implementation.

Instead of writing your own XML parser and generator from scratch, it might be nice to leverage Codable with a helper library. There is already a Linux-compatible XML Codable library called XMLCoder that might be a great fit for this project, or possibly an inspiration for your own Codable support.

Cheers!

@mremond
Copy link
Member

mremond commented Oct 16, 2019

Thanks @chrisballinger I will have a look :)

@mremond
Copy link
Member

mremond commented Jun 9, 2020

Hi @chrisballinger

I am back working on this project. If I am not mistaken, Codable would be nice to be able to serialize the content. However, for parsing, in the context of an infinite stream, Codable is not easy to put in place and even a bit hackish, I think, for decoding.

Am I missing something ?

@chrisballinger
Copy link
Author

Yeah that's a good point, you'd need to break the stream up manually and pass each full stanza to your Codable decoder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants