Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
liblinphone
Commits
01999cba
Commit
01999cba
authored
Aug 18, 2017
by
Ronan
Browse files
feat(Message): add interface
parent
f9a078be
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/message/message.h
View file @
01999cba
...
...
@@ -32,6 +32,7 @@ LINPHONE_BEGIN_NAMESPACE
class
Address
;
class
ChatRoom
;
class
Content
;
class
ErrorInfo
;
class
MessagePrivate
;
...
...
@@ -39,52 +40,43 @@ class LINPHONE_PUBLIC Message : public Object {
friend
class
ChatRoom
;
public:
std
::
string
getText
()
const
;
MessageDirection
getDirection
()
const
;
/**
* @brief Set a chat message text to be sent by linphone_chat_room_send_message.
*/
int
setText
(
const
std
::
string
&
text
)
;
std
::
shared_ptr
<
const
Address
>
getFromAddress
()
const
;
std
::
shared_ptr
<
const
Address
>
getToAddress
()
const
;
std
::
shared_ptr
<
const
Address
>
getLocalAddress
()
const
;
std
::
shared_ptr
<
const
Address
>
getRemoteAddress
()
const
;
/**
* @brief Get the state of the message.
*/
// ChatMessageState getState () const;
std
::
shared_ptr
<
ChatRoom
>
getChatRoom
()
const
;
/**
* @brief Get if the message was encrypted when transfered.
*/
bool
isSecured
();
std
::
shared_ptr
<
const
ErrorInfo
>
getErrorInfo
()
const
;
/**
* @brief Get the time the message was sent.
*/
time_t
getTime
()
const
;
std
::
string
getContentType
()
const
;
std
::
shared_ptr
<
ChatRoom
>
getChatRoom
();
std
::
string
getText
()
const
;
void
setText
(
const
std
::
string
&
text
);
std
::
string
getMessageI
d
()
const
;
void
sen
d
()
const
;
std
::
string
getAppdata
()
const
;
void
setAppdata
(
const
std
::
string
&
data
);
bool
containsReadableText
()
const
;
std
::
shared_ptr
<
const
Address
>
getPeerAddress
()
const
;
bool
isSecured
()
const
;
std
::
shared_ptr
<
const
Address
>
getFromAddress
()
const
;
void
setFromAddress
(
const
std
::
shared_ptr
<
const
Address
>
&
address
);
time_t
getTime
()
const
;
std
::
shared_ptr
<
const
Address
>
getToAddress
()
const
;
void
setToAddress
(
const
std
::
shared_ptr
<
const
Address
>
&
addr
);
std
::
string
getId
()
const
;
std
::
shared_ptr
<
const
Address
>
getLocalAddress
()
const
;
std
::
string
getAppdata
()
const
;
void
setAppdata
(
const
std
::
string
&
data
);
std
::
string
getCustomHeaderValue
(
const
std
::
string
&
headerName
);
std
::
list
<
const
std
::
shared_ptr
<
Content
>
>
getContents
()
const
;
void
addContent
(
std
::
shared_ptr
<
Content
>
&
content
);
void
removeContent
(
std
::
shared_ptr
<
Content
>
&
content
);
std
::
string
getCustomHeaderValue
(
const
std
::
string
&
headerName
);
void
addCustomHeader
(
const
std
::
string
&
headerName
,
const
std
::
string
&
headerValue
);
void
removeCustomHeader
(
const
std
::
string
&
headerName
);
std
::
shared_ptr
<
const
ErrorInfo
>
getErrorInfo
()
const
;
protected:
Message
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment