8件ヒット
[1-8件を表示]
(0.021秒)
種類
- インスタンスメソッド (7)
- クラス (1)
クラス
- Pathname (7)
キーワード
- Pathname (1)
- binread (1)
- readable? (1)
-
readable
_ real? (1) - readlines (1)
- readlink (1)
-
world
_ readable? (1)
検索結果
先頭5件
-
Pathname
# read(*args) -> String | nil (54376.0) -
IO.read(self.to_s, *args)と同じです。
IO.read(self.to_s, *args)と同じです。
@see IO.read -
Pathname
# binread(*args) -> String | nil (18307.0) -
IO.binread(self.to_s, *args)と同じです。
...じです。
//emlist[例][ruby]{
require "pathname"
pathname = Pathname("testfile")
pathname.binread # => "This is line one\nThis is line two\nThis is line three\nAnd so on...\n"
pathname.binread(20) # => "This is line one\nThi"
pathname.binread(20, 10) # => "ne one\nThis is lin... -
Pathname
# readable? -> bool (18307.0) -
FileTest.readable?(self.to_s) と同じです。
FileTest.readable?(self.to_s) と同じです。
@see FileTest.#readable? -
Pathname
# readable _ real? -> bool (18307.0) -
FileTest.readable_real?(self.to_s) と同じです。
FileTest.readable_real?(self.to_s) と同じです。
@see FileTest.#readable_real? -
Pathname
# readlines(*args) -> [String] (18307.0) -
IO.readlines(self.to_s, *args)と同じです。
IO.readlines(self.to_s, *args)と同じです。
@see IO.readlines -
Pathname
# readlink -> Pathname (18307.0) -
Pathname.new(File.readlink(self.to_s)) と同じです。
...Pathname.new(File.readlink(self.to_s)) と同じです。
@see File.readlink... -
Pathname
# world _ readable? -> bool (18307.0) -
FileTest.world_readable?(self.to_s) と同じです。
FileTest.world_readable?(self.to_s) と同じです。
@see FileTest.#world_readable? -
Pathname (25.0)
-
パス名をオブジェクト指向らしく扱うクラスです。
...クラスです。
Pathname オブジェクトはパス名を表しており、ファイルやディレクトリそのものを表してはいません。
当然、存在しないファイルのパス名も扱えます。
絶対パスも相対パスも扱えます。
Pathname オブジェクト......るメソッドはありません。
Pathname のインスタンスメソッドには、ディレクトリのパスを返す Pathname#dirname のように、
文字列操作だけで結果を返すものもあれば、ファイルの中身を読み出す Pathname#read のように
ファイルシ......ムにアクセスするものもあります。
Pathname オブジェクトの生成には、Pathname.new のほかに Kernel#Pathname も使えます。
//emlist[例][ruby]{
require 'pathname'
Pathname.new("foo/bar") # => #<Pathname:foo/bar>
Pathname("foo/bar") # => #<Pathname:foo/bar>
//}...