Sha256: 2ea54cdcdb1bde272b7f153f30ad8977f9b3ea105fd6d021637d7dde7065aab6
Contents?: true
Size: 381 Bytes
Versions: 15
Compression:
Stored size: 381 Bytes
Contents
# Struct `attributes` ------ Returns the key values of the assigned struct. ```ruby person = Struct.new(:name, :age) person.new('bob', 60) person.attributes #=> { name: 'bob', age: 60 } ``` `replace` ------ Replaces values provided within the hash. ```ruby person = Struct.new(:name, :age) person.new('bob', 60) person.replace(name: 'tom', age: 28) preson.name #=> 'tom' ```
Version data entries
15 entries across 15 versions & 1 rubygems