22件ヒット
[1-22件を表示]
(0.104秒)
ライブラリ
- ビルトイン (11)
-
json
/ add / rational (11)
クラス
- Rational (22)
検索結果
-
Rational
# hash -> Integer (27108.0) -
自身のハッシュ値を返します。
...自身のハッシュ値を返します。
@return ハッシュ値を返します。
@see Object#hash... -
Rational
# to _ json(*args) -> String (9037.0) -
自身を JSON 形式の文字列に変換して返します。
...JSON::Generator::GeneratorMethods::Hash#to_json を呼び出しています。
@param args 使用しません。
//emlist[例][ruby]{
require 'json/add/rational'
Rational(1, 3).to_json # => "{\"json_class\":\"Rational\",\"n\":1,\"d\":3}"
//}
@see JSON::Generator::GeneratorMethods::Hash#to_json......eneratorMethods::Hash#to_json を呼び出しています。
@param args 引数はそのまま JSON::Generator::GeneratorMethods::Hash#to_json
に渡されます。
//emlist[例][ruby]{
require 'json/add/rational'
Rational(1, 3).to_json # => "{\"json_class\":\"Rational\",\"n\":1,\"d\":......3}"
//}
@see JSON::Generator::GeneratorMethods::Hash#to_json...