Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

class System.​Xml.​XmlUrlResolver

Assembly: System.Xml.ReaderWriter

Inheritance: object → XmlResolver → XmlUrlResolver

Resolves external XML resources named by a Uniform Resource Identifier (URI).

Properties

Gets or sets the cache policy for the underlying <see cref="T:System.Net.WebRequest" /> object.
Credentials
Sets credentials used to authenticate web requests.
Proxy
Gets or sets the network proxy for the underlying <see cref="T:System.Net.WebRequest" /> object.

Methods

public object
GetEntity​(Uri absoluteUri, string role, Type ofObjectToReturn)
Maps a URI to an object that contains the actual resource.
Returns A stream object or <see langword="null" /> if a type other than stream is specified.
absoluteUri The URI returned from <see cref="M:System.Xml.XmlResolver.ResolveUri(System.Uri,System.String)" /> .
role Currently not used.
ofObjectToReturn The type of object to return. The current implementation only returns <see cref="T:System.IO.Stream" /> objects.
public Threading.​Tasks.​Task<​object>
GetEntityAsync​(Uri absoluteUri, string role, Type? ofObjectToReturn)
Asynchronously maps a URI to an object that contains the actual resource.
Returns A stream object or <see langword="null" /> if a type other than stream is specified.
absoluteUri The URI returned from <see cref="M:System.Xml.XmlResolver.ResolveUri(System.Uri,System.String)" /> .
role Currently not used.
ofObjectToReturn The type of object to return. The current implementation only returns <see cref="T:System.IO.Stream" /> objects.
public Uri
ResolveUri​(Uri baseUri, string relativeUri)
Resolves the absolute URI from the base and relative URIs.
Returns The absolute URI, or <see langword="null" /> if the relative URI cannot be resolved.
baseUri The base URI used to resolve the relative URI.
relativeUri The URI to resolve. The URI can be absolute or relative. If absolute, this value effectively replaces the <paramref name="baseUri" /> value. If relative, it combines with the <paramref name="baseUri" /> to make an absolute URI.
public bool
SupportsType​(Uri absoluteUri, Type? type)
Inherited from XmlResolver
Enables the resolver to return types other than <see cref="T:System.IO.Stream" /> .
Returns <see langword="true" /> if the <paramref name="type" /> is supported; otherwise, <see langword="false" /> .
absoluteUri The URI.
type The type to return.
public bool
Equals​(object obj)
Inherited from object
protected void
Finalize​()
Inherited from object
public int
GetHashCode​()
Inherited from object
public Type
GetType​()
Inherited from object
protected object
MemberwiseClone​()
Inherited from object
public string
ToString​()
Inherited from object