Namespace: OpenEdge.Net
Class
URI
Parent classes:
Progress.Lang.Object

Inherits: Progress.Lang.Object

Copyright (c) 2014-2017 by Progress Software Corporation. All rights reserved.
File:URI
Purpose:A generic URI object, useful for making request over a network
Author(s):pjudge
Created:Wed Dec 18 13:02:50 EST 2013
Notes:* W3C spec at http://tools.ietf.org/html/rfc3986
reserved = gen-delims / sub-delims
gen-delims = ":" / "/" / "?" / "#" / "[" / "]" / "@"
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
pchar = unreserved / pct-encoded / sub-delims / ":" / "@"
ALPHA / DIGIT / "-" / "." / "_" / "~" /
"!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" /
R:" / "@"
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Default:unreserved
Query:query = *( pchar / "/" / "?" )
ALPHA / DIGIT / "-" / "." / "_" / "~" /
"!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" /
":" / "@" /
"/" / "?"
Scheme:scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
Fragment:fragment = *( pchar / "/" / "?" )
Path:path-abempty = *( "/" segment )
segment = *pchar
UserInfo:userinfo = *( unreserved / pct-encoded / sub-delims / ":" )
Host:host = IP-literal / IPv4address / reg-name
reg-name = *( unreserved / pct-encoded / sub-delims )
IP-literal = "[" ( IPv6address / IPvFuture ) "]"
IPv4address = dec-octet "." dec-octet "." dec-octet "." dec-octet
dec-octet = DIGIT ; 0-9
/ %x31-39 DIGIT ; 10-99
/ "1" 2DIGIT ; 100-199
/ "2" %x30-34 DIGIT ; 200-249
/ "25" %x30-35 ; 250-255




