1586件ヒット
[201-300件を表示]
(0.232秒)
ライブラリ
- ビルトイン (1580)
-
shell
/ command-processor (6)
クラス
- Data (14)
- Dir (303)
- Encoding (11)
-
Encoding
:: Converter (66) - Enumerator (23)
-
Enumerator
:: Chain (6) -
Enumerator
:: Lazy (11) - File (480)
-
File
:: Stat (11) - IO (143)
- Random (44)
- Regexp (33)
- RubyVM (1)
-
RubyVM
:: InstructionSequence (31) -
Shell
:: CommandProcessor (6) - SystemExit (11)
- Thread (30)
- Time (47)
- TracePoint (10)
モジュール
- GC (55)
-
GC
:: Profiler (22) - Process (29)
-
RubyVM
:: AbstractSyntaxTree (8) - Warning (13)
キーワード
- [] (20)
- []= (5)
-
abort
_ on _ exception= (11) -
absolute
_ path (11) -
absolute
_ path? (5) -
asciicompat
_ encoding (22) - atime (11)
- binread (11)
- binwrite (11)
- blockdev? (11)
- chardev? (11)
- chdir (33)
- children (14)
- chroot (11)
- compatible? (11)
- compile (11)
-
def
_ builtin _ commands (6) - define (4)
- delete (11)
-
delete
_ if (11) - directory? (11)
- each (11)
-
each
_ child (28) -
each
_ key (11) -
each
_ pair (11) -
each
_ value (11) - empty? (16)
- entries (22)
- executable? (11)
-
executable
_ real? (11) - exist? (11)
- exists? (9)
- exit (11)
- exit! (11)
- file? (11)
- filter (6)
- filter! (6)
- fnmatch (11)
- fnmatch? (11)
- foreach (66)
- glob (22)
- grpowned? (11)
-
handle
_ interrupt (11) -
keep
_ if (11) -
last
_ match (22) -
last
_ status (7) -
latest
_ gc _ info (22) -
load
_ from _ binary _ extra _ data (9) - lstat (11)
- lutime (7)
- members (2)
- mkdir (11)
- new (138)
- open (66)
- owned? (11)
-
parse
_ file (8) - path (11)
- pipe? (11)
- private (23)
- produce (5)
- rand (33)
-
raw
_ data (11) - read (33)
- readable? (11)
-
readable
_ real? (11) - readlines (33)
- readlink (11)
- realdirpath (11)
- realpath (11)
- reject (11)
- reject! (11)
-
report
_ on _ exception= (8) -
resolve
_ feature _ path (1) - rmdir (11)
-
search
_ convpath (11) - select (11)
- select! (11)
- setgid? (11)
- setuid? (11)
- size (11)
- size? (11)
- socket? (11)
- split (11)
- start (11)
- stat (43)
- state (11)
- sticky? (11)
- symlink? (11)
- sysopen (11)
-
total
_ time (11) - truncate (11)
- union (11)
- unlink (11)
- update (22)
- utime (11)
-
values
_ at (11) - warn (3)
-
world
_ readable? (11) -
world
_ writable? (11) - writable? (11)
-
writable
_ real? (11) - write (22)
- zero? (11)
検索結果
先頭5件
-
Encoding
:: Converter . asciicompat _ encoding(encoding) -> Encoding | nil (14101.0) -
同じ文字集合を持つ ASCII 互換エンコーディングを返します。
...ングでない場合は nil を返します。
//emlist[][ruby]{
Encoding::Converter.asciicompat_encoding("ISO-2022-JP") #=> #<Encoding:stateless-ISO-2022-JP>
Encoding::Converter.asciicompat_encoding("UTF-16BE") #=> #<Encoding:UTF-8>
Encoding::Converter.asciicompat_encoding("UTF-8") #=> nil
//}... -
Encoding
:: Converter . asciicompat _ encoding(string) -> Encoding | nil (14101.0) -
同じ文字集合を持つ ASCII 互換エンコーディングを返します。
...ングでない場合は nil を返します。
//emlist[][ruby]{
Encoding::Converter.asciicompat_encoding("ISO-2022-JP") #=> #<Encoding:stateless-ISO-2022-JP>
Encoding::Converter.asciicompat_encoding("UTF-16BE") #=> #<Encoding:UTF-8>
Encoding::Converter.asciicompat_encoding("UTF-8") #=> nil
//}... -
File
. absolute _ path(file _ name , dir _ string=nil) -> String (14101.0) -
file_name を絶対パスに変換した文字列を返します。
....expand_path と異なり、 file_name 先頭が "~" である場合
それは展開されません。普通のディレクトリ名として処理されます。
//emlist[例][ruby]{
p Dir.getwd #=> "/home/matz/work/bar"
p ENV["HOME"] #=> "/home/matz"
p File.......absolute_path("..") #=> "/home/matz/work"
p File.absolute_path("..", "/tmp") #=> "/"
p File.absolute_path("~") #=> "/home/matz/work/bar/~"
p File.absolute_path("~foo") #=> "/home/matz/work/bar/~foo"
//}
@see File.expand_path... -
File
. absolute _ path?(file _ name) -> bool (14101.0) -
file_name が絶対パスなら true を、そうでなければ false を返します。
...合は、to_path メソッド、to_str メソッドの順で暗黙の型変換が試みられます。
@raise TypeError 引数に文字列以外の(暗黙の型変換が行えない)オブジェクトを指定した場合に発生します。
//emlist[例][ruby]{
File.absolute_path?("//foo/bar......\\baz") # => true
File.absolute_path?("C:foo\\bar") # => false
File.absolute_path?("~") # => false
# プラットフォームが cygwin、mswin、mingw の場合
File.absolute_path?("C:\\foo\\bar") # => true
File.absolute_path?("/foo/bar\\baz") # => false
# プラットフォ......ームが上記以外の場合
File.absolute_path?("C:\\foo\\bar") # => false
File.absolute_path?("/foo/bar\\baz") # => true
//}... -
File
. atime(filename) -> Time (14101.0) -
最終アクセス時刻を返します。
...セス時刻を返します。
@param filename ファイル名を表す文字列か IO オブジェクトを指定します。
@raise Errno::EXXX ファイルの時刻の取得に失敗した場合に発生します。
//emlist[例][ruby]{
File.atime(__FILE__) # => 2017-11-28 22:38:44 +0900
//}... -
File
. path(filename) -> String (14101.0) -
指定されたファイル名を文字列で返します。filename が文字列でない場合は、to_path メソッドを呼びます。
...は、to_path メソッドを呼びます。
@param filename ファイル名を表す文字列か to_path メソッドが定義されたオブジェクトを指定します。
//emlist[例][ruby]{
require 'pathname'
class MyPath
def initialize(path)
@path = path
end
def to_path
File.......absolute_path(@path)
end
end
File.path("/dev/null") # => "/dev/null"
File.path(Pathname("/tmp")) # => "/tmp"
File.path(MyPath.new(".")) # => "/Users/user/projects/txt"
//}... -
GC
. latest _ gc _ info(key) -> object (14101.0) -
最新のGCの情報を返します。
...ます。
//emlist[例][ruby]{
latest = GC.latest_gc_info
latest # => {:major_by=>nil, :gc_by=>:newobj, :have_finalizer=>false, :immediate_sweep=>false, :state=>:sweeping}
stat = GC.stat
merged = GC.latest_gc_info(stat)
merged == latest.merge(stat) # => true
GC.latest_gc_info(:gc_by) # => :new... -
GC
. latest _ gc _ info(result _ hash = {}) -> Hash (14101.0) -
最新のGCの情報を返します。
...ます。
//emlist[例][ruby]{
latest = GC.latest_gc_info
latest # => {:major_by=>nil, :gc_by=>:newobj, :have_finalizer=>false, :immediate_sweep=>false, :state=>:sweeping}
stat = GC.stat
merged = GC.latest_gc_info(stat)
merged == latest.merge(stat) # => true
GC.latest_gc_info(:gc_by) # => :new... -
GC
. stat(key) -> Numeric (14101.0) -
GC 内部の統計情報を Hash で返します。
...場合は数値を返します。
GC.stat
# =>
{
:count=>2,
:heap_used=>9,
:heap_length=>11,
:heap_increment=>2,
:heap_live_slot=>6836,
:heap_free_slot=>519,
:heap_final_slot=>0,
:heap_swept_slot=>818,
:total_allocated_object=>7674,
:total_freed_object=......で返します。
引数 key を指定した場合は数値を返します。
GC.stat
# =>
{
:count=>0,
:heap_allocated_pages=>24,
:heap_sorted_length=>24,
:heap_allocatable_pages=>0,
:heap_available_slots=>9783,
:heap_live_slots=>7713,
:heap_free_......heap_marked_slots=>0,
:heap_swept_slots=>0,
:heap_eden_pages=>24,
:heap_tomb_pages=>0,
:total_allocated_pages=>24,
:total_freed_pages=>0,
:total_allocated_objects=>7796,
:total_freed_objects=>83,
:malloc_increase_bytes=>2389312,
:malloc_increase_bytes_lim... -
GC
. stat(result _ hash = {}) -> {Symbol => Integer} (14101.0) -
GC 内部の統計情報を Hash で返します。
...で返します。
引数 key を指定した場合は数値を返します。
GC.stat
# =>
{
:count=>0,
:heap_allocated_pages=>24,
:heap_sorted_length=>24,
:heap_allocatable_pages=>0,
:heap_available_slots=>9783,
:heap_live_slots=>7713,
:heap_free_......heap_marked_slots=>0,
:heap_swept_slots=>0,
:heap_eden_pages=>24,
:heap_tomb_pages=>0,
:total_allocated_pages=>24,
:total_freed_pages=>0,
:total_allocated_objects=>7796,
:total_freed_objects=>83,
:malloc_increase_bytes=>2389312,
:malloc_increase_bytes_lim...