Fields Summary |
---|
public static final String | POSTDIALPOST Dial method label text. |
public static final String | PHONE_CONTEXT_TAGPhone context parameter label text. |
public static final String | ISUBISDN subaddress parameter label text. |
public static final String | PROVIDER_TAGProvider parameter label text. |
public static final String | USERUser name parameter label text. |
public static final String | TRANSPORTTransport type parameter label text. |
public static final String | METHODMethod name parameter label text. |
public static final String | TTLTime to live parameter label text. |
public static final String | MADDRMail address parameter label text. |
public static final String | LRLR parameter label text. |
protected String | uriStringImbedded URI. |
protected String | schemeCurrent URI scheme. |
Methods Summary |
---|
public java.lang.Object | clone()Overrides the base clone method.
try {
return new URI(this.uriString);
} catch (ParseException ex) {
throw new RuntimeException(ex.getMessage() + this.uriString);
}
|
public java.lang.String | encode()Encode the URI.
return uriString;
|
public java.lang.String | getPlainURI()Returns the URI part of the address (without parameters)
i.e. scheme:user@host:port.
return encode();
|
public java.lang.String | getScheme()Returns the value of the "scheme" of
this URI, for example "sip", "sips" or "tel".
return scheme;
|
public boolean | isSipURI()This method determines if this is a URI with a scheme of
"sip" or "sips".
return this instanceof SipURI;
|
public boolean | isTelURL()This method determines if this is a URI with a scheme of
"tel"
return this instanceof TelURL;
|
public void | setScheme(java.lang.String sch)Sets the value of the "scheme" of
this URI, for example "sip", "sips" or "tel".
Ref. RFC 3261, p. 224:
scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
final String errMsg = "Invalid scheme format";
char ch;
// Check if the scheme is valid
if (sch == null || !StringTokenizer.isAlpha(sch.charAt(0))) {
throw new IllegalArgumentException(errMsg);
}
for (int i = 1; i < sch.length(); i++) {
ch = sch.charAt(i);
if (!StringTokenizer.isAlpha(ch) && !StringTokenizer.isDigit(ch) &&
(ch != '+") && (ch != '-") && (ch != '.")) {
throw new IllegalArgumentException(errMsg);
}
}
scheme = sch;
|
public java.lang.String | toString()Encodes this URI.
return this.encode();
|