Load custom marshal format, re-initializing defaults as needed
Recursively walk dependencies of this spec, executing the block
for each hop.
Set
the version to version
.
Display an informational alert. Will ask question
if it is not nil.
Returns an array of syntax error messages
If no missing pairs are found it falls back on the original error messages
Returns the parser to be used.
Unless a URI::Parser is defined, DEFAULT_PARSER is used.
Sets userinfo, argument is string like ‘name:pass’.
v
Public setter for the user
component (with validation).
See also URI::Generic.check_user
.
require 'uri' uri = URI.parse("http://john:S3nsit1ve@my.example.com") uri.user = "sam" uri.to_s #=> "http://sam:V3ry_S3nsit1ve@my.example.com"
Returns the userinfo, either as ‘user’ or ‘user:password’.
Returns the user component (without URI
decoding).
v
Public setter for the query component v
.
require 'uri' uri = URI.parse("http://my.example.com/?id=25") uri.query = "id=1" uri.to_s #=> "http://my.example.com/?id=1"
Returns true if URI
is hierarchical.
URI
has components listed in order of decreasing significance from left to right, see RFC3986 www.rfc-editor.org/rfc/rfc3986 1.2.3.
require 'uri' uri = URI.parse("http://my.example.com/") uri.hierarchical? #=> true uri = URI.parse("mailto:joe@example.com") uri.hierarchical? #=> false
Attempts to parse other URI
oth
, returns [parsed_oth, self].
require 'uri' uri = URI.parse("http://my.example.com") uri.coerce("http://foo.com") #=> [#<URI::HTTP http://foo.com>, #<URI::HTTP http://my.example.com>]
Returns filter.
Setter for filter val
.
Setter for headers v
.
Returns a Hash
(not a DBM
database) created by using each value in the database as a key, with the corresponding key as its value.
Note that all values in the hash will be Strings, but the keys will be actual objects.
Returns the number of the signal that caused the process to terminate or nil
if the process was not terminated by an uncaught signal.