/* * Copyright 2021 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include #include "include/core/SkPath.h" namespace { static void Path_Release(JNIEnv* env, jobject, jlong native_path) { delete reinterpret_cast(native_path); } } // namespace int register_jetski_Path(JNIEnv* env) { static const JNINativeMethod methods[] = { {"nRelease" , "(J)V" , reinterpret_cast(Path_Release)}, }; const auto clazz = env->FindClass("org/skia/jetski/Path"); return clazz ? env->RegisterNatives(clazz, methods, std::size(methods)) : JNI_ERR; }