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

C# Support #2

Open
frodofine opened this issue Nov 19, 2018 · 2 comments
Open

C# Support #2

frodofine opened this issue Nov 19, 2018 · 2 comments

Comments

@frodofine
Copy link
Contributor

C# support would be a great addition to Chemfiles! I see that Java support has been somewhat added, so C# can build from this!

I think it would be best to add C# classes corresponding to classes: Trajectory, Frame, Atom, Vector3D, Property, Residue, and Topology. It's fairly simple to add C# binds to a CAPI and the member functions of these classes would just map to these functions.

@Luthaf
Copy link
Member

Luthaf commented Nov 19, 2018

Sounds like a good plan!

Bindgen code is not really good code, even taking out the fact that parsing C is complicated and produces a weird AST. So if you need any help implementing this, just ask! I'll need to rewrite this at some point =)

On a side note, while there is java code in bindgen, I never finished the bindings code (https://github.com/chemfiles/chemfiles.java), and the java module in bindgen was not updated since 2016 =/ So depending on the way used to declare C function and to call them in C#, the code generating an other language might be a better inspiration.

@frodofine
Copy link
Contributor Author

C# is generally similar to Java, and calling C is pretty easy in that regard!

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