Ruby/Справочник/File: различия между версиями

Содержимое удалено Содержимое добавлено
м Категоризация по запросу на w:ВП:РДБ
мНет описания правки
Строка 189:
Matches any one character. Equivalent to <tt>/.{1}/</tt> in regexp.
Matches any one character in <tt>set</tt>. Behaves exactly like character sets in Regexp, including set negation (<tt>[^a-z]</tt>).
Escapes the next metacharacter.{{АкмарКонец рамки}}
<i>flags</i> is a bitwise OR of the <tt>FNM_xxx</tt> parameters. The same glob pattern and flags are used by <tt>Dir::glob</tt>.
<code>File.fnmatch('cat', 'cat') #=&gt; true
Строка 225:
Matches any one character. Equivalent to <tt>/.{1}/</tt> in regexp.
Matches any one character in <tt>set</tt>. Behaves exactly like character sets in Regexp, including set negation (<tt>[^a-z]</tt>).
Escapes the next metacharacter.{{АкмарКонец рамки}}
<i>flags</i> is a bitwise OR of the <tt>FNM_xxx</tt> parameters. The same glob pattern and flags are used by <tt>Dir::glob</tt>.
<code>File.fnmatch('cat', 'cat') #=&gt; true