()
| 945 | } |
| 946 | |
| 947 | pub(crate) unsafe fn get_factory_create_for_static_method() -> errors::Result<jmethodID> { |
| 948 | get_cached!( |
| 949 | FACTORY_CREATE_FOR_STATIC_METHOD, |
| 950 | { |
| 951 | let env = get_thread_local_env()?; |
| 952 | let create_for_static_method_signature = |
| 953 | format!("(Ljava/lang/String;)L{};", INVO_IFACE_NAME); |
| 954 | |
| 955 | let cstr1 = utils::to_c_string("createForStatic"); |
| 956 | let cstr2 = utils::to_c_string(&create_for_static_method_signature); |
| 957 | let j = unsafe { |
| 958 | (opt_to_res(get_jni_get_static_method_id())?)( |
| 959 | env, |
| 960 | get_factory_class()?, |
| 961 | cstr1, |
| 962 | cstr2, |
| 963 | ) |
| 964 | }; |
| 965 | utils::drop_c_string(cstr1); |
| 966 | utils::drop_c_string(cstr2); |
| 967 | |
| 968 | j |
| 969 | }, |
| 970 | set_factory_create_for_static_method |
| 971 | ) |
| 972 | } |
| 973 | |
| 974 | pub(crate) fn set_factory_create_java_array_method(j: jmethodID) { |
| 975 | debug("Called set_factory_create_java_array_method"); |
no outgoing calls
no test coverage detected