Request. Register Prefix(String, IWebRequestCreate) Method
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Registers a WebRequest descendant for the specified URI.
public: static bool RegisterPrefix(System::String ^ prefix, System::Net::IWebRequestCreate ^ creator);
public static bool RegisterPrefix (string prefix, System.Net.IWebRequestCreate creator);
static member RegisterPrefix : string * System.Net.IWebRequestCreate -> bool
Public Shared Function RegisterPrefix (prefix As String, creator As IWebRequestCreate) As Boolean
true if registration is successful; otherwise,
The RegisterPrefix method registers WebRequest descendants to service requests. WebRequest descendants are typically registered to handle a specific protocol, such HTTP or FTP, but can be registered to handle a request to a specific server or path on a server.
The pre-registered reserve types already registered include the following:
Duplicate prefixes are not allowed. RegisterPrefix returns
false if an attempt is made to register a duplicate prefix.