RESTServiceHelperTryParseRestUrlPathInternal Method |
Tries to parse an absolute URL of a REST service endpoint and splits the absolute path to absolute path prefix and relative REST path.
Namespace: CMS.WebServicesAssembly: CMS.WebServices (in CMS.WebServices.dll) Version: 12.0.0
Syntax protected virtual bool TryParseRestUrlPathInternal(
string absoluteUrl,
out string absolutePathPrefix,
out string relativeRestPath
)
Parameters
- absoluteUrl
- Type: SystemString
Absolute URL identifying REST service endpoint. - absolutePathPrefix
- Type: SystemString
When this method returns, contains absolute path prefix of the absolute path (the path portion preceding '/rest'). Contains null if parsing fails. - relativeRestPath
- Type: SystemString
When this method returns, contains relative path within the REST endpoint (e.g. '/rest/all'). Contains null if parsing fails.
Return Value
Type:
BooleanReturns true upon successful parsing, otherwise false.
Examples
Parses a URL in format http://example.com/web/virtual/path/rest/om.activitytype?format=xml to /web/virtual/path prefix and /rest/om.activitytype REST path.
See Also