lib/retentiongrid/resource.rb
# Return all attributes as a hash
# @return [Hash]
Return all attributes as a hash
Return all attributes as a hash
def attributes
      self.class::ATTRIBUTES_NAMES.inject({}) do |attribs, attrib_name|
        value = self.send(attrib_name)
        attribs[attrib_name] = value unless value.nil?
        attribs
      end
    end
def attributes self . class :: ATTRIBUTES_NAMES . inject ( { } ) do | attribs , attrib_name | value = self . send ( attrib_name ) attribs [ attrib_name ] = value unless value . nil? attribs end end
Return all attributes as a hash
Return all attributes as a hash
None
Hash