Esempio n. 1
0
        public unsafe ConfigurableResource(int p0, string p1, global::Com.Liveperson.Infra.Configuration.ConfigurableResource.ResourceType p2)
            : base(IntPtr.Zero, JniHandleOwnership.DoNotTransfer)
        {
            if (((global::Java.Lang.Object) this).Handle != IntPtr.Zero)
            {
                return;
            }

            IntPtr native_p1 = JNIEnv.NewString(p1);

            try {
                JValue *__args = stackalloc JValue [3];
                __args [0] = new JValue(p0);
                __args [1] = new JValue(native_p1);
                __args [2] = new JValue(p2);
                if (((object)this).GetType() != typeof(ConfigurableResource))
                {
                    SetHandle(
                        global::Android.Runtime.JNIEnv.StartCreateInstance(((object)this).GetType(), "(ILjava/lang/String;Lcom/liveperson/infra/configuration/ConfigurableResource$ResourceType;)V", __args),
                        JniHandleOwnership.TransferLocalRef);
                    global::Android.Runtime.JNIEnv.FinishCreateInstance(((global::Java.Lang.Object) this).Handle, "(ILjava/lang/String;Lcom/liveperson/infra/configuration/ConfigurableResource$ResourceType;)V", __args);
                    return;
                }

                if (id_ctor_ILjava_lang_String_Lcom_liveperson_infra_configuration_ConfigurableResource_ResourceType_ == IntPtr.Zero)
                {
                    id_ctor_ILjava_lang_String_Lcom_liveperson_infra_configuration_ConfigurableResource_ResourceType_ = JNIEnv.GetMethodID(class_ref, "<init>", "(ILjava/lang/String;Lcom/liveperson/infra/configuration/ConfigurableResource$ResourceType;)V");
                }
                SetHandle(
                    global::Android.Runtime.JNIEnv.StartCreateInstance(class_ref, id_ctor_ILjava_lang_String_Lcom_liveperson_infra_configuration_ConfigurableResource_ResourceType_, __args),
                    JniHandleOwnership.TransferLocalRef);
                JNIEnv.FinishCreateInstance(((global::Java.Lang.Object) this).Handle, class_ref, id_ctor_ILjava_lang_String_Lcom_liveperson_infra_configuration_ConfigurableResource_ResourceType_, __args);
            } finally {
                JNIEnv.DeleteLocalRef(native_p1);
            }
        }
Esempio n. 2
0
            public static unsafe global::Com.Liveperson.Infra.Configuration.ConfigurableResource.ResourceType 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/infra/configuration/ConfigurableResource$ResourceType;");
                }
                IntPtr native_p0 = JNIEnv.NewString(p0);

                try {
                    JValue *__args = stackalloc JValue [1];
                    __args [0] = new JValue(native_p0);
                    global::Com.Liveperson.Infra.Configuration.ConfigurableResource.ResourceType __ret = global::Java.Lang.Object.GetObject <global::Com.Liveperson.Infra.Configuration.ConfigurableResource.ResourceType> (JNIEnv.CallStaticObjectMethod(class_ref, id_valueOf_Ljava_lang_String_, __args), JniHandleOwnership.TransferLocalRef);
                    return(__ret);
                } finally {
                    JNIEnv.DeleteLocalRef(native_p0);
                }
            }