Method Summary
Options Name Purpose
AddPathSegment (character) /* Adds/appends a segment to the Path property Will %-encode the segment value Empty/blank segments are ignored @param character A path segment */
AddQuery (character) /** Adds a name-only QueryMap argument. Equivalent to calling AddQueryMap(pcname, ?). @param character The QueryMap name */
AddQuery (character, character) /** Adds a query argument @param character The query name @param character The query value */
BuildUri () /* constructs a string representation */
CHARACTER Decode () /** Attempts to decode a previously-encoded URL. @return character A decoded URL */
CHARACTER Decode (character) /** Attempts to decode a previously-encoded string. @param character The string to decode @return character A decoded URL @throws AppError If the encoding is malformed */
CHARACTER Decode (character, character) /** Attempts to decode a previously-encoded string. @param character The string to decode @param character The target codepage to encode into. Defaults to CPINTERNAL @return character A decoded URL @throws AppError If the encoding is malformed */
CHARACTER Decode (String) /** Attempts to decode a previously-encoded string. @param String The string to decode @throws AppError If the encoding is malformed */
CHARACTER Encode () /** Encodes this URI @return character An encoded version of the URI */
CHARACTER Encode (character, UriEncodingTypeEnum) /** Encodes a string for a particular purpose . Wrapper around Encode<encoding-type> and EncodeString() for the Default. Usage of Encode<encoding-type> is recommended. @param character The string to encode @param EncondingTypeEnum The type of encoding to apply @return character the encoded string */
CHARACTER Encode (URI) /** Encodes a URI. @param URI The URI to encode @param character A character representaion of the URI */
CHARACTER EncodeCookie (character) /* Encodes a string per Cookie encoding rules. This method is here for historical reasons. Cookie US-ASCII characters excluding CTLs, whitespace (32) DQUOTE (34), comma (44), semicolon (59), and backslash (92) @param character A string to encode @return character An encoded string */
CHARACTER EncodeCookie (String) /* Encodes a string per Cookie encoding rules. This method is here for historical reasons. Cookie US-ASCII characters excluding CTLs, whitespace (32) DQUOTE (34), comma (44), semicolon (59), and backslash (92) @param String A string to encode @return character An encoded string */
CHARACTER EncodeFragment () /* Encodes this URI's Fragment per URI Fragment encoding rules @return character An encoded string */
CHARACTER EncodeFragment (character) /* Encodes a string per URI Fragment encoding rules https://tools.ietf.org/html/rfc3986#page-11 unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" pchar = unreserved / pct-encoded / sub-delims / ":" / "@" Fragment : fragment = *( pchar / "/" / "?" ) @param character A string to encode @return character An encoded string */
CHARACTER EncodeFragment (String) /* Encodes a string per URI Fragment encoding rules https://tools.ietf.org/html/rfc3986#page-11 unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" pchar = unreserved / pct-encoded / sub-delims / ":" / "@" Fragment : fragment = *( pchar / "/" / "?" ) @param String A string to encode @return character An encoded string */
CHARACTER EncodeHost () /* Encodes this uri's Host per URI Host encoding rules @return character An encoded string */
CHARACTER EncodeHost (character) /* Encodes a string per URI Host encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" Host = *( unreserved / pct-encoded / sub-delims ) @param character A string to encode @return character An encoded string */
CHARACTER EncodeHost (String) /* Encodes a string per URI Host encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" Host = *( unreserved / pct-encoded / sub-delims ) @param String A string to encode @return character An encoded string */
CHARACTER EncodePath (character) /* Encodes a string per URI Path encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" Path = 1*( unreserved / pct-encoded / sub-delims / "@" ) @param character A string to encode @return character An encoded string */
CHARACTER EncodePath (String) /* Encodes a string per URI Path encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" Path = 1*( unreserved / pct-encoded / sub-delims / "@" ) @param String A string to encode @return character An encoded string */
CHARACTER EncodeQuery () /* Encodes this URI's Query string per URI Query encoding rules. @return character An encoded path string */
CHARACTER EncodeQuery (character) /* Encodes a string per URI Query encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" pchar = unreserved / pct-encoded / sub-delims / ":" / "@" Query = *( pchar / "/" / "?" ) @param character A string to encode @return character An encoded string */
CHARACTER EncodeQuery (String) /* Encodes a string per URI Query encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" pchar = unreserved / pct-encoded / sub-delims / ":" / "@" Query = *( pchar / "/" / "?" ) @param String A string to encode @return character An encoded string */
CHARACTER EncodeQuery (URI) /* Encodes a URI's Path string per URI Path encoding rules. This is a separate method since we store the Path whole and so you cannot simply call EncodePath(uri:Path) since that will encode the path delimiters that you need unencoded. @param URI A URI whose path to encode @return character An encoded path string */
CHARACTER EncodeScheme () /* Encodes this URI's scheme per URI Scheme encoding rules @return character An encoded string */
CHARACTER EncodeScheme (character) /* Encodes a string per URI Scheme encoding rules https://tools.ietf.org/html/rfc3986#page-11 Scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." ) @param character A string to encode @return character An encoded string */
CHARACTER EncodeScheme (String) /* Encodes a string per URI Scheme encoding rules https://tools.ietf.org/html/rfc3986#page-11 Scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." ) @param String A string to encode @return character An encoded string */
CHARACTER EncodeString (character) /* Encodes a string per URI Default encoding rules https://tools.ietf.org/html/rfc3986#page-11 Default = unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" @param character A string to encode @return character An encoded string */
CHARACTER EncodeString (character, character, logical[128], logical) /* Encodes a string per the input flags @param character The string to encode @param character The codepage of the input/source string @param logical[128] An array of flags indicating which ASCII chars to encode @param logical TRUE if existing % values must be reencoded as %25 @return character The encoded string */
CHARACTER EncodeString (String) /* Encodes a string per URI Default encoding rules https://tools.ietf.org/html/rfc3986#page-11 Default = unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" @param String A string to encode @return character An encoded string */
CHARACTER EncodeURI (URI) /** Encodes a URI. @param URI The URI to encode @param character A character representaion of the URI */
CHARACTER EncodeUserinfo () /* Encodes this uri's Host per URI Host encoding rules @return character An encoded string */
CHARACTER EncodeUserinfo (character) /* Encodes a string per URI userinfo encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" Host = *( unreserved / pct-encoded / sub-delims / ":" ) @param character A string to encode @return character An encoded string */
CHARACTER EncodeUserinfo (String) /* Encodes a string per URI userinfo encoding rules https://tools.ietf.org/html/rfc3986#page-11 sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "=" unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~" Host = *( unreserved / pct-encoded / sub-delims / ":" ) @param String A string to encode @return character An encoded string */
INTEGER GetPathSegments (character[]) /* Helper method to return the path as an array of segments. @return character[] An array of path segments. */
INTEGER GetQueryNames (character[]) /** Returns an array of query names @param character[] An array @return integer The number */
CHARACTER GetQueryValue (character) /** Get a char query value from the query @param character The query name */
OpenEdge.Net.URI Parse (character) /** Parses a string containing a URI and creates a URI object from it @param character a string URI (eg http://www.progress.com/) @return URI A URI representation of the string. */
LOGICAL RemoveQuery (character) /* Removes a query parameter @param character The name of the query @return logical TRUE if the named query existed (before removal) */
SetPath (character[]) /* Sets the Path property from an array of segments. Will %-encode the segment values Empty/blank segments are ignored @param character[] An array of path segments. */
CHARACTER ToString () /** Returns a string representation of this URI @return character The string URI */

