MCPcopy Create free account
hub / github.com/antvis/F2Native / SetChartGeomShapes

Function SetChartGeomShapes

core/android/F2NativeJNI.cpp:354–367  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

352}
353
354static jint SetChartGeomShapes(JNIEnv *env, jclass clazz, jlong geom, jstring type, jstring field, jobjectArray shapes) {
355 xg::geom::AbstractGeom *_geom = reinterpret_cast<xg::geom::AbstractGeom *>(geom);
356 std::string _field = JavaStringToString(env, field);
357 jsize len = env->GetArrayLength(shapes);
358 std::vector<std::string> _shapes;
359 for(int index = 0; index < len; ++index) {
360 jstring shape = (jstring)env->GetObjectArrayElement(shapes, index);
361 std::string _shape = JavaStringToString(env, shape);
362 _shapes.push_back(std::move(_shape));
363 }
364
365 _geom->Shape(_field, std::move(_shapes));
366 return 0;
367}
368
369static jint SetChartGeomShape(JNIEnv *env, jclass clazz, jlong geom, jstring type, jstring shape) {
370 xg::geom::AbstractGeom *_geom = reinterpret_cast<xg::geom::AbstractGeom *>(geom);

Callers

nothing calls this directly

Calls 3

JavaStringToStringFunction · 0.85
push_backMethod · 0.80
ShapeMethod · 0.45

Tested by

no test coverage detected