ld-patch 3.1.2 → 3.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fe7a4c97dcc0221199b7b13feb6dbb1b1b391382e5e7a0658d3909927841d911
4
- data.tar.gz: 400b59467e176a6486751a1652470383083250999f157d233377027b1bc7a045
3
+ metadata.gz: 5d07d0448e3c60b5914fc701865a6616b8c5f060db3ace27d3faf36c7b4e4055
4
+ data.tar.gz: 4b712590d54698ed034ccfe3240a26a473903ca52cf50848e2887ee82ed607d2
5
5
  SHA512:
6
- metadata.gz: 299a418ac2b089e17943e67f21ee8edb49e972d71f878f3cf082291aa42aa95455cffe974f7826be99c11c83e52c26ececcaddb7379f9b516b60384485700323
7
- data.tar.gz: 4c6cb57eeddbdf30f070dd9ecd0422460d939efe534f4b3df97e356aff99af93502365b9b6ebde4d26bbc86fb327e0ff8dcb1c90533e1b89a82d28becbeb1cc4
6
+ metadata.gz: c7a2fd556c496f710019ad71690e942c56bad0db2cea739120ba82e87f36f6a3e2b6c9f947416c00f60cba925ef3af3296ba9fb39ea83d5cbaa355f999cfd5f0
7
+ data.tar.gz: a549e48839de8448deb97190fba247bed927a5cccd320c7b06af498f4ce356fd713a8c5adba73063c7bb39c5c1439458368f739a56397871ff42c865d040386d
data/README.md CHANGED
@@ -4,7 +4,7 @@ This is a [Ruby][] implementation of [LD Patch][] for [RDF.rb][].
4
4
 
5
5
  [![Gem Version](https://badge.fury.io/rb/ld-patch.png)](https://badge.fury.io/rb/ld-patch)
6
6
  [![Build Status](https://github.com/ruby-rdf/ld-patch/workflows/CI/badge.svg?branch=develop)](https://github.com/ruby-rdf/ld-patch/actions?query=workflow%3ACI)
7
- [![Coverage Status](https://coveralls.io/repos/ruby-rdf/ld-patch/badge.svg)](https://coveralls.io/github/ruby-rdf/ld-patch)
7
+ [![Coverage Status](https://coveralls.io/repos/ruby-rdf/ld-patch/badge.svg?branch=develop)](https://coveralls.io/github/ruby-rdf/ld-patch?branch=develop)
8
8
  [![Gitter chat](https://badges.gitter.im/ruby-rdf/rdf.png)](https://gitter.im/ruby-rdf/rdf)
9
9
 
10
10
  ## Description
data/VERSION CHANGED
@@ -1 +1 @@
1
- 3.1.2
1
+ 3.1.3
@@ -43,7 +43,7 @@ module LD::Patch::Algebra
43
43
  end
44
44
 
45
45
  # Also delete triples having var in the object position
46
- queryable.query(object: var).each do |statement|
46
+ queryable.query({object: var}).each do |statement|
47
47
  queryable.delete(statement)
48
48
  cut_count += 1
49
49
  end
@@ -52,11 +52,11 @@ module LD::Patch::Algebra
52
52
  case op
53
53
  when RDF::URI
54
54
  terms.map do |subject|
55
- queryable.query(subject: subject, predicate: op).map(&:object)
55
+ queryable.query({subject: subject, predicate: op}).map(&:object)
56
56
  end.flatten
57
57
  when SPARQL::Algebra::Query
58
58
  # Get path solutions for each term for op
59
- op.execute(queryable, options.merge(terms: terms)).map do |soln|
59
+ op.execute(queryable, **options.merge(terms: terms)).map do |soln|
60
60
  soln.path
61
61
  end.flatten
62
62
  else
@@ -31,7 +31,7 @@ module LD::Patch::Algebra
31
31
  # @see http://www.w3.org/TR/rdf-sparql-query/#sparqlAlgebra
32
32
  def execute(queryable, options = {}, &block)
33
33
  debug(options) {"Prefix"}
34
- @solutions = queryable.query(operands.last, options.merge(depth: options[:depth].to_i + 1), &block)
34
+ @solutions = queryable.query(operands.last, **options.merge(depth: options[:depth].to_i + 1), &block)
35
35
  end
36
36
 
37
37
  ##
@@ -30,7 +30,7 @@ module LD::Patch::Algebra
30
30
  terms = Array(options.fetch(:terms))
31
31
 
32
32
  results = terms.map do |object|
33
- queryable.query(object: object, predicate: op).map(&:subject)
33
+ queryable.query({object: object, predicate: op}).map(&:subject)
34
34
  end.flatten
35
35
 
36
36
  RDF::Query::Solutions.new(results.map {|t| RDF::Query::Solution.new(path: t)})
@@ -35,7 +35,7 @@ module LD::Patch::Algebra
35
35
  var_or_iri = solution[var_or_iri]
36
36
  end
37
37
 
38
- list_heads = queryable.query(subject: var_or_iri, predicate: predicate).map {|s| s.object}
38
+ list_heads = queryable.query({subject: var_or_iri, predicate: predicate}).map {|s| s.object}
39
39
 
40
40
  raise LD::Patch::Error, "UpdateList ambigious value for #{var_or_iri.to_ntriples} and #{predicate.to_ntriples}" if list_heads.length > 1
41
41
  raise LD::Patch::Error, "UpdateList no value found for #{var_or_iri.to_ntriples} and #{predicate.to_ntriples}" if list_heads.empty?
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ld-patch
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.2
4
+ version: 3.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregg Kellogg
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-12-25 00:00:00.000000000 Z
11
+ date: 2021-02-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rdf
@@ -249,7 +249,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
249
249
  - !ruby/object:Gem::Version
250
250
  version: '0'
251
251
  requirements: []
252
- rubygems_version: 3.1.4
252
+ rubygems_version: 3.2.3
253
253
  signing_key:
254
254
  specification_version: 4
255
255
  summary: W3C Linked Data Patch Format for RDF.rb.