Method: Hash#parse_object

Defined in:
lib/parse/model/object.rb

#parse_objectParse::Object

Turns a Parse formatted JSON hash into a Parse-Stack class object, if one is found. This is equivalent to calling Parse::Object.build on the hash object itself, but allows for doing this in loops, such as map when using symbol to proc. However, you can also use the Array extension ‘Array#parse_objects` for doing that more safely.

Returns:

  • (Parse::Object)

    A Parse::Object subclass represented the built class.



536
537
538
# File 'lib/parse/model/object.rb', line 536

def parse_object
  Parse::Object.build(self)
end