Sha256: 3616a78388272d259e5fd7e1bd0febfe15ad4565f3a6a783c7c985d249035066
Contents?: true
Size: 1.07 KB
Versions: 28
Compression:
Stored size: 1.07 KB
Contents
{ "schema_type": "object", "schema_version": "1.0", "name": "slice", "path": "packages/ree_hash/package/ree_hash/functions/slice.rb", "mount_as": "fn", "class": "ReeHash::Slice", "factory": null, "methods": [ { "doc": "Replaces the hash with only the given keys.\nReturns a hash containing the removed key/value pairs.\n\n hash = { a: 1, b: {e: 2, f: 1}, c: 3, d: 4 }\n slice(hash, [:a, :b]) # => {a: 1, b: 2}\n slice(hash, [:a, b: [:e]]) # => {a: 1, b: {e: 2}}", "throws": [ "ReeHash::Slice::MissingKeyErr", "ReeHash::Slice::InvalidFilterKey" ], "return": "Hash", "args": [ { "arg": "hash", "type": "Hash" }, { "arg": "keys", "type": "[:key0, .., :keyM => [:keyN, .., :keyZ]]" }, { "arg": "opts", "type": "Ksplat[:raise? => Bool]" } ] } ], "links": [ { "target": "build_filter_keys", "package_name": "ree_hash", "as": "build_filter_keys", "imports": [ ] } ] }
Version data entries
28 entries across 28 versions & 1 rubygems