MCPcopy Create free account
hub / github.com/HelloBush/Java_MHXYdemo / extractWrapper

Function extractWrapper

lib/jacob-1.20_src/jacob-1.20/jni/SafeArray.cpp:60–72  ·  view source on GitHub ↗

* extracts the Variant from the int pointer in the java object */

Source from the content-addressed store, hash-verified

58 * extracts the Variant from the int pointer in the java object
59 */
60VARIANT *extractWrapper(JNIEnv *env, jobject arg)
61{
62 jclass argClass = env->GetObjectClass(arg);
63 jfieldID vf = env->GetFieldID( argClass, V_FLD, "J");
64 jlong vnum = env->GetLongField(arg, vf);
65 if (vnum != NULL)
66 {
67 // if vnum is not NULL, then there is a Variant wrapper present
68 VARIANT *v = (VARIANT *)vnum;
69 return v;
70 }
71 return NULL;
72}
73
74// extract a SAFEARRAY from a SafeArray object
75SAFEARRAY *extractSA(JNIEnv *env, jobject arg)

Callers 2

extractSAFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected