forked from mirrors/linphone-iphone
Change the account creator API so that it is wrapper-friendly.
This commit is contained in:
parent
18141ff1db
commit
60802389ba
19 changed files with 1614 additions and 1638 deletions
|
|
@ -52,7 +52,7 @@ set(LINPHONE_PRIVATE_HEADER_FILES
|
|||
|
||||
set(LINPHONE_SOURCE_FILES_C
|
||||
account_creator.c
|
||||
account_creator_request_engine.c
|
||||
account_creator_service.c
|
||||
address.c
|
||||
authentication.c
|
||||
bellesip_sal/sal_address_impl.c
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ lib_LTLIBRARIES=liblinphone.la
|
|||
|
||||
liblinphone_la_SOURCES=\
|
||||
account_creator.c \
|
||||
account_creator_request_engine.c \
|
||||
account_creator_service.c \
|
||||
address.c \
|
||||
authentication.c \
|
||||
buffer.c \
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -1,161 +0,0 @@
|
|||
/*
|
||||
account_creator_request_engine.c
|
||||
Copyright (C) 2017 Belledonne Communications SARL
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
#include "linphone/account_creator_request_engine.h"
|
||||
#include "linphone/core.h"
|
||||
#include "private.h"
|
||||
|
||||
BELLE_SIP_DECLARE_NO_IMPLEMENTED_INTERFACES(LinphoneAccountCreatorRequestCbs);
|
||||
|
||||
BELLE_SIP_INSTANCIATE_VPTR(LinphoneAccountCreatorRequestCbs, belle_sip_object_t,
|
||||
NULL, // destroy
|
||||
NULL, // clone
|
||||
NULL, // marshal
|
||||
FALSE
|
||||
);
|
||||
|
||||
/************************** Start Account Creator requests_cbs **************************/
|
||||
LinphoneAccountCreatorRequestCbs * linphone_account_creator_requests_cbs_new(void) {
|
||||
return belle_sip_object_new(LinphoneAccountCreatorRequestCbs);
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestCbs * linphone_account_creator_requests_cbs_ref(LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
belle_sip_object_ref(requests_cbs);
|
||||
return requests_cbs;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_unref(LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
belle_sip_object_unref(requests_cbs);
|
||||
}
|
||||
|
||||
void *linphone_account_creator_requests_cbs_get_user_data(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->user_data;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_user_data(LinphoneAccountCreatorRequestCbs *requests_cbs, void *ud) {
|
||||
requests_cbs->user_data = ud;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_constructor_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->account_creator_request_constructor_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_constructor_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->account_creator_request_constructor_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_destructor_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->account_creator_request_destructor_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_destructor_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->account_creator_request_destructor_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_create_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->create_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_create_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->create_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_account_exist_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->is_account_exist_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_is_account_exist_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->is_account_exist_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_activate_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->activate_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_activate_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->activate_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_account_activated_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->is_account_activated_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_is_account_activated_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->is_account_activated_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_link_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->link_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_link_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->link_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_activate_alias_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->activate_alias_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_activate_alias_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->activate_alias_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_alias_used_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->is_alias_used_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_is_alias_used_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->is_alias_used_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_account_linked_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->is_account_linked_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_is_account_linked_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->is_account_linked_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_recover_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->is_account_linked_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_recover_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->recover_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_update_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs) {
|
||||
return requests_cbs->update_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_requests_cbs_set_update_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb) {
|
||||
requests_cbs->update_account_request_cb = cb;
|
||||
}
|
||||
|
||||
/************************** End Account Creator requests_cbs **************************/
|
||||
|
||||
void linphone_core_set_account_creator_request_engine_cbs(LinphoneCore *lc, LinphoneAccountCreatorRequestCbs *cbs) {
|
||||
if (lc->default_ac_request_cbs)
|
||||
linphone_account_creator_requests_cbs_unref(lc->default_ac_request_cbs);
|
||||
lc->default_ac_request_cbs = cbs;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestCbs* linphone_core_get_account_creator_request_engine_cbs(LinphoneCore *lc) {
|
||||
return lc->default_ac_request_cbs;
|
||||
}
|
||||
161
coreapi/account_creator_service.c
Normal file
161
coreapi/account_creator_service.c
Normal file
|
|
@ -0,0 +1,161 @@
|
|||
/*
|
||||
account_creator_service.c
|
||||
Copyright (C) 2017 Belledonne Communications SARL
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
#include "linphone/account_creator_service.h"
|
||||
#include "linphone/core.h"
|
||||
#include "private.h"
|
||||
|
||||
BELLE_SIP_DECLARE_NO_IMPLEMENTED_INTERFACES(LinphoneAccountCreatorService);
|
||||
|
||||
BELLE_SIP_INSTANCIATE_VPTR(LinphoneAccountCreatorService, belle_sip_object_t,
|
||||
NULL, // destroy
|
||||
NULL, // clone
|
||||
NULL, // marshal
|
||||
FALSE
|
||||
);
|
||||
|
||||
/************************** Start Account Creator service **************************/
|
||||
LinphoneAccountCreatorService * linphone_account_creator_service_new(void) {
|
||||
return belle_sip_object_new(LinphoneAccountCreatorService);
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorService * linphone_account_creator_service_ref(LinphoneAccountCreatorService *service) {
|
||||
belle_sip_object_ref(service);
|
||||
return service;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_unref(LinphoneAccountCreatorService *service) {
|
||||
belle_sip_object_unref(service);
|
||||
}
|
||||
|
||||
void *linphone_account_creator_service_get_user_data(const LinphoneAccountCreatorService *service) {
|
||||
return service->user_data;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_user_data(LinphoneAccountCreatorService *service, void *ud) {
|
||||
service->user_data = ud;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_constructor_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->account_creator_service_constructor_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_constructor_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->account_creator_service_constructor_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_destructor_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->account_creator_service_destructor_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_destructor_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->account_creator_service_destructor_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_create_account_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->create_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_create_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->create_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_account_exist_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->is_account_exist_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_is_account_exist_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->is_account_exist_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_activate_account_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->activate_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_activate_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->activate_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_account_activated_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->is_account_activated_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_is_account_activated_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->is_account_activated_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_link_account_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->link_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_link_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->link_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_activate_alias_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->activate_alias_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_activate_alias_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->activate_alias_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_alias_used_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->is_alias_used_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_is_alias_used_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->is_alias_used_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_account_linked_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->is_account_linked_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_is_account_linked_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->is_account_linked_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_recover_account_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->is_account_linked_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_recover_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->recover_account_request_cb = cb;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_update_account_cb(const LinphoneAccountCreatorService *service) {
|
||||
return service->update_account_request_cb;
|
||||
}
|
||||
|
||||
void linphone_account_creator_service_set_update_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb) {
|
||||
service->update_account_request_cb = cb;
|
||||
}
|
||||
|
||||
/************************** End Account Creator service **************************/
|
||||
|
||||
void linphone_core_set_account_creator_service(LinphoneCore *lc, LinphoneAccountCreatorService *service) {
|
||||
if (lc->default_ac_service)
|
||||
linphone_account_creator_service_unref(lc->default_ac_service);
|
||||
lc->default_ac_service = service;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorService * linphone_core_get_account_creator_service(LinphoneCore *lc) {
|
||||
return lc->default_ac_service;
|
||||
}
|
||||
|
|
@ -2080,21 +2080,21 @@ static void linphone_core_internal_subscription_state_changed(LinphoneCore *lc,
|
|||
}
|
||||
}
|
||||
|
||||
static void _linphone_core_init_account_creator_request_cbs(LinphoneCore *lc) {
|
||||
LinphoneAccountCreatorRequestCbs *cbs = linphone_account_creator_requests_cbs_new();
|
||||
cbs->account_creator_request_constructor_cb = linphone_account_creator_constructor_custom;
|
||||
cbs->account_creator_request_destructor_cb = NULL;
|
||||
cbs->create_account_request_cb = linphone_account_creator_create_account_custom;
|
||||
cbs->is_account_exist_request_cb = linphone_account_creator_is_account_exist_custom;
|
||||
cbs->activate_account_request_cb = linphone_account_creator_activate_account_custom;
|
||||
cbs->is_account_activated_request_cb = linphone_account_creator_is_account_activated_custom;
|
||||
cbs->link_account_request_cb = linphone_account_creator_link_phone_number_with_account_custom;
|
||||
cbs->activate_alias_request_cb = linphone_account_creator_activate_phone_number_link_custom;
|
||||
cbs->is_alias_used_request_cb = linphone_account_creator_is_phone_number_used_custom;
|
||||
cbs->is_account_linked_request_cb = linphone_account_creator_is_account_linked_custom;
|
||||
cbs->recover_account_request_cb = linphone_account_creator_recover_phone_account_custom;
|
||||
cbs->update_account_request_cb = linphone_account_creator_update_password_custom;
|
||||
linphone_core_set_account_creator_request_engine_cbs(lc, cbs);
|
||||
static void _linphone_core_init_account_creator_service(LinphoneCore *lc) {
|
||||
LinphoneAccountCreatorService *service = linphone_account_creator_service_new();
|
||||
service->account_creator_service_constructor_cb = linphone_account_creator_constructor_linphone;
|
||||
service->account_creator_service_destructor_cb = NULL;
|
||||
service->create_account_request_cb = linphone_account_creator_create_account_linphone;
|
||||
service->is_account_exist_request_cb = linphone_account_creator_is_account_exist_linphone;
|
||||
service->activate_account_request_cb = linphone_account_creator_activate_account_linphone;
|
||||
service->is_account_activated_request_cb = linphone_account_creator_is_account_activated_linphone;
|
||||
service->link_account_request_cb = linphone_account_creator_link_phone_number_with_account_linphone;
|
||||
service->activate_alias_request_cb = linphone_account_creator_activate_phone_number_link_linphone;
|
||||
service->is_alias_used_request_cb = linphone_account_creator_is_phone_number_used_linphone;
|
||||
service->is_account_linked_request_cb = linphone_account_creator_is_account_linked_linphone;
|
||||
service->recover_account_request_cb = linphone_account_creator_recover_phone_account_linphone;
|
||||
service->update_account_request_cb = linphone_account_creator_update_password_linphone;
|
||||
linphone_core_set_account_creator_service(lc, service);
|
||||
}
|
||||
|
||||
static void linphone_core_init(LinphoneCore * lc, LinphoneCoreCbs *cbs, LpConfig *config, void * userdata){
|
||||
|
|
@ -2112,7 +2112,7 @@ static void linphone_core_init(LinphoneCore * lc, LinphoneCoreCbs *cbs, LpConfig
|
|||
|
||||
linphone_task_list_init(&lc->hooks);
|
||||
|
||||
_linphone_core_init_account_creator_request_cbs(lc);
|
||||
_linphone_core_init_account_creator_service(lc);
|
||||
|
||||
linphone_core_cbs_set_notify_received(internal_cbs, linphone_core_internal_notify_received);
|
||||
linphone_core_cbs_set_subscription_state_changed(internal_cbs, linphone_core_internal_subscription_state_changed);
|
||||
|
|
@ -5763,8 +5763,8 @@ static void linphone_core_uninit(LinphoneCore *lc)
|
|||
if (lc->im_encryption_engine) {
|
||||
linphone_im_encryption_engine_unref(lc->im_encryption_engine);
|
||||
}
|
||||
if (lc->default_ac_request_cbs) {
|
||||
linphone_account_creator_requests_cbs_unref(lc->default_ac_request_cbs);
|
||||
if (lc->default_ac_service) {
|
||||
linphone_account_creator_service_unref(lc->default_ac_service);
|
||||
}
|
||||
|
||||
linphone_core_free_payload_types(lc);
|
||||
|
|
|
|||
|
|
@ -8188,15 +8188,15 @@ extern "C" void Java_org_linphone_core_LinphoneXmlRpcSessionImpl_sendRequest(JNI
|
|||
|
||||
// Account creator
|
||||
|
||||
static void account_creator_is_account_used(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_is_account_used(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
ms_error("cannot attach VM\n");
|
||||
return;
|
||||
}
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8213,7 +8213,7 @@ static void account_creator_is_account_used(LinphoneAccountCreator *creator, Lin
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_create_account(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_create_account(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8221,8 +8221,8 @@ static void account_creator_create_account(LinphoneAccountCreator *creator, Linp
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8239,7 +8239,7 @@ static void account_creator_create_account(LinphoneAccountCreator *creator, Linp
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_activate_account(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_activate_account(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8247,8 +8247,8 @@ static void account_creator_activate_account(LinphoneAccountCreator *creator, Li
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8265,7 +8265,7 @@ static void account_creator_activate_account(LinphoneAccountCreator *creator, Li
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_link_phone_number_with_account(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_link_phone_number_with_account(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8273,8 +8273,8 @@ static void account_creator_link_phone_number_with_account(LinphoneAccountCreato
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8291,7 +8291,7 @@ static void account_creator_link_phone_number_with_account(LinphoneAccountCreato
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_activate_phone_number_link(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_activate_phone_number_link(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8299,8 +8299,8 @@ static void account_creator_activate_phone_number_link(LinphoneAccountCreator *c
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8317,7 +8317,7 @@ static void account_creator_activate_phone_number_link(LinphoneAccountCreator *c
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_is_account_linked(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_is_account_linked(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8325,8 +8325,8 @@ static void account_creator_is_account_linked(LinphoneAccountCreator *creator, L
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8343,7 +8343,7 @@ static void account_creator_is_account_linked(LinphoneAccountCreator *creator, L
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_is_phone_number_used(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_is_phone_number_used(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8351,8 +8351,8 @@ static void account_creator_is_phone_number_used(LinphoneAccountCreator *creator
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8369,7 +8369,7 @@ static void account_creator_is_phone_number_used(LinphoneAccountCreator *creator
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_is_account_activated(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_is_account_activated(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8377,8 +8377,8 @@ static void account_creator_is_account_activated(LinphoneAccountCreator *creator
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8395,7 +8395,7 @@ static void account_creator_is_account_activated(LinphoneAccountCreator *creator
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_phone_account_recovered(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_phone_account_recovered(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8403,8 +8403,8 @@ static void account_creator_phone_account_recovered(LinphoneAccountCreator *crea
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8421,7 +8421,7 @@ static void account_creator_phone_account_recovered(LinphoneAccountCreator *crea
|
|||
env->CallVoidMethod(listener, method, getAccountCreator(env, creator), statusObject);
|
||||
}
|
||||
|
||||
static void account_creator_password_updated(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char *resp) {
|
||||
static void account_creator_password_updated(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char *resp) {
|
||||
JNIEnv *env = 0;
|
||||
jint result = jvm->AttachCurrentThread(&env,NULL);
|
||||
if (result != 0) {
|
||||
|
|
@ -8429,8 +8429,8 @@ static void account_creator_password_updated(LinphoneAccountCreator *creator, Li
|
|||
return;
|
||||
}
|
||||
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_responses_cbs_get_user_data(cbs);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
jobject listener = (jobject) linphone_account_creator_cbs_get_user_data(cbs);
|
||||
if (listener == NULL) {
|
||||
ms_error("account_creator_response() notification without listener");
|
||||
return ;
|
||||
|
|
@ -8463,26 +8463,26 @@ extern "C" void Java_org_linphone_core_LinphoneAccountCreatorImpl_unref(JNIEnv *
|
|||
extern "C" void Java_org_linphone_core_LinphoneAccountCreatorImpl_setListener(JNIEnv* env, jobject thiz, jlong ptr, jobject jlistener) {
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
jobject listener = env->NewGlobalRef(jlistener);
|
||||
LinphoneAccountCreatorResponseCbs *cbs;
|
||||
LinphoneAccountCreatorCbs *cbs;
|
||||
|
||||
cbs = linphone_account_creator_get_responses_cbs(account_creator);
|
||||
linphone_account_creator_responses_cbs_set_user_data(cbs, listener);
|
||||
linphone_account_creator_responses_cbs_set_is_account_exist_cb(cbs, account_creator_is_account_used);
|
||||
linphone_account_creator_responses_cbs_set_create_account_cb(cbs, account_creator_create_account);
|
||||
linphone_account_creator_responses_cbs_set_activate_account_cb(cbs, account_creator_activate_account);
|
||||
linphone_account_creator_responses_cbs_set_link_account_cb(cbs, account_creator_link_phone_number_with_account);
|
||||
linphone_account_creator_responses_cbs_set_activate_alias_cb(cbs, account_creator_activate_phone_number_link);
|
||||
linphone_account_creator_responses_cbs_set_is_account_activated_cb(cbs, account_creator_is_account_activated);
|
||||
linphone_account_creator_responses_cbs_set_recover_account_cb(cbs, account_creator_phone_account_recovered);
|
||||
linphone_account_creator_responses_cbs_set_is_alias_used_cb(cbs, account_creator_is_phone_number_used);
|
||||
linphone_account_creator_responses_cbs_set_is_account_linked_cb(cbs, account_creator_is_account_linked);
|
||||
linphone_account_creator_responses_cbs_set_update_account_cb(cbs, account_creator_password_updated);
|
||||
cbs = linphone_account_creator_get_callbacks(account_creator);
|
||||
linphone_account_creator_cbs_set_user_data(cbs, listener);
|
||||
linphone_account_creator_cbs_set_is_account_exist(cbs, account_creator_is_account_used);
|
||||
linphone_account_creator_cbs_set_create_account(cbs, account_creator_create_account);
|
||||
linphone_account_creator_cbs_set_activate_account(cbs, account_creator_activate_account);
|
||||
linphone_account_creator_cbs_set_link_account(cbs, account_creator_link_phone_number_with_account);
|
||||
linphone_account_creator_cbs_set_activate_alias(cbs, account_creator_activate_phone_number_link);
|
||||
linphone_account_creator_cbs_set_is_account_activated(cbs, account_creator_is_account_activated);
|
||||
linphone_account_creator_cbs_set_recover_account(cbs, account_creator_phone_account_recovered);
|
||||
linphone_account_creator_cbs_set_is_alias_used(cbs, account_creator_is_phone_number_used);
|
||||
linphone_account_creator_cbs_set_is_account_linked(cbs, account_creator_is_account_linked);
|
||||
linphone_account_creator_cbs_set_update_account(cbs, account_creator_password_updated);
|
||||
}
|
||||
|
||||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setUsername(JNIEnv *env, jobject thiz, jlong ptr, jstring jusername) {
|
||||
const char *username = GetStringUTFChars(env, jusername);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphoneUsernameCheck status = linphone_account_creator_set_username(account_creator, username);
|
||||
LinphoneAccountCreatorUsernameStatus status = linphone_account_creator_set_username(account_creator, username);
|
||||
ReleaseStringUTFChars(env, jusername, username);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
@ -8497,7 +8497,7 @@ extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setPhoneNumber
|
|||
const char *phone_number = GetStringUTFChars(env, jphonenumber);
|
||||
const char *country_code = GetStringUTFChars(env, jcountrycode);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphonePhoneNumberMask status = linphone_account_creator_set_phone_number(account_creator, phone_number, country_code);
|
||||
LinphoneAccountCreatorPhoneNumberStatusMask status = linphone_account_creator_set_phone_number(account_creator, phone_number, country_code);
|
||||
ReleaseStringUTFChars(env, jphonenumber, phone_number);
|
||||
ReleaseStringUTFChars(env, jcountrycode, country_code);
|
||||
return (jint) status;
|
||||
|
|
@ -8512,7 +8512,7 @@ extern "C" jstring Java_org_linphone_core_LinphoneAccountCreatorImpl_getPhoneNum
|
|||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setPassword(JNIEnv *env, jobject thiz, jlong ptr, jstring jpassword) {
|
||||
const char *password = GetStringUTFChars(env, jpassword);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphonePasswordCheck status = linphone_account_creator_set_password(account_creator, password);
|
||||
LinphoneAccountCreatorPasswordStatus status = linphone_account_creator_set_password(account_creator, password);
|
||||
ReleaseStringUTFChars(env, jpassword, password);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
@ -8526,7 +8526,7 @@ extern "C" jstring Java_org_linphone_core_LinphoneAccountCreatorImpl_getPassword
|
|||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setHa1(JNIEnv *env, jobject thiz, jlong ptr, jstring jha1) {
|
||||
const char *ha1 = GetStringUTFChars(env, jha1);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphonePasswordCheck status = linphone_account_creator_set_ha1(account_creator, ha1);
|
||||
LinphoneAccountCreatorPasswordStatus status = linphone_account_creator_set_ha1(account_creator, ha1);
|
||||
ReleaseStringUTFChars(env, jha1, ha1);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
@ -8540,7 +8540,7 @@ extern "C" jstring Java_org_linphone_core_LinphoneAccountCreatorImpl_getHa1(JNIE
|
|||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setActivationCode(JNIEnv *env, jobject thiz, jlong ptr, jstring jcode) {
|
||||
const char *activation_code = GetStringUTFChars(env, jcode);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphoneActivationCodeCheck status = linphone_account_creator_set_activation_code(account_creator, activation_code);
|
||||
LinphoneAccountCreatorActivationCodeStatus status = linphone_account_creator_set_activation_code(account_creator, activation_code);
|
||||
ReleaseStringUTFChars(env, jcode, activation_code);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
@ -8548,7 +8548,7 @@ extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setActivationC
|
|||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setLanguage(JNIEnv *env, jobject thiz, jlong ptr, jstring jlang) {
|
||||
const char *lang = GetStringUTFChars(env, jlang);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphoneLanguageCheck status = linphone_account_creator_set_language(account_creator, lang);
|
||||
LinphoneAccountCreatorLanguageStatus status = linphone_account_creator_set_language(account_creator, lang);
|
||||
ReleaseStringUTFChars(env, jlang, lang);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
@ -8556,7 +8556,7 @@ extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setLanguage(JN
|
|||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setDisplayName(JNIEnv *env, jobject thiz, jlong ptr, jstring jname) {
|
||||
const char *name = GetStringUTFChars(env, jname);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphoneUsernameCheck status = linphone_account_creator_set_display_name(account_creator, name);
|
||||
LinphoneAccountCreatorUsernameStatus status = linphone_account_creator_set_display_name(account_creator, name);
|
||||
ReleaseStringUTFChars(env, jname, name);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
@ -8570,7 +8570,7 @@ extern "C" jstring Java_org_linphone_core_LinphoneAccountCreatorImpl_getDisplayN
|
|||
extern "C" jint Java_org_linphone_core_LinphoneAccountCreatorImpl_setEmail(JNIEnv *env, jobject thiz, jlong ptr, jstring jemail) {
|
||||
const char *email = GetStringUTFChars(env, jemail);
|
||||
LinphoneAccountCreator *account_creator = (LinphoneAccountCreator *)ptr;
|
||||
LinphoneEmailCheck status = linphone_account_creator_set_email(account_creator, email);
|
||||
LinphoneAccountCreatorEmailStatus status = linphone_account_creator_set_email(account_creator, email);
|
||||
ReleaseStringUTFChars(env, jemail, email);
|
||||
return (jint) status;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1128,7 +1128,7 @@ struct _LinphoneCore
|
|||
|
||||
LinphoneAddress *default_rls_addr; /*default resource list server*/
|
||||
LinphoneImEncryptionEngine *im_encryption_engine;
|
||||
struct _LinphoneAccountCreatorRequestCbs *default_ac_request_cbs;
|
||||
struct _LinphoneAccountCreatorService *default_ac_service;
|
||||
MSBandwidthController *bw_controller;
|
||||
};
|
||||
|
||||
|
|
@ -1414,12 +1414,12 @@ BELLE_SIP_DECLARE_VPTR_NO_EXPORT(LinphoneXmlRpcSession);
|
|||
* Account creator interface *
|
||||
****************************************************************************/
|
||||
|
||||
struct _LinphoneAccountCreatorRequestCbs {
|
||||
struct _LinphoneAccountCreatorService {
|
||||
belle_sip_object_t base;
|
||||
void *user_data;
|
||||
|
||||
LinphoneAccountCreatorRequestFunc account_creator_request_constructor_cb; /**< Constructor */
|
||||
LinphoneAccountCreatorRequestFunc account_creator_request_destructor_cb; /**< Destructor */
|
||||
LinphoneAccountCreatorRequestFunc account_creator_service_constructor_cb; /**< Constructor */
|
||||
LinphoneAccountCreatorRequestFunc account_creator_service_destructor_cb; /**< Destructor */
|
||||
|
||||
LinphoneAccountCreatorRequestFunc create_account_request_cb; /**< Request to create account */
|
||||
LinphoneAccountCreatorRequestFunc is_account_exist_request_cb; /**< Request to know if account exist */
|
||||
|
|
@ -1436,28 +1436,28 @@ struct _LinphoneAccountCreatorRequestCbs {
|
|||
LinphoneAccountCreatorRequestFunc update_account_request_cb; /**< Request to update account */
|
||||
};
|
||||
|
||||
BELLE_SIP_DECLARE_VPTR(LinphoneAccountCreatorRequestCbs);
|
||||
BELLE_SIP_DECLARE_VPTR(LinphoneAccountCreatorService);
|
||||
|
||||
struct _LinphoneAccountCreatorResponseCbs {
|
||||
struct _LinphoneAccountCreatorCbs {
|
||||
belle_sip_object_t base;
|
||||
void *user_data;
|
||||
|
||||
LinphoneAccountCreatorResponseFunc create_account_response_cb; /**< Response of create_account request */
|
||||
LinphoneAccountCreatorResponseFunc is_account_exist_response_cb; /**< Response of is_account_exist request */
|
||||
LinphoneAccountCreatorCbsStatusCb create_account_response_cb; /**< Response of create_account request */
|
||||
LinphoneAccountCreatorCbsStatusCb is_account_exist_response_cb; /**< Response of is_account_exist request */
|
||||
|
||||
LinphoneAccountCreatorResponseFunc activate_account_response_cb; /**< Response of activate_account request */
|
||||
LinphoneAccountCreatorResponseFunc is_account_activated_response_cb; /**< Response of is_account_activated request */
|
||||
LinphoneAccountCreatorCbsStatusCb activate_account_response_cb; /**< Response of activate_account request */
|
||||
LinphoneAccountCreatorCbsStatusCb is_account_activated_response_cb; /**< Response of is_account_activated request */
|
||||
|
||||
LinphoneAccountCreatorResponseFunc link_account_response_cb; /**< Response of link_account request */
|
||||
LinphoneAccountCreatorResponseFunc activate_alias_response_cb; /**< Response of activation alias */
|
||||
LinphoneAccountCreatorResponseFunc is_alias_used_response_cb; /**< Response of is_alias_used request */
|
||||
LinphoneAccountCreatorResponseFunc is_account_linked_response_cb; /**< Response of is_account_linked request */
|
||||
LinphoneAccountCreatorCbsStatusCb link_account_response_cb; /**< Response of link_account request */
|
||||
LinphoneAccountCreatorCbsStatusCb activate_alias_response_cb; /**< Response of activation alias */
|
||||
LinphoneAccountCreatorCbsStatusCb is_alias_used_response_cb; /**< Response of is_alias_used request */
|
||||
LinphoneAccountCreatorCbsStatusCb is_account_linked_response_cb; /**< Response of is_account_linked request */
|
||||
|
||||
LinphoneAccountCreatorResponseFunc recover_account_response_cb; /**< Response of recover_account request */
|
||||
LinphoneAccountCreatorResponseFunc update_account_response_cb; /**< Response of update_account request */
|
||||
LinphoneAccountCreatorCbsStatusCb recover_account_response_cb; /**< Response of recover_account request */
|
||||
LinphoneAccountCreatorCbsStatusCb update_account_response_cb; /**< Response of update_account request */
|
||||
};
|
||||
|
||||
BELLE_SIP_DECLARE_VPTR(LinphoneAccountCreatorResponseCbs);
|
||||
BELLE_SIP_DECLARE_VPTR(LinphoneAccountCreatorCbs);
|
||||
|
||||
struct _LinphoneAccountCreator {
|
||||
belle_sip_object_t base;
|
||||
|
|
@ -1465,8 +1465,8 @@ struct _LinphoneAccountCreator {
|
|||
LinphoneCore *core;
|
||||
|
||||
/* AccountCreator */
|
||||
LinphoneAccountCreatorRequestCbs *requests_cbs; /**< Account creator requests cbs */
|
||||
LinphoneAccountCreatorResponseCbs *responses_cbs; /**< Account creator responses cbs */
|
||||
LinphoneAccountCreatorService *service; /**< Account creator service */
|
||||
LinphoneAccountCreatorCbs *cbs; /**< Account creator cbs */
|
||||
LinphoneXmlRpcSession *xmlrpc_session; /**< XML-RPC session */
|
||||
LinphoneProxyConfig *proxy_cfg; /**< Default proxy config */
|
||||
|
||||
|
|
@ -1492,6 +1492,85 @@ struct _LinphoneAccountCreator {
|
|||
|
||||
BELLE_SIP_DECLARE_VPTR_NO_EXPORT(LinphoneAccountCreator);
|
||||
|
||||
/**
|
||||
* Account creator custom to set Linphone default values
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_constructor_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to test the existence of a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_account_exist_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to create a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_create_account_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to activate a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_activate_account_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to test the validation of a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_account_activated_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to test the existence a phone number with a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_phone_number_used_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to link a phone number with a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_link_phone_number_with_account_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to activate the link of a phone number with a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_activate_phone_number_link_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to a Linphone account with the phone number.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_recover_phone_account_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to ask if an account is linked with a phone number
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return if this account is linked with a phone number
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_account_linked_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to ask if an account is linked with a phone number
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] new_pwd const char * : new password for the account creator
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_update_password_linphone(LinphoneAccountCreator *creator);
|
||||
|
||||
|
||||
/*****************************************************************************
|
||||
* CardDAV interface *
|
||||
****************************************************************************/
|
||||
|
|
@ -1638,8 +1717,8 @@ LINPHONE_PUBLIC LinphoneImEncryptionEngine *linphone_im_encryption_engine_new(Li
|
|||
|
||||
BELLE_SIP_DECLARE_TYPES_BEGIN(linphone,10000)
|
||||
BELLE_SIP_TYPE_ID(LinphoneAccountCreator),
|
||||
BELLE_SIP_TYPE_ID(LinphoneAccountCreatorRequestCbs),
|
||||
BELLE_SIP_TYPE_ID(LinphoneAccountCreatorResponseCbs),
|
||||
BELLE_SIP_TYPE_ID(LinphoneAccountCreatorCbs),
|
||||
BELLE_SIP_TYPE_ID(LinphoneAccountCreatorService),
|
||||
BELLE_SIP_TYPE_ID(LinphoneBuffer),
|
||||
BELLE_SIP_TYPE_ID(LinphoneContactProvider),
|
||||
BELLE_SIP_TYPE_ID(LinphoneContactSearch),
|
||||
|
|
|
|||
|
|
@ -31,9 +31,9 @@ static LinphoneAccountCreator * linphone_gtk_assistant_get_creator(GtkWidget *w)
|
|||
return (LinphoneAccountCreator *)g_object_get_data(G_OBJECT(w), "creator");
|
||||
}
|
||||
|
||||
static void linphone_gtk_create_account_cb(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char* resp) {
|
||||
static void linphone_gtk_create_account_cb(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char* resp) {
|
||||
GtkWidget *assistant = (GtkWidget *)linphone_account_creator_get_user_data(creator);
|
||||
if (status == LinphoneRequestAccountCreated) {
|
||||
if (status == LinphoneAccountCreatorStatusAccountCreated) {
|
||||
// Go to page_6_linphone_account_validation_wait
|
||||
gtk_assistant_set_current_page(GTK_ASSISTANT(assistant), 6);
|
||||
} else { // Error when attempting to create the account
|
||||
|
|
@ -48,9 +48,9 @@ static void create_account(GtkWidget *assistant) {
|
|||
linphone_account_creator_create_account(creator);
|
||||
}
|
||||
|
||||
static void linphone_gtk_test_account_validation_cb(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char* resp) {
|
||||
static void linphone_gtk_test_account_validation_cb(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char* resp) {
|
||||
GtkWidget *assistant = (GtkWidget *)linphone_account_creator_get_user_data(creator);
|
||||
if (status == LinphoneRequestAccountActivated) {
|
||||
if (status == LinphoneAccountCreatorStatusAccountActivated) {
|
||||
// Go to page_9_finish
|
||||
gtk_assistant_set_current_page(GTK_ASSISTANT(assistant), 9);
|
||||
} else {
|
||||
|
|
@ -215,11 +215,11 @@ static gboolean update_interface_with_username_availability(GtkWidget *page) {
|
|||
GtkLabel* usernameError = GTK_LABEL(linphone_gtk_get_widget(assistant, "p4_label_error"));
|
||||
int account_status = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(page), "is_username_used"));
|
||||
|
||||
if (account_status == LinphoneRequestAccountNotExist) {
|
||||
if (account_status == LinphoneAccountCreatorStatusAccountNotExist) {
|
||||
g_object_set_data(G_OBJECT(page), "is_username_available", GINT_TO_POINTER(1));
|
||||
gtk_image_set_from_stock(isUsernameOk, GTK_STOCK_OK, GTK_ICON_SIZE_LARGE_TOOLBAR);
|
||||
gtk_label_set_text(usernameError, "");
|
||||
} else if (account_status == LinphoneRequestAccountExist) {
|
||||
} else if (account_status == LinphoneAccountCreatorStatusAccountExist) {
|
||||
gtk_label_set_text(usernameError, _("Username is already in use!"));
|
||||
g_object_set_data(G_OBJECT(page), "is_username_available", GINT_TO_POINTER(0));
|
||||
gtk_image_set_from_stock(isUsernameOk, GTK_STOCK_NO, GTK_ICON_SIZE_LARGE_TOOLBAR);
|
||||
|
|
@ -232,7 +232,7 @@ static gboolean update_interface_with_username_availability(GtkWidget *page) {
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
static void linphone_gtk_test_account_existence_cb(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char* resp) {
|
||||
static void linphone_gtk_test_account_existence_cb(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char* resp) {
|
||||
GtkWidget *assistant = (GtkWidget *)linphone_account_creator_get_user_data(creator);
|
||||
GtkWidget *page = gtk_assistant_get_nth_page(GTK_ASSISTANT(assistant), gtk_assistant_get_current_page(GTK_ASSISTANT(assistant)));
|
||||
g_object_set_data(G_OBJECT(page), "is_username_used", GINT_TO_POINTER(status));
|
||||
|
|
@ -324,11 +324,11 @@ void linphone_gtk_account_creation_password_changed(GtkEntry *entry) {
|
|||
|
||||
static void linphone_gtk_assistant_init(GtkWidget *w) {
|
||||
LinphoneAccountCreator *creator = linphone_account_creator_new(linphone_gtk_get_core(), "https://subscribe.linphone.org:444/wizard.php");
|
||||
LinphoneAccountCreatorResponseCbs *cbs = linphone_account_creator_get_responses_cbs(creator);
|
||||
LinphoneAccountCreatorCbs *cbs = linphone_account_creator_get_callbacks(creator);
|
||||
linphone_account_creator_set_user_data(creator, w);
|
||||
linphone_account_creator_responses_cbs_set_is_account_exist_cb(cbs, linphone_gtk_test_account_existence_cb);
|
||||
linphone_account_creator_responses_cbs_set_is_account_activated_cb(cbs, linphone_gtk_test_account_validation_cb);
|
||||
linphone_account_creator_responses_cbs_set_create_account_cb(cbs, linphone_gtk_create_account_cb);
|
||||
linphone_account_creator_cbs_set_is_account_exist(cbs, linphone_gtk_test_account_existence_cb);
|
||||
linphone_account_creator_cbs_set_is_account_activated(cbs, linphone_gtk_test_account_validation_cb);
|
||||
linphone_account_creator_cbs_set_create_account(cbs, linphone_gtk_create_account_cb);
|
||||
g_object_set_data(G_OBJECT(w), "creator", creator);
|
||||
|
||||
gtk_assistant_set_forward_page_func(GTK_ASSISTANT(w), linphone_gtk_assistant_forward, w, NULL);
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
|
||||
set(HEADER_FILES
|
||||
account_creator.h
|
||||
account_creator_request_engine.h
|
||||
account_creator_service.h
|
||||
address.h
|
||||
auth_info.h
|
||||
buffer.h
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ linphone_includedir=$(includedir)/linphone
|
|||
|
||||
linphone_include_HEADERS=\
|
||||
account_creator.h \
|
||||
account_creator_request_engine.h \
|
||||
account_creator_service.h \
|
||||
address.h \
|
||||
auth_info.h \
|
||||
buffer.h \
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ extern "C" {
|
|||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] status The status of the LinphoneAccountCreator test existence operation that has just finished
|
||||
**/
|
||||
typedef void (*LinphoneAccountCreatorResponseFunc)(LinphoneAccountCreator *creator, LinphoneRequestStatus status, const char* resp);
|
||||
typedef void (*LinphoneAccountCreatorCbsStatusCb)(LinphoneAccountCreator *creator, LinphoneAccountCreatorStatus status, const char* resp);
|
||||
|
||||
/************************** Start Account Creator data **************************/
|
||||
|
||||
|
|
@ -51,72 +51,72 @@ LINPHONE_PUBLIC LinphoneAccountCreator * linphone_account_creator_new(LinphoneCo
|
|||
/**
|
||||
* Send a request to know the existence of account on server.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_account_exist(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_account_exist(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to create an account on server.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_create_account(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_create_account(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to know if an account is activated on server.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_account_activated(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_account_activated(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to activate an account on server.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_activate_account(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_activate_account(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to link an account to an alias.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_link_account(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_link_account(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to activate an alias.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_activate_alias(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_activate_alias(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to know if an alias is used.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_alias_used(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_alias_used(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to know if an account is linked.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_account_linked(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_is_account_linked(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to recover an account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_recover_account(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_recover_account(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send a request to update an account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if the request has been sent, LinphoneAccountCreatorStatusRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_update_account(LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_update_account(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Acquire a reference to the LinphoneAccountCreator.
|
||||
|
|
@ -149,9 +149,9 @@ LINPHONE_PUBLIC void linphone_account_creator_set_user_data(LinphoneAccountCreat
|
|||
* Set the username.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] username The username to set
|
||||
* @return LinphoneUsernameOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorUsernameStatusOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneUsernameCheck linphone_account_creator_set_username(LinphoneAccountCreator *creator, const char *username);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorUsernameStatus linphone_account_creator_set_username(LinphoneAccountCreator *creator, const char *username);
|
||||
|
||||
/**
|
||||
* Get the username.
|
||||
|
|
@ -165,9 +165,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_username(const Linphon
|
|||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] phone_number The phone number to set
|
||||
* @param[in] country_code Country code to associate phone number with
|
||||
* @return LinphonePhoneNumberOk if everything is OK, or specific(s) error(s) otherwise.
|
||||
* @return LinphoneAccountCreatorPhoneNumberStatusOk if everything is OK, or specific(s) error(s) otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphonePhoneNumberMask linphone_account_creator_set_phone_number(LinphoneAccountCreator *creator, const char *phone_number, const char *country_code);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorPhoneNumberStatusMask linphone_account_creator_set_phone_number(LinphoneAccountCreator *creator, const char *phone_number, const char *country_code);
|
||||
|
||||
/**
|
||||
* Get the RFC 3966 normalized phone number.
|
||||
|
|
@ -180,9 +180,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_phone_number(const Lin
|
|||
* Set the password.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] password The password to set
|
||||
* @return LinphonePasswordOk if everything is OK, or specific(s) error(s) otherwise.
|
||||
* @return LinphoneAccountCreatorPasswordStatusOk if everything is OK, or specific(s) error(s) otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphonePasswordCheck linphone_account_creator_set_password(LinphoneAccountCreator *creator, const char *password);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorPasswordStatus linphone_account_creator_set_password(LinphoneAccountCreator *creator, const char *password);
|
||||
|
||||
/**
|
||||
* Get the password.
|
||||
|
|
@ -195,9 +195,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_password(const Linphon
|
|||
* Set the ha1.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] ha1 The ha1 to set
|
||||
* @return LinphonePasswordOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorPasswordStatusOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphonePasswordCheck linphone_account_creator_set_ha1(LinphoneAccountCreator *creator, const char *ha1);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorPasswordStatus linphone_account_creator_set_ha1(LinphoneAccountCreator *creator, const char *ha1);
|
||||
|
||||
/**
|
||||
* Get the ha1.
|
||||
|
|
@ -210,9 +210,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_ha1(const LinphoneAcco
|
|||
* Set the activation code.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] activation_code The activation code to set
|
||||
* @return LinphoneActivationCodeOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorActivationCodeStatusOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneActivationCodeCheck linphone_account_creator_set_activation_code(LinphoneAccountCreator *creator, const char *activation_code);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorActivationCodeStatus linphone_account_creator_set_activation_code(LinphoneAccountCreator *creator, const char *activation_code);
|
||||
|
||||
/**
|
||||
* Get the activation code.
|
||||
|
|
@ -225,9 +225,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_activation_code(const
|
|||
* Set the language to use in email or SMS if supported.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] lang The language to use
|
||||
* @return LinphoneLanguageOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorLanguageStatusOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneLanguageCheck linphone_account_creator_set_language(LinphoneAccountCreator *creator, const char *lang);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorLanguageStatus linphone_account_creator_set_language(LinphoneAccountCreator *creator, const char *lang);
|
||||
|
||||
/**
|
||||
* Get the language use in email of SMS.
|
||||
|
|
@ -240,9 +240,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_language(const Linphon
|
|||
* Set the display name.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] display_name The display name to set
|
||||
* @return LinphoneUsernameOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorUsernameStatusOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneUsernameCheck linphone_account_creator_set_display_name(LinphoneAccountCreator *creator, const char *display_name);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorUsernameStatus linphone_account_creator_set_display_name(LinphoneAccountCreator *creator, const char *display_name);
|
||||
|
||||
/**
|
||||
* Get the display name.
|
||||
|
|
@ -255,9 +255,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_display_name(const Lin
|
|||
* Set the email.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] email The email to set
|
||||
* @return LinphoneEmailOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorEmailStatusOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneEmailCheck linphone_account_creator_set_email(LinphoneAccountCreator *creator, const char *email);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorEmailStatus linphone_account_creator_set_email(LinphoneAccountCreator *creator, const char *email);
|
||||
|
||||
/**
|
||||
* Get the email.
|
||||
|
|
@ -270,9 +270,9 @@ LINPHONE_PUBLIC const char * linphone_account_creator_get_email(const LinphoneAc
|
|||
* Set the domain.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] domain The domain to set
|
||||
* @return LinphoneRequestOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_set_domain(LinphoneAccountCreator *creator, const char *domain);
|
||||
LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_set_domain(LinphoneAccountCreator *creator, const char *domain);
|
||||
|
||||
/**
|
||||
* Get the domain.
|
||||
|
|
@ -285,9 +285,9 @@ LINPHONE_DEPRECATED LINPHONE_PUBLIC const char * linphone_account_creator_get_do
|
|||
* Set the route.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] route The route to set
|
||||
* @return LinphoneRequestOk if everything is OK, or a specific error otherwise.
|
||||
* @return LinphoneAccountCreatorStatusRequestOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_set_route(LinphoneAccountCreator *creator, const char *route);
|
||||
LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneAccountCreatorStatus linphone_account_creator_set_route(LinphoneAccountCreator *creator, const char *route);
|
||||
|
||||
/**
|
||||
* Get the route.
|
||||
|
|
@ -297,297 +297,190 @@ LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creat
|
|||
LINPHONE_DEPRECATED LINPHONE_PUBLIC const char * linphone_account_creator_get_route(const LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Get the LinphoneAccountCreatorResponseCbs object associated with a LinphoneAccountCreator.
|
||||
* Get the LinphoneAccountCreatorCbs object associated with a LinphoneAccountCreator.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return The LinphoneAccountCreatorResponseCbs object associated with the LinphoneAccountCreator.
|
||||
* @donotwrap
|
||||
* @return The LinphoneAccountCreatorCbs object associated with the LinphoneAccountCreator.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseCbs * linphone_account_creator_get_responses_cbs(const LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbs * linphone_account_creator_get_callbacks(const LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Get the LinphoneAccountCreatorRequestCbs object associated with a LinphoneAccountCreator.
|
||||
* Get the LinphoneAccountCreatorService object associated with a LinphoneAccountCreator.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return The LinphoneAccountCreatorRequestCbs object associated with the LinphoneAccountCreator.
|
||||
* @return The LinphoneAccountCreatorService object associated with the LinphoneAccountCreator.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestCbs * linphone_account_creator_get_requests_cbs(const LinphoneAccountCreator *creator);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorService * linphone_account_creator_get_service(const LinphoneAccountCreator *creator);
|
||||
|
||||
/************************** End Account Creator data **************************/
|
||||
|
||||
/************************** Start Account Creator Linphone **************************/
|
||||
|
||||
/**
|
||||
* Account creator custom to set Linphone default values
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_constructor_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to test the existence of a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_account_exist_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to create a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_create_account_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to activate a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_activate_account_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to test the validation of a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_account_activated_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to test the existence a phone number with a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_phone_number_used_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to link a phone number with a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_link_phone_number_with_account_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to activate the link of a phone number with a Linphone account.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_activate_phone_number_link_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to a Linphone account with the phone number.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return LinphoneRequestOk if the request has been sent, LinphoneRequestFailed otherwise
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_recover_phone_account_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to ask if an account is linked with a phone number
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @return if this account is linked with a phone number
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_is_account_linked_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* Send an XML-RPC request to ask if an account is linked with a phone number
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
* @param[in] new_pwd const char * : new password for the account creator
|
||||
* @return LinphoneRequestOk if everything is OK, or a specific error otherwise.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneRequestStatus linphone_account_creator_update_password_custom(LinphoneAccountCreator *creator);
|
||||
|
||||
/************************** End Account Creator Linphone **************************/
|
||||
|
||||
/************************** Start Account Creator Cbs **************************/
|
||||
|
||||
/**
|
||||
* Acquire a reference to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @return The same LinphoneAccountCreatorResponseCbs object.
|
||||
* @donotwrap
|
||||
* Acquire a reference to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The same LinphoneAccountCreatorCbs object.
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseCbs * linphone_account_creator_responses_cbs_ref(LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbs * linphone_account_creator_cbs_ref(LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Release a reference to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @donotwrap
|
||||
* Release a reference to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_unref(LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_unref(LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Retrieve the user pointer associated with a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @return The user pointer associated with the LinphoneAccountCreatorResponseCbs object.
|
||||
* @donotwrap
|
||||
* Retrieve the user pointer associated with a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The user pointer associated with the LinphoneAccountCreatorCbs object.
|
||||
**/
|
||||
LINPHONE_PUBLIC void *linphone_account_creator_responses_cbs_get_user_data(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC void *linphone_account_creator_cbs_get_user_data(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] ud The user pointer to associate with the LinphoneAccountCreatorResponseCbs object.
|
||||
* @donotwrap
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] ud The user pointer to associate with the LinphoneAccountCreatorCbs object.
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_user_data(LinphoneAccountCreatorResponseCbs *responses_cbs, void *ud);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_user_data(LinphoneAccountCreatorCbs *cbs, void *ud);
|
||||
|
||||
/**
|
||||
* Get the create account request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_create_account_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_create_account(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The create account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_create_account_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_create_account(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the is account exist request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current is account exist request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_is_account_exist_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_is_account_exist(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The is account exist request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_is_account_exist_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_is_account_exist(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the activate account request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current activate account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_activate_account_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_activate_account(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The activate account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_activate_account_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_activate_account(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the is account activated request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current is account activated request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_is_account_activated_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_is_account_activated(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The is account activated request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_is_account_activated_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_is_account_activated(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the link account request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current link account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_link_account_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_link_account(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The link account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_link_account_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_link_account(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the activate alias request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current link account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_activate_alias_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_activate_alias(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The activate alias request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_activate_alias_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_activate_alias(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the is alias used request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current is alias used request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_is_alias_used_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_is_alias_used(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The is alias used request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_is_alias_used_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_is_alias_used(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the is account linked request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current is account linked request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_is_account_linked_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_is_account_linked(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The is account linked request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_is_account_linked_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_is_account_linked(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the recover account request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current recover account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_recover_account_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_recover_account(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The recover account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_recover_account_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_recover_account(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/**
|
||||
* Get the update account request.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @return The current update account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorResponseFunc linphone_account_creator_responses_cbs_get_update_account_cb(const LinphoneAccountCreatorResponseCbs *responses_cbs);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorCbsStatusCb linphone_account_creator_cbs_get_update_account(const LinphoneAccountCreatorCbs *cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorResponseCbs object.
|
||||
* @param[in] responses_cbs LinphoneAccountCreatorResponseCbs object.
|
||||
* Assign a user pointer to a LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cbs LinphoneAccountCreatorCbs object.
|
||||
* @param[in] cb The update account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_responses_cbs_set_update_account_cb(LinphoneAccountCreatorResponseCbs *responses_cbs, LinphoneAccountCreatorResponseFunc cb);
|
||||
LINPHONE_PUBLIC void linphone_account_creator_cbs_set_update_account(LinphoneAccountCreatorCbs *cbs, LinphoneAccountCreatorCbsStatusCb cb);
|
||||
|
||||
/************************** End Account Creator Cbs **************************/
|
||||
|
||||
|
|
|
|||
|
|
@ -1,282 +0,0 @@
|
|||
/*
|
||||
account_creator_request_engine.h
|
||||
Copyright (C) 2017 Belledonne Communications SARL
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
#ifndef LINPHONE_ACCOUNT_CREATOR_REQUEST_ENGINE_H_
|
||||
#define LINPHONE_ACCOUNT_CREATOR_REQUEST_ENGINE_H_
|
||||
|
||||
#include "linphone/types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Function to set custom server request.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
*/
|
||||
typedef LinphoneRequestStatus (*LinphoneAccountCreatorRequestFunc)(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* @addtogroup account_creator_request
|
||||
* @{
|
||||
*/
|
||||
|
||||
/************************** Start Account Creator Requests **************************/
|
||||
|
||||
/**
|
||||
* Create a new LinphoneAccountCreatorRequestCbs object.
|
||||
* @return a new LinphoneAccountCreatorRequestCbs object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LinphoneAccountCreatorRequestCbs * linphone_account_creator_requests_cbs_new(void);
|
||||
|
||||
/**
|
||||
* Acquire a reference to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The same LinphoneAccountCreatorRequestCbs object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LinphoneAccountCreatorRequestCbs * linphone_account_creator_requests_cbs_ref(LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Release a reference to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @donotwrap
|
||||
**/
|
||||
void linphone_account_creator_requests_cbs_unref(LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Retrieve the user pointer associated with a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The user pointer associated with the LinphoneAccountCreatorRequestCbs object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void *linphone_account_creator_requests_cbs_get_user_data(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] ud The user pointer to associate with the LinphoneAccountCreatorRequestCbs object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_user_data(LinphoneAccountCreatorRequestCbs *requests_cbs, void *ud);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The constructor of account creator requests.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_constructor_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the constructor of account creator requests.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current constructor of create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_constructor_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The destructor.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_destructor_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the destructor of create account request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current destructor of create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_destructor_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Get the create account request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_create_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The create account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_create_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is account exist request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current is account exist request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_account_exist_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The is account exist request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_is_account_exist_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the activate account request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current activate account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_activate_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The activate account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_activate_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is account activated request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current is account activated request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_account_activated_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The is account activated request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_is_account_activated_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the link account request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current link account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_link_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The link account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_link_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the activate alias request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current link account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_activate_alias_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The activate alias request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_activate_alias_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is alias used request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current is alias used request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_alias_used_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The is alias used request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_is_alias_used_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is account linked request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current is account linked request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_is_account_linked_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The is account linked request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_is_account_linked_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the recover account request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current recover account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_recover_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The recover account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_recover_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the update account request.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @return The current update account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_requests_cbs_get_update_account_cb(const LinphoneAccountCreatorRequestCbs *requests_cbs);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] requests_cbs LinphoneAccountCreatorRequestCbs object.
|
||||
* @param[in] cb The update account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_requests_cbs_set_update_account_cb(LinphoneAccountCreatorRequestCbs *requests_cbs, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/************************** End Account Creator Requests **************************/
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @}
|
||||
*/
|
||||
|
||||
#endif /* LINPHONE_ACCOUNT_CREATOR_REQUEST_ENGINE_H_ */
|
||||
282
include/linphone/account_creator_service.h
Normal file
282
include/linphone/account_creator_service.h
Normal file
|
|
@ -0,0 +1,282 @@
|
|||
/*
|
||||
account_creator_service.h
|
||||
Copyright (C) 2017 Belledonne Communications SARL
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
#ifndef LINPHONE_ACCOUNT_CREATOR_SERVICE_H_
|
||||
#define LINPHONE_ACCOUNT_CREATOR_SERVICE_H_
|
||||
|
||||
#include "linphone/types.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Function to set custom server request.
|
||||
* @param[in] creator LinphoneAccountCreator object
|
||||
*/
|
||||
typedef LinphoneAccountCreatorStatus (*LinphoneAccountCreatorRequestFunc)(LinphoneAccountCreator *creator);
|
||||
|
||||
/**
|
||||
* @addtogroup account_creator_request
|
||||
* @{
|
||||
*/
|
||||
|
||||
/************************** Start Account Creator Requests **************************/
|
||||
|
||||
/**
|
||||
* Create a new LinphoneAccountCreatorService object.
|
||||
* @return a new LinphoneAccountCreatorService object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LinphoneAccountCreatorService * linphone_account_creator_service_new(void);
|
||||
|
||||
/**
|
||||
* Acquire a reference to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The same LinphoneAccountCreatorService object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LinphoneAccountCreatorService * linphone_account_creator_service_ref(LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Release a reference to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @donotwrap
|
||||
**/
|
||||
void linphone_account_creator_service_unref(LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Retrieve the user pointer associated with a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The user pointer associated with the LinphoneAccountCreatorService object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void *linphone_account_creator_service_get_user_data(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] ud The user pointer to associate with the LinphoneAccountCreatorService object.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_user_data(LinphoneAccountCreatorService *service, void *ud);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The constructor of account creator requests.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_constructor_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the constructor of account creator requests.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current constructor of create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_constructor_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The destructor.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_destructor_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the destructor of create account request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current destructor of create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_destructor_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Get the create account request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current create account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_create_account_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The create account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_create_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is account exist request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current is account exist request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_account_exist_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The is account exist request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_is_account_exist_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the activate account request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current activate account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_activate_account_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The activate account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_activate_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is account activated request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current is account activated request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_account_activated_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The is account activated request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_is_account_activated_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the link account request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current link account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_link_account_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The link account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_link_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the activate alias request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current link account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_activate_alias_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The activate alias request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_activate_alias_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is alias used request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current is alias used request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_alias_used_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The is alias used request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_is_alias_used_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the is account linked request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current is account linked request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_is_account_linked_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The is account linked request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_is_account_linked_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the recover account request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current recover account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_recover_account_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The recover account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_recover_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/**
|
||||
* Get the update account request.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @return The current update account request.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestFunc linphone_account_creator_service_get_update_account_cb(const LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Assign a user pointer to a LinphoneAccountCreatorService object.
|
||||
* @param[in] service LinphoneAccountCreatorService object.
|
||||
* @param[in] cb The update account request to be used.
|
||||
* @donotwrap
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_account_creator_service_set_update_account_cb(LinphoneAccountCreatorService *service, LinphoneAccountCreatorRequestFunc cb);
|
||||
|
||||
/************************** End Account Creator Requests **************************/
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @}
|
||||
*/
|
||||
|
||||
#endif /* LINPHONE_ACCOUNT_CREATOR_SERVICE_H_ */
|
||||
|
|
@ -33,7 +33,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|||
#include "linphone/sipsetup.h"
|
||||
|
||||
#include "linphone/account_creator.h"
|
||||
#include "linphone/account_creator_request_engine.h"
|
||||
#include "linphone/account_creator_service.h"
|
||||
#include "linphone/address.h"
|
||||
#include "linphone/auth_info.h"
|
||||
#include "linphone/buffer.h"
|
||||
|
|
@ -1909,18 +1909,18 @@ LINPHONE_PUBLIC void linphone_core_abort_authentication(LinphoneCore *lc, Linpho
|
|||
LINPHONE_PUBLIC void linphone_core_clear_all_auth_info(LinphoneCore *lc);
|
||||
|
||||
/**
|
||||
* Sets an default account creator request cbs in the core
|
||||
* Sets an default account creator service in the core
|
||||
* @param lc LinphoneCore object
|
||||
* @param cbs LinphoneAccountCreatorRequestCbs object
|
||||
* @param cbs LinphoneAccountCreatorService object
|
||||
**/
|
||||
LINPHONE_PUBLIC void linphone_core_set_account_creator_request_engine_cbs(LinphoneCore *lc, LinphoneAccountCreatorRequestCbs *cbs);
|
||||
LINPHONE_PUBLIC void linphone_core_set_account_creator_service(LinphoneCore *lc, LinphoneAccountCreatorService *service);
|
||||
|
||||
/**
|
||||
* Get default account creator request cbs from the core
|
||||
* Get default account creator service from the core
|
||||
* @param lc LinphoneCore object
|
||||
* @return LinphoneAccountCreatorRequestCbs object
|
||||
* @return LinphoneAccountCreatorService object
|
||||
**/
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorRequestCbs* linphone_core_get_account_creator_request_engine_cbs(LinphoneCore *lc);
|
||||
LINPHONE_PUBLIC LinphoneAccountCreatorService * linphone_core_get_account_creator_service(LinphoneCore *lc);
|
||||
|
||||
/**
|
||||
* Enable or disable the audio adaptive jitter compensation.
|
||||
|
|
|
|||
|
|
@ -34,121 +34,122 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|||
typedef struct _LinphoneAccountCreator LinphoneAccountCreator;
|
||||
|
||||
/**
|
||||
* An object to handle the requests callbacks for handling the LinphoneAccountCreator server requests.
|
||||
* An object to define a LinphoneAccountCreator service.
|
||||
* @ingroup account_creator
|
||||
* @donotwrap
|
||||
**/
|
||||
typedef struct _LinphoneAccountCreatorRequestCbs LinphoneAccountCreatorRequestCbs;
|
||||
typedef struct _LinphoneAccountCreatorService LinphoneAccountCreatorService;
|
||||
|
||||
/**
|
||||
* An object to handle the responses callbacks for handling the LinphoneAccountCreator operations.
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef struct _LinphoneAccountCreatorResponseCbs LinphoneAccountCreatorResponseCbs;
|
||||
typedef struct _LinphoneAccountCreatorCbs LinphoneAccountCreatorCbs;
|
||||
|
||||
/**
|
||||
* Enum describing Phone number checking.
|
||||
* @ingroup account_creator_checking
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef enum _LinphonePhoneNumberCheck {
|
||||
LinphonePhoneNumberOk = 0x1, /**< Phone number ok */
|
||||
LinphonePhoneNumberTooShort = 0x2, /**< Phone number too short */
|
||||
LinphonePhoneNumberTooLong = 0x4, /**< Phone number too long */
|
||||
LinphonePhoneNumberCountryCodeInvalid = 0x8, /**< Country code invalid */
|
||||
LinphonePhoneNumberInvalid = 0x10, /**< Phone number invalid */
|
||||
} LinphonePhoneNumberCheck;
|
||||
typedef enum _LinphoneAccountCreatorPhoneNumberStatus {
|
||||
LinphoneAccountCreatorPhoneNumberStatusOk = 0x1, /**< Phone number ok */
|
||||
LinphoneAccountCreatorPhoneNumberStatusTooShort = 0x2, /**< Phone number too short */
|
||||
LinphoneAccountCreatorPhoneNumberStatusTooLong = 0x4, /**< Phone number too long */
|
||||
LinphoneAccountCreatorPhoneNumberStatusInvalidCountryCode = 0x8, /**< Country code invalid */
|
||||
LinphoneAccountCreatorPhoneNumberStatusInvalid = 0x10 /**< Phone number invalid */
|
||||
} LinphoneAccountCreatorPhoneNumberStatus;
|
||||
|
||||
/**
|
||||
* A mask of #LinphonePhoneNumberCheck values
|
||||
* @ingroup account_creator_checking
|
||||
* A mask of #LinphoneAccountCreatorPhoneNumberStatus values
|
||||
* @ingroup account_creator
|
||||
*/
|
||||
typedef unsigned int LinphonePhoneNumberMask;
|
||||
typedef unsigned int LinphoneAccountCreatorPhoneNumberStatusMask;
|
||||
|
||||
/**
|
||||
* Enum describing Username checking.
|
||||
* @ingroup account_creator_checking
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef enum _LinphoneUsernameCheck {
|
||||
LinphoneUsernameOk, /**< Username ok */
|
||||
LinphoneUsernameTooShort, /**< Username too short */
|
||||
LinphoneUsernameTooLong, /**< Username too long */
|
||||
LinphoneUsernameInvalidCharacters, /**< Contain invalid characters */
|
||||
LinphoneUsernameInvalid, /**< Invalid username */
|
||||
} LinphoneUsernameCheck;
|
||||
typedef enum _LinphoneAccountCreatorUsernameStatus {
|
||||
LinphoneAccountCreatorUsernameStatusOk, /**< Username ok */
|
||||
LinphoneAccountCreatorUsernameStatusTooShort, /**< Username too short */
|
||||
LinphoneAccountCreatorUsernameStatusTooLong, /**< Username too long */
|
||||
LinphoneAccountCreatorUsernameStatusInvalidCharacters, /**< Contain invalid characters */
|
||||
LinphoneAccountCreatorUsernameStatusInvalid /**< Invalid username */
|
||||
} LinphoneAccountCreatorUsernameStatus;
|
||||
|
||||
/**
|
||||
* Enum describing Email checking.
|
||||
* @ingroup account_creator_checking
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef enum _LinphoneEmailCheck {
|
||||
LinphoneEmailOk, /**< Email ok */
|
||||
LinphoneEmailMalformed, /**< Email malformed */
|
||||
LinphoneEmailInvalidCharacters, /**< Contain invalid characters */
|
||||
} LinphoneEmailCheck;
|
||||
typedef enum _LinphoneAccountCreatorEmailStatus {
|
||||
LinphoneAccountCreatorEmailStatusOk, /**< Email ok */
|
||||
LinphoneAccountCreatorEmailStatusMalformed, /**< Email malformed */
|
||||
LinphoneAccountCreatorEmailStatusInvalidCharacters /**< Contain invalid characters */
|
||||
} LinphoneAccountCreatorEmailStatus;
|
||||
|
||||
/**
|
||||
* Enum describing Password checking.
|
||||
* @ingroup account_creator_checking
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef enum _LinphonePasswordCheck {
|
||||
LinphonePasswordOk, /**< Password ok */
|
||||
LinphonePasswordTooShort, /**< Password too short */
|
||||
LinphonePasswordTooLong, /**< Password too long */
|
||||
LinphonePasswordInvalidCharacters, /**< Contain invalid characters */
|
||||
LinphonePasswordMissingCharacters, /**< Missing specific characters */
|
||||
} LinphonePasswordCheck;
|
||||
typedef enum _LinphoneAccountCreatorPasswordStatus {
|
||||
LinphoneAccountCreatorPasswordStatusOk, /**< Password ok */
|
||||
LinphoneAccountCreatorPasswordStatusTooShort, /**< Password too short */
|
||||
LinphoneAccountCreatorPasswordStatusTooLong, /**< Password too long */
|
||||
LinphoneAccountCreatorPasswordStatusInvalidCharacters, /**< Contain invalid characters */
|
||||
LinphoneAccountCreatorPasswordStatusMissingCharacters /**< Missing specific characters */
|
||||
} LinphoneAccountCreatorPasswordStatus;
|
||||
|
||||
/**
|
||||
* Enum describing language checking.
|
||||
* @ingroup account_creator_checking
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef enum _LinphoneLanguageCheck {
|
||||
LinphoneLanguageOk, /**< Language ok */
|
||||
} LinphoneLanguageCheck;
|
||||
typedef enum _LinphoneAccountCreatorLanguageStatus {
|
||||
LinphoneAccountCreatorLanguageStatusOk /**< Language ok */
|
||||
} LinphoneAccountCreatorLanguageStatus;
|
||||
|
||||
/**
|
||||
* Enum describing Activation code checking.
|
||||
* @ingroup account_creator_checking
|
||||
* @ingroup account_creator
|
||||
**/
|
||||
typedef enum _LinphoneActivationCodeCheck {
|
||||
LinphoneActivationCodeOk, /**< Activation code ok */
|
||||
LinphoneActivationCodeTooShort, /**< Activation code too short */
|
||||
LinphoneActivationCodeTooLong, /**< Activation code too long */
|
||||
LinphoneActivationCodeInvalidCharacters, /**< Contain invalid characters */
|
||||
} LinphoneActivationCodeCheck;
|
||||
typedef enum _LinphoneAccountCreatorActivationCodeStatus {
|
||||
LinphoneAccountCreatorActivationCodeStatusOk, /**< Activation code ok */
|
||||
LinphoneAccountCreatorActivationCodeStatusTooShort, /**< Activation code too short */
|
||||
LinphoneAccountCreatorActivationCodeStatusTooLong, /**< Activation code too long */
|
||||
LinphoneAccountCreatorActivationCodeStatusInvalidCharacters /**< Contain invalid characters */
|
||||
} LinphoneAccountCreatorActivationCodeStatus;
|
||||
|
||||
/**
|
||||
* Enum describing the status of server request.
|
||||
* @ingroup account_creator_request
|
||||
**/
|
||||
typedef enum _LinphoneRequestStatus {
|
||||
typedef enum _LinphoneAccountCreatorStatus {
|
||||
/** Request status **/
|
||||
LinphoneRequestOk, /**< Request passed */
|
||||
LinphoneRequestFailed, /**< Request failed */
|
||||
LinphoneRequestMissingArguments, /**< Request failed due to missing argument(s) */
|
||||
LinphoneRequestMissingCallbacks, /**< Request failed due to missing callback(s) */
|
||||
LinphoneAccountCreatorStatusRequestOk, /**< Request passed */
|
||||
LinphoneAccountCreatorStatusRequestFailed, /**< Request failed */
|
||||
LinphoneAccountCreatorStatusMissingArguments, /**< Request failed due to missing argument(s) */
|
||||
LinphoneAccountCreatorStatusMissingCallbacks, /**< Request failed due to missing callback(s) */
|
||||
|
||||
/** Account status **/
|
||||
/* Creation */
|
||||
LinphoneRequestAccountCreated, /**< Account created */
|
||||
LinphoneRequestAccountNotCreated, /**< Account not created */
|
||||
LinphoneAccountCreatorStatusAccountCreated, /**< Account created */
|
||||
LinphoneAccountCreatorStatusAccountNotCreated, /**< Account not created */
|
||||
/* Existence */
|
||||
LinphoneRequestAccountExist, /**< Account exist */
|
||||
LinphoneRequestAccountExistWithAlias, /**< Account exist with alias */
|
||||
LinphoneRequestAccountNotExist, /**< Account not exist */
|
||||
LinphoneRequestAliasIsAccount, /**< Account was created with Alias */
|
||||
LinphoneRequestAliasExist, /**< Alias exist */
|
||||
LinphoneRequestAliasNotExist, /**< Alias not exist */
|
||||
LinphoneAccountCreatorStatusAccountExist, /**< Account exist */
|
||||
LinphoneAccountCreatorStatusAccountExistWithAlias, /**< Account exist with alias */
|
||||
LinphoneAccountCreatorStatusAccountNotExist, /**< Account not exist */
|
||||
LinphoneAccountCreatorStatusAliasIsAccount, /**< Account was created with Alias */
|
||||
LinphoneAccountCreatorStatusAliasExist, /**< Alias exist */
|
||||
LinphoneAccountCreatorStatusAliasNotExist, /**< Alias not exist */
|
||||
/* Activation */
|
||||
LinphoneRequestAccountActivated, /**< Account activated */
|
||||
LinphoneRequestAccountAlreadyActivated, /**< Account already activated */
|
||||
LinphoneRequestAccountNotActivated, /**< Account not activated */
|
||||
LinphoneAccountCreatorStatusAccountActivated, /**< Account activated */
|
||||
LinphoneAccountCreatorStatusAccountAlreadyActivated, /**< Account already activated */
|
||||
LinphoneAccountCreatorStatusAccountNotActivated, /**< Account not activated */
|
||||
/* Linking */
|
||||
LinphoneRequestAccountLinked, /**< Account linked */
|
||||
LinphoneRequestAccountNotLinked, /**< Account not linked */
|
||||
LinphoneAccountCreatorStatusAccountLinked, /**< Account linked */
|
||||
LinphoneAccountCreatorStatusAccountNotLinked, /**< Account not linked */
|
||||
|
||||
/** Server **/
|
||||
LinphoneRequestErrorServer, /**< Error server */
|
||||
} LinphoneRequestStatus;
|
||||
LinphoneAccountCreatorStatusServerError /**< Error server */
|
||||
} LinphoneAccountCreatorStatus;
|
||||
|
||||
struct SalAddress;
|
||||
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
|
|
@ -370,6 +370,8 @@ class Project:
|
|||
return ev
|
||||
|
||||
def __parseCEnumMemberdef(self, node):
|
||||
if not Project.__canBeWrapped(self, node):
|
||||
return None
|
||||
e = CEnum(node.find('./name').text)
|
||||
deprecatedNode = node.find(".//xrefsect[xreftitle='Deprecated']")
|
||||
if deprecatedNode is not None:
|
||||
|
|
@ -420,6 +422,8 @@ class Project:
|
|||
self.add(s)
|
||||
|
||||
def __parseCTypedefMemberdef(self, node):
|
||||
if not Project.__canBeWrapped(self, node):
|
||||
return None
|
||||
name = node.find('./name').text
|
||||
definition = node.find('./definition').text
|
||||
if definition.startswith('typedef '):
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@ import os
|
|||
import sys
|
||||
import errno
|
||||
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..', '..', 'tools'))
|
||||
print(sys.path)
|
||||
import genapixml as CApi
|
||||
import abstractapi as AbsApi
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue