다음을 통해 공유


URLStreamHandler.ParseURL(URL, String, Int32, Int32) Method

Definition

Parses the string representation of a URL into a URL object.

[Android.Runtime.Register("parseURL", "(Ljava/net/URL;Ljava/lang/String;II)V", "GetParseURL_Ljava_net_URL_Ljava_lang_String_IIHandler")]
protected virtual void ParseURL (Java.Net.URL? u, string? spec, int start, int limit);
[<Android.Runtime.Register("parseURL", "(Ljava/net/URL;Ljava/lang/String;II)V", "GetParseURL_Ljava_net_URL_Ljava_lang_String_IIHandler")>]
abstract member ParseURL : Java.Net.URL * string * int * int -> unit
override this.ParseURL : Java.Net.URL * string * int * int -> unit

Parameters

u
URL

the URL to receive the result of parsing the spec.

spec
String

the String representing the URL that must be parsed.

start
Int32

the character index at which to begin parsing. This is just past the ':' (if there is one) that specifies the determination of the protocol name.

limit
Int32

the character position to stop parsing at. This is the end of the string or the position of the "#" character, if present. All information after the sharp sign indicates an anchor.

Attributes

Remarks

Parses the string representation of a URL into a URL object.

If there is any inherited context, then it has already been copied into the URL argument.

The parseURL method of URLStreamHandler parses the string representation as if it were an http specification. Most URL protocol families have a similar parsing. A stream protocol handler for a protocol that has a different syntax must override this routine.

Java documentation for java.net.URLStreamHandler.parseURL(java.net.URL, java.lang.String, int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

See also