swiftlang / swift-java

Apache License 2.0
724 stars 27 forks source link

JavaKit: Cache field/method IDs in JavaObjectHolder #113

Open DougGregor opened 3 weeks ago

DougGregor commented 3 weeks ago

Right now, uses of JNI constructs always look up the field/method IDs. We should cache those lookups somewhere in the JavaObjectHolder instance so they need only be performed once for the lifetime of the Swift wrapper.