occi-core 4.3.5 → 4.3.6
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 +4 -4
- data/lib/occi/core/entity.rb +4 -4
- data/lib/occi/core/kind.rb +7 -1
- data/lib/occi/version.rb +1 -1
- metadata +3 -4
- data/.travis.yml +0 -30
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 982c9d4d37b5b8e86e38e039dce74a1a27c3d0f9
|
4
|
+
data.tar.gz: 8ff90a2a4c11dbeed57dd7ac8e8a5f4a7d14d9ec
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d5b7a5296a00711b0d9b3f1abfc8a6e089aeaf1e5e71c6de83ff987d49dbe65e2e4d0eb0cfbffb16303fc9e772ffbbe111b378f4a072bc5454d941ac93831f48
|
7
|
+
data.tar.gz: 1a5b883d2eef57cdf6ee9dc498e3b9516f34025d2ba2c2193ab7f97d2d766c117dee223d0a5898ba703b215d5d451d7a4da484a59b650fcf14ad5c5e93615901
|
data/lib/occi/core/entity.rb
CHANGED
@@ -208,11 +208,11 @@ module Occi
|
|
208
208
|
|
209
209
|
# @return [String] text representation
|
210
210
|
def to_text
|
211
|
-
text = "Category: #{self.kind.term};scheme=#{self.kind.scheme.inspect};class=\"kind\"
|
211
|
+
text = "Category: #{self.kind.term};scheme=#{self.kind.scheme.inspect};class=\"kind\""
|
212
212
|
@mixins.each do |mixin|
|
213
213
|
scheme, term = mixin.to_s.split('#')
|
214
214
|
scheme << '#'
|
215
|
-
text << "\nCategory: #{term};scheme=#{scheme.inspect};class=\"mixin\"
|
215
|
+
text << "\nCategory: #{term};scheme=#{scheme.inspect};class=\"mixin\""
|
216
216
|
end
|
217
217
|
|
218
218
|
text << @attributes.to_text
|
@@ -225,12 +225,12 @@ module Occi
|
|
225
225
|
# @return [Hash] hash containing the HTTP headers of the text/occi rendering
|
226
226
|
def to_header
|
227
227
|
header = Hashie::Mash.new
|
228
|
-
header['Category'] = "#{self.kind.term};scheme=#{self.kind.scheme.inspect};class=\"kind\"
|
228
|
+
header['Category'] = "#{self.kind.term};scheme=#{self.kind.scheme.inspect};class=\"kind\""
|
229
229
|
|
230
230
|
@mixins.each do |mixin|
|
231
231
|
scheme, term = mixin.to_s.split('#')
|
232
232
|
scheme << '#'
|
233
|
-
header['Category'] << ",#{term};scheme=#{scheme.inspect};class=\"mixin\"
|
233
|
+
header['Category'] << ",#{term};scheme=#{scheme.inspect};class=\"mixin\""
|
234
234
|
end
|
235
235
|
|
236
236
|
attributes = @attributes.to_header
|
data/lib/occi/core/kind.rb
CHANGED
@@ -93,7 +93,13 @@ module Occi
|
|
93
93
|
# @param kind [Occi::Core::Kind, String] Kind or Type Identifier of a Kind where relation should be checked.
|
94
94
|
# @return [true,false]
|
95
95
|
def related_to?(kind)
|
96
|
-
|
96
|
+
to_s == kind.to_s || parent.to_s == kind.to_s \
|
97
|
+
|| \
|
98
|
+
(parent.to_s == "http://schemas.ogf.org/occi/infrastructure#network" && kind.to_s == "http://schemas.ogf.org/occi/core#resource") \
|
99
|
+
|| \
|
100
|
+
(parent.to_s == "http://schemas.ogf.org/occi/infrastructure#storage" && kind.to_s == "http://schemas.ogf.org/occi/core#resource") \
|
101
|
+
|| \
|
102
|
+
(parent.to_s == "http://schemas.ogf.org/occi/infrastructure#compute" && kind.to_s == "http://schemas.ogf.org/occi/core#resource")
|
97
103
|
end
|
98
104
|
|
99
105
|
def entity_type
|
data/lib/occi/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: occi-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.3.
|
4
|
+
version: 4.3.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Feldhaus
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2017-
|
13
|
+
date: 2017-07-18 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: json
|
@@ -304,7 +304,6 @@ extra_rdoc_files: []
|
|
304
304
|
files:
|
305
305
|
- ".gitignore"
|
306
306
|
- ".rspec"
|
307
|
-
- ".travis.yml"
|
308
307
|
- ".yardopts"
|
309
308
|
- AUTHORS
|
310
309
|
- Gemfile
|
@@ -457,7 +456,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
457
456
|
version: '0'
|
458
457
|
requirements: []
|
459
458
|
rubyforge_project:
|
460
|
-
rubygems_version: 2.
|
459
|
+
rubygems_version: 2.6.12
|
461
460
|
signing_key:
|
462
461
|
specification_version: 4
|
463
462
|
summary: OCCI toolkit
|
data/.travis.yml
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
language: ruby
|
2
|
-
|
3
|
-
rvm:
|
4
|
-
- 1.9.3
|
5
|
-
- 2.0.0
|
6
|
-
- 2.1
|
7
|
-
- 2.2
|
8
|
-
- 2.3
|
9
|
-
- ruby-head
|
10
|
-
|
11
|
-
matrix:
|
12
|
-
allow_failures:
|
13
|
-
- rvm: 2.3
|
14
|
-
- rvm: ruby-head
|
15
|
-
fast_finish: true
|
16
|
-
|
17
|
-
branches:
|
18
|
-
only:
|
19
|
-
- master
|
20
|
-
- 4.0.x
|
21
|
-
- 4.1.x
|
22
|
-
- 4.2.x
|
23
|
-
- 4.3.x
|
24
|
-
|
25
|
-
install: 'gem install bundler -v ">= 1.7.12" && bundle install --retry=10'
|
26
|
-
|
27
|
-
env:
|
28
|
-
- ON_TRAVIS_CI=yes
|
29
|
-
|
30
|
-
sudo: false
|