本文整理汇总了Java中org.jxmpp.jid.FullJid类的典型用法代码示例。如果您正苦于以下问题:Java FullJid类的具体用法?Java FullJid怎么用?Java FullJid使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
FullJid类属于org.jxmpp.jid包,在下文中一共展示了FullJid类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: fullFrom
import org.jxmpp.jid.FullJid; //导入依赖的package包/类
/**
* Get a {@link FullJid} representing the given String.
*
* @param jid the JID's String.
* @return a full JID representing the input String.
* @throws XmppStringprepException if an error occurs.
*/
public static FullJid fullFrom(String jid) throws XmppStringprepException {
FullJid fullJid = FULLJID_CACHE.lookup(jid);
if (fullJid != null) {
return fullJid;
}
String localpart = XmppStringUtils.parseLocalpart(jid);
String domainpart = XmppStringUtils.parseDomain(jid);
String resource = XmppStringUtils.parseResource(jid);
try {
fullJid = fullFrom(localpart, domainpart, resource);
} catch (XmppStringprepException e) {
throw new XmppStringprepException(jid, e);
}
FULLJID_CACHE.put(jid, fullJid);
return fullJid;
}
示例2: asFullJidIfPossible
import org.jxmpp.jid.FullJid; //导入依赖的package包/类
@Override
public FullJid asFullJidIfPossible() {
return this;
}
示例3: asFullJidIfPossible
import org.jxmpp.jid.FullJid; //导入依赖的package包/类
@Override
public FullJid asFullJidIfPossible() {
return null;
}
示例4: hasResource
import org.jxmpp.jid.FullJid; //导入依赖的package包/类
@Override
public final boolean hasResource() {
return this instanceof FullJid;
}