このマニュアルは既にメンテナンスが終了したバージョンの Ruby を対象としています。 最新版のマニュアルへ

Ruby 3.0 リファレンスマニュアル

singleton method JSON::Generator::GeneratorMethods::String::Extend.json_create

json_create(hash) -> StringRuby 1.9.3 から[permalink][rdoc][edit]

JSON のオブジェクトから Ruby の文字列を生成して返します。

[PARAM] hash:
キーとして "raw" という文字列を持ち、その値として数値の配列を持つハッシュを指定します。
require 'json'
p String.json_create({"raw" => [0x41, 0x42, 0x43]}) # => "ABC"