|
DotNetDupe 4.0.6
C++17/20 Implementation of the .NET Base Class Library (BCL)
|
Parses a new URI scheme and provides scheme-specific component extraction. More...
#include <UriParser.h>
Public Member Functions | |
| UriParser () | |
| Constructs a default instance of UriParser. | |
| virtual String | GetComponents (const Uri &uri, UriComponents components, UriFormat format) |
| Gets the components from a URI formatted as specified. | |
| Public Member Functions inherited from DotNetDupe::System::Object | |
| virtual | ~Object ()=default |
| Virtual destructor ensuring polymorphic cleanup. | |
| virtual bool | Equals (const Object &obj) const |
| Determines whether the specified Object is equal to the current Object. | |
| virtual int | GetHashCode () const |
| Serves as the default hash function. | |
| bool | operator== (const Object &obj) const |
| Determines reference equality between two objects. | |
| char * | ToStringA () const |
| Returns narrow-character string representation. | |
| wchar_t * | ToStringW () const |
| Returns wide-character string representation. | |
Static Public Member Functions | |
| static UriParser * | GetParser (const String &schemeName) |
| Retrieves the registered parser associated with a scheme. | |
| static bool | IsKnownScheme (const String &schemeName) |
| Indicates whether the parser for a scheme is registered. | |
| static void | Register (UriParser *uriParser, const String &schemeName, int defaultPort) |
| Registers a custom parser and default port for a specific URI scheme. | |
| Static Public Member Functions inherited from DotNetDupe::System::Object | |
| static bool | Equals (const Object &obj1, const Object &obj2) |
| Static helper determining whether two object instances are equal. | |
Parses a new URI scheme and provides scheme-specific component extraction.
Modeled after .NET System.UriParser. Manages registered scheme parsers and handles custom parsing behaviors for standard and application-defined protocol schemes.
Definition at line 23 of file UriParser.h.
| DotNetDupe::System::UriParser::UriParser | ( | ) |
Constructs a default instance of UriParser.
Default initialization of base URI parser.
Definition at line 12 of file UriParser.cpp.
Referenced by DotNetDupe::System::GenericUriParser::GenericUriParser(), GetParser(), and Register().
|
virtual |
Gets the components from a URI formatted as specified.
| uri | The source Uri to extract components from. |
| components | Bitwise combination of UriComponents to extract. |
| format | The escaping format specification. |
Base implementation: return absolute URI string.
Definition at line 35 of file UriParser.cpp.
References DotNetDupe::System::Uri::GetAbsoluteUri().
Retrieves the registered parser associated with a scheme.
| schemeName | The scheme name to look up. |
Step: Search for registered parser matching scheme name.
Definition at line 26 of file UriParser.cpp.
References UriParser().
|
static |
Indicates whether the parser for a scheme is registered.
| schemeName | The scheme name to check. |
Check if scheme is registered in parser map.
Definition at line 21 of file UriParser.cpp.
|
static |
Registers a custom parser and default port for a specific URI scheme.
| uriParser | Pointer to the parser instance to register. |
| schemeName | The protocol scheme name (e.g. "http", "custom"). |
| defaultPort | The default TCP/UDP port associated with the scheme. |
Associate parser instance and default port with given scheme name.
Definition at line 16 of file UriParser.cpp.
References UriParser().