active_any 0.0.4 → 0.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e8f0f6be0c590ca667a1c62e6b24c2354597201c
4
- data.tar.gz: 8895030ab834a80199bfd73dce24d33b86a21ad6
3
+ metadata.gz: 7bce4c099011efca225f189fd83ea2cca319d59b
4
+ data.tar.gz: 8b696b3147b302128b675d11358a12deb8bb94ad
5
5
  SHA512:
6
- metadata.gz: b003bd481d71a28fff409b1bf50148ee1a1b026bc9a404570de84ded22769e42fadf81c96b5006e82b4ee68a254e15cf477a976feef36da68e3514e6f2032218
7
- data.tar.gz: dfbf059cd768d49f45a23aa1bc36af8f2048067616b832e41d99d404fb712820914cb69f9009e51c40022f4ef54d38e742071208a234450f4c73833f9d528b68
6
+ metadata.gz: 3c90267f62743a6472b16da2f165acdd26e8b7a71e83bbd9fea34de3e3edb3ef376afc9957baaf018d8ba60e24b1d1eadda2b98833fe013cc728a6a47b5d0aad
7
+ data.tar.gz: b36851cd8b79fda86ee9cbebd1460239a2ad0b2237b2aec22d46ff0c5d4a596aa5e45dfa898ee6ec634a8cba7f04ae60d9af0a114c1c605fd9671abcad75aba2
@@ -14,7 +14,7 @@ module ActiveAny
14
14
  end
15
15
  end
16
16
 
17
- def query(_where_clause, _limit_value = nil, _group_values = [], _order_values = [])
17
+ def query(*)
18
18
  raise NotImplementedError.new, "#{self.class.name} can not handle for #{value.class}"
19
19
  end
20
20
  end
@@ -3,14 +3,14 @@
3
3
  module ActiveAny
4
4
  class ObjectAdapter < AbstractAdapter
5
5
  def query(where_clause: Relation::WhereClause.empty, order_clause: Relation::OrderClause.empty, limit_value: nil, group_values: [])
6
- records = select_handler(@klass.data, where_clause)
6
+ records = where_handler(klass.data, where_clause)
7
7
  records = group_handler(records, group_values)
8
8
  records = limit_handler(records, limit_value)
9
9
  records = order_handler(records, order_clause)
10
10
  records
11
11
  end
12
12
 
13
- def select_handler(records, where_clause)
13
+ def where_handler(records, where_clause)
14
14
  records.select do |record|
15
15
  where_clause.all? do |condition|
16
16
  condition.evaluate(self, record)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveAny
4
- VERSION = '0.0.4'
4
+ VERSION = '0.0.5'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_any
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - yuemori