michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #ifndef _CC_SERVICE_H_ michael@0: #define _CC_SERVICE_H_ michael@0: michael@0: #include "cc_constants.h" michael@0: michael@0: /** michael@0: * Defines the management methods. michael@0: */ michael@0: /** michael@0: * The following methods are defined to bring up the pSipcc stack michael@0: */ michael@0: /** michael@0: * Initialize the pSipcc stack. CC_Service_create() must be called before michael@0: * calling this function. michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_init(); michael@0: michael@0: /** michael@0: * This function creates various data module needed for initialization of michael@0: * pSipcc stack. On reboot or after CC_Service_destroy(), application must call michael@0: * first this function followed by CC_Service_init() and then michael@0: * CC_Service_start() to bring pSipcc stack in in-service. This function michael@0: * need to be called only once. michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_create(); michael@0: michael@0: /** michael@0: * Gracefully unload the pSipcc stack. To bring up the pSipcc stack again, michael@0: * follow the function calling sequence starting from CC_Service_create(). michael@0: * @return SUCCESS michael@0: */ michael@0: cc_return_t CC_Service_destroy(); michael@0: michael@0: /** michael@0: * Bring up the pSipcc stack in service. CC_Service_init() must be called michael@0: * before calling this function. michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_start(); michael@0: michael@0: /** michael@0: * Shutdown pSipcc stack for restarting michael@0: * @param mgmt_reason the reason to shutdown pSipcc stack michael@0: * @param reason_string literal string for shutdown michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_shutdown(cc_shutdown_reason_t mgmt_reason, cc_string_t reason_string); michael@0: michael@0: /** michael@0: * Unregister all lines of a phone michael@0: * @param mgmt_reason the reason to bring down the registration michael@0: * @param reason_string the literal string for unregistration michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_unregisterAllLines(cc_shutdown_reason_t mgmt_reason, cc_string_t reason_string); michael@0: michael@0: /** michael@0: * Register all lines for a phone. michael@0: * @param mgmt_reason the reason of registration michael@0: * @param reason_string the literal string of the registration michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_registerAllLines(cc_shutdown_reason_t mgmt_reason, cc_string_t reason_string); michael@0: michael@0: /** michael@0: * Restart pSipcc stack michael@0: * @return SUCCESS or FAILURE michael@0: */ michael@0: cc_return_t CC_Service_restart(); michael@0: michael@0: #endif /* _CC_SERVICE_H_ */