83件ヒット
[1-83件を表示]
(0.051秒)
種類
- インスタンスメソッド (32)
- 特異メソッド (22)
- ライブラリ (11)
- クラス (11)
- 文書 (7)
クラス
- File (21)
-
File
:: Stat (22) -
WIN32OLE
_ VARIABLE (11)
キーワード
-
NEWS for Ruby 2
. 5 . 0 (7) - Stat (11)
- birthtime (10)
-
ole
_ type _ detail (11) - tsort (11)
- utime (11)
検索結果
先頭5件
-
NEWS for Ruby 2
. 5 . 0 (26066.0) -
NEWS for Ruby 2.5.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...NEWS for Ruby 2.5.0
このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
それぞれのエントリーは参照情報があるため短いです。
十分な情報と共に書かれた全ての変更のリス......Dir.glob :base というキーワード引数を追加しました 13056
* Dir.chdir (ブロックなしで呼び出した場合), Dir.open, Dir.new, Dir.mkdir, Dir.rmdir,
Dir.empty? はGVLを解放するようになりました
* Dir.children を追加 11302
* Dir.each_child を......するようになりました
13941
* File.rename GVL を解放するようになりました 13951
* File::Stat#atime, File::Stat#mtime, File::Stat#ctime
Windows 8 以降でタイムスタンプの分数表現をサポートしました 13726
* File::Stat#ino, File.identica... -
File
:: Stat # mtime -> Time (18113.0) -
最終更新時刻を返します。
...最終更新時刻を返します。
//emlist[][ruby]{
fs = File::Stat.new($0)
#例
p fs.mtime #=> Wed Sep 05 20:42:18 +0900 2007
//}
@see Time... -
File
:: Stat . new(path) -> File :: Stat (18113.0) -
path に関する File::Stat オブジェクトを生成して返します。 File.stat と同じです。
..."C:/Program Files/ruby-1.8/lib/ruby/site_ruby/1.8"
p File::Stat.new($:[0])
#=> 例
#<File::Stat dev=0x2, ino=0, mode=040755, nlink=1, uid=0, gid=0, rdev=0x2, size=0, blksize=nil, blocks=nil, atime=Sun Sep 02 14:15:20 +0900 2007, mtime=Tue Apr 24 23:03:44 +0900 2007, ctime=Tue Apr 24 23:03:37 +0900... -
File
. utime(atime , mtime , *filename) -> Integer (143.0) -
ファイルの最終アクセス時刻と更新時刻を変更します。 シンボリックリンクに対しては File.lutime と違って、 シンボリックのリンク先を変更します。
...刻を変更します。
@param atime 最終アクセス時刻を Time か、起算時からの経過秒数を数値で指定します。
@param mtime 更新時刻を Time か、起算時からの経過秒数を数値で指定します。
@param filename ファイル名を表す文字列を指定......。
//emlist[例: Time を指定][ruby]{
atime = Time.new(2018, 1, 2, 3, 4, 5)
mtime = Time.new(2018, 2, 3, 4, 5, 6)
File.utime(atime, mtime, "testfile") # => 1
File.atime("testfile") # => 2018-01-02 03:04:05 +0900
File.mtime("testfile") # => 2018-02-03 04:05:06 +0900......//}
//emlist[例: 経過秒数で指定][ruby]{
File.utime(1, 2, "testfile") # => 1
File.atime("testfile") # => 1970-01-01 09:00:01 +0900
File.mtime("testfile") # => 1970-01-01 09:00:02 +0900
//}......先を変更します。
@param atime 最終アクセス時刻を Time か、起算時からの経過秒数を数値で指定します。
@param mtime 更新時刻を Time か、起算時からの経過秒数を数値で指定します。
@param filename ファイル名を表す文字列を指定......//}
//emlist[例: 経過秒数で指定][ruby]{
File.utime(1, 2, "testfile") # => 1
File.atime("testfile") # => 1970-01-01 09:00:01 +0900
File.mtime("testfile") # => 1970-01-01 09:00:02 +0900
//}
@see File.lutime... -
tsort (24.0)
-
tsort はトポロジカルソートと強連結成分に関するモジュールを提供します。
...raise TSort::Cyclic.new("cyclic dependencies: #{fs.join ', '}")
end
n = ns.first
if Array === n
outputs, inputs, block = n
inputs_time = inputs.map {|f| File.mtime f}.max
begin
outputs_time = outputs.map {|f| File.mtime f}.min
rescue E......tsort_each_child(node, &block)
@dep[node].each(&block)
end
include TSort
end
def command(arg)
print arg, "\n"
system arg
end
m = Make.new
m.rule(%w[t1]) { command 'date > t1' }
m.rule(%w[t2]) { command 'date > t2' }
m.rule(%w[t3]) { command 'date > t3' }
m.rule(%w[t4], %w[t1 t3]) { co... -
File
# birthtime -> Time (12.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
:: Stat (12.0) -
ファイルの情報を格納したオブジェクトのクラス。
...。ただ、
ファイル名を引数に取るかわりに Stat 自身について判定する点が違います。
//emlist[][ruby]{
p File::Stat.new($0).directory? #=> false
p FileTest.directory?($0) #=> false
//}
1.8 以降では、属性メソッドがシステムでサポートされていな......lksize 望ましいI/Oのブロックサイズ
blocks 割り当てられているブロック数
atime 最終アクセス時刻
mtime 最終更新時刻
ctime 最終状態変更時刻(状態の変更とは chmod などによるもので、Unix では i-node の変... -
WIN32OLE
_ VARIABLE # ole _ type _ detail -> [String] (12.0) -
変数の型と属性を取得します。
...変数の型と属性を取得します。
@return 変数の型と属性を文字列配列で返します。
tobj = WIN32OLE_TYPE.new('Microsoft XML, v5.0', 'tagSTATSTG')
tobj.variables.each do |v|
puts "#{v.ole_type} [#{v.ole_type_detail.join(', ')}] #{v.name}"
end
出力結果......Tで未定義なので変換できない
UI4 [UI4] type
_ULARGE_INTEGER [USERDEFINED, _ULARGE_INTEGER] cbSize
_FILETIME [USERDEFINED, _FILETIME] mtime
_FILETIME [USERDEFINED, _FILETIME] ctime
_FILETIME [USERDEFINED, _FILETIME] atime
UI4 [UI4] grfMode
UI4 [UI4] grfLocksSupported
GUID [USERDEF...