indexing
description: "File URL"
status: "See note at end of class"
date: "$Date$"
revision: "$Revision$"
class interface
FILE_URL
create
make (a: STRING)
URLa
URL
require URL
address_specified: a /= void and then not a.is_empty
ensure URL
address_set: address = a
default_port_set: port = default_port
no_proxy_set: proxy_information = void
feature
Hash_code: INTEGER is 0
location: STRING
URL
name: FILE_NAME
port: INTEGER
URL
proxy_host: STRING
URL
require URL
proxy_supported: is_proxy_supported
has_proxy: is_proxy_used
ensure URL
result_not_empty: Result /= void and then not Result.is_empty
proxy_port: INTEGER
URL
require URL
proxy_supported: is_proxy_supported
has_proxy: is_proxy_used
ensure URL
result_non_negative: Result >= 0
Service: STRING is "file"
feature
Default_port: INTEGER is 0
Has_username: BOOLEAN is False
is_correct: BOOLEAN
URL
Is_hashable: BOOLEAN is False
Is_password_accepted: BOOLEAN is False
Is_proxy_supported: BOOLEAN is False
is_proxy_used: BOOLEAN
URL
proxy_host_ok (host: STRING): BOOLEAN
require URL
proxy_supported: is_proxy_supported
feature
reset_proxy
URL
require URL
proxy_supported: is_proxy_supported
ensure URL
no_proxy_set: not is_proxy_used
port_reset: proxy_port = 0
set_password (pw: STRING)
require URL
password_accepted: is_password_accepted
non_empty_password: pw /= void and then not pw.is_empty
set_port (port_no: INTEGER)
port_no
URL
require URL
port_non_negative: port_no >= 0
ensure URL
port_set: port = port_no
set_proxy (host: STRING; port_no: INTEGER)
hostport_no
URL
require URL
proxy_supported: is_proxy_supported
non_empty_host: host /= void and then not host.is_empty
host_valid: proxy_host_ok (host)
non_negative_port: port_no >= 0
ensure URL
host_set: proxy_host = host
port_set: proxy_port = port_no
set_proxy_information (pi: PROXY_INFORMATION)
pi
URL
require URL
proxy_supported: is_proxy_supported
ensure URL
proxy_information_set: proxy_information = pi
set_username (un: STRING)
require URL
username_ok: has_username
non_empty_username: un /= void and then not un.is_empty
invariant
ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)
URL
proxy_used_definition: is_proxy_used = (proxy_information /= void)
proxy_usage_constraint: is_proxy_used implies is_proxy_supported
end -- FILE_URL