proxygen
OnLoad.cpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2018-present, Facebook, Inc.
3  * All rights reserved.
4  *
5  * This source code is licensed under the BSD-style license found in the
6  * LICENSE file in the root directory of this source tree.
7  */
8 
11 
12 using namespace fizz;
13 
14 JNIEXPORT jint JNI_OnLoad(JavaVM* vm, void* /*reserved*/) {
15  JNIEnv* env;
16  if (vm->GetEnv(reinterpret_cast<void**>(&env), JNI_VERSION_1_6) != JNI_OK) {
17  return -1;
18  }
19 
20  jni::setVM(vm);
22 
23  return JNI_VERSION_1_6;
24 }
JNIEXPORT jint JNI_OnLoad(JavaVM *vm, void *)
Definition: OnLoad.cpp:14
void setVM(JavaVM *jvm)
Definition: JniUtils.cpp:19
Definition: Actions.h:16
static void onLoad(JNIEnv *env)