O'Reilly logo

C# in a Nutshell by Peter Drayton, Ted Neward, Ben Albahari

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

XmlUrlResolver

Synopsis

This class resolves URLs of external resources and retrieves them for parsing. XmlUrlResolver implements XmlResolver and provides methods for retrieving external DTDs, Schemas, and imported stylesheets via a URL. To retrieve resources on a network, the Credentials property can be set to provide usernames and passwords, as well as define authentication schemes. You can set this property by supplying a System.Net.ICredentials object. By default, this property is set for anonymous access to a URI resource.

public class XmlUrlResolver : XmlResolver {
// Public Constructors
   public method XmlUrlResolver();  
// Public Instance Properties
   public override field ICredentials Credentials{set; }         // overrides XmlResolver
                  // Public Instance Methods
   public override method object GetEntity(Uri absoluteUri,      // overrides XmlResolver
        string role, Type ofObjectToReturn);  
   public override method Uri ResolveUri(Uri baseUri,            // overrides XmlResolver
        string relativeUri);  
}

Hierarchy

System.ObjectXmlResolverXmlUrlResolver

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required