使用 XEP-0191 的 iOS 阻止用户 [英] iOS block user using XEP-0191

查看:20
本文介绍了使用 XEP-0191 的 iOS 阻止用户的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在 iOS 中开发聊天应用程序并使用 openfire xmpp 服务器?我正在尝试使用 XEP-0191 阻止用户:阻止命令但结果出错.

I am developing chat application in iOS and using openfire xmpp server? I am trying to block the user using XEP-0191: Blocking Command but getting error in result.

错误 xmlns="jabber:client" type="cancel" code="503"服务不可用 xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"

error xmlns="jabber:client" type="cancel" code="503" service-unavailable xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"

推荐答案

据我所知,openfier 不支持阻止用户的 XEP-0191.您需要实施 XEP-0016 隐私列表.所以你必须使用创建隐私列表这种方法.

As i know openfier does not support XEP-0191 for block user. you need to implement XEP-0016 privacy list. so you have to create privacylist using this method.

- (void)setListWithName:(NSString *)privacyListName items:(NSArray *)items fromUser:(NSString *)user

你可以用下面的方法激活它

and you can make it active with below method

- (void)setActiveListName:(NSString *)privacyListName;

请参考

如何在 iOS 中使用 xmpp 屏蔽好友?

有关隐私列表的更多详细信息,请关注

For more detail Regarding privacy list please follow

XEP-0016

这篇关于使用 XEP-0191 的 iOS 阻止用户的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