ライブラリ
- ビルトイン (1708)
-
cgi
/ core (33) -
cgi
/ html (22) -
cgi
/ session (44) - csv (88)
- digest (11)
- erb (33)
- fiddle (11)
-
irb
/ cmd / load (33) -
irb
/ context (11) -
irb
/ ext / save-history (22) -
irb
/ frame (11) -
irb
/ input-method (88) - logger (22)
- mkmf (77)
-
net
/ ftp (265) -
net
/ http (121) -
net
/ pop (22) -
net
/ smtp (33) - openssl (77)
- optparse (11)
- pathname (406)
- psych (11)
- rake (473)
-
rake
/ gempackagetask (11) -
rake
/ loaders / makefile (11) -
rake
/ packagetask (66) -
rake
/ rdoctask (33) -
rake
/ testtask (11) -
rdoc
/ code _ object (11) -
rdoc
/ context (33) -
rdoc
/ generator / json _ index (11) -
rdoc
/ parser (11) -
rdoc
/ stats (22) -
rdoc
/ top _ level (66) - ripper (11)
-
ripper
/ filter (11) -
rubygems
/ commands / build _ command (22) -
rubygems
/ config _ file (242) -
rubygems
/ format (22) -
rubygems
/ gem _ path _ searcher (22) -
rubygems
/ indexer (33) -
rubygems
/ installer (66) -
rubygems
/ old _ format (22) -
rubygems
/ package / tar _ reader / entry (11) -
rubygems
/ package / tar _ writer (44) -
rubygems
/ remote _ fetcher (44) -
rubygems
/ require _ paths _ builder (11) -
rubygems
/ source _ info _ cache (99) -
rubygems
/ spec _ fetcher (11) -
rubygems
/ specification (132) -
rubygems
/ validator (11) - shell (330)
-
shell
/ builtin-command (12) -
shell
/ command-processor (330) -
shell
/ filter (336) - socket (22)
- stringio (11)
- tempfile (88)
- tracer (33)
- un (44)
-
webrick
/ httprequest (11) -
webrick
/ httpresponse (44) -
webrick
/ httpservlet / filehandler (88) -
webrick
/ httputils (22) - win32ole (33)
- zlib (341)
クラス
-
ARGF
. class (132) - BasicObject (22)
- Binding (17)
-
CGI
:: Session :: FileStore (44) - CSV (88)
- Class (11)
-
Digest
:: Base (11) - Dir (21)
- ERB (33)
-
Fiddle
:: Function (11) - File (131)
-
File
:: Stat (462) -
Gem
:: Commands :: BuildCommand (22) -
Gem
:: ConfigFile (242) -
Gem
:: Format (22) -
Gem
:: GemPathSearcher (22) -
Gem
:: Indexer (33) -
Gem
:: Installer (66) -
Gem
:: OldFormat (22) -
Gem
:: Package :: TarReader :: Entry (11) -
Gem
:: Package :: TarWriter (44) -
Gem
:: RemoteFetcher (44) -
Gem
:: SourceInfoCache (99) -
Gem
:: SpecFetcher (11) -
Gem
:: Specification (132) -
Gem
:: Validator (11) - IO (789)
-
IRB
:: Context (33) -
IRB
:: ExtendCommand :: Load (11) -
IRB
:: ExtendCommand :: Require (11) -
IRB
:: ExtendCommand :: Source (11) -
IRB
:: FileInputMethod (22) -
IRB
:: Frame (11) -
IRB
:: InputMethod (22) -
IRB
:: ReadlineInputMethod (22) -
IRB
:: StdioInputMethod (22) - LoadError (11)
- Logger (11)
-
Logger
:: LogDevice (11) - Method (23)
-
Net
:: FTP (238) -
Net
:: FTP :: MLSxEntry (27) -
Net
:: HTTP (77) -
Net
:: HTTPGenericRequest (22) -
Net
:: HTTPResponse (22) -
Net
:: POP3 (22) -
Net
:: SMTP (33) - Object (11)
-
OpenSSL
:: Config (11) -
OpenSSL
:: SSL :: SSLContext (44) -
OpenSSL
:: X509 :: ExtensionFactory (11) -
OpenSSL
:: X509 :: Store (11) - OptionParser (11)
- Pathname (406)
- Proc (12)
-
Psych
:: SyntaxError (11) -
RDoc
:: CodeObject (11) -
RDoc
:: Context (33) -
RDoc
:: Generator :: JsonIndex (11) -
RDoc
:: Options (44) -
RDoc
:: Parser (11) -
RDoc
:: Stats (22) -
RDoc
:: TopLevel (66) -
Rake
:: Application (22) -
Rake
:: DefaultLoader (11) -
Rake
:: FileCreationTask (22) -
Rake
:: FileList (242) -
Rake
:: FileTask (22) -
Rake
:: GemPackageTask (11) -
Rake
:: MakefileLoader (11) -
Rake
:: PackageTask (66) -
Rake
:: RDocTask (33) -
Rake
:: TestTask (11) - Ripper (11)
-
Ripper
:: Filter (11) -
RubyVM
:: InstructionSequence (44) - Shell (330)
-
Shell
:: AppendFile (6) -
Shell
:: CommandProcessor (330) -
Shell
:: Filter (336) -
Shell
:: Glob (6) -
Socket
:: AncillaryData (11) - String (22)
- StringIO (11)
- Tempfile (88)
- Tracer (33)
- UNIXSocket (11)
-
WEBrick
:: HTTPRequest (11) -
WEBrick
:: HTTPResponse (44) -
WEBrick
:: HTTPServlet :: DefaultFileHandler (44) -
WEBrick
:: HTTPServlet :: FileHandler (44) -
WEBrick
:: HTTPUtils :: FormData (22) -
WIN32OLE
_ METHOD (22) -
WIN32OLE
_ TYPE (11) -
Zlib
:: GzipFile (143) -
Zlib
:: GzipFile :: Error (22) -
Zlib
:: GzipReader (22) -
Zlib
:: GzipWriter (154)
モジュール
-
CGI
:: HtmlExtension (22) -
CGI
:: QueryExtension (33) - Enumerable (11)
- FileUtils (44)
-
Gem
:: RequirePathsBuilder (11) - Kernel (154)
-
Rake
:: Cloneable (22) -
Rake
:: TaskManager (11) - RakeFileUtils (33)
キーワード
- * (11)
- << (34)
- <=> (11)
- == (11)
- > (6)
- >> (18)
- [] (29)
- []= (11)
-
absolute
_ path (11) -
add
_ file (33) -
add
_ file _ simple (22) -
add
_ row (11) - advise (11)
-
all
_ one _ file (11) - append (18)
- args (11)
- ascend (22)
- atime (51)
- backtrace (11)
- backtrace= (11)
-
base
_ label (11) - basename (29)
- benchmark (11)
- benchmark= (11)
- birthtime (31)
- blksize (11)
- blockdev? (29)
- blocks (11)
-
body
_ stream (11) -
body
_ stream= (11) -
bulk
_ threshold (11) -
bulk
_ threshold= (11) -
ca
_ file (22) -
ca
_ file= (22) -
cache
_ file (11) - call (11)
- cat (18)
-
cert
_ store= (22) - chardev? (29)
- chmod (51)
- chown (40)
- chunk (11)
- cleanpath (11)
-
clear
_ exclude (11) - clone (22)
- close (55)
- close! (11)
-
close
_ on _ exec= (11) - closed? (22)
- comment (11)
- comment= (11)
- compress (11)
- config= (11)
-
config
_ file _ name (11) -
content
_ length (11) -
content
_ length= (11) - count (11)
-
cpp
_ command (11) - crc (11)
-
create
_ body (11) -
create
_ makefile (11) - ctime (51)
-
def
_ class (11) -
defined
_ in? (11) - delete (51)
-
delete
_ all (22) - descend (22)
- dev (11)
-
dev
_ major (11) -
dev
_ minor (11) - directory? (29)
- dirname (29)
-
do
_ GET (22) -
do
_ OPTIONS (11) -
do
_ POST (11) - download (11)
-
dummy
_ makefile (11) - dup (22)
- each (94)
-
each
_ byte (22) -
each
_ char (22) -
each
_ codepoint (22) -
each
_ filename (11) -
each
_ line (66) - echo (18)
- egrep (11)
- encoding (11)
- eof (11)
- eof? (33)
- eval (11)
- exclude (11)
-
excluded
_ from _ list? (11) - executable? (29)
-
executable
_ real? (29) - execute (33)
- exist? (18)
- existing (11)
- existing! (11)
- exists? (18)
- ext (11)
-
external
_ encoding (11) - extname (11)
-
extra
_ rdoc _ files (11) -
extra
_ rdoc _ files= (11) -
extract
_ files (11) - facts (9)
- fcntl (11)
- fdatasync (11)
- file (44)
- file? (60)
-
file
_ absolute _ name (11) -
file
_ absolute _ name= (11) -
file
_ create (11) -
file
_ entries (22) -
file
_ entries= (22) -
file
_ field (22) -
file
_ input? (11) -
file
_ name (22) -
file
_ relative _ name (11) -
file
_ relative _ name= (11) -
file
_ stat (11) -
file
_ stat= (11) -
file
_ uri? (11) - fileboxes (11)
- filename (77)
- filename= (33)
- fileno (54)
- files (33)
- files= (11)
- finish (22)
- flock (22)
- flush (22)
- fnmatch (11)
- fnmatch? (11)
- foreach (18)
-
formatted
_ program _ filename (11) - formatter (11)
- ftype (40)
-
gem
_ file (11) -
gem
_ file _ list (11) - generate (11)
-
generate
_ bin _ script (11) -
generate
_ bin _ symlink (11) -
generate
_ windows _ script (11) - get (44)
-
get
_ file _ uri _ path (11) -
get
_ line (11) - getbinaryfile (22)
- getbyte (22)
- getc (22)
- gets (44)
- gettextfile (22)
- gid (11)
- glob (18)
- grpowned? (29)
- gsub (11)
- gsub! (11)
- gzip (11)
-
handle
_ arguments (11) - hash (11)
- helpfile (22)
- helpstring (11)
-
history
_ file (11) -
history
_ file= (11) - import (22)
-
in
_ files (11) - include (11)
-
inline
_ source (11) - ino (11)
-
inplace
_ mode= (11) - input (11)
- input= (6)
- inspect (11)
-
install
_ files (11) -
install
_ rb (11) -
instance
_ eval (22) -
internal
_ encoding (11) -
is
_ a? (11) - isatty (11)
- join (18)
-
kind
_ of? (11) - label (11)
-
latest
_ cache _ file (11) -
latest
_ system _ cache _ file (11) -
latest
_ user _ cache _ file (11) - lchmod (11)
- lchown (11)
- length (11)
- level (11)
-
lib
_ files (11) - lineno (22)
- lineno= (11)
- link (18)
- load (33)
-
load
_ file (11) -
load
_ gemspecs (11) -
load
_ rakefile (11) -
load
_ specs (11) - lstat (40)
- main= (11)
-
make
_ link (11) -
make
_ partial _ content (11) -
make
_ symlink (11) -
matching
_ file? (11) -
matching
_ files (11) - mdtm (11)
- mlsd (18)
- mode (11)
- mtime (73)
- mtime= (11)
- needed? (22)
- nlink (11)
-
not
_ modified? (11) - nowrite (11)
-
num
_ files (11) -
num
_ files= (11) - open (51)
-
open
_ uri _ or _ path (11) -
orig
_ name (11) -
orig
_ name= (11) -
os
_ code (11) - out (18)
- owned? (29)
-
package
_ files (11) -
package
_ files= (11) - parameters (11)
-
parent
_ file _ name (11) -
parse
_ files _ matching (11) - path (77)
- path= (11)
- pathmap (22)
- pipe? (29)
- pos (22)
- pos= (11)
- post (22)
- pread (7)
-
prepare
_ range (11) - print (11)
- printf (11)
- put (22)
- putbinaryfile (22)
- putc (11)
- puts (22)
- puttextfile (22)
- pwrite (7)
- query (11)
- rakefile (11)
- rdev (11)
-
rdev
_ major (11) -
rdev
_ minor (11) -
rdoc
_ files (11) -
rdoc
_ files= (11) - read (22)
-
read
_ body (22) -
read
_ cache _ data (11) - readable? (29)
-
readable
_ atfer _ eof? (33) -
readable
_ real? (29) - readbyte (22)
- readchar (33)
- readline (44)
- readlines (33)
- readlink (29)
-
really
_ verbose (11) - realpath (22)
-
record
_ location (11) -
recv
_ io (11) - rename (29)
- reopen (33)
-
reset
_ cache _ file (11) - resolve (11)
-
respond
_ to? (11) - restore (11)
- rewind (11)
- rm (29)
-
rm
_ f (11) -
rm
_ rf (11) - ruby (11)
-
safe
_ ln (11) - seek (11)
-
send
_ mail (11) - sendmail (11)
- service (11)
-
set
_ encoding (33) -
set
_ encoding _ by _ bom (5) -
set
_ get _ line _ procs (11) -
set
_ params (11) - setgid? (29)
- setuid? (29)
- sh (11)
- shebang (11)
- size (62)
- size? (29)
- socket? (29)
-
source
_ location (6) - split (29)
-
split
_ all (11) - stat (51)
- sticky? (29)
- storbinary (22)
- storlines (22)
- sub (11)
- sub! (11)
- superclass (11)
- symlink (18)
- symlink? (29)
- sync (22)
- sync= (11)
-
synthesize
_ file _ task (11) - sysread (11)
- sysseek (11)
-
system
_ cache _ file (11) - syswrite (11)
-
tar
_ bz2 _ file (11) -
tar
_ gz _ file (11) - tee (18)
- tell (22)
- test (18)
-
test
_ file (11) -
test
_ file= (11) -
test
_ files (11) -
test
_ files= (22) -
test
_ suite _ file (11) -
test
_ suite _ file= (11) -
tgz
_ file (11) -
to
_ a (11) -
to
_ ary (11) -
to
_ i (33) -
to
_ io (22) -
to
_ path (22) -
to
_ s (22) - touch (11)
-
trace
_ func (22) - truncate (51)
-
try
_ file (11) - tty? (11)
- type (9)
- uid (11)
-
unescape
_ filename? (11) - ungetbyte (11)
- ungetc (11)
-
unix
_ rights (11) - unlink (29)
- update (11)
-
update
_ sources (11) -
update
_ sources= (11) -
user
_ cache _ file (11) - utime (29)
- verbose (22)
- verbose= (11)
-
verify
_ gem _ file (11) -
wait
_ writable (11) -
when
_ writing (11) -
world
_ readable? (11) -
world
_ writable? (11) - writable? (29)
-
writable
_ real? (29) - write (33)
-
write
_ require _ paths _ file _ if _ needed (11) - yaml? (11)
- zero? (29)
-
zip
_ file (11)
検索結果
先頭5件
-
File
# lstat -> File :: Stat (21148.0) -
ファイルの状態を含む File::Stat オブジェクトを生成して返します。 シンボリックリンクに関してリンクそのものの情報を返します。 lstat(2) を実装していないシステムでは、IO#statと同じです。
...ファイルの状態を含む File::Stat オブジェクトを生成して返します。
シンボリックリンクに関してリンクそのものの情報を返します。
lstat(2) を実装していないシステムでは、IO#statと同じです。
@raise Errno::EXXX 失敗した場合......ose されている場合に発生します。
//emlist[例][ruby]{
# testlink は testfile のシンボリックリンク
File.open("testlink") do |f|
p f.lstat == File.stat("testfile") # => false
p f.stat == File.stat("testfile") # => true
end
//}
@see IO#stat, File.stat, File.lstat... -
File
# flock(operation) -> 0 | false (21121.0) -
ファイルをロックします。
...をロックします。
ロックを取得するまでブロックされます。
ロックの取得に成功した場合は 0 を返します。
File::LOCK_NB (ノンブロッキング) を指定すると、本来ならブロックされる場合に
ブロックされずに false を返すよう......eration に有効な定数は以下の通りです。定数は File::Constants で定義されていますが、
File クラスの親クラスの IO が File::Constants をインクルードしているので、
これらの定数は File::LOCK_SH などとして参照可能です。
: LOCK_SH
共......ブロックモード。
File::LOCK_SH | File::LOCK_NB のように他の指定と or することで指
定します。この指定がない場合、ブロックされる条件での flock
の呼び出しはロックが解除されるまでブロックされます。
File::LOCK_NB の指定が... -
File
# path -> String (21043.0) -
オープン時に使用したパスを文字列で返します。
...Error TMPFILE File::Constants::TMPFILEオプション付きで作成されている場合に発生します。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path } #=> "testfile"
File.open("/tmp/../tmp/xxx", "w") {|f| f.path } #=> "/tmp/../tmp/xxx"
File.open("/......tmp", File::RDWR | File::TMPFILE){|f| f.path } # IOError: File is unnamed (TMPFILE?)
//}... -
File
# to _ path -> String (21043.0) -
オープン時に使用したパスを文字列で返します。
...Error TMPFILE File::Constants::TMPFILEオプション付きで作成されている場合に発生します。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path } #=> "testfile"
File.open("/tmp/../tmp/xxx", "w") {|f| f.path } #=> "/tmp/../tmp/xxx"
File.open("/......tmp", File::RDWR | File::TMPFILE){|f| f.path } # IOError: File is unnamed (TMPFILE?)
//}... -
File
# path -> String (21037.0) -
オープン時に使用したパスを文字列で返します。
...、
File::Constants::TMPFILEオプション付きで作成されていたりする場合です。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path } #=> "testfile"
File.open("/tmp/../tmp/xxx", "w") {|f| f.path } #=> "/tmp/../tmp/xxx"
File.open("/tmp", File::R......DWR | File::TMPFILE){|f| f.path } #=> "/tmp"
//}... -
File
# to _ path -> String (21037.0) -
オープン時に使用したパスを文字列で返します。
...、
File::Constants::TMPFILEオプション付きで作成されていたりする場合です。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path } #=> "testfile"
File.open("/tmp/../tmp/xxx", "w") {|f| f.path } #=> "/tmp/../tmp/xxx"
File.open("/tmp", File::R......DWR | File::TMPFILE){|f| f.path } #=> "/tmp"
//}... -
File
# atime -> Time (21031.0) -
最終アクセス時刻を Time オブジェクトとして返します。
...に発生します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例:][ruby]{
IO.write("testfile", "test")
File.open("testfile") { |f| f.atime } # => 2017-12-21 22:58:17 +0900
//}
@see File#lstat, File#ctime, File#mtime, File#birthtime... -
File
# birthtime -> Time (21031.0) -
作成された時刻を Time オブジェクトとして返します。
...::EXXX ファイルの時刻の取得に失敗した場合に発生します。
@raise NotImplementedError Windows のような birthtime のない環境で発生します。
File.new("testfile").birthtime #=> Wed Apr 09 08:53:14 CDT 2003
@see File#lstat, File#atime, File#ctime, File#mtime... -
File
# ctime -> Time (21031.0) -
状態が最後に変更された時刻を Time オブジェクトとして返します。状態の変更とは chmod などによるものです。
...に発生します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例:][ruby]{
IO.write("testfile", "test")
File.open("testfile") { |f| f.ctime } # => 2017-12-21 22:58:17 +0900
//}
@see File#lstat, File#atime, File#mtime, File#birthtime... -
File
# mtime -> Time (21031.0) -
最終更新時刻を Time オブジェクトとして返します。
...に発生します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例:][ruby]{
IO.write("testfile", "test")
File.open("testfile") { |f| f.mtime } # => 2017-12-21 22:58:17 +0900
//}
@see File#lstat, File#atime, File#ctime, File#birthtime... -
File
# atime -> Time (21025.0) -
最終アクセス時刻を Time オブジェクトとして返します。
...れている場合に発生します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例:][ruby]{
IO.write("testfile", "test")
File.open("testfile") { |f| f.atime } # => 2017-12-21 22:58:17 +0900
//}
@see File#lstat, File#ctime, File#mtime... -
File
# chown(owner , group) -> 0 (21025.0) -
ファイルのオーナーとグループを変更します。
...ます。
@raise Errno::EXXX 変更に失敗した場合に発生します。
//emlist[例][ruby]{
File.open("testfile") { |f| f.chown(502, 1000) } # => 0
File.stat("testfile").uid # => 502
File.stat("testfile").gid # => 1000
//}
@see File.chown... -
File
# ctime -> Time (21025.0) -
状態が最後に変更された時刻を Time オブジェクトとして返します。状態の変更とは chmod などによるものです。
...れている場合に発生します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例:][ruby]{
IO.write("testfile", "test")
File.open("testfile") { |f| f.ctime } # => 2017-12-21 22:58:17 +0900
//}
@see File#lstat, File#atime, File#mtime... -
File
# mtime -> Time (21025.0) -
最終更新時刻を Time オブジェクトとして返します。
...ている場合に発生します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例:][ruby]{
IO.write("testfile", "test")
File.open("testfile") { |f| f.mtime } # => 2017-12-21 22:58:17 +0900
//}
@see File#lstat, File#atime, File#ctime... -
File
# size -> Integer (21013.0) -
ファイルのサイズを返します。
...ファイルのサイズを返します。
//emlist[例][ruby]{
File.open("/dev/null") do |f|
f.size #=> 0
end
//}
@raise IOError 自身が close されている場合に発生します。
@raise Errno::EXXX 失敗した場合に発生します。
@see File#lstat...