Module: Tmux::FilterableHash Private

Defined in:
lib/tmux/filterable_hash.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Instance Method Summary (collapse)

Instance Method Details

- (Hash) filter(search)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



7
8
9
10
11
12
13
# File 'lib/tmux/filterable_hash.rb', line 7

def filter(search)
  self.select { |key, value|
    value.all? { |v_key, v_value|
      !search.has_key?(v_key) || v_value == search[v_key]
    }
  }
end