コード例 #1
0
        public static unsafe global::Com.Liveperson.Api.Response.Types.ConversationState ValueOf(string p0)
        {
            if (id_valueOf_Ljava_lang_String_ == IntPtr.Zero)
            {
                id_valueOf_Ljava_lang_String_ = JNIEnv.GetStaticMethodID(class_ref, "valueOf", "(Ljava/lang/String;)Lcom/liveperson/api/response/types/ConversationState;");
            }
            IntPtr native_p0 = JNIEnv.NewString(p0);

            try {
                JValue *__args = stackalloc JValue [1];
                __args [0] = new JValue(native_p0);
                global::Com.Liveperson.Api.Response.Types.ConversationState __ret = global::Java.Lang.Object.GetObject <global::Com.Liveperson.Api.Response.Types.ConversationState> (JNIEnv.CallStaticObjectMethod(class_ref, id_valueOf_Ljava_lang_String_, __args), JniHandleOwnership.TransferLocalRef);
                return(__ret);
            } finally {
                JNIEnv.DeleteLocalRef(native_p0);
            }
        }
        public unsafe ConversationData(global::Com.Liveperson.Api.Response.Types.ConversationState p0, global::Com.Liveperson.Api.Response.Model.Result p1, string p2)
            : base(IntPtr.Zero, JniHandleOwnership.DoNotTransfer)
        {
            if (((global::Java.Lang.Object) this).Handle != IntPtr.Zero)
            {
                return;
            }

            IntPtr native_p2 = JNIEnv.NewString(p2);

            try {
                JValue *__args = stackalloc JValue [3];
                __args [0] = new JValue(p0);
                __args [1] = new JValue(p1);
                __args [2] = new JValue(native_p2);
                if (((object)this).GetType() != typeof(ConversationData))
                {
                    SetHandle(
                        global::Android.Runtime.JNIEnv.StartCreateInstance(((object)this).GetType(), "(Lcom/liveperson/api/response/types/ConversationState;Lcom/liveperson/api/response/model/Result;Ljava/lang/String;)V", __args),
                        JniHandleOwnership.TransferLocalRef);
                    global::Android.Runtime.JNIEnv.FinishCreateInstance(((global::Java.Lang.Object) this).Handle, "(Lcom/liveperson/api/response/types/ConversationState;Lcom/liveperson/api/response/model/Result;Ljava/lang/String;)V", __args);
                    return;
                }

                if (id_ctor_Lcom_liveperson_api_response_types_ConversationState_Lcom_liveperson_api_response_model_Result_Ljava_lang_String_ == IntPtr.Zero)
                {
                    id_ctor_Lcom_liveperson_api_response_types_ConversationState_Lcom_liveperson_api_response_model_Result_Ljava_lang_String_ = JNIEnv.GetMethodID(class_ref, "<init>", "(Lcom/liveperson/api/response/types/ConversationState;Lcom/liveperson/api/response/model/Result;Ljava/lang/String;)V");
                }
                SetHandle(
                    global::Android.Runtime.JNIEnv.StartCreateInstance(class_ref, id_ctor_Lcom_liveperson_api_response_types_ConversationState_Lcom_liveperson_api_response_model_Result_Ljava_lang_String_, __args),
                    JniHandleOwnership.TransferLocalRef);
                JNIEnv.FinishCreateInstance(((global::Java.Lang.Object) this).Handle, class_ref, id_ctor_Lcom_liveperson_api_response_types_ConversationState_Lcom_liveperson_api_response_model_Result_Ljava_lang_String_, __args);
            } finally {
                JNIEnv.DeleteLocalRef(native_p2);
            }
        }