active_triples-mongoid_strategy 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.coveralls.yml +1 -0
- data/.gitignore +10 -0
- data/.travis.yml +16 -0
- data/AUTHORS +1 -0
- data/Gemfile +3 -0
- data/LICENSE +12 -0
- data/README.md +48 -0
- data/active_triples-mongoid.gemspec +35 -0
- data/lib/active_triples/mongoid_strategy.rb +97 -0
- data/lib/active_triples/mongoid_strategy/version.rb +5 -0
- data/spec/active_triples/persistence_strategies/mongoid_strategy_spec.rb +144 -0
- data/spec/spec_helper.rb +30 -0
- data/spec/support/shared_examples/mongoid_strategy.rb +36 -0
- data/spec/support/shared_examples/persistence_strategy.rb +22 -0
- metadata +186 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 22af17eaa429dc4f0ba5da01fbb6d3ad532c178b
|
4
|
+
data.tar.gz: f4970070d0d69869df6b540d330df6ef9e7d12ab
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: d7466df581b75490179329e68b88192846bb996745ef0a867259e36636ca512616d7a4168e641f930c38b13137541d7d63d8f80fd6f296d53f9715c5fdb7e04d
|
7
|
+
data.tar.gz: 41122d3427e8a5506d996d074925dd165c4a3801509e3872916c77fb0b091c15729618a47c6ac53badebb5c0da920c9f153728bd3b5e67ec04a29b7f884a12c6
|
data/.coveralls.yml
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
service_name: travis-ci
|
data/.gitignore
ADDED
data/.travis.yml
ADDED
@@ -0,0 +1,16 @@
|
|
1
|
+
language: ruby
|
2
|
+
bundler_args: --without debug
|
3
|
+
script: "bundle exec rspec spec"
|
4
|
+
sudo: false
|
5
|
+
cache: bundler
|
6
|
+
rvm:
|
7
|
+
- 2.0
|
8
|
+
- 2.1
|
9
|
+
- 2.2.4
|
10
|
+
- 2.3.0
|
11
|
+
- jruby-9.0.4.0
|
12
|
+
- rbx-2
|
13
|
+
matrix:
|
14
|
+
allow_failures:
|
15
|
+
- rvm: jruby-9.0.4.0
|
16
|
+
- rvm: rbx-2
|
data/AUTHORS
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
* MJ Suhonos (mj@suhonos.ca)
|
data/Gemfile
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
##########################################################################
|
2
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
3
|
+
# you may not use this file except in compliance with the License.
|
4
|
+
# You may obtain a copy of the License at
|
5
|
+
#
|
6
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
7
|
+
#
|
8
|
+
# Unless required by applicable law or agreed to in writing, software
|
9
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
10
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
11
|
+
# See the License for the specific language governing permissions and
|
12
|
+
# limitations under the License.
|
data/README.md
ADDED
@@ -0,0 +1,48 @@
|
|
1
|
+
# ActiveTriples::MongoidStrategy
|
2
|
+
|
3
|
+
[![Build Status](https://travis-ci.org/ActiveTriples/active_triples-mongoi.png?branch=master)](https://travis-ci.org/ActiveTriples/active_triples-mongoid_strategy)
|
4
|
+
[![Coverage Status](https://coveralls.io/repos/ActiveTriples/active_triples-mongoid_strategy/badge.png?branch=master)](https://coveralls.io/r/ActiveTriples/active_triples-mongoid_strategy?branch=master)
|
5
|
+
[![Gem Version](https://badge.fury.io/rb/active_triples-mongoid_strategy.svg)](http://badge.fury.io/rb/active_triples-mongoid_strategy)
|
6
|
+
|
7
|
+
Provides a graph-based persistence strategy for the [ActiveTriples](https://github.com/ActiveTriples/ActiveTriples) framework. `ActiveTriples::RDFSources` are persisted to MongoDB natively as Compacted [JSON-LD](http://json-ld.org) documents.
|
8
|
+
|
9
|
+
## Installation
|
10
|
+
|
11
|
+
Add this line to your application's Gemfile:
|
12
|
+
|
13
|
+
gem 'active_triples-mongoid_strategy'
|
14
|
+
|
15
|
+
And then execute:
|
16
|
+
|
17
|
+
$ bundle install
|
18
|
+
|
19
|
+
Or install it yourself as:
|
20
|
+
|
21
|
+
$ gem install active_triples-mongoid_strategy
|
22
|
+
|
23
|
+
## Usage
|
24
|
+
|
25
|
+
Start by [configuring Mongoid](https://docs.mongodb.org/ecosystem/tutorial/mongoid-installation/#configuration) for your environment or application as per the documentation.
|
26
|
+
|
27
|
+
Persistence strategies currently (as of [ActiveTriples 0.8.1](https://github.com/ActiveTriples/ActiveTriples/tree/v0.8.1)) use `RDF::Repository` as the default persistence strategy. To override this, you have to inject `MongoidStrategy` into `RDFSource` instances at runtime:
|
28
|
+
|
29
|
+
```ruby
|
30
|
+
require 'active_triples/mongoid_strategy'
|
31
|
+
|
32
|
+
source = ActiveTriples::Resource.new
|
33
|
+
source.persistence_strategy # => #<ActiveTriples::RepositoryStrategy:...>
|
34
|
+
|
35
|
+
source.set_persistence_strategy(ActiveTriples::MongoidStrategy)
|
36
|
+
source.persistence_strategy # => #<ActiveTriples::MongoidStrategy:...>
|
37
|
+
```
|
38
|
+
|
39
|
+
## Contributing
|
40
|
+
|
41
|
+
Please observe the following guidelines:
|
42
|
+
|
43
|
+
- Do your work in a feature branch based on ```master``` and rebase before submitting a pull request.
|
44
|
+
- Write tests for your contributions.
|
45
|
+
- Document every method you add using YARD annotations. (_Note: Annotations are sparse in the existing codebase, help us fix that!_)
|
46
|
+
- Organize your commits into logical units.
|
47
|
+
- Don't leave trailing whitespace (i.e. run ```git diff --check``` before committing).
|
48
|
+
- Use [well formed](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html) commit messages.
|
@@ -0,0 +1,35 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
$:.push File.expand_path("../lib", __FILE__)
|
3
|
+
require "active_triples/mongoid_strategy/version"
|
4
|
+
|
5
|
+
Gem::Specification.new do |s|
|
6
|
+
s.name = "active_triples-mongoid_strategy"
|
7
|
+
s.version = ActiveTriples::MongoidStrategy::VERSION
|
8
|
+
s.platform = Gem::Platform::RUBY
|
9
|
+
s.authors = ["MJ Suhonos"]
|
10
|
+
s.homepage = 'https://github.com/ActiveTriples/active_triples-mongoid_strategy'
|
11
|
+
s.email = 'mj@suhonos.ca'
|
12
|
+
s.summary = %q{Mongoid persistence for ActiveTriples.}
|
13
|
+
s.description = %q{active_triples-mongoid provides a graph-based MongoDB persistence strategy for ActiveTriples.}
|
14
|
+
s.license = "Apache-2.0"
|
15
|
+
s.required_ruby_version = '>= 2.0.0'
|
16
|
+
|
17
|
+
s.add_dependency('active-triples', '~> 0.8')
|
18
|
+
s.add_dependency('mongoid', '~> 5.0')
|
19
|
+
|
20
|
+
s.add_development_dependency('pry')
|
21
|
+
s.add_development_dependency('pry-byebug')
|
22
|
+
s.add_development_dependency('rdoc')
|
23
|
+
s.add_development_dependency('rspec')
|
24
|
+
s.add_development_dependency('rdf-spec')
|
25
|
+
s.add_development_dependency('coveralls')
|
26
|
+
s.add_development_dependency('guard-rspec')
|
27
|
+
|
28
|
+
s.files = `git ls-files`.split("\n")
|
29
|
+
s.test_files = `git ls-files -- {spec}/*`.split("\n")
|
30
|
+
|
31
|
+
s.extra_rdoc_files = [
|
32
|
+
"LICENSE",
|
33
|
+
"README.md"
|
34
|
+
]
|
35
|
+
end
|
@@ -0,0 +1,97 @@
|
|
1
|
+
require 'active_triples/persistence_strategies/persistence_strategy'
|
2
|
+
require 'active_triples/mongoid_strategy/version'
|
3
|
+
require 'mongoid'
|
4
|
+
require 'json/ld'
|
5
|
+
|
6
|
+
module ActiveTriples
|
7
|
+
##
|
8
|
+
# Persistence strategy for projecting `RDFSource` to `Mongoid::Documents`.
|
9
|
+
class MongoidStrategy
|
10
|
+
include PersistenceStrategy
|
11
|
+
|
12
|
+
# @!attribute [r] obj
|
13
|
+
# the RDFSource to persist with this strategy
|
14
|
+
# @!attribute [r] collection
|
15
|
+
# the Mongoid::Document class that the object
|
16
|
+
# will project itself on when persisting
|
17
|
+
attr_reader :obj, :collection
|
18
|
+
|
19
|
+
##
|
20
|
+
# @param obj [RDFSource] the `RDFSource` to persist with the strategy.
|
21
|
+
def initialize(obj)
|
22
|
+
@obj = obj
|
23
|
+
@collection = set_klass
|
24
|
+
end
|
25
|
+
|
26
|
+
##
|
27
|
+
# Delete the Document from the collection
|
28
|
+
def erase_old_resource
|
29
|
+
persisted_document.destroy
|
30
|
+
end
|
31
|
+
|
32
|
+
##
|
33
|
+
# Delete the Document from the collection
|
34
|
+
# and mark the Resource as destroyed
|
35
|
+
def destroy
|
36
|
+
super { erase_old_resource }
|
37
|
+
end
|
38
|
+
|
39
|
+
##
|
40
|
+
# Persists the object to the repository
|
41
|
+
#
|
42
|
+
# @return [true] returns true if the save did not error
|
43
|
+
def persist!
|
44
|
+
# Persist ALL objects as a @graph
|
45
|
+
unless obj.empty?
|
46
|
+
doc = collection.find_or_initialize_by(id: obj.id)
|
47
|
+
doc.attributes = JSON.parse(obj.dump(:jsonld, standard_prefixes: true,
|
48
|
+
useNativeTypes: true))
|
49
|
+
doc.save
|
50
|
+
end
|
51
|
+
|
52
|
+
@persisted = true
|
53
|
+
end
|
54
|
+
|
55
|
+
##
|
56
|
+
# Repopulates the graph from the repository.
|
57
|
+
#
|
58
|
+
# @return [Boolean]
|
59
|
+
def reload
|
60
|
+
# Retrieve document from #collection if it exists
|
61
|
+
doc = persisted_document.first
|
62
|
+
obj << JSON::LD::API.toRDF(doc.as_document,
|
63
|
+
rename_bnodes: false) unless doc.nil?
|
64
|
+
@persisted = true
|
65
|
+
end
|
66
|
+
|
67
|
+
private
|
68
|
+
|
69
|
+
##
|
70
|
+
# @return [Mongoid::Criteria] criteria matching the document
|
71
|
+
def persisted_document
|
72
|
+
collection.where(id: obj.id)
|
73
|
+
end
|
74
|
+
|
75
|
+
##
|
76
|
+
# Return the delegated class for the object's model
|
77
|
+
def set_klass
|
78
|
+
klass_name = obj.model_name.name.demodulize.to_sym
|
79
|
+
|
80
|
+
if self.class.constants.include? klass_name
|
81
|
+
return self.class.const_get(klass_name)
|
82
|
+
else
|
83
|
+
return delegate_klass(klass_name)
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
##
|
88
|
+
# Define a Mongoid::Document delegate class
|
89
|
+
def delegate_klass(klass_name)
|
90
|
+
klass = self.class.const_set(klass_name, Class.new)
|
91
|
+
klass.include Mongoid::Document
|
92
|
+
klass.include Mongoid::Attributes::Dynamic
|
93
|
+
klass.store_in collection: obj.model_name.plural
|
94
|
+
klass
|
95
|
+
end
|
96
|
+
end
|
97
|
+
end
|
@@ -0,0 +1,144 @@
|
|
1
|
+
require 'active_triples/mongoid_strategy'
|
2
|
+
require 'spec_helper'
|
3
|
+
|
4
|
+
options = { clients: { default: { database: 'active_triples', hosts: ['localhost:27017'] } } }
|
5
|
+
Mongoid.load_configuration(options)
|
6
|
+
Mongo::Logger.logger.level = Logger::INFO
|
7
|
+
|
8
|
+
describe ActiveTriples::MongoidStrategy do
|
9
|
+
let(:rdf_source) { ActiveTriples::Resource.new }
|
10
|
+
let(:subject) { described_class.new(rdf_source) }
|
11
|
+
|
12
|
+
before :each do
|
13
|
+
Mongoid.purge!
|
14
|
+
end
|
15
|
+
|
16
|
+
context 'with behaviour' do
|
17
|
+
it_behaves_like 'a persistence strategy'
|
18
|
+
|
19
|
+
describe '#persisted?' do
|
20
|
+
context 'before persist!' do
|
21
|
+
it 'returns false' do
|
22
|
+
expect(subject).not_to be_persisted
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
context 'after persist!' do
|
27
|
+
it 'returns true' do
|
28
|
+
subject.persist!
|
29
|
+
expect(subject).to be_persisted
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
describe '#destroy' do
|
35
|
+
shared_examples 'destroy resource' do
|
36
|
+
it 'removes the resource from the collection' do
|
37
|
+
subject.persist!
|
38
|
+
expect { subject.destroy }
|
39
|
+
.to change { subject.collection.count }.from(1).to(0)
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
it 'marks resource as destroyed' do
|
44
|
+
subject.destroy
|
45
|
+
expect(subject).to be_destroyed
|
46
|
+
end
|
47
|
+
|
48
|
+
it 'leaves other resources unchanged' do
|
49
|
+
# insert a new resource into the collection
|
50
|
+
other_resource = ActiveTriples::Resource.new
|
51
|
+
other_resource << RDF::Statement(other_resource.to_term, RDF::Vocab::DC.title, 'snorkmaiden')
|
52
|
+
described_class.new(other_resource).persist!
|
53
|
+
|
54
|
+
expect { subject.destroy }
|
55
|
+
.not_to change { subject.collection.count }
|
56
|
+
end
|
57
|
+
|
58
|
+
context 'with statements' do
|
59
|
+
before { rdf_source << RDF::Statement(rdf_source.to_term, RDF::Vocab::DC.title, 'moomin') }
|
60
|
+
|
61
|
+
include_examples 'destroy resource'
|
62
|
+
|
63
|
+
context 'with subjects' do
|
64
|
+
before do
|
65
|
+
subject.obj.set_subject! RDF::URI('http://example.org/moomin')
|
66
|
+
end
|
67
|
+
|
68
|
+
include_examples 'destroy resource'
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
describe '#destroyed?' do
|
74
|
+
it 'is false' do
|
75
|
+
expect(subject).not_to be_destroyed
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
79
|
+
describe '#reload' do
|
80
|
+
it 'returns true when both collection and object are empty' do
|
81
|
+
expect(subject.reload).to be true
|
82
|
+
end
|
83
|
+
end
|
84
|
+
end
|
85
|
+
|
86
|
+
context 'with literals' do
|
87
|
+
literals = [
|
88
|
+
# Non-localized String
|
89
|
+
'Comet in Moominland',
|
90
|
+
RDF::Literal('Mumintrollet pa kometjakt'),
|
91
|
+
|
92
|
+
# Localized string
|
93
|
+
RDF::Literal('Mumintrollet pa kometjakt', language: :sv),
|
94
|
+
|
95
|
+
# Boolean
|
96
|
+
true,
|
97
|
+
RDF::Literal("false", datatype: RDF::XSD.boolean),
|
98
|
+
|
99
|
+
# Integer
|
100
|
+
16_589_991,
|
101
|
+
RDF::Literal("31415927", datatype: RDF::XSD.integer),
|
102
|
+
|
103
|
+
# Float
|
104
|
+
12.345,
|
105
|
+
RDF::Literal("67.890", datatype: RDF::XSD.double),
|
106
|
+
|
107
|
+
# Symbol
|
108
|
+
:something,
|
109
|
+
RDF::Literal("else", datatype: RDF::XSD.token),
|
110
|
+
|
111
|
+
# Date
|
112
|
+
Date.new(1946),
|
113
|
+
RDF::Literal("1947-01-01", datatype: RDF::XSD.date),
|
114
|
+
|
115
|
+
# DateTime
|
116
|
+
DateTime.new(1951, 2, 3, 4, 5, 6),
|
117
|
+
RDF::Literal("1952-03-04T05:06:07Z", datatype: RDF::XSD.dateTime),
|
118
|
+
|
119
|
+
# Time
|
120
|
+
Time.now,
|
121
|
+
RDF::Literal(Time.now, datatype: RDF::XSD.time),
|
122
|
+
|
123
|
+
# URI
|
124
|
+
RDF::URI('http://foo.org'),
|
125
|
+
]
|
126
|
+
|
127
|
+
it_behaves_like 'a mongoid strategy', literals
|
128
|
+
|
129
|
+
# Test persistence with various types of value
|
130
|
+
literals.each { |value| it_behaves_like 'a mongoid strategy', value }
|
131
|
+
end
|
132
|
+
|
133
|
+
context 'with objects' do
|
134
|
+
objects = [
|
135
|
+
ActiveTriples::Resource.new,
|
136
|
+
ActiveTriples::Resource.new('http://example.uri/'),
|
137
|
+
]
|
138
|
+
|
139
|
+
it_behaves_like 'a mongoid strategy', objects
|
140
|
+
|
141
|
+
# Test persistence with various types of value
|
142
|
+
objects.each { |value| it_behaves_like 'a mongoid strategy', value }
|
143
|
+
end
|
144
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
require 'coveralls'
|
3
|
+
Coveralls.wear!
|
4
|
+
|
5
|
+
require 'bundler/setup'
|
6
|
+
Bundler.setup
|
7
|
+
|
8
|
+
require 'rdf/spec'
|
9
|
+
require 'rdf/vocab'
|
10
|
+
require 'webmock/rspec'
|
11
|
+
require 'active_triples'
|
12
|
+
|
13
|
+
require 'pry' unless ENV["CI"]
|
14
|
+
|
15
|
+
Dir['./spec/support/**/*.rb'].each { |f| require f }
|
16
|
+
|
17
|
+
WebMock.disable_net_connect!
|
18
|
+
|
19
|
+
RSpec.configure do |config|
|
20
|
+
config.color = true
|
21
|
+
config.tty = true
|
22
|
+
|
23
|
+
config.include(RDF::Spec::Matchers)
|
24
|
+
|
25
|
+
# Uncomment the following line to get errors and backtrace for deprecation warnings
|
26
|
+
# config.raise_errors_for_deprecations!
|
27
|
+
|
28
|
+
# Use the specified formatter
|
29
|
+
config.formatter = :documentation
|
30
|
+
end
|
@@ -0,0 +1,36 @@
|
|
1
|
+
shared_examples 'a mongoid strategy' do |value|
|
2
|
+
before do
|
3
|
+
subject.obj[RDF::Vocab::DC.title] = value
|
4
|
+
end
|
5
|
+
|
6
|
+
describe '#persist!' do
|
7
|
+
it "writes graph with #{value.inspect} to #collection" do
|
8
|
+
subject.persist!
|
9
|
+
expect(subject.collection.all.map(&:id))
|
10
|
+
.to contain_exactly *rdf_source.id
|
11
|
+
end
|
12
|
+
|
13
|
+
it 'serializes as JSON-LD' do
|
14
|
+
subject.persist!
|
15
|
+
|
16
|
+
json_ld = JSON.parse(subject.obj.dump(:jsonld))
|
17
|
+
g = RDF::Graph.new << JSON::LD::API.toRdf(json_ld, rename_bnodes: false)
|
18
|
+
|
19
|
+
expect(subject.obj.statements)
|
20
|
+
.to contain_exactly *g.statements
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
describe '#reload' do
|
25
|
+
it 're-populates graph from a persisted document' do
|
26
|
+
g = RDF::Graph.new << subject.obj.statements
|
27
|
+
|
28
|
+
subject.persist!
|
29
|
+
subject.obj.clear
|
30
|
+
subject.reload
|
31
|
+
|
32
|
+
expect(subject.obj.statements)
|
33
|
+
.to contain_exactly *g.statements
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
shared_examples 'a persistence strategy' do
|
3
|
+
shared_context 'with changes' do
|
4
|
+
before do
|
5
|
+
subject.obj << RDF::Statement.new(RDF::Node.new, RDF::Vocab::DC.title, 'moomin')
|
6
|
+
end
|
7
|
+
end
|
8
|
+
|
9
|
+
describe '#persist!' do
|
10
|
+
it 'evaluates true on success' do
|
11
|
+
expect(subject.persist!).to be_truthy
|
12
|
+
end
|
13
|
+
|
14
|
+
context 'with changes' do
|
15
|
+
include_context 'with changes'
|
16
|
+
|
17
|
+
it 'evaluates true on success' do
|
18
|
+
expect(subject.persist!).to be_truthy
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
metadata
ADDED
@@ -0,0 +1,186 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: active_triples-mongoid_strategy
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- MJ Suhonos
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-02-16 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: active-triples
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.8'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0.8'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: mongoid
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '5.0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '5.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: pry
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: pry-byebug
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rdoc
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: rspec
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: rdf-spec
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: coveralls
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - ">="
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - ">="
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '0'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: guard-rspec
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - ">="
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '0'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - ">="
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '0'
|
139
|
+
description: active_triples-mongoid provides a graph-based MongoDB persistence strategy
|
140
|
+
for ActiveTriples.
|
141
|
+
email: mj@suhonos.ca
|
142
|
+
executables: []
|
143
|
+
extensions: []
|
144
|
+
extra_rdoc_files:
|
145
|
+
- LICENSE
|
146
|
+
- README.md
|
147
|
+
files:
|
148
|
+
- ".coveralls.yml"
|
149
|
+
- ".gitignore"
|
150
|
+
- ".travis.yml"
|
151
|
+
- AUTHORS
|
152
|
+
- Gemfile
|
153
|
+
- LICENSE
|
154
|
+
- README.md
|
155
|
+
- active_triples-mongoid.gemspec
|
156
|
+
- lib/active_triples/mongoid_strategy.rb
|
157
|
+
- lib/active_triples/mongoid_strategy/version.rb
|
158
|
+
- spec/active_triples/persistence_strategies/mongoid_strategy_spec.rb
|
159
|
+
- spec/spec_helper.rb
|
160
|
+
- spec/support/shared_examples/mongoid_strategy.rb
|
161
|
+
- spec/support/shared_examples/persistence_strategy.rb
|
162
|
+
homepage: https://github.com/ActiveTriples/active_triples-mongoid_strategy
|
163
|
+
licenses:
|
164
|
+
- Apache-2.0
|
165
|
+
metadata: {}
|
166
|
+
post_install_message:
|
167
|
+
rdoc_options: []
|
168
|
+
require_paths:
|
169
|
+
- lib
|
170
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
171
|
+
requirements:
|
172
|
+
- - ">="
|
173
|
+
- !ruby/object:Gem::Version
|
174
|
+
version: 2.0.0
|
175
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
176
|
+
requirements:
|
177
|
+
- - ">="
|
178
|
+
- !ruby/object:Gem::Version
|
179
|
+
version: '0'
|
180
|
+
requirements: []
|
181
|
+
rubyforge_project:
|
182
|
+
rubygems_version: 2.5.1
|
183
|
+
signing_key:
|
184
|
+
specification_version: 4
|
185
|
+
summary: Mongoid persistence for ActiveTriples.
|
186
|
+
test_files: []
|