func _getGoField(fieldObj *rtc.Obj) *rtc.Field { extra := fieldObj.Extra() if extra != nil { return extra.(*rtc.Field) } root := fieldObj.GetFieldValue("root", "Ljava/lang/reflect/Field;").(*rtc.Obj) return root.Extra().(*rtc.Field) }
func _getGoMethod(methodObj *rtc.Obj, isConstructor bool) *rtc.Method { extra := methodObj.Extra() if extra != nil { return extra.(*rtc.Method) } if isConstructor { root := methodObj.GetFieldValue("root", "Ljava/lang/reflect/Constructor;").(*rtc.Obj) return root.Extra().(*rtc.Method) } else { root := methodObj.GetFieldValue("root", "Ljava/lang/reflect/Method;").(*rtc.Obj) return root.Extra().(*rtc.Method) } }
func Unbox(obj *rtc.Obj, primitiveDescriptor string) interface{} { return obj.GetFieldValue("value", primitiveDescriptor) }
// java.lang.String -> go string func GoString(jStr *rtc.Obj) string { charArr := jStr.GetFieldValue("value", "[C").(*rtc.Obj) return _utf16ToString(charArr.Chars()) }
func _getPath(fileObj *rtc.Obj) string { pathStr := fileObj.GetFieldValue("path", "Ljava/lang/String;").(*rtc.Obj) return rtda.GoString(pathStr) }