public class Resourcepart extends Part
 You can create instances of this class from Strings using from(String).
 
| Modifier and Type | Field and Description | 
|---|---|
static Resourcepart | 
EMPTY
The empty resource part. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
static Resourcepart | 
from(String resource)
Get the  
Resourcepart representing the input String. | 
static Resourcepart | 
fromOrNull(CharSequence cs)
 | 
static Resourcepart | 
fromOrThrowUnchecked(CharSequence cs)
Like  
from(String) but does throw an unchecked IllegalArgumentException instead of a
 XmppStringprepException. | 
assertNotLongerThan1023BytesOrEmpty, charAt, equals, hashCode, intern, length, subSequence, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitchars, codePointspublic static final Resourcepart EMPTY
 This empty resource part is the part that is represented by the empty String. This is useful in cases where you
 have a collection of Resourceparts that does not allow null values, but you want to deal with the
 "no resource" case.
 
public static Resourcepart fromOrNull(CharSequence cs)
cs - the input CharSequencenullpublic static Resourcepart fromOrThrowUnchecked(CharSequence cs)
from(String) but does throw an unchecked IllegalArgumentException instead of a
 XmppStringprepException.cs - the character sequence which should be transformed to a ResourcepartResourcepart if no exception occursIllegalArgumentException - if the given input is not a valid Resourcepartfrom(String)public static Resourcepart from(String resource) throws XmppStringprepException
Resourcepart representing the input String.resource - the input String.XmppStringprepException - if an error occurs.