Constructor Summary
Options Name Purpose
URI () /* Static constructor. Used to build lists of to-encode character flags */
URI (character) /** Constructor. Defaults to HTTP scheme. @param character The host name. */
URI (character, character) /** Constructor. @param character The scheme for this URI. @param character The host name. */
URI (character, character, integer) /** Constructor. @param character The scheme for this URI. @param character The host name. @param integer The port to use. */
URI (character, character, integer, character, IStringStringMap, character) /** Constructor. @param character The scheme for this URI. @param character The host name. @param integer The port to use. @param character The path @param IStringStringMap the QueryMap arguments @param character The fragment, if any */

Property Summary
Options Name Purpose
CHARACTER BaseURI /** Returns a base URI (scheme, host, etc) */
CHARACTER Fragment /** (optional) The URI fragment (ie trails the # at the end of the URI) */
CHARACTER Host /** (mandatory) The host name*/
CHARACTER Password /** (optional) The user's password */
CHARACTER Path /** (optional) The URI path. May contain ;-delmited parameters. If a path contains a / that value MUST be %-encoded before setting here. Use URI:EncodePath() on each /-delimited path segment before setting this property. Alternatively use SetPath(segment[]) to set paths with / values Values cannot be empty or null. */
INTEGER Port /** (optional) The port for this URI. Some schemes assume a default (ie 80 for http) */
OpenEdge.Core.Collections.IStringStringMap QueryMap /** A map of QueryMap arguments. Set these value via AddQueryMap() */
CHARACTER QueryString /** Returns the Query string, if any */
CHARACTER RelativeURI /** Returns a relative URI (path, QueryMap et al) */
CHARACTER Scheme /** (mandatory) The schema of the URI (ie http, https etc) */
CHARACTER User /** (optional) A user for this URI */


Method Detail
Top

AddPathSegment (character)

