名前¶
URI::Split - Parse and compose URI strings
URI::Split - URI 文字列をパースおよび構成する
概要¶
use URI::Split qw(uri_split uri_join);
($scheme, $auth, $path, $query, $frag) = uri_split($uri);
$uri = uri_join($scheme, $auth, $path, $query, $frag);
説明¶
Provides functions to parse and compose URI strings. The following functions are provided:
URI 文字列のパースおよび構成を行う関数を提供します。 次の関数が提供されます:
- ($scheme, $auth, $path, $query, $frag) = uri_split($uri)
-
Breaks up a URI string into its component parts. An
undefvalue is returned for those parts that are not present. The $path part is always present (but can be the empty string) and is thus never returned asundef.URI 文字列を構成要素に分解します。 要素がない部分に対しては
undefが返されます。 $path 部分は常に存在する (但し空文字列のことはあります) ので、undefを返すことはありません。No sensible value is returned if this function is called in a scalar context.
この関数がスカラコンテキストで呼び出されると、 特に意味のある値は返しません。
- $uri = uri_join($scheme, $auth, $path, $query, $frag)
-
Puts together a URI string from its parts. Missing parts are signaled by passing
undeffor the corresponding argument.URI の要素から文字列を作り上げます。 存在しない部分に対しては、対応する引数として
undefを渡すことで示します。Minimal escaping is applied to parts that contain reserved chars that would confuse a parser. For instance, any occurrence of '?' or '#' in $path is always escaped, as it would otherwise be parsed back as a query or fragment.
パーサを混乱させる予約文字を含む部分には最小限のエスケープが行われます。 例えば、$path にある '?' や '#' は常にエスケープされます; さもなければクエリやフラグメントとしてパースされるかもしれないからです。
SEE ALSO¶
コピーライト¶
Copyright 2003, Gisle Aas
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.