public virtual unsafe void Put(string p0, global::Com.Algorithmia.Client.HttpContentType p1) { if (id_put_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_ == IntPtr.Zero) { id_put_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_ = JNIEnv.GetMethodID(class_ref, "put", "(Ljava/lang/String;Lcom/algorithmia/client/HttpContentType;)V"); } IntPtr native_p0 = JNIEnv.NewString(p0); try { JValue *__args = stackalloc JValue [2]; __args [0] = new JValue(native_p0); __args [1] = new JValue(p1); if (GetType() == ThresholdType) { JNIEnv.CallVoidMethod(((global::Java.Lang.Object) this).Handle, id_put_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_, __args); } else { JNIEnv.CallNonvirtualVoidMethod(((global::Java.Lang.Object) this).Handle, ThresholdClass, JNIEnv.GetMethodID(ThresholdClass, "put", "(Ljava/lang/String;Lcom/algorithmia/client/HttpContentType;)V"), __args); } } finally { JNIEnv.DeleteLocalRef(native_p0); } }
public unsafe StringEntity(string p0, global::Com.Algorithmia.Client.HttpContentType p1) : base(IntPtr.Zero, JniHandleOwnership.DoNotTransfer) { if (((global::Java.Lang.Object) this).Handle != IntPtr.Zero) { return; } IntPtr native_p0 = JNIEnv.NewString(p0); try { JValue *__args = stackalloc JValue [2]; __args [0] = new JValue(native_p0); __args [1] = new JValue(p1); if (GetType() != typeof(StringEntity)) { SetHandle( global::Android.Runtime.JNIEnv.StartCreateInstance(GetType(), "(Ljava/lang/String;Lcom/algorithmia/client/HttpContentType;)V", __args), JniHandleOwnership.TransferLocalRef); global::Android.Runtime.JNIEnv.FinishCreateInstance(((global::Java.Lang.Object) this).Handle, "(Ljava/lang/String;Lcom/algorithmia/client/HttpContentType;)V", __args); return; } if (id_ctor_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_ == IntPtr.Zero) { id_ctor_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_ = JNIEnv.GetMethodID(class_ref, "<init>", "(Ljava/lang/String;Lcom/algorithmia/client/HttpContentType;)V"); } SetHandle( global::Android.Runtime.JNIEnv.StartCreateInstance(class_ref, id_ctor_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_, __args), JniHandleOwnership.TransferLocalRef); JNIEnv.FinishCreateInstance(((global::Java.Lang.Object) this).Handle, class_ref, id_ctor_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_, __args); } finally { JNIEnv.DeleteLocalRef(native_p0); } }
static void n_Put_Ljava_lang_String_Lcom_algorithmia_client_HttpContentType_(IntPtr jnienv, IntPtr native__this, IntPtr native_p0, IntPtr native_p1) { global::Com.Algorithmia.Data.DataFile __this = global::Java.Lang.Object.GetObject <global::Com.Algorithmia.Data.DataFile> (jnienv, native__this, JniHandleOwnership.DoNotTransfer); string p0 = JNIEnv.GetString(native_p0, JniHandleOwnership.DoNotTransfer); global::Com.Algorithmia.Client.HttpContentType p1 = global::Java.Lang.Object.GetObject <global::Com.Algorithmia.Client.HttpContentType> (native_p1, JniHandleOwnership.DoNotTransfer); __this.Put(p0, p1); }