Commit d940181
committed
Make
Optionally do not look for the `JniAddNativeMethodRegistrationAttribute`.
It turns out that this attribute is not commonly present in
Xamarin.Android applications and so all of the calls to
`GetCustomAttribute` failed to find it, incurring unnecessary
performance penalty on the application.
Make the code consult a global flag (in case of Xamarin.Android it is
set on the build time) which tells it whether or not to skip querying
for the above custom attribute. The flag is `true` by default to
maintain backward compatibility.GetCustomAttribute calls optional in JniTypeManager1 parent 4f47ec8 commit d940181
File tree
2 files changed
+13
-0
lines changed- src/Java.Interop/Java.Interop
2 files changed
+13
-0
lines changedLines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
333 | 333 | | |
334 | 334 | | |
335 | 335 | | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
336 | 339 | | |
337 | 340 | | |
338 | 341 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
0 commit comments