// WARNING: Please don't edit this file. It was generated by Python/WinRT v2.0.0-beta.2

#include "py.Windows.Phone.PersonalInformation.Provisioning.h"


namespace py::cpp::Windows::Phone::PersonalInformation::Provisioning
{
    // ----- ContactPartnerProvisioningManager class --------------------

    static PyObject* _new_ContactPartnerProvisioningManager(PyTypeObject* /*unused*/, PyObject* /*unused*/, PyObject* /*unused*/) noexcept
    {
        static_assert(py::py_type<winrt::Windows::Phone::PersonalInformation::Provisioning::ContactPartnerProvisioningManager>::type_name);
        py::set_invalid_activation_error(py::py_type<winrt::Windows::Phone::PersonalInformation::Provisioning::ContactPartnerProvisioningManager>::type_name);
        return nullptr;
    }

    static PyObject* ContactPartnerProvisioningManager_AssociateNetworkAccountAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        auto arg_count = PyTuple_Size(args);

        if (arg_count == 3)
        {
            if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Phone.PersonalInformation.Provisioning.ContactPartnerProvisioningManager", L"AssociateNetworkAccountAsync", 3))
            {
                py::set_arg_count_version_error(3);
                return nullptr;
            }

            try
            {
                auto param0 = py::convert_to<winrt::Windows::Phone::PersonalInformation::ContactStore>(args, 0);
                auto param1 = py::convert_to<winrt::hstring>(args, 1);
                auto param2 = py::convert_to<winrt::hstring>(args, 2);

                return py::convert(winrt::Windows::Phone::PersonalInformation::Provisioning::ContactPartnerProvisioningManager::AssociateNetworkAccountAsync(param0, param1, param2));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* ContactPartnerProvisioningManager_AssociateSocialNetworkAccountAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        auto arg_count = PyTuple_Size(args);

        if (arg_count == 3)
        {
            if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Phone.PersonalInformation.Provisioning.ContactPartnerProvisioningManager", L"AssociateSocialNetworkAccountAsync", 3))
            {
                py::set_arg_count_version_error(3);
                return nullptr;
            }

            try
            {
                auto param0 = py::convert_to<winrt::Windows::Phone::PersonalInformation::ContactStore>(args, 0);
                auto param1 = py::convert_to<winrt::hstring>(args, 1);
                auto param2 = py::convert_to<winrt::hstring>(args, 2);

                return py::convert(winrt::Windows::Phone::PersonalInformation::Provisioning::ContactPartnerProvisioningManager::AssociateSocialNetworkAccountAsync(param0, param1, param2));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* ContactPartnerProvisioningManager_ImportVcardToSystemAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        auto arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Phone.PersonalInformation.Provisioning.ContactPartnerProvisioningManager", L"ImportVcardToSystemAsync", 1))
            {
                py::set_arg_count_version_error(1);
                return nullptr;
            }

            try
            {
                auto param0 = py::convert_to<winrt::Windows::Storage::Streams::IInputStream>(args, 0);

                return py::convert(winrt::Windows::Phone::PersonalInformation::Provisioning::ContactPartnerProvisioningManager::ImportVcardToSystemAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyMethodDef _methods_ContactPartnerProvisioningManager[] = {
        { }
    };

    static PyGetSetDef _getset_ContactPartnerProvisioningManager[] = {
        { }
    };

    static PyType_Slot _type_slots_ContactPartnerProvisioningManager[] = 
    {
        { Py_tp_new, reinterpret_cast<void*>(_new_ContactPartnerProvisioningManager) },
        { Py_tp_methods, reinterpret_cast<void*>(_methods_ContactPartnerProvisioningManager) },
        { Py_tp_getset, reinterpret_cast<void*>(_getset_ContactPartnerProvisioningManager) },
        { },
    };

    static PyType_Spec type_spec_ContactPartnerProvisioningManager =
    {
        "winrt._winrt_windows_phone_personalinformation_provisioning.ContactPartnerProvisioningManager",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_ContactPartnerProvisioningManager
    };

    static PyGetSetDef getset_ContactPartnerProvisioningManager_Static[] = {
        { }
    };

    static PyMethodDef methods_ContactPartnerProvisioningManager_Static[] = {
        { "associate_network_account_async", reinterpret_cast<PyCFunction>(ContactPartnerProvisioningManager_AssociateNetworkAccountAsync), METH_VARARGS, nullptr },
        { "associate_social_network_account_async", reinterpret_cast<PyCFunction>(ContactPartnerProvisioningManager_AssociateSocialNetworkAccountAsync), METH_VARARGS, nullptr },
        { "import_vcard_to_system_async", reinterpret_cast<PyCFunction>(ContactPartnerProvisioningManager_ImportVcardToSystemAsync), METH_VARARGS, nullptr },
        { }
    };

    static PyType_Slot type_slots_ContactPartnerProvisioningManager_Static[] = 
    {
        { Py_tp_base, reinterpret_cast<void*>(&PyType_Type) },
        { Py_tp_getset, reinterpret_cast<void*>(getset_ContactPartnerProvisioningManager_Static) },
        { Py_tp_methods, reinterpret_cast<void*>(methods_ContactPartnerProvisioningManager_Static) },
        { }
    };

    static PyType_Spec type_spec_ContactPartnerProvisioningManager_Static =
    {
        "winrt._winrt_windows_phone_personalinformation_provisioning.ContactPartnerProvisioningManager_Static",
        static_cast<int>(PyType_Type.tp_basicsize),
        static_cast<int>(PyType_Type.tp_itemsize),
        Py_TPFLAGS_DEFAULT,
        type_slots_ContactPartnerProvisioningManager_Static
    };

    // ----- MessagePartnerProvisioningManager class --------------------

    static PyObject* _new_MessagePartnerProvisioningManager(PyTypeObject* /*unused*/, PyObject* /*unused*/, PyObject* /*unused*/) noexcept
    {
        static_assert(py::py_type<winrt::Windows::Phone::PersonalInformation::Provisioning::MessagePartnerProvisioningManager>::type_name);
        py::set_invalid_activation_error(py::py_type<winrt::Windows::Phone::PersonalInformation::Provisioning::MessagePartnerProvisioningManager>::type_name);
        return nullptr;
    }

    static PyObject* MessagePartnerProvisioningManager_ImportMmsToSystemAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        auto arg_count = PyTuple_Size(args);

        if (arg_count == 7)
        {
            if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Phone.PersonalInformation.Provisioning.MessagePartnerProvisioningManager", L"ImportMmsToSystemAsync", 7))
            {
                py::set_arg_count_version_error(7);
                return nullptr;
            }

            try
            {
                auto param0 = py::convert_to<bool>(args, 0);
                auto param1 = py::convert_to<bool>(args, 1);
                auto param2 = py::convert_to<winrt::hstring>(args, 2);
                auto param3 = py::convert_to<winrt::hstring>(args, 3);
                auto param4 = py::convert_to<winrt::Windows::Foundation::Collections::IVectorView<winrt::hstring>>(args, 4);
                auto param5 = py::convert_to<winrt::Windows::Foundation::DateTime>(args, 5);
                auto param6 = py::convert_to<winrt::Windows::Foundation::Collections::IVectorView<winrt::Windows::Foundation::Collections::IMapView<winrt::hstring, winrt::Windows::Foundation::IInspectable>>>(args, 6);

                return py::convert(winrt::Windows::Phone::PersonalInformation::Provisioning::MessagePartnerProvisioningManager::ImportMmsToSystemAsync(param0, param1, param2, param3, param4, param5, param6));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* MessagePartnerProvisioningManager_ImportSmsToSystemAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        auto arg_count = PyTuple_Size(args);

        if (arg_count == 6)
        {
            if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Phone.PersonalInformation.Provisioning.MessagePartnerProvisioningManager", L"ImportSmsToSystemAsync", 6))
            {
                py::set_arg_count_version_error(6);
                return nullptr;
            }

            try
            {
                auto param0 = py::convert_to<bool>(args, 0);
                auto param1 = py::convert_to<bool>(args, 1);
                auto param2 = py::convert_to<winrt::hstring>(args, 2);
                auto param3 = py::convert_to<winrt::hstring>(args, 3);
                auto param4 = py::convert_to<winrt::Windows::Foundation::Collections::IVectorView<winrt::hstring>>(args, 4);
                auto param5 = py::convert_to<winrt::Windows::Foundation::DateTime>(args, 5);

                return py::convert(winrt::Windows::Phone::PersonalInformation::Provisioning::MessagePartnerProvisioningManager::ImportSmsToSystemAsync(param0, param1, param2, param3, param4, param5));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyMethodDef _methods_MessagePartnerProvisioningManager[] = {
        { }
    };

    static PyGetSetDef _getset_MessagePartnerProvisioningManager[] = {
        { }
    };

    static PyType_Slot _type_slots_MessagePartnerProvisioningManager[] = 
    {
        { Py_tp_new, reinterpret_cast<void*>(_new_MessagePartnerProvisioningManager) },
        { Py_tp_methods, reinterpret_cast<void*>(_methods_MessagePartnerProvisioningManager) },
        { Py_tp_getset, reinterpret_cast<void*>(_getset_MessagePartnerProvisioningManager) },
        { },
    };

    static PyType_Spec type_spec_MessagePartnerProvisioningManager =
    {
        "winrt._winrt_windows_phone_personalinformation_provisioning.MessagePartnerProvisioningManager",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_MessagePartnerProvisioningManager
    };

    static PyGetSetDef getset_MessagePartnerProvisioningManager_Static[] = {
        { }
    };

    static PyMethodDef methods_MessagePartnerProvisioningManager_Static[] = {
        { "import_mms_to_system_async", reinterpret_cast<PyCFunction>(MessagePartnerProvisioningManager_ImportMmsToSystemAsync), METH_VARARGS, nullptr },
        { "import_sms_to_system_async", reinterpret_cast<PyCFunction>(MessagePartnerProvisioningManager_ImportSmsToSystemAsync), METH_VARARGS, nullptr },
        { }
    };

    static PyType_Slot type_slots_MessagePartnerProvisioningManager_Static[] = 
    {
        { Py_tp_base, reinterpret_cast<void*>(&PyType_Type) },
        { Py_tp_getset, reinterpret_cast<void*>(getset_MessagePartnerProvisioningManager_Static) },
        { Py_tp_methods, reinterpret_cast<void*>(methods_MessagePartnerProvisioningManager_Static) },
        { }
    };

    static PyType_Spec type_spec_MessagePartnerProvisioningManager_Static =
    {
        "winrt._winrt_windows_phone_personalinformation_provisioning.MessagePartnerProvisioningManager_Static",
        static_cast<int>(PyType_Type.tp_basicsize),
        static_cast<int>(PyType_Type.tp_itemsize),
        Py_TPFLAGS_DEFAULT,
        type_slots_MessagePartnerProvisioningManager_Static
    };

    // ----- Windows.Phone.PersonalInformation.Provisioning Initialization --------------------
    PyDoc_STRVAR(module_doc, "Windows::Phone::PersonalInformation::Provisioning");


    static PyModuleDef module_def
        = {PyModuleDef_HEAD_INIT,
           "_winrt_windows_phone_personalinformation_provisioning",
           module_doc,
           0,
           nullptr,
           nullptr,
           nullptr,
           nullptr,
           nullptr};

} // py::cpp::Windows::Phone::PersonalInformation::Provisioning

PyMODINIT_FUNC PyInit__winrt_windows_phone_personalinformation_provisioning(void) noexcept
{
    using namespace py::cpp::Windows::Phone::PersonalInformation::Provisioning;

    if (py::import_winrt_runtime() == -1)
    {
        return nullptr;
    }

    py::pyobj_handle module{PyModule_Create(&module_def)};

    if (!module)
    {
        return nullptr;
    }

    auto object_type = py::get_object_type();
    if (!object_type)
    {
        return nullptr;
    }

    py::pyobj_handle object_bases{PyTuple_Pack(1, object_type)};

    if (!object_bases)
    {
        return nullptr;
    }

    py::pyobj_handle type_ContactPartnerProvisioningManager_Static{PyType_FromSpec(&type_spec_ContactPartnerProvisioningManager_Static)};
    if (!type_ContactPartnerProvisioningManager_Static)
    {
        return nullptr;
    }

    if (py::register_python_type(module.get(), &type_spec_ContactPartnerProvisioningManager, object_bases.get(), reinterpret_cast<PyTypeObject*>(type_ContactPartnerProvisioningManager_Static.get())) == -1)
    {
        return nullptr;
    }

    py::pyobj_handle type_MessagePartnerProvisioningManager_Static{PyType_FromSpec(&type_spec_MessagePartnerProvisioningManager_Static)};
    if (!type_MessagePartnerProvisioningManager_Static)
    {
        return nullptr;
    }

    if (py::register_python_type(module.get(), &type_spec_MessagePartnerProvisioningManager, object_bases.get(), reinterpret_cast<PyTypeObject*>(type_MessagePartnerProvisioningManager_Static.get())) == -1)
    {
        return nullptr;
    }


    return module.detach();
}
