4件ヒット
[1-4件を表示]
(0.051秒)
検索結果
-
Dir
# tell -> Integer (45628.0) -
ディレクトリストリームの現在の位置を整数で返します。
ディレクトリストリームの現在の位置を整数で返します。
@raise IOError 既に自身が close している場合に発生します。
//emlist[例][ruby]{
Dir.open("/tmp") {|d|
d.each {|f|
p d.pos
}
}
//} -
IO
# tell -> Integer (45628.0) -
ファイルポインタの現在の位置を整数で返します。
ファイルポインタの現在の位置を整数で返します。
@raise IOError 既に close されている場合に発生します。
//emlist[例][ruby]{
IO.write("testfile", "This is line one\n")
File.open("testfile") do |f|
f.pos # => 0
f.gets # => "This is line one\n"
f.pos # => 17
end
//} -
Dir
# pos -> Integer (328.0) -
ディレクトリストリームの現在の位置を整数で返します。
ディレクトリストリームの現在の位置を整数で返します。
@raise IOError 既に自身が close している場合に発生します。
//emlist[例][ruby]{
Dir.open("/tmp") {|d|
d.each {|f|
p d.pos
}
}
//} -
IO
# pos -> Integer (328.0) -
ファイルポインタの現在の位置を整数で返します。
ファイルポインタの現在の位置を整数で返します。
@raise IOError 既に close されている場合に発生します。
//emlist[例][ruby]{
IO.write("testfile", "This is line one\n")
File.open("testfile") do |f|
f.pos # => 0
f.gets # => "This is line one\n"
f.pos # => 17
end
//}