mirror of
https://github.com/qmlnet/qmlnet.git
synced 2026-05-15 14:15:54 -06:00
[GH-ISSUE #39] Use Reflection.Emit for object invocation. #19
Labels
No labels
bug
enhancement
help wanted
help wanted
pull-request
question
todo
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/qmlnet#19
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @pauldotknopf on GitHub (Jul 25, 2018).
Original GitHub issue: https://github.com/qmlnet/qmlnet/issues/39
This will give us a huge performance boost.
Using what we've learned in #36, we should not send callbacks to the native world.
Instead, every
NetMethodInfoandNetPropertyInfowill have a unitlong Id. This id will be used to lookup cached dynamic methods that perform as little as possible.For example:
The same thing can be done with property reading/setting.
@RichiCoder1 commented on GitHub (Aug 10, 2018):
Just in case you're interested:
With Refit, it allows you to define an interface and add attributes to it, and then Refit generates the meat of the code (either using a standalone app or an msbuild task).
Refit does this by scanning the source files using Roslyn, and then generating output files (again using roslyn/template files).
https://github.com/reactiveui/refit/blob/master/InterfaceStubGenerator.Core/InterfaceStubGenerator.cs
@pauldotknopf commented on GitHub (Aug 10, 2018):
Oh, wow! I was wondering how they supported Xamarin where it does AOT compilation. Turns out, they aren't using Reflection.Emit!
I haven't thought about an approach like this. I'm not sure how it would look in Qml.Net.
@RichiCoder1 commented on GitHub (Aug 10, 2018):
Absolutely. Figured I'd at least mention it just in case it's applicable :). And would work with AOT restrictions on mobile platforms if/when you got there.