class method
JSON.create_id=
(::_ToS create_id) -> ::_ToS
create_id=(new_value)
ext/json/lib/json/common.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.0.0/ext/json/lib/json/common.rb, line 228
def self.create_id=(new_value)
Thread.current[:"JSON.create_id"] = new_value.dup.freeze
end
Sets create identifier, which is used to decide if the json_create hook of a class should be called; initial value is json_class:
Example
JSON.create_id # => 'json_class'
See also
.create_id
.deprecated_singleton_attr_accessor
.[]
.on_mixed_keys_hash
also in
3.4 · 3.3 · 3.2 · 3.1 · 3.0