Package org.jxmpp.jid.impl
Class DomainpartJid
java.lang.Object
org.jxmpp.jid.impl.AbstractJid
org.jxmpp.jid.impl.DomainpartJid
- All Implemented Interfaces:
Serializable,CharSequence,Comparable<Jid>,BareJid,DomainBareJid,DomainJid,Jid
- See Also:
-
Field Summary
Fields inherited from class org.jxmpp.jid.impl.AbstractJid
cache -
Method Summary
Modifier and TypeMethodDescriptionReturn a JID created by removing the Resourcepart from this JID.Convert this Jid to aDomainBareJid.Convert this Jid to aDomainFullJidif possible.Convert this Jid to aEntityBareJidif possible.Convert this Jid to aEntityFullJidif possible.Convert this Jid to aEntityJidif possible.Convert this Jid to aFullJidif possible.Return the unescaped String representation of this JID.Get theDomainpartof this Jid.Get the localpart of this JID or null.Get the resourcepart of this JID or null.booleanCheck if this is an instance ofEntityBareJidorDomainBareJid.booleanisParentOf(DomainBareJid domainBareJid) SeeJid.isParentOf(Jid).booleanisParentOf(DomainFullJid domainFullJid) SeeJid.isParentOf(Jid).booleanisParentOf(EntityBareJid bareJid) SeeJid.isParentOf(Jid).booleanisParentOf(EntityFullJid fullJid) SeeJid.isParentOf(Jid).booleanisStrictParentOf(DomainBareJid domainBareJid) booleanisStrictParentOf(DomainFullJid domainFullJid) booleanisStrictParentOf(EntityBareJid bareJid) SeeJid.isParentOf(Jid).booleanisStrictParentOf(EntityFullJid fullJid) toString()Returns the String representation of this JID.Methods inherited from class org.jxmpp.jid.impl.AbstractJid
asDomainFullJidOrThrow, asEntityBareJidOrThrow, asEntityFullJidOrThrow, asEntityJidOrThrow, asFullJidOrThrow, asUrlEncodedString, charAt, compareTo, downcast, equals, equals, equals, getLocalpartOrThrow, getResourceOrEmpty, getResourceOrThrow, hashCode, hasLocalpart, hasResource, intern, isDomainBareJid, isDomainFullJid, isEntityBareJid, isEntityFullJid, isEntityJid, isParentOf, isStrictParentOf, length, subSequenceMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.CharSequence
charAt, chars, codePoints, length, subSequenceMethods inherited from interface java.lang.Comparable
compareToMethods inherited from interface org.jxmpp.jid.Jid
asDomainFullJidOrThrow, asEntityBareJidOrThrow, asEntityFullJidOrThrow, asEntityJidOrThrow, asFullJidOrThrow, asUrlEncodedString, downcast, equals, equals, getLocalpartOrThrow, getResourceOrEmpty, getResourceOrThrow, hasLocalpart, hasResource, intern, isDomainBareJid, isDomainFullJid, isEntityBareJid, isEntityFullJid, isEntityJid, isParentOf, isStrictParentOf
-
Method Details
-
getDomain
Description copied from interface:JidGet theDomainpartof this Jid. -
toString
Description copied from interface:JidReturns the String representation of this JID. -
asUnescapedString
Description copied from interface:JidReturn the unescaped String representation of this JID.Since certain Unicode code points are disallowed in the localpart of a JID by the required stringprep profile, those need to get escaped when used in a real JID. The unescaped representation of the JID is only for presentation to a human user or for gatewaying to a non-XMPP system.
For example, if the users inputs'at&t guy@example.com', the escaped real JID created withJidCreatewill be'at\26t\20guy@example.com', which is whatJid.toString()will return. ButJid.asUnescapedString()will return again'at&t guy@example.com'.- Specified by:
asUnescapedStringin interfaceJid- Returns:
- the unescaped String representation of this JID.
-
asDomainBareJid
Description copied from interface:JidConvert this Jid to aDomainBareJid.Note that it is always possible to convert a Jid to a DomainBareJid, since every Jid has a domain part.
- Specified by:
asDomainBareJidin interfaceJid- Returns:
- the corresponding DomainBareJid.
-
hasNoResource
Description copied from interface:JidCheck if this is an instance ofEntityBareJidorDomainBareJid.- Specified by:
hasNoResourcein interfaceJid- Specified by:
hasNoResourcein classAbstractJid- Returns:
- true if this is an instance of BareJid or DomainBareJid
-
asEntityBareJidIfPossible
Description copied from interface:JidConvert this Jid to aEntityBareJidif possible.- Specified by:
asEntityBareJidIfPossiblein interfaceJid- Returns:
- the corresponding
EntityBareJidor null.
-
asEntityFullJidIfPossible
Description copied from interface:JidConvert this Jid to aEntityFullJidif possible.- Specified by:
asEntityFullJidIfPossiblein interfaceJid- Returns:
- the corresponding
EntityFullJidor null.
-
asDomainFullJidIfPossible
Description copied from interface:JidConvert this Jid to aDomainFullJidif possible.- Specified by:
asDomainFullJidIfPossiblein interfaceJid- Returns:
- the corresponding DomainFullJid or null.
-
isParentOf
Description copied from interface:JidSeeJid.isParentOf(Jid).- Specified by:
isParentOfin interfaceJid- Parameters:
bareJid- the bare JID.- Returns:
- true if this JID is a parent of the given JID.
-
isParentOf
Description copied from interface:JidSeeJid.isParentOf(Jid).- Specified by:
isParentOfin interfaceJid- Parameters:
fullJid- the full JID.- Returns:
- true if this JID is a parent of the given JID.
-
isParentOf
Description copied from interface:JidSeeJid.isParentOf(Jid).- Specified by:
isParentOfin interfaceJid- Parameters:
domainBareJid- the domain bare JID.- Returns:
- true if this JID is a parent of the given JID.
-
isParentOf
Description copied from interface:JidSeeJid.isParentOf(Jid).- Specified by:
isParentOfin interfaceJid- Parameters:
domainFullJid- the domain full JID.- Returns:
- true if this JID is a parent of the given JID.
-
isStrictParentOf
Description copied from interface:JidSeeJid.isParentOf(Jid).- Specified by:
isStrictParentOfin interfaceJid- Parameters:
bareJid- the bare JID.- Returns:
- true if this JID is a parent of the given JID.
-
isStrictParentOf
Description copied from interface:Jid- Specified by:
isStrictParentOfin interfaceJid- Parameters:
fullJid- the full JID.- Returns:
- true if this JID is a parent of the given JID.
-
isStrictParentOf
Description copied from interface:Jid- Specified by:
isStrictParentOfin interfaceJid- Parameters:
domainBareJid- the domain bare JID.- Returns:
- true if this JID is a parent of the given JID.
-
isStrictParentOf
Description copied from interface:Jid- Specified by:
isStrictParentOfin interfaceJid- Parameters:
domainFullJid- the domain full JID.- Returns:
- true if this JID is a parent of the given JID.
-
asBareJid
Description copied from interface:JidReturn a JID created by removing the Resourcepart from this JID. -
asEntityJidIfPossible
Description copied from interface:JidConvert this Jid to aEntityJidif possible.- Specified by:
asEntityJidIfPossiblein interfaceJid- Returns:
- the corresponding
EntityJidor null.
-
asFullJidIfPossible
Description copied from interface:JidConvert this Jid to aFullJidif possible.- Specified by:
asFullJidIfPossiblein interfaceJid- Returns:
- the corresponding
FullJidor null.
-
getResourceOrNull
Description copied from interface:JidGet the resourcepart of this JID or null.If the JID is of form
<localpart@domain.example/resource>then this method returns 'resource'. If the JID no resourcepart, thennullis returned.- Specified by:
getResourceOrNullin interfaceJid- Specified by:
getResourceOrNullin classAbstractJid- Returns:
- the resource of this JID or null.
-
getLocalpartOrNull
Description copied from interface:JidGet the localpart of this JID or null.If the JID is of form
<localpart@domain.example>then this method returns 'localpart'. If the JID has no localpart, thennullis returned.- Specified by:
getLocalpartOrNullin interfaceJid- Specified by:
getLocalpartOrNullin classAbstractJid- Returns:
- the localpart of this JID or null.
-