Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@tarun018
Copy link
Contributor

No description provided.

tarun018 added 3 commits July 15, 2017 00:07
Updates MIXJoin Element list of subscriptions to an unordered_set.
Remove redundant MIXSubscribe Element.

License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.

Test-Information:
Added tests for MIXUpdateSubscription Parser and Serializer based on examples in XEP 0369, which passes.
Tested on Ubuntu 16.04 LTS.

Change-Id: Ied06269cf329b4fdffdde4ace67ebffa4089fbde
Updates MIXJoin Element list of subscriptions to an unordered_set.
Remove redundant MIXSubscribe Element.

License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.

Test-Information:
Tests added for joining and leaving a channel as in XEP-0369, which passes.
Tested on Ubuntu 16.04 LTS.

Change-Id: Ibc2737f6154eeee1a85e98cb5f80c8bdbad35dcd
Add MIXRetract element, its parser and serializer

License:
This patch is BSD-licensed, see Documentation/Licenses/BSD-simplified.txt for details.

Test-Information:
Added tests for SendMessage, ReceiveMessage and RetractMessage, which passes.
Added tests for MIXRetract Parser and Serializer based on examples in XEP 0369, which passes.
Tested on Ubuntu 16.04 LTS.

Change-Id: I65555a9129c2eccd632861259be92e2be607ee64
Copy link
Collaborator

@tfar tfar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some first round feedback.

/**
* Join a MIX channel and subscribe to nodes.
*/
virtual void joinChannelAndSubscribe(const JID &channel, const std::unordered_set<std::string>& nodes) = 0;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An object which conforms to the MIX interface is supposed to represent a single client <-> MIX channel relation. So the channel is going to be the same for all methods and probably passed in the constructor.

for (auto node : nodes) {
joinPayload->addSubscription(node);
}
auto request = std::make_shared<GenericRequest<MIXJoin> >(IQ::Set, getJID(), joinPayload, iqRouter_);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use >> instead of > >.


virtual void leaveChannel(const JID &channel) = 0;

virtual void sendMessage(const JID &channel, const std::string &body) = 0;
Copy link
Collaborator

@tfar tfar Jul 18, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably take something more flexible than std::string. What if you want to send XHTML-IM.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants