Liblinphone 3.9.1中文--Modules--Chat room and Messaging

來源:互聯網
上載者:User

Chat room and Messaging  聊天室和訊息傳遞


     #define  linphone_chat_message_set_from(msg, addr) linphone_chat_message_set_from_address(msg,addr)

     #define  linphone_chat_message_get_from(msg)    linphone_chat_message_get_from_address(msg)

     #define  linphone_chat_message_set_to(msg, addr)   linphone_chat_message_set_to_address(msg, addr)

     #define  linphone_chat_message_get_to(msg)   linphone_chat_message_get_to_addr(msg)


自訂類型

     typedef struct _LinphoneChatMessageCbs  LinphoneChatMessageCbs

     typedef struct _LinphoneChatMessage     LinphoneChatMessage

     typedef struct _LinphoneChatRoom        LinphoneChatRoom

     typedef enum   _LinphoneChatMessageState  LinphoneChatMessageState

     typedef enum   _LinphoneLimeState   LinphoneLimeState

     typedef void(* LinphoneChatMessageStateChangedCb)(LinphoneChatMessage *msg,LinphoneChatMessageState state,void *ud)

     typedef void(* LinphoneChatMessageCbsMsgStateChangedCb)(LinphoneChatMessge* msg,LinphoneChatMessageState state)

     typedef void(* LinphoneChatMessageCbsFileTransferRecvCb)(LinphoneChatMessage *message, const LinphoneContent * content, const LinphoneBuffer *buffer)

     typedef  LinphoneBuffer* (* LinphoneChatMessageCbsFileTransferSendCb)(LinphoneChatMessage *message, const LinphoneContent *content, size_t offset, size_t size)

     typedef void(* LinphoneChatMessageCbsFileTransferProgressIndicationCb)(LinphoneChatMessage *message, const LinphoneContent *content, size_t  offset, size_t total)


枚舉類型

   enum   _LinphoneChatMessageState{

            LinphoneChatMessageStateIdle,

            LinphoneChatMessageStateInProgress,

            LinphoneChatMessageStateDelivered,

            LinphoneChatMessageStateNotDelivered,

            LinphoneChatMessageStateFileTransferError,

            LinphoneChatMessageStateFileTransferDone

       }


  enum   _LinphoneLimeState{

           LinphoneLimeDisabled,

           LinphoneLimeMandatory,

           LinphoneLimePreferred

       }



函數

                 

void  linphone_core_set_chat_database_path (LinphoneCore *lc, const char *path)
 
const char *  linphone_core_get_chat_database_path (const LinphoneCore *lc)
 
LinphoneChatRoom *  linphone_core_get_chat_room (LinphoneCore *lc, const LinphoneAddress *addr)
 
LinphoneChatRoom *  linphone_core_get_chat_room_from_uri (LinphoneCore *lc, const char *to)
 
void  linphone_core_delete_chat_room (LinphoneCore *lc, LinphoneChatRoom *cr)
 
void  linphone_core_disable_chat (LinphoneCore *lc, LinphoneReason deny_reason)
 
void  linphone_core_enable_chat (LinphoneCore *lc)
 
bool_t  linphone_core_chat_enabled (const LinphoneCore *lc)
 
MS2_DEPRECATED void  linphone_chat_room_destroy (LinphoneChatRoom *cr)
 
LinphoneChatMessage *  linphone_chat_room_create_message (LinphoneChatRoom *cr, const char *message)
 
LinphoneChatMessage *  linphone_chat_room_create_message_2 (LinphoneChatRoom *cr, const char *message, const char *external_body_url,LinphoneChatMessageState state, time_t time, bool_t is_read, bool_t is_incoming)
 
LinphoneChatRoom *  linphone_chat_room_ref (LinphoneChatRoom *cr)
 
void  linphone_chat_room_unref (LinphoneChatRoom *cr)
 
void *  linphone_chat_room_get_user_data (const LinphoneChatRoom *cr)
 
void  linphone_chat_room_set_user_data (LinphoneChatRoom *cr, void *ud)
 
LinphoneChatMessage *  linphone_chat_room_create_file_transfer_message (LinphoneChatRoom *cr, const LinphoneContent*initial_content)
 
const LinphoneAddress *  linphone_chat_room_get_peer_address (LinphoneChatRoom *cr)
 
MS2_DEPRECATED void  linphone_chat_room_send_message (LinphoneChatRoom *cr, const char *msg)
 
MS2_DEPRECATED void 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.