964件ヒット
[1-100件を表示]
(0.064秒)
種類
- 特異メソッド (773)
- インスタンスメソッド (143)
- 定数 (48)
ライブラリ
- ビルトイン (964)
キーワード
-
ALT
_ SEPARATOR (12) -
PATH
_ SEPARATOR (12) - SEPARATOR (12)
- Separator (12)
-
absolute
_ path (12) -
absolute
_ path? (6) - atime (24)
- basename (12)
- birthtime (22)
- blockdev? (12)
- chardev? (12)
- chmod (24)
- chown (24)
- ctime (24)
- delete (12)
- directory? (12)
- dirname (12)
- empty? (9)
- executable? (12)
-
executable
_ real? (12) - exist? (12)
- exists? (9)
- extname (12)
- file? (12)
- flock (12)
- fnmatch (12)
- fnmatch? (12)
- ftype (12)
- grpowned? (12)
- identical? (12)
- join (12)
- lchmod (12)
- lchown (12)
- link (12)
- lstat (24)
- lutime (8)
- mkfifo (10)
- mtime (24)
- new (12)
- open (24)
- owned? (12)
- path (24)
- pipe? (12)
- readable? (12)
-
readable
_ real? (12) - readlink (12)
- realdirpath (12)
- realpath (12)
- rename (12)
- setgid? (12)
- setuid? (12)
- size (24)
- size? (12)
- socket? (12)
- split (12)
- stat (12)
- sticky? (12)
- symlink (12)
- symlink? (12)
-
to
_ path (12) - truncate (24)
- umask (24)
- unlink (12)
- utime (12)
-
world
_ readable? (12) -
world
_ writable? (12) - writable? (12)
-
writable
_ real? (12) - zero? (12)
検索結果
先頭5件
-
File
. delete(*filename) -> Integer (9201.0) -
ファイルを削除します。削除したファイルの数を返します。 削除に失敗した場合は例外 Errno::EXXX が発生します。
...m filename ファイル名を表す文字列を指定します。
@raise Errno::EXXX 失敗した場合に発生します。
//emlist[例][ruby]{
IO.write("test.txt", "test")
p File.exist?("test.txt") # => true
p File.delete("test.txt") # => 1
p File.exist?("test.txt") # => false
begin
File.......delete("test.txt")
rescue
p $! # => #<Errno::ENOENT: No such file or directory @ unlink_internal - test.txt>
end
//}... -
File
. executable?(path) -> bool (9101.0) -
FileTest.#executable? と同じです。
...
FileTest.#executable? と同じです。
@param path パスを表す文字列を指定します。... -
File
. executable _ real?(path) -> bool (9101.0) -
FileTest.#executable_real? と同じです。
...
FileTest.#executable_real? と同じです。
@param path パスを表す文字列を指定します。... -
File
. file?(path) -> bool (9101.0) -
FileTest.#file? と同じです。
...
FileTest.#file? と同じです。
@param path パスを表す文字列か IO オブジェクトを指定します。... -
File
. readable?(path) -> bool (9101.0) -
FileTest.#readable? と同じです。
...
FileTest.#readable? と同じです。
@param path パスを表す文字列か IO オブジェクトを指定します。... -
File
. readable _ real?(path) -> bool (9101.0) -
FileTest.#readable_real? と同じです。
...
FileTest.#readable_real? と同じです。
@param path パスを表す文字列か IO オブジェクトを指定します。... -
File
. unlink(*filename) -> Integer (9101.0) -
ファイルを削除します。削除したファイルの数を返します。 削除に失敗した場合は例外 Errno::EXXX が発生します。
...m filename ファイル名を表す文字列を指定します。
@raise Errno::EXXX 失敗した場合に発生します。
//emlist[例][ruby]{
IO.write("test.txt", "test")
p File.exist?("test.txt") # => true
p File.delete("test.txt") # => 1
p File.exist?("test.txt") # => false
begin
File.......delete("test.txt")
rescue
p $! # => #<Errno::ENOENT: No such file or directory @ unlink_internal - test.txt>
end
//}... -
File
. world _ readable?(path) -> Integer | nil (9101.0) -
path が全てのユーザから読めるならばそのファイルのパーミッションを表す 整数を返します。そうでない場合は nil を返します。
...返します。そうでない場合は nil を返します。
整数の意味はプラットフォームに依存します。
@param path パスを表す文字列か IO オブジェクトを指定します。
//emlist[例][ruby]{
m = File.world_readable?("/etc/passwd")
"%o" % m... -
File
. world _ writable?(path) -> bool (9101.0) -
path が全てのユーザから書き込めるならば、そのファイルのパーミッションを表す 整数を返します。そうでない場合は nil を返します。
...返します。そうでない場合は nil を返します。
整数の意味はプラットフォームに依存します。
@param path パスを表す文字列か IO オブジェクトを指定します。
//emlist[例][ruby]{
m = File.world_writable?("/tmp")
"%o" % m...