Class URL
Specialises on the URL subset of URIs and provides extended parsing of the authority part, namely a hostname (or IP address), explicit port number and login credentials (further split up into username and password).
In general, a server-based authority is in the form of user [":" password]
"@" host [":" port]. The host part is mandatory, all other parts and their
delimiters are optional and initialised to null
, if not specified.
For security reasons the complete authority is automatically in-memory encrypted, if login credentials with a non-empty password are contained.
History
In Medusa 3.0, the initial draft of this class was named Server
and was
later renamed to the current name in 3.1.
- Core\Object implements Core\Chainable
- Core\Set implements Core\Accessor
- Core\URI
- Core\URI\URL
Direct known subclasses
Core\URI\Driver\file
,
Core\URI\Driver\ftp
,
Core\URI\Driver\http
,
Core\URI\Driver\ssl
,
Core\URI\Driver\tcp
Package: Core\URI
Since: 3.1
Requires: PHP 5.3
Version: 1.1
Located at URI/URL.inc.php
Methods summary
public
|
Methods inherited from Core\URI
__toString()
,
_parseArray()
,
_parseURI()
,
autocreate()
,
cloneWithAppendedParameters()
,
decode()
,
encode()
,
isAbsolute()
,
parameters()
,
remoteURIForPath()
,
validate()
Methods inherited from Core\Object
__autocreateFactory()
,
__call()
,
__processParameters()
,
attachMethod()
,
chain()
,
getValueForKey()
,
getValueForKeyPath()
,
getValueForUndefinedKey()
,
hash()
,
issetValueForKey()
,
setValueForKey()
,
setValueForKeyPath()
,
setValueForUndefinedKey()
,
uuid()
Constants summary
Constants inherited from Core\Object
AnyParameterType
,
AutochainParameterType
,
AutocreateParameterType
,
BooleanParameterType
,
CharParameterType
,
EnumParameterType
,
IntegerParameterType
,
RealParameterType
,
StringParameterType
,
UserParameterType
Properties summary
protected
string
|
$_v_user
KVC property. |
|
protected
|
$_v_password
KVC property. |
|
protected
string
|
$_v_host
KVC property. |
|
protected
integer
|
$_v_port
KVC property. |
Properties inherited from Core\URI
$_parameterCache
,
$_v_authority
,
$_v_fragment
,
$_v_path
,
$_v_query
,
$_v_scheme
,
$_v_schemeNS
Magic properties
public read-only
string
|
$user
Username extracted from authority part or |
public read-only
|
$password
In-memory encrypted password extracted from authority part or |
public read-only
string
|
$host
Hostname extracted from authority part or |
public read-only
integer
|
$port
Port number extracted from authority part or |
Magic properties inherited from Core\URI
$authority
,
$fragment
,
$isAbsolute
,
$parameters
,
$path
,
$query
,
$scheme
,
$schemeNS