reality-facets 1.2.0 → 1.3.0

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: 319b46e31a3bfe159970f09b3baf2b57f081f249
4
- data.tar.gz: d448877634b53d91de1b9c41d4a3e96b705bbff4
3
+ metadata.gz: bb281ab73c6286e5c1a45396e041b0fc1d93970a
4
+ data.tar.gz: 64a10ebd482f32587978b40bdc4965534e07c028
5
5
  SHA512:
6
- metadata.gz: 2ede2928bfe8f5a4bf60c61df3fb8d7d7b948eb7855373ee635766bc027ddecb001b920ebd57fb59092679d18372950bfcb19f8998e1c7731204afec3cb8b5e9
7
- data.tar.gz: b0c350ca3b1194b77fb2f543152bc60546ed57fefe00f3bb8bf57b0e822762390a71fb9c633363f70644f7d04e1ca96eb6be8149911a23b25745ad5dc961fb65
6
+ metadata.gz: 0550cce27e866f4489e052caf535ccff1a07ebc7a492599403e0d462bffb115c3737ff81b28c5489090e72520893b4f163d4f56d33a2bcc3f540de42babdd2bc
7
+ data.tar.gz: c1a021e2d8ba9783fc0dbe6f5f6349e889bbad06caa639971796adac11e082800ba01b12abafc425faa28d52b6f4fd4351021b23bb0cb85935d5874966ba1f60
@@ -0,0 +1,29 @@
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.
13
+ #
14
+
15
+ module Reality #nodoc
16
+ module Facets #nodoc
17
+
18
+ class << self
19
+ # Copy the targets from the specified generator container to the facet container.
20
+ # This is typically used when projects include both reality-generators and reality-facets
21
+ # and do not want to duplicate the code tor defining targets in both systems
22
+ def copy_targets_from_generator_target_manager(generator_container, facet_container)
23
+ facet_container.target_manager.targets.each do |target|
24
+ generator_container.target_manager.target(target.key, target.container_key, :access_method => target.access_method)
25
+ end
26
+ end
27
+ end
28
+ end
29
+ end
@@ -23,3 +23,5 @@ require 'reality/facets/target_manager'
23
23
  require 'reality/facets/faceted_model'
24
24
  require 'reality/facets/facet'
25
25
  require 'reality/facets/facet_container'
26
+
27
+ require 'reality/facets/generators_integration'
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{reality-facets}
5
- s.version = '1.2.0'
5
+ s.version = '1.3.0'
6
6
  s.platform = Gem::Platform::RUBY
7
7
 
8
8
  s.authors = ['Peter Donald']
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: reality-facets
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Donald
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-12-07 00:00:00.000000000 Z
11
+ date: 2016-12-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: reality-core
@@ -100,6 +100,7 @@ files:
100
100
  - lib/reality/facets/facet.rb
101
101
  - lib/reality/facets/facet_container.rb
102
102
  - lib/reality/facets/faceted_model.rb
103
+ - lib/reality/facets/generators_integration.rb
103
104
  - lib/reality/facets/target_manager.rb
104
105
  - reality-facets.gemspec
105
106
  - test/facets/test_facet.rb