Class: ArelExtensions::Nodes::JsonGet
Constant Summary
Constants inherited from JsonNode
ArelExtensions::Nodes::JsonNode::RETURN_TYPE
Constants inherited from Function
Instance Attribute Summary collapse
-
#key ⇒ Object
Returns the value of attribute key.
Attributes inherited from JsonNode
Instance Method Summary collapse
-
#initialize(json, key) ⇒ JsonGet
constructor
A new instance of JsonGet.
Methods inherited from JsonNode
#get, #group, #hash, #merge, #set
Methods inherited from Function
#!=, #==, #as, #convert_to_date_node, #convert_to_datetime_node, #convert_to_node, #convert_to_number, #convert_to_string_node, #expr, #left, #return_type, #right, #type_of_attribute
Methods included from Predications
#cast, #convert_to_node, #imatches, #in, #matches, #not_in, #when
Constructor Details
#initialize(json, key) ⇒ JsonGet
Returns a new instance of JsonGet.
88 89 90 91 |
# File 'lib/arel_extensions/nodes/json.rb', line 88 def initialize json, key @dict = json @key = convert_to_node(key) end |
Instance Attribute Details
#key ⇒ Object
Returns the value of attribute key.
86 87 88 |
# File 'lib/arel_extensions/nodes/json.rb', line 86 def key @key end |