/* Adds/appends a segment to the Path property
Will %-encode the segment value
Empty/blank segments are ignored
Parameters:
pcSegment CHARACTER
Top

AddQuery (character)

Purpose: Adds a name-only QueryMap argument. Equivalent to calling
AddQueryMap(pcname, ?).
Parameters:
pcName CHARACTER
Top

AddQuery (character, character)

Purpose: Adds a query argument
Parameters:
pcName CHARACTER
pcValue CHARACTER
Top

BuildUri ()

/* constructs a string representation
Top

CHARACTER Decode ()

Purpose: Attempts to decode a previously-encoded URL.
Returns CHARACTER
character A decoded URL
Top

CHARACTER Decode (character)

Purpose: Attempts to decode a previously-encoded string.
@throws AppError If the encoding is malformed
Parameters:
pcEncodedString CHARACTER
Returns CHARACTER
character A decoded URL
Top

CHARACTER Decode (character, character)

Purpose: Attempts to decode a previously-encoded string.
@throws AppError If the encoding is malformed
Parameters:
pEncodedString CHARACTER
pTargetCodepage CHARACTER
Returns CHARACTER
character A decoded URL
Top

CHARACTER Decode (String)

Purpose: Attempts to decode a previously-encoded string.
@throws AppError If the encoding is malformed
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
Top

CHARACTER Encode ()

Purpose: Encodes this URI
Returns CHARACTER
character An encoded version of the URI
Top

CHARACTER Encode (character, UriEncodingTypeEnum)

Purpose: Encodes a string for a particular purpose . Wrapper around Encode<encoding-type> and
EncodeString() for the Default.
Usage of Encode<encoding-type> is recommended.
Parameters:
pcString CHARACTER
poEncodingType OpenEdge.Net.UriEncodingTypeEnum
Returns CHARACTER
character the encoded string
Top

CHARACTER Encode (URI)

Purpose: Encodes a URI.
Parameters:
poURI OpenEdge.Net.URI
Returns CHARACTER
Top

CHARACTER EncodeCookie (character)

/* Encodes a string per Cookie encoding rules. This method is here for historical reasons.
Cookie US-ASCII characters excluding CTLs, whitespace (32) DQUOTE (34), comma (44), semicolon (59), and backslash (92)
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeCookie (String)

/* Encodes a string per Cookie encoding rules. This method is here for historical reasons.
Cookie US-ASCII characters excluding CTLs, whitespace (32) DQUOTE (34), comma (44), semicolon (59), and backslash (92)
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeFragment ()

/* Encodes this URI's Fragment per URI Fragment encoding rules
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeFragment (character)

/* Encodes a string per URI Fragment encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
pchar = unreserved / pct-encoded / sub-delims / ":" / "@"
Fragment : fragment = *( pchar / "/" / "?" )
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeFragment (String)

/* Encodes a string per URI Fragment encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
pchar = unreserved / pct-encoded / sub-delims / ":" / "@"
Fragment : fragment = *( pchar / "/" / "?" )
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeHost ()

/* Encodes this uri's Host per URI Host encoding rules
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeHost (character)

/* Encodes a string per URI Host encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Host = *( unreserved / pct-encoded / sub-delims )
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeHost (String)

/* Encodes a string per URI Host encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Host = *( unreserved / pct-encoded / sub-delims )
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodePath (character)

/* Encodes a string per URI Path encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Path = 1*( unreserved / pct-encoded / sub-delims / "@" )
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodePath (String)

/* Encodes a string per URI Path encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Path = 1*( unreserved / pct-encoded / sub-delims / "@" )
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeQuery ()

/* Encodes this URI's Query string per URI Query encoding rules.
Returns CHARACTER
character An encoded path string
Top

CHARACTER EncodeQuery (character)

/* Encodes a string per URI Query encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
pchar = unreserved / pct-encoded / sub-delims / ":" / "@"
Query = *( pchar / "/" / "?" )
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeQuery (String)

/* Encodes a string per URI Query encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
pchar = unreserved / pct-encoded / sub-delims / ":" / "@"
Query = *( pchar / "/" / "?" )
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeQuery (URI)

/* Encodes a URI's Path string per URI Path encoding rules.
This is a separate method since we store the Path whole and
so you cannot simply call EncodePath(uri:Path) since that
will encode the path delimiters that you need unencoded.
Parameters:
poURI OpenEdge.Net.URI
Returns CHARACTER
character An encoded path string
Top

CHARACTER EncodeScheme ()

/* Encodes this URI's scheme per URI Scheme encoding rules
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeScheme (character)

/* Encodes a string per URI Scheme encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
Scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeScheme (String)

/* Encodes a string per URI Scheme encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
Scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." )
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeString (character)

/* Encodes a string per URI Default encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
Default = unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeString (character, character, logical[128], logical)

/* Encodes a string per the input flags
Parameters:
pcString CHARACTER
pcSourceCodepage CHARACTER
pcEncodeFlags LOGICAL
plReEncode LOGICAL
Returns CHARACTER
character The encoded string
Top

CHARACTER EncodeString (String)

/* Encodes a string per URI Default encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
Default = unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeURI (URI)

Purpose: Encodes a URI.
Parameters:
poURI OpenEdge.Net.URI
Returns CHARACTER
Top

CHARACTER EncodeUserinfo ()

/* Encodes this uri's Host per URI Host encoding rules
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeUserinfo (character)

/* Encodes a string per URI userinfo encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Host = *( unreserved / pct-encoded / sub-delims / ":" )
Parameters:
pcString CHARACTER
Returns CHARACTER
character An encoded string
Top

CHARACTER EncodeUserinfo (String)

/* Encodes a string per URI userinfo encoding rules
https://tools.ietf.org/html/rfc3986#page-11 //tools.ietf.org/html/rfc3986#page-11
sub-delims = "!" / "$" / "&" / "'" / "(" / ")" / "*" / "+" / "," / ";" / "="
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
Host = *( unreserved / pct-encoded / sub-delims / ":" )
Parameters:
pString OpenEdge.Core.String
Returns CHARACTER
character An encoded string
Top

INTEGER GetPathSegments (character[])

/* Helper method to return the path as an array of segments.
Parameters:
pSegments CHARACTER
Returns INTEGER
character[] An array of path segments.
Top

INTEGER GetQueryNames (character[])

Purpose: Returns an array of query names
Parameters:
pcNames CHARACTER
Returns INTEGER
integer The number
Top

CHARACTER GetQueryValue (character)

Purpose: Get a char query value from the query
Parameters:
pcName CHARACTER
Returns CHARACTER
Top

OpenEdge.Net.URI Parse (character)

Purpose: Parses a string containing a URI and creates a URI object from it
Parameters:
pcURI CHARACTER
Returns OpenEdge.Net.URI
URI A URI representation of the string.
Top

LOGICAL RemoveQuery (character)

/* Removes a query parameter
Parameters:
pcName CHARACTER
Returns LOGICAL
logical TRUE if the named query existed (before removal)
Top

SetPath (character[])

/* Sets the Path property from an array of segments.
Will %-encode the segment values
Empty/blank segments are ignored
Parameters:
pcSegments CHARACTER
Top

CHARACTER ToString ()

Purpose: Returns a string representation of this URI
Returns CHARACTER
character The string URI


Constructor Detail
Top

STATIC URI ()

/* Static constructor. Used to build lists of to-encode character flags
Top

URI (character)

Purpose: Constructor. Defaults to HTTP scheme.
Parameters:
pcHost CHARACTER
Top

URI (character, character)

Purpose: Constructor.
Parameters:
pcScheme CHARACTER
pcHost CHARACTER
Top

URI (character, character, integer)

Purpose: Constructor.
Parameters:
pcScheme CHARACTER
pcHost CHARACTER
piPort INTEGER
Top

URI (character, character, integer, character, IStringStringMap, character)

Purpose: Constructor.
Parameters:
pcScheme CHARACTER
pcHost CHARACTER
piPort INTEGER
pcPath CHARACTER
poQueryMap OpenEdge.Core.Collections.IStringStringMap
pcFragment CHARACTER


Property Detail
Top

CHARACTER BaseURI

Purpose: Returns a base URI (scheme, host, etc)
Returns CHARACTER
Top

CHARACTER Fragment

Purpose: (optional) The URI fragment (ie trails the # at the end of the URI)
Returns CHARACTER
Top

CHARACTER Host

Purpose: (mandatory) The host name
Returns CHARACTER
Top

CHARACTER Password

Purpose: (optional) The user's password
Returns CHARACTER
Top

CHARACTER Path

Purpose: (optional) The URI path. May contain ;-delmited parameters.
If a path contains a / that value MUST be %-encoded before setting
here. Use URI:EncodePath() on each /-delimited path segment before setting
this property.
Alternatively use SetPath(segment[]) to set paths with / values
Values cannot be empty or null.
Returns CHARACTER
Top

INTEGER Port

Purpose: (optional) The port for this URI. Some schemes assume a default (ie 80 for http)
Returns INTEGER
Top

OpenEdge.Core.Collections.IStringStringMap QueryMap

Purpose: A map of QueryMap arguments. Set these value via AddQueryMap()
Returns OpenEdge.Core.Collections.IStringStringMap
Top

CHARACTER QueryString

Purpose: Returns the Query string, if any
Returns CHARACTER
Top

CHARACTER RelativeURI

Purpose: Returns a relative URI (path, QueryMap et al)
Returns CHARACTER
Top

CHARACTER Scheme

Purpose: (mandatory) The schema of the URI (ie http, https etc)
Returns CHARACTER
Top

CHARACTER User

Purpose: (optional) A user for this URI
Returns CHARACTER


Copyright © 2017 Progress Software Corporation. All rights Reserved.

Progress® OpenEdge® Release 11.7