The Conversation class encapsulates all types of communication possible with Skype client. Instant messaging, calls, video calls, file transfers, SMS, screen sharing - all take place within the context of a Conversation. Contacts are represented in Conversation as Participant objects. This also applies to contacts of PSTN type. All events in a conversation are represented as Message objects.
.
More...
#include <skype-embedded_2.h>
Public Types | |
| enum | { MODULE_ID = 18 } |
| enum | PROPERTY { P_IDENTITY = 972, P_TYPE = 902, P_LIVE_HOST = 918, P_LIVE_START_TIMESTAMP = 974, P_LIVE_IS_MUTED = 996, P_ALERT_STRING = 920, P_IS_BOOKMARKED, P_GIVEN_DISPLAYNAME = 925, P_DISPLAYNAME = 924, P_LOCAL_LIVESTATUS = 927, P_INBOX_TIMESTAMP, P_INBOX_MESSAGE_ID = 973, P_UNCONSUMED_SUPPRESSED_MESSAGES = 975, P_UNCONSUMED_NORMAL_MESSAGES, P_UNCONSUMED_ELEVATED_MESSAGES, P_UNCONSUMED_MESSAGES_VOICE = 970, P_ACTIVE_VM_ID, P_CONSUMPTION_HORIZON = 979, P_LAST_ACTIVITY_TIMESTAMP = 981, P_SPAWNED_FROM_CONVO_ID = 915, P_CREATOR = 903, P_CREATION_TIMESTAMP, P_MY_STATUS = 919, P_OPT_JOINING_ENABLED = 922, P_OPT_ENTRY_LEVEL_RANK = 906, P_OPT_DISCLOSE_HISTORY, P_OPT_ADMIN_ONLY_ACTIVITIES = 909, P_PASSWORDHINT = 980, P_META_NAME = 910, P_META_TOPIC, P_META_GUIDELINES = 913, P_META_PICTURE } |
| enum | TYPE { DIALOG = 1, CONFERENCE, TERMINATED_CONFERENCE, LEGACY_VOICE_CONFERENCE, LEGACY_SHAREDGROUP } |
| enum | MY_STATUS { CONNECTING = 1, RETRY_CONNECTING, DOWNLOADING_MESSAGES, QUEUED_TO_ENTER, APPLICANT, APPLICATION_DENIED, INVALID_ACCESS_TOKEN, CONSUMER, RETIRED_FORCEFULLY, RETIRED_VOLUNTARILY } |
| enum | LOCAL_LIVESTATUS { NONE = 0, STARTING, RINGING_FOR_ME, IM_LIVE, ON_HOLD_LOCALLY = 5, ON_HOLD_REMOTELY, OTHERS_ARE_LIVE, OTHERS_ARE_LIVE_FULL = 11, PLAYING_VOICE_MESSAGE = 8, RECORDING_VOICE_MESSAGE, RECENTLY_LIVE, TRANSFERRING = 12 } |
| enum | ALLOWED_ACTIVITY { SET_META = 1, ADD_CONSUMERS, SPEAK = 4, SPEAK_AND_WRITE = 8 } |
| enum | PARTICIPANTFILTER { ALL = 0, CONSUMERS, APPLICANTS, CONSUMERS_AND_APPLICANTS, MYSELF, OTHER_CONSUMERS } |
| enum | LIST_TYPE { ALL_CONVERSATIONS = 0, INBOX_CONVERSATIONS, BOOKMARKED_CONVERSATIONS, LIVE_CONVERSATIONS, REALLY_ALL_CONVERSATIONS = 5 } |
| typedef ConversationRef | Ref |
| typedef ConversationRefs | Refs |
Public Member Functions | |
| virtual | ~Conversation () |
| ConversationRef | ref () |
| bool | SetOption (const int &propKey, const uint &value) |
| bool | SetTopic (const Sid::String &topic, const bool isXML=false) |
| bool | SetGuidelines (const Sid::String &guidelines, const bool isXML=false) |
| bool | SetPicture (const Sid::Binary &jpeg) |
| bool | SpawnConference (const Sid::List_String &identitiesToAdd, ConversationRef &conference) |
| bool | AddConsumers (const Sid::List_String &identities) |
| bool | Assimilate (const ConversationRef &otherConversation, ConversationRef &conversation) |
| bool | JoinLiveSession (const Sid::String accessToken="") |
| bool | RingOthers (const Sid::List_String identities=Sid::List_String(), const bool videoCall=false, const Sid::String origin="") |
| bool | MuteMyMicrophone () |
| bool | UnmuteMyMicrophone () |
| bool | HoldMyLiveSession () |
| bool | ResumeMyLiveSession () |
| bool | LeaveLiveSession (const bool postVoiceAutoresponse=false) |
| bool | StartVoiceMessage () |
| bool | TransferLiveSession (const Sid::List_String &identities, const Sid::String transferTopic="") |
| bool | CanTransferLiveSession (const Sid::String &identity, bool &result) |
| bool | SendDTMF (const Participant::DTMF &dtmf, const uint lengthInMS=260) |
| bool | StopSendDTMF () |
| bool | SetMyTextStatusTo (const Participant::TEXT_STATUS &status) |
| bool | PostText (const Sid::String &text, MessageRef &message, const bool isXML=false) |
| bool | PostContacts (const ContactRefs &contacts) |
| bool | PostFiles (const Sid::List_Filename &paths, const Sid::String &body, TRANSFER_SENDFILE_ERROR &error_code, Sid::Filename &error_file) |
| bool | PostVoiceMessage (const VoicemailRef &voicemail, const Sid::String &body) |
| bool | PostSMS (const SmsRef &sms, const Sid::String &body) |
| bool | GetJoinBlob (Sid::String &blob) |
| bool | Join () |
| bool | EnterPassword (const Sid::String &password) |
| bool | SetPassword (const Sid::String &password, const Sid::String &hint) |
| bool | RetireFrom () |
| bool | Delete () |
| bool | RenameTo (const Sid::String &name) |
| bool | SetBookmark (const bool &bookmark) |
| bool | SetAlertString (const Sid::String &alertString) |
| bool | RemoveFromInbox () |
| bool | AddToInbox (const uint timestamp=0) |
| bool | SetConsumedHorizon (const uint ×tamp, const bool also_unconsume=false) |
| bool | MarkUnread () |
| bool | IsMemberOf (const ContactGroupRef &group, bool &result) |
| bool | GetParticipants (ParticipantRefs &participants, const Conversation::PARTICIPANTFILTER filter=Conversation::ALL) |
| bool | GetLastMessages (MessageRefs &contextMessages, MessageRefs &unconsumedMessages, const uint requireTimestamp=0) |
| bool | FindMessage (const Sid::String &text, MessageRef &message, const uint fromTimestampUp=MAX_UINT) |
| virtual void | OnParticipantListChange () |
| virtual void | OnMessage (const MessageRef &message) |
| virtual void | OnSpawnConference (const ConversationRef &spawned) |
| bool | GetPropIdentity (Sid::String &identity) |
| bool | GetPropType (Conversation::TYPE &type) |
| bool | GetPropLiveHost (Sid::String &live_host) |
| bool | GetPropLiveStartTimestamp (uint &live_start_timestamp) |
| bool | GetPropLiveIsMuted (bool &live_is_muted) |
| bool | GetPropAlertString (Sid::String &alert_string) |
| bool | GetPropIsBookmarked (bool &is_bookmarked) |
| bool | GetPropGivenDisplayname (Sid::String &given_displayname) |
| bool | GetPropDisplayname (Sid::String &displayname) |
| bool | GetPropLocalLivestatus (LOCAL_LIVESTATUS &local_livestatus) |
| bool | GetPropInboxTimestamp (uint &inbox_timestamp) |
| bool | GetPropInboxMessageId (MessageRef &inbox_message_id) |
| bool | GetPropUnconsumedSuppressedMessages (uint &unconsumed_suppressed_messages) |
| bool | GetPropUnconsumedNormalMessages (uint &unconsumed_normal_messages) |
| bool | GetPropUnconsumedElevatedMessages (uint &unconsumed_elevated_messages) |
| bool | GetPropUnconsumedMessagesVoice (bool &unconsumed_messages_voice) |
| bool | GetPropActiveVmId (VoicemailRef &active_vm_id) |
| bool | GetPropConsumptionHorizon (uint &consumption_horizon) |
| bool | GetPropLastActivityTimestamp (uint &last_activity_timestamp) |
| bool | GetPropSpawnedFromConvoId (ConversationRef &spawned_from_convo_id) |
| bool | GetPropCreator (Sid::String &creator) |
| bool | GetPropCreationTimestamp (uint &creation_timestamp) |
| bool | GetPropMyStatus (MY_STATUS &my_status) |
| bool | GetPropOptJoiningEnabled (bool &opt_joining_enabled) |
| bool | GetPropOptEntryLevelRank (Participant::RANK &opt_entry_level_rank) |
| bool | GetPropOptDiscloseHistory (bool &opt_disclose_history) |
| bool | GetPropOptAdminOnlyActivities (ALLOWED_ACTIVITY &opt_admin_only_activities) |
| bool | GetPropPasswordhint (Sid::String &passwordhint) |
| bool | GetPropMetaName (Sid::String &meta_name) |
| bool | GetPropMetaTopic (Sid::String &meta_topic) |
| bool | GetPropMetaGuidelines (Sid::String &meta_guidelines) |
| bool | GetPropMetaPicture (Sid::Binary &meta_picture) |
The Conversation class encapsulates all types of communication possible with Skype client. Instant messaging, calls, video calls, file transfers, SMS, screen sharing - all take place within the context of a Conversation. Contacts are represented in Conversation as Participant objects. This also applies to contacts of PSTN type. All events in a conversation are represented as Message objects.
.
tutorial_14.cpp, tutorial_16.cpp, tutorial_3.cpp, tutorial_5.cpp, tutorial_6.cpp, and tutorial_7.cpp.
Definition at line 1034 of file skype-embedded_2.h.
| typedef ConversationRef Conversation::Ref |
Definition at line 1043 of file skype-embedded_2.h.
| typedef ConversationRefs Conversation::Refs |
Definition at line 1044 of file skype-embedded_2.h.
| anonymous enum |
Definition at line 1045 of file skype-embedded_2.h.
values for opt_admin_only_activities property
| SET_META |
allowed to set the CONVERSATION_META properties |
| ADD_CONSUMERS |
allowed to add participants to the conference |
| SPEAK |
allowed to speak, but not write |
| SPEAK_AND_WRITE |
allowed to speak and write |
Definition at line 1167 of file skype-embedded_2.h.
Definition at line 1407 of file skype-embedded_2.h.
Definition at line 1151 of file skype-embedded_2.h.
Definition at line 1138 of file skype-embedded_2.h.
Definition at line 1378 of file skype-embedded_2.h.
Properties of the Conversation class
| P_IDENTITY |
contact identity in case of dialogs, chat name in case of conferences, type: Sid::String |
| P_TYPE |
type of the conversation, type: Conversation::TYPE |
| P_LIVE_HOST |
host of current live session. none => no session. myself in case of 1:1 calls, type: Sid::String |
| P_LIVE_START_TIMESTAMP |
moment when first participant other than host joined the current or last live session, type: uint |
| P_LIVE_IS_MUTED |
if live session is muted, type: bool |
| P_ALERT_STRING |
'' everything matches, '=' nothing matches, '=string' string matches, type: Sid::String |
| P_IS_BOOKMARKED |
if conversation is bookmarked/flagged, type: bool |
| P_GIVEN_DISPLAYNAME |
name assigned via GiveDisplayname, type: Sid::String |
| P_DISPLAYNAME |
resulting display name of the conversation (based on given name, topic, participant list, etc), type: Sid::String |
| P_LOCAL_LIVESTATUS |
if the conversation is live and in which status it is then, type: LOCAL_LIVESTATUS |
| P_INBOX_TIMESTAMP |
timestamp to sort the conversations in inbox by. 0 means not in inbox, type: uint |
| P_INBOX_MESSAGE_ID |
ID of the message that caused INBOX_TIMESTAMP to be set, type: MessageRef |
| P_UNCONSUMED_SUPPRESSED_MESSAGES |
number of messages in UNCONSUMED_SUPPRESSED consumption status, type: uint |
| P_UNCONSUMED_NORMAL_MESSAGES |
number of messages in UNCONSUMED_NORMAL consumption status, type: uint |
| P_UNCONSUMED_ELEVATED_MESSAGES |
DEPRECATED, not set anymore, type: uint |
| P_UNCONSUMED_MESSAGES_VOICE |
if there are unconsumed voice or call messages in the conversation, type: bool |
| P_ACTIVE_VM_ID |
ID of voice message that is being played or recorded in this conversation, type: VoicemailRef |
| P_CONSUMPTION_HORIZON |
consumption cutoff timestamp: messages after (but not including) this are considered unconsumed, type: uint |
| P_LAST_ACTIVITY_TIMESTAMP |
timestamp of last activity in conversation, type: uint |
| P_SPAWNED_FROM_CONVO_ID |
dialog this conference was spawned from, type: ConversationRef |
| P_CREATOR |
identity of conversation creator (doesn't apply to dialogs), type: Sid::String |
| P_CREATION_TIMESTAMP |
timestamp of creation (doesn't apply to dialogs), type: uint |
| P_MY_STATUS |
my status in this conversation (connecting, participating, retired, etc) (doesn't apply to dialogs), type: MY_STATUS |
| P_OPT_JOINING_ENABLED |
if it's a public conversation (doesn't apply to dialogs), type: bool |
| P_OPT_ENTRY_LEVEL_RANK |
rank that is auto-assigned at join (doesn't apply to dialogs), type: Participant::RANK |
| P_OPT_DISCLOSE_HISTORY |
if history visible to new consumers (doesn't apply to dialogs), type: bool |
| P_OPT_ADMIN_ONLY_ACTIVITIES |
activities that only ADMIN can do. Bitmap of ALLOWED_ACTIVITY values (doesn't apply to dialogs), type: ALLOWED_ACTIVITY |
| P_PASSWORDHINT |
public conversation password hint, use SetPassword to set (doesn't apply to dialogs), type: Sid::String |
| P_META_NAME |
user-set name, separate from topic (doesn't apply to dialogs), type: Sid::String |
| P_META_TOPIC |
conversation topic (doesn't apply to dialogs), type: Sid::String |
| P_META_GUIDELINES |
guidelines (doesn't apply to dialogs), type: Sid::String |
| P_META_PICTURE |
conversation picture, in jpeg format (doesn't apply to dialogs), type: Sid::Binary |
Definition at line 1059 of file skype-embedded_2.h.
| enum Conversation::TYPE |
Definition at line 1130 of file skype-embedded_2.h.
| Conversation::~Conversation | ( | ) | [virtual] |
Definition at line 526 of file skype-embedded_2.cpp.
| bool Conversation::AddConsumers | ( | const Sid::List_String & | identities | ) |
Takes one or more Contact identities and creates corresponding Participant objects within the context of this Conversation, which must be of type CONFERENCE. If you have an existing dialog conversation, use SpawnConference instead.
| identities | Contact identities to be added to the Conversation. |
| bool Conversation::AddToInbox | ( | const uint | timestamp = 0 |
) |
Sets Conversation inbox_timestamp property. If the timestamp argument is left empty or is greater than conversation consumption horizon, then the conversation will be restored to the inbox.
| timestamp | If left empty or set to 0, the inbox_timestamp property is set to current time. |
| bool Conversation::Assimilate | ( | const ConversationRef & | otherConversation, | |
| ConversationRef & | conversation | |||
| ) |
Merges two live conversations. For example, if the user already has a live conversation up - let's call it conversation A. Then a new incoming call occurs - another conversation obtains LOCAL_LIVESTATUS == Conversation::RINGING_FOR_ME, let's call it conversation B. The user wishes to pick up the new incoming call and add it to the existing one. For this you can first call B->JoinLiveSession and then merge two calls with A->Assimilate(B, A). The second argument will return the merged conversation. Note that there are actually three conversation objects involved: A (before merge), B and C (after the merge). Normally it would make sense to have the first conversation (A) as the second argument, so that it gets overwritten with the assimilation result.
| otherConversation | The new conversation to be merged with the one already in live state. | |
| conversation | Returns a 3rd live conversation, result of merging two existing ones. |
| bool Conversation::CanTransferLiveSession | ( | const Sid::String & | identity, | |
| bool & | result | |||
| ) |
Checks if the identity is available for receiving a transferred live session. If you are going to attempt to go for multiple transfer targets, you should use this check for all the target identities.
| identity | Target identity. | |
| result | Returns true if call transfer to given target is possible. |
| bool Conversation::Delete | ( | ) |
Deletes this conversation, which must be of type CONFERENCE - dialogs between local user and any of his contacts are always persistant. Note that this also removes corresponding Message and Participant objects.
| bool Conversation::EnterPassword | ( | const Sid::String & | password | ) |
Submits password for joining password-protected conversation.
| password | Password string. |
| bool Conversation::FindMessage | ( | const Sid::String & | text, | |
| MessageRef & | message, | |||
| const uint | fromTimestampUp = MAX_UINT | |||
| ) |
Finds the most recent Message object in the conversation that contains the substring specified by the text argument. If no matching messages are found, this method will return false. The search proceeds backwards in time, starting from the timestamp argument. To continue searching, you can start with timestamp=MAX_UINT, retrieve the TIMESTAMP property of the matching message, decrement it by one, and submit it as timestamp for the next FindMessage call.
| text | Substring to search for. | |
| message | Returns matching message or 0 if there was no match. As the likelihood of this object being invalid is quite high, you should always check for method return value before you start calling methods of this object. |
| bool Conversation::GetJoinBlob | ( | Sid::String & | blob | ) |
Retrieves a binary join blob for joining public conversations, which are always of type CONFERENCE. If called for a dialog, the blob argument will contain the empty string. The best way to create a Public Chat is to first create a fresh conversation with Skype class CreateConference, then minimally apply the public chat options OPT_JOINING_ENABLED and OPT_ENTRY_LEVEL_RANK - options, like this (C++):
@n C->SetOption(Conversation::OPT_JOINING_ENABLED, true); @n
When that is done, you can call GetJoinBlob to retrieve the blob string. Use the blob string to generate and post an HTML link whose href attribute looks like this: href="skype:?chat&blob=_BLOB_GOES_HERE" A person running Skype desktop client can click this link to join the conversation and have that conversation opened in his UI. Note that the conversation host (creator) needs to be online for new joiners-via-link to start participating in the Public Chat.
| blob | Returns the public conversation join blob. |
| bool Conversation::GetLastMessages | ( | MessageRefs & | contextMessages, | |
| MessageRefs & | unconsumedMessages, | |||
| const uint | requireTimestamp = 0 | |||
| ) |
Returns recent messages. The messages are returned in two lists - new messages (unconsumed) and recent message history (context messages). The context message list contains messages that are already above the consumption horizon but are fairly recent, making it likely that displaying them in UI would be good default behaviour.
| contextMessages | Already consumed messages, provided for context | |
| unconsumedMessages | Unconsumed messages | |
| requireTimestamp | If set to a non-zero value, includes messages no earlier than this timestamp, if not, includes messages from the last 24 hours only |
| bool Conversation::GetParticipants | ( | ParticipantRefs & | participants, | |
| const Conversation::PARTICIPANTFILTER | filter = Conversation::ALL | |||
| ) |
Retrieves the list of this conversation's current participants, which you can optionally request to be filtered. If no Participants pass the filter, an empty list will be returned (the method itself still returns true).
| participants | List of conversation Participant objects that passed the filter. | |
| filter | Conversation::PARTICIPANTFILTER - defaults to Conversation::ALL |
| bool Conversation::GetPropActiveVmId | ( | VoicemailRef & | active_vm_id | ) |
Conversation::P_ACTIVE_VM_ID property get accessor
| bool Conversation::GetPropAlertString | ( | Sid::String & | alert_string | ) |
Conversation::P_ALERT_STRING property get accessor
| bool Conversation::GetPropConsumptionHorizon | ( | uint & | consumption_horizon | ) |
Conversation::P_CONSUMPTION_HORIZON property get accessor
| bool Conversation::GetPropCreationTimestamp | ( | uint & | creation_timestamp | ) |
Conversation::P_CREATION_TIMESTAMP property get accessor
| bool Conversation::GetPropCreator | ( | Sid::String & | creator | ) |
Conversation::P_CREATOR property get accessor
| bool Conversation::GetPropDisplayname | ( | Sid::String & | displayname | ) |
Conversation::P_DISPLAYNAME property get accessor
| bool Conversation::GetPropGivenDisplayname | ( | Sid::String & | given_displayname | ) |
Conversation::P_GIVEN_DISPLAYNAME property get accessor
| bool Conversation::GetPropIdentity | ( | Sid::String & | identity | ) |
Conversation::P_IDENTITY property get accessor
| bool Conversation::GetPropInboxMessageId | ( | MessageRef & | inbox_message_id | ) |
Conversation::P_INBOX_MESSAGE_ID property get accessor
| bool Conversation::GetPropInboxTimestamp | ( | uint & | inbox_timestamp | ) |
Conversation::P_INBOX_TIMESTAMP property get accessor
| bool Conversation::GetPropIsBookmarked | ( | bool & | is_bookmarked | ) |
Conversation::P_IS_BOOKMARKED property get accessor
| bool Conversation::GetPropLastActivityTimestamp | ( | uint & | last_activity_timestamp | ) |
Conversation::P_LAST_ACTIVITY_TIMESTAMP property get accessor
| bool Conversation::GetPropLiveHost | ( | Sid::String & | live_host | ) |
Conversation::P_LIVE_HOST property get accessor
| bool Conversation::GetPropLiveIsMuted | ( | bool & | live_is_muted | ) |
Conversation::P_LIVE_IS_MUTED property get accessor
| bool Conversation::GetPropLiveStartTimestamp | ( | uint & | live_start_timestamp | ) |
Conversation::P_LIVE_START_TIMESTAMP property get accessor
| bool Conversation::GetPropLocalLivestatus | ( | LOCAL_LIVESTATUS & | local_livestatus | ) |
Conversation::P_LOCAL_LIVESTATUS property get accessor
| bool Conversation::GetPropMetaGuidelines | ( | Sid::String & | meta_guidelines | ) |
Conversation::P_META_GUIDELINES property get accessor
| bool Conversation::GetPropMetaName | ( | Sid::String & | meta_name | ) |
Conversation::P_META_NAME property get accessor
| bool Conversation::GetPropMetaPicture | ( | Sid::Binary & | meta_picture | ) |
Conversation::P_META_PICTURE property get accessor
| bool Conversation::GetPropMetaTopic | ( | Sid::String & | meta_topic | ) |
Conversation::P_META_TOPIC property get accessor
| bool Conversation::GetPropMyStatus | ( | MY_STATUS & | my_status | ) |
Conversation::P_MY_STATUS property get accessor
| bool Conversation::GetPropOptAdminOnlyActivities | ( | ALLOWED_ACTIVITY & | opt_admin_only_activities | ) |
Conversation::P_OPT_ADMIN_ONLY_ACTIVITIES property get accessor
| bool Conversation::GetPropOptDiscloseHistory | ( | bool & | opt_disclose_history | ) |
Conversation::P_OPT_DISCLOSE_HISTORY property get accessor
| bool Conversation::GetPropOptEntryLevelRank | ( | Participant::RANK & | opt_entry_level_rank | ) |
Conversation::P_OPT_ENTRY_LEVEL_RANK property get accessor
| bool Conversation::GetPropOptJoiningEnabled | ( | bool & | opt_joining_enabled | ) |
Conversation::P_OPT_JOINING_ENABLED property get accessor
| bool Conversation::GetPropPasswordhint | ( | Sid::String & | passwordhint | ) |
Conversation::P_PASSWORDHINT property get accessor
| bool Conversation::GetPropSpawnedFromConvoId | ( | ConversationRef & | spawned_from_convo_id | ) |
Conversation::P_SPAWNED_FROM_CONVO_ID property get accessor
| bool Conversation::GetPropType | ( | Conversation::TYPE & | type | ) |
Conversation::P_TYPE property get accessor
| bool Conversation::GetPropUnconsumedElevatedMessages | ( | uint & | unconsumed_elevated_messages | ) |
Conversation::P_UNCONSUMED_ELEVATED_MESSAGES property get accessor
| bool Conversation::GetPropUnconsumedMessagesVoice | ( | bool & | unconsumed_messages_voice | ) |
Conversation::P_UNCONSUMED_MESSAGES_VOICE property get accessor
| bool Conversation::GetPropUnconsumedNormalMessages | ( | uint & | unconsumed_normal_messages | ) |
Conversation::P_UNCONSUMED_NORMAL_MESSAGES property get accessor
| bool Conversation::GetPropUnconsumedSuppressedMessages | ( | uint & | unconsumed_suppressed_messages | ) |
Conversation::P_UNCONSUMED_SUPPRESSED_MESSAGES property get accessor
| bool Conversation::HoldMyLiveSession | ( | ) |
Puts the conversation on hold - Conversation LOCAL_LIVESTATUS changes to ON_HOLD_LOCALLY and to ON_HOLD_REMOTELY for remote participants.
| bool Conversation::IsMemberOf | ( | const ContactGroupRef & | group, | |
| bool & | result | |||
| ) |
Checks if the conversation is a member of the given ContactGroup
| group | ContactGroup | |
| result | True if this conversation is a member of the ContactGroup specified by the group argument contains the conversation |
| bool Conversation::Join | ( | ) |
Tries to join a public conversation (aka public chat). This method is only useful if you have used Skype::GetConversationByBlob method with alsoJoin argument set to false.
| bool Conversation::JoinLiveSession | ( | const Sid::String | accessToken = "" |
) |
starts, answers or joins a live session (first one to join becomes LIVE_HOST)
| accessToken | if starting a live session, allows to set a custom access token |
| bool Conversation::LeaveLiveSession | ( | const bool | postVoiceAutoresponse = false |
) |
Hang up or refuse to answer an incoming call. Set postVoiceAutoresponse to true to enable a caller to leave a voicemail message.
| bool Conversation::MarkUnread | ( | ) |
sets consumption horizon to last inbox message id timestamp
| bool Conversation::MuteMyMicrophone | ( | ) |
Sets VOICE_STATUS to LISTENING in the Participant instance associated with us, causing any input from our microphone to be ignored. This is a Conversation class method, rather than Participant class, because this only applies to local participant.
| virtual void Conversation::OnMessage | ( | const MessageRef & | message | ) | [virtual] |
Deprecated: Use the other OnMessage
| void Conversation::OnParticipantListChange | ( | ) | [virtual] |
This callback gets fired when participants join or leave the conversation.
Definition at line 681 of file skype-embedded_2.cpp.
| virtual void Conversation::OnSpawnConference | ( | const ConversationRef & | spawned | ) | [virtual] |
This callback gets fired when a new Conversation is created using SpawnConference.
| spawned | Conversation object that got created. |
| bool Conversation::PostContacts | ( | const ContactRefs & | contacts | ) |
Takes a list of Contacts as an argument and posts the list into the Conversation. The purpose of this feature is to enable sharing contacts between users, without resorting to contact search. Instead, if user A has contacts B and C, he can post contact C into chat with contact B. At this point, Contact B can add contact C to his contact list. From remote side, the posted contacts will appear as messages with type Message::POSTED_CONTACTS appearing in the conversation. The UI should allow adding these contacts from messages with this type into the contact list.
The list of posted contacts can be retrieved with the Message::GetContacts method.
Additionally, the UI then can parse the posted Contact data out of the Message::P_BODY_XML property. The list of contacts is wrapped between <contacts ..> </contacts> tags. Each contact item in the xml has following format:
@n <contacts alt="alt text"><c t="s" s="skypename" f="full name"/></contacts> @n
@n <contacts alt="alt text"><c t="p" p="+37212345678" d="Some PSTN number"/></contacts> @n
@n <contacts alt="alt text"><c t="p" p="+37212345678" d="Some PSTN number"/><c t="s" s="someskypename"/></contacts> @n
| contacts | List of Contact objects, to be posted in the conversation. |
| bool Conversation::PostFiles | ( | const Sid::List_Filename & | paths, | |
| const Sid::String & | body, | |||
| TRANSFER_SENDFILE_ERROR & | error_code, | |||
| Sid::Filename & | error_file | |||
| ) |
Takes a list of fully-qualified filenames and initiates corresponding file transfers in the conversation. From the remote side, incoming file transfers will appear as a conversation message with type POSTED_FILES. Once such a message is detected, the list of file transfer objects can be retrieved with Message::GetTransfers. At that point, remote participants will need to accept or decline those transfers.
| paths | list of fully-qualified filenames to be transferred | |
| body | Optional BODY_XML property for POSTED_FILES type messages that show up in remote UI. | |
| error_code | Error code, possible values come from the TRANSFER_SENDFILE_ERROR enumerator. This will be set for the first failed fail. The failed file is identified in the error_file return argument. | |
| error_file | Filename of the file that triggered error. |
| bool Conversation::PostSMS | ( | const SmsRef & | sms, | |
| const Sid::String & | body | |||
| ) |
Takes an SMS instance created by Skype::CreateOutgoingSms and posts it in the conversation. Note that you will need to set both Sms body text (Sms::SetBody) and recipient list (Sms::SetTargets) before you can post the object.
| sms | SMS object. | |
| body | This argument is currently ignored. The message text needs to be set with Sms::SetBody method, prior to passing the Sms object to this method |
| bool Conversation::PostText | ( | const Sid::String & | text, | |
| MessageRef & | message, | |||
| const bool | isXML = false | |||
| ) |
Posts the specified text the conversation, and populates message with a reference to the corresponding Message object (if no error occurred during execution). The isXML argument can be used if the client UI has already taken care of converting message text to xml (for example, your UI might enable users to use bold tags in text messages.)
| bool Conversation::PostVoiceMessage | ( | const VoicemailRef & | voicemail, | |
| const Sid::String & | body | |||
| ) |
Stops the active voicemail recording and sends it (dialog only)
| voicemail | This argument is deprecated as of SDK version 3.2. Instead of manually constructing Voicemail object, you can call Conversation::StartVoiceMessage method to start recording a voicemail in context of a dialog. PostVoiceMessage will stop recording this voicemail and post it in the dialog. If instead of sending Voicemail, the user decides to cancel it, you should use Conversation::LeaveLiveSession method (Voicemail::Cancel is deprecated). | |
| body | Optional text message that remote UI can display in conversation, to notify the user of a new voicemail. |
| ConversationRef Conversation::ref | ( | ) | [inline] |
Definition at line 1046 of file skype-embedded_2.h.
| bool Conversation::RemoveFromInbox | ( | ) |
Removes conversation from Inbox.
| bool Conversation::RenameTo | ( | const Sid::String & | name | ) |
Changes the META_NAME property of the conversation. Note that unlike topic and guidelines, this rename is just local - remote participants can have their own private names for conversations.
| name | New name for the conversation. Passing an empty string in this argument causes the META_NAME to unset. |
| bool Conversation::ResumeMyLiveSession | ( | ) |
Resumes call from local hold.
| bool Conversation::RetireFrom | ( | ) |
Leaves the conference. Not applicable to dialogs.
| bool Conversation::RingOthers | ( | const Sid::List_String | identities = Sid::List_String(), |
|
| const bool | videoCall = false, |
|||
| const Sid::String | origin = "" | |||
| ) |
This is an alternative to calling Ring method for each Participant individually. This also works with dialogs (with identities containing only one item).
| identities | List of Participants to ring. Leaving the list empty will result in ringing all participants of at least speaker level. | |
| videoCall | If true, indicates that we want to do a video call (video still needs to be separately enabled) | |
| origin | When call is initiated from web link, this argument must contain the URI that was used |
| bool Conversation::SendDTMF | ( | const Participant::DTMF & | dtmf, | |
| const uint | lengthInMS = 260 | |||
| ) |
Sends DTMF tone to a live conversation.
| dtmf | Outgoing dtmf tone, possible values come from Participant::DTMF enumerator. | |
| lengthInMS | Duration in milliseconds. Defaults to 260 ms. Note that the DTMF tone can be also cancelled with Conversation::StopSendDTMF method. |
| bool Conversation::SetAlertString | ( | const Sid::String & | alertString | ) |
Setter for Conversation class ALERT_STRING property. The main use of this property is checking bodies of incoming messages in the conversation for the alert string and producing notifications in UI for the user, when appropriate.
| alertString | Substring to check in BODY_XML property of incoming messages. |
| bool Conversation::SetBookmark | ( | const bool & | bookmark | ) |
Setter for Conversation class IS_BOOKMARKED.
| bookmark | Set true to set the bookmark, false to remove the bookmark. |
| bool Conversation::SetConsumedHorizon | ( | const uint & | timestamp, | |
| const bool | also_unconsume = false | |||
| ) |
This method can be used to set the consumption (read) status of messages in the conversation. It sets Message::CONSUMPTION_STATUS to Message::CONSUMED for all messages in the conversation, older than the given timestamp. If the second argument is set to true, it also modifies messages more recent than the timestamp, by marking them as unconsumed.
| timestamp | Consumption cutoff timestamp. Setting this to current time will mark all messages in the conversation as consumed. | |
| also_unconsume | If set to true, this also marks messages newer than the cutoff timestamp as unconsumed. For example, setting timestamp to 0 and also_unconsumed to true, will unconsume all messages in the conversation. |
| bool Conversation::SetGuidelines | ( | const Sid::String & | guidelines, | |
| const bool | isXML = false | |||
| ) |
Setter for Conversation META_GUIDELINES. This property will be visible to remote participants of the conversation.
| guidelines | New value for the META_GUIDELINES property. | |
| isXML | Set true to notify remote UIs that the new guideline contains XML tags. |
| bool Conversation::SetMyTextStatusTo | ( | const Participant::TEXT_STATUS & | status | ) |
Sets local user typing indicator in the Conversation. Remote Participants can display these in their UI.
| status | Typing indicator status value - Participant::TEXT_STATUS |
| bool Conversation::SetOption | ( | const int & | propKey, | |
| const uint & | value | |||
| ) |
Setter method for Conversation option properties. Option properties are all Conversation properties starting with OPT_ prefix.
| propKey | Conversation property key, for example: Conversation::OPT_JOINING_ENABLED | |
| value | New value for the option property. |
| bool Conversation::SetPassword | ( | const Sid::String & | password, | |
| const Sid::String & | hint | |||
| ) |
Sets password protection/new password for the conversation.
| password | New password. | |
| hint | Password hint. |
| bool Conversation::SetPicture | ( | const Sid::Binary & | jpeg | ) |
Sets the conversation's avatar to the specified JPEG image, which is propagated to both local and remote participants. Before calling this method, you should use Skype::ValidateAvatar to verify that jpeg references a valid JPEG image.
| jpeg | Conversation avatar binary. |
| bool Conversation::SetTopic | ( | const Sid::String & | topic, | |
| const bool | isXML = false | |||
| ) |
Setter for Conversation class META_TOPIC. This topic will be set for remote participants as well.
| topic | New conversation topic. | |
| isXML | Notifies remote UIs that the new topic contains xml tags. |
| bool Conversation::SpawnConference | ( | const Sid::List_String & | identitiesToAdd, | |
| ConversationRef & | conference | |||
| ) |
When called from dialog conversation, this spawns a new conversation, with existing two dialog participants plus new contact identities given in the identitiesToAdd list. You do not need to add existing dialog participants to the string list. In fact, passing only the existing participants in the identities list will cause the method call to fail (return false), the same as if the list was empty. This method will also return false if the original conversation was not a dialog (contained more than two participants). Also note that this method always creates a new Conversation - even if a conversation with exactly the same participant list existed before.
| identitiesToAdd | String list of additional participant identities. You do not need to add existing two participants from the original dialog to this list. | |
| conference | Returns the resulting conversation or 0 if the method call failed. |
| bool Conversation::StartVoiceMessage | ( | ) |
Begin recording a voice mail for this conversation's remote participant. Applies to conversations of type DIALOG only.
| bool Conversation::StopSendDTMF | ( | ) |
Stops the current DTMF tone being played into conversation. For example, use this method to cancel DTMF signals started with Conversation::SendDTMF before the duration given in lengthInMS runs out.
| bool Conversation::TransferLiveSession | ( | const Sid::List_String & | identities, | |
| const Sid::String | transferTopic = "" | |||
| ) |
This method is for doing call transfers. NB! Call transfers only work in one-on-one conversations (dialogs). Before attempting call transfer, you should check availability of transfer recipients with Conversation class CanTransferLiveSession method. If the current conversation has a live session up, that session (call) will be transferred to targets specified in the identities list. Note that identities is a string list - all identities in that list will get incoming calls. The first one of them to pick up the call - wins, and rest of the transfer targets will stop ringing.
Let's take a closer look how this works in practice. We have three call participants involved in the process, and two separate conversations. Let there be three callers: Caller A (call originator), Caller B (transferor) and Caller C (recipient of transfer).
| identities | String list of transfer target identities. As soon as first one in this list picks up the call, others will stop ringing. | |
| transferTopic | Optional conversation topic. This value will get set as META_TOPIC property of the conversation at the transferee end. Note that this is the only case where META_TOPIC field is used in context of dialog conversations. Thus assumption that remote UI will display topic field in case of dialogs may not be 100% correct. |
| bool Conversation::UnmuteMyMicrophone | ( | ) |
Sets VOICE_STATUS to SPEAKING in the Participant instance associated with us, causing any input from our microphone to be sent to the call host. This is a Conversation class method, rather than Participant class, because this only applies to local participant.
(c) Skype Technologies S.A. Confidential/Proprietary
Last updated: Fri Mar 16 2012