ライブラリ
- ビルトイン (66)
- mkmf (22)
-
rdoc
/ context (11) - socket (77)
-
win32
/ registry (22)
クラス
- File (33)
- Module (22)
- Object (11)
-
RDoc
:: Context (11) - Socket (11)
-
Socket
:: AncillaryData (66) -
Win32
:: Registry (22)
モジュール
- Kernel (22)
キーワード
-
class
_ variables (11) -
connect
_ nonblock (11) -
convertible
_ int (22) - flock (11)
-
instance
_ variables (11) -
ip
_ pktinfo (11) -
ipv6
_ pktinfo (11) -
ipv6
_ pktinfo _ addr (11) -
ipv6
_ pktinfo _ ifindex (11) - path (11)
- read (11)
-
to
_ path (11) -
unix
_ rights (11) - write (11)
検索結果
先頭5件
-
Module
# constants(inherit = true) -> [Symbol] (18162.0) -
そのモジュール(またはクラス)で定義されている定数名の配列を返します。
...ます。
Object のサブクラスの場合、Objectやそのスーパークラスで定義されている
定数は含まれません。 Object.constants とすると Object クラスで定義された
定数の配列が得られます。
得られる定数の順序は保証されません。
@p......dule.constants, Kernel.#local_variables, Kernel.#global_variables, Object#instance_variables, Module#class_variables
//emlist[Module.constants と Module#constants の違い][ruby]{
# 出力の簡略化のため起動時の定数一覧を取得して後で差し引く
$clist = Module.constants
cla......s Bar
BAR = 1
# Bar は BAR を含む
p constants # => [:BAR]
# 出力に FOO は含まれない
p Module.constants - $clist # => [:BAR, :Bar, :Foo]
class Baz
# Baz は定数を含まない
p constants # => []
# ネス... -
RDoc
:: Context # constants -> [RDoc :: Constant] (18102.0) -
追加された RDoc::Constant の配列を返します。
追加された RDoc::Constant の配列を返します。 -
Socket
:: AncillaryData # timestamp -> Time (37.0) -
タイムスタンプ制御メッセージに含まれる時刻を Time オブジェクト で返します。
...00
p t.usec #=> 775581
p t.nsec #=> 775581000
}
}
@see Socket::Constants::SCM_TIMESTAMP,
Socket::Constants::SCM_TIMESTAMPNS,
Socket::Constants::SCM_BINTIME,
Socket::Constants::SO_TIMESTAMP,
Socket::Constants::SO_TIMESTAMPNS,
Socket::Constants::SO_BINTIME... -
Kernel
# convertible _ int(type , headers = nil , opts = nil) (17.0) -
Returns the convertible integer type of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. _Convertible_ means actually same type, or typedefed from same type. If the +type+ is a integer type and _convertible_ type is found, following macros are passed as preprocessor constants to the compiler using the +type+ name, in uppercase. * 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X' is the found _convertible_ type name. * 'TYP2NUM' and 'NUM2TYP, where 'TYP' is the +type+ name in uppercase with replacing '_t' suffix with 'T', followed by '=X' where 'X' is the macro name to convert +type+ to +Integer+ object, and vice versa. For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return "unsigned long", and define macros: #define TYPEOF_FOOBAR_T unsigned long #define FOOBART2NUM ULONG2NUM #define NUM2FOOBART NUM2ULONG
...pe, or typedefed from same type.
If the +type+ is a integer type and _convertible_ type is found,
following macros are passed as preprocessor constants to the
compiler using the +type+ name, in uppercase.
* 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X'
is the found _c... -
Kernel
# convertible _ int(type , headers = nil , opts = nil) { . . . } (17.0) -
Returns the convertible integer type of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. _Convertible_ means actually same type, or typedefed from same type. If the +type+ is a integer type and _convertible_ type is found, following macros are passed as preprocessor constants to the compiler using the +type+ name, in uppercase. * 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X' is the found _convertible_ type name. * 'TYP2NUM' and 'NUM2TYP, where 'TYP' is the +type+ name in uppercase with replacing '_t' suffix with 'T', followed by '=X' where 'X' is the macro name to convert +type+ to +Integer+ object, and vice versa. For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return "unsigned long", and define macros: #define TYPEOF_FOOBAR_T unsigned long #define FOOBART2NUM ULONG2NUM #define NUM2FOOBART NUM2ULONG
...pe, or typedefed from same type.
If the +type+ is a integer type and _convertible_ type is found,
following macros are passed as preprocessor constants to the
compiler using the +type+ name, in uppercase.
* 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X'
is the found _c... -
File
# flock(operation) -> 0 | false (13.0) -
ファイルをロックします。
...に発生します。
引数 operation に有効な定数は以下の通りです。定数は File::Constants で定義されていますが、
File クラスの親クラスの IO が File::Constants をインクルードしているので、
これらの定数は File::LOCK_SH などとして参... -
Module
# class _ variables(inherit = true) -> [Symbol] (13.0) -
クラス/モジュールに定義されているクラス変数の名前の配列を返します。
...d
class Two < One
@@var2 = 2
end
One.class_variables # => [:@@var1]
Two.class_variables # => [:@@var2, :@@var1]
Two.class_variables(false) # => [:@@var2]
//}
@see Module.constants, Kernel.#local_variables, Kernel.#global_variables, Object#instance_variables, Module#constants... -
Object
# instance _ variables -> [Symbol] (13.0) -
オブジェクトのインスタンス変数名をシンボルの配列として返します。
...列として返します。
//emlist[][ruby]{
obj = Object.new
obj.instance_eval { @foo, @bar = nil }
p obj.instance_variables
#=> [:@foo, :@bar]
//}
@see Object#instance_variable_get, Kernel.#local_variables, Kernel.#global_variables, Module.constants, Module#constants, Module#class_variables... -
File
# path -> String (7.0) -
オープン時に使用したパスを文字列で返します。
...ファイルを指しているとは限りません。
たとえば、ファイルが移動されていたり、削除されていたり、
File::Constants::TMPFILEオプション付きで作成されていたりする場合です。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path }......ません。
たとえば、ファイルが移動されていたり、削除されていたりする場合です。
@raise IOError TMPFILE File::Constants::TMPFILEオプション付きで作成されている場合に発生します。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path }... -
File
# to _ path -> String (7.0) -
オープン時に使用したパスを文字列で返します。
...ません。
たとえば、ファイルが移動されていたり、削除されていたりする場合です。
@raise IOError TMPFILE File::Constants::TMPFILEオプション付きで作成されている場合に発生します。
//emlist[例][ruby]{
File.open("testfile") {|f| f.path }...