URI-схема файла

http://en.wikipedia.org/w/index.php?title=File_URI_scheme&action=history, “File URI scheme”, public translation into Russian from English More about this translation.

See also 3 similar translations

Translate into another language.

Participants

RusCloud548 points
Join Translated.by to translate! If you already have a Translated.by account, please sign in.
If you do not want to register an account, you can sign in with OpenID.
Pages: ← previous Ctrl next next untranslated
1 2 3 4

File URI scheme

URI-схема файла

History of edits (Latest: RusCloud 11 months ago) §

The file URI scheme is a URI scheme specified in RFC 1630 and RFC 1738, typically used to retrieve files from within one's own computer.

URI-схема файла — схема URI, определённая в документах RFC 1630 и RFC 1738. Как правило используется для обращения к файлам на своём компьютере.

History of edits (Latest: RusCloud 11 months ago) §

Format

Формат

History of edits (Latest: RusCloud 11 months ago) §

A file URL takes the form of

URL-адрес файла имеет форму

History of edits (Latest: RusCloud 11 months ago) §

file://host/path

file://host/path

History of edits (Latest: RusCloud 11 months ago) §

where host is the fully qualified domain name of the system on which the path is accessible, and path is a hierarchical directory path of the form directory/directory/.../name. If host is omitted, it is taken to be "localhost", the machine from which the URL is being interpreted. Note that when omitting host you do not omit the slash ("file:///foo.txt" is okay, while "file://foo.txt" is not, although some interpreters manage to handle the latter).

где host — полное доменное имя системы, у которой запрашивается файл, а path — иерархический путь по каталогам в формате каталог/каталог/ ... /имя_файла. Если не будет указан host, он по умолчанию будет принят как "localhost", обозначающий компьютер, на котором вводят адрес. Следует иметь ввиду, что пропуская host, слэш при этом не пропускается. То есть "file:///foo.txt" — правильно, "file://foo.txt" — неправильно. Тем не менее некоторые интерпретаторы могут скушать и последний вариант).

History of edits (Latest: RusCloud 11 months ago) §

Meaning of slash character

Смысл слэша (косой черты)

History of edits (Latest: RusCloud 11 months ago) §

The slash character (/), depending on its position, is used in different meanings in a file URL.

Символ слэш (/) в зависимости от положения в URL-адресе файла имеет разный смысл.

History of edits (Latest: RusCloud 11 months ago) §

* The // after the file: is part of the general syntax of URLs. (The double slash // should always appear in a file URL according to the specification, but in practice many Web browsers allow you to omit it, in some cases at least.)

* // после file: — часть синтаксиса URL-адреса. (Согласно спецификации двойной слэш // должен всегда быть в URL-адресе файла, однако на практике многие браузеры разрешают его пропускать.)

History of edits (Latest: RusCloud 11 months ago) §

* The single slash between host and path is part of the syntax of file URLs.

* Одиночный слэш / между host и path — часть синтаксиса URL-адреса файла.

History of edits (Latest: RusCloud 11 months ago) §

* And the slashes in path separate directory names in a hierarchical system of directories and subdirectories. In this usage, the slash is a general, system-independent way of separating the parts, and in a particular host system it might be used as such in a pathname (as in Unix systems).

* Слэши в path разделяют имена каталогов в иерархической системе каталогов и подкаталогов. В таком употреблении слэш — общий, независимый от системы способ разделения на части. На отдельной взятой операционной системе хоста слэш / может иметь тот же смысл в пути к файлу (как в системах Unix в pathname).

History of edits (Latest: RusCloud 11 months ago) §

Examples

Примеры

History of edits (Latest: RusCloud 11 months ago) §

Linux

Linux

History of edits (Latest: RusCloud 11 months ago) §

Here are two Linux examples pointing to the same /etc/fstab file:

Два примера URL-адреса на файл /etc/fstab в системе Linux:

History of edits (Latest: RusCloud 11 months ago) §

file://localhost/etc/fstab

file://localhost/etc/fstab

History of edits (Latest: RusCloud 11 months ago) §

file:///etc/fstab

file:///etc/fstab

History of edits (Latest: RusCloud 11 months ago) §

Windows

Windows

History of edits (Latest: RusCloud 11 months ago) §

Here are some examples which may be accepted by some applications on Windows systems, referring to the same, local file c:\WINDOWS\clock.avi

Примеры URL-адреса на файл c:\WINDOWS\clock.avi в системе Windows:

History of edits (Latest: RusCloud 11 months ago) §

file://localhost/c|/WINDOWS/clock.avi

file://localhost/c|/WINDOWS/clock.avi

History of edits (Latest: RusCloud 11 months ago) §

file:///c|/WINDOWS/clock.avi

file:///c:/WINDOWS/clock.avi

History of edits (Latest: RusCloud 11 months ago) §

file://localhost/c:/WINDOWS/clock.avi

file://localhost/c:/WINDOWS/clock.avi

History of edits (Latest: RusCloud 11 months ago) §

Here is the correct URI as understood by the Windows Shell API:

URI, корректный с точки зрения Windows Shell API:

History of edits (Latest: RusCloud 11 months ago) §

file:///c:/WINDOWS/clock.avi

file:///c:/WINDOWS/clock.avi

History of edits (Latest: RusCloud 11 months ago) §

For a local file, the last is the most obvious and human-readable, and also the canonical one understood by the operating system.

Для локального файла последний пример наиболее очевидный и лёгкий для восприятия. Его каноническая форма понятна и для операционной системы.

History of edits (Latest: RusCloud 11 months ago) §

Things to consider

Некоторые особенности на рассмотрение

History of edits (Latest: RusCloud 11 months ago) §

Windows

Windows

History of edits (Latest: RusCloud 11 months ago) §

On MS Windows systems, the normal colon (:) after a device letter has sometimes been replaced by a vertical bar (|) in file URLs. This reflected the original URL syntax, which made the colon a reserved character in a path part.

В Windows обыкновенное двоеточие (:) в URL-адресе файла после буквы устройства иногда заменено вертикальной чертой (|). Таким образом воспроизведён первоначальный URL-синтаксис, который сделал двоеточие зарезервированным символом в части path.

History of edits (Latest: RusCloud 11 months ago) §
Pages: ← previous Ctrl next next untranslated
1 2 3 4