Creates a weak reference of this Instance.
(&self)
| 82 | |
| 83 | /// Creates a weak reference of this Instance. |
| 84 | fn _weak_ref(&self) -> errors::Result<Instance> { |
| 85 | Ok(Instance { |
| 86 | class_name: self.class_name.clone(), |
| 87 | jinstance: jni_utils::_create_weak_global_ref_from_global_ref( |
| 88 | self.jinstance, |
| 89 | cache::get_thread_local_env()?, |
| 90 | )?, |
| 91 | skip_deleting_jobject: false, |
| 92 | }) |
| 93 | } |
| 94 | } |
| 95 | |
| 96 | impl TryFrom<InvocationArg> for Instance { |
nothing calls this directly
no test coverage detected