yzz 2.1.0 → 2.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/yzz.rb +8 -0
- data/lib/yzz/side_pair.rb +7 -5
- data/lib/yzz/version.rb +1 -1
- data/test/yzz_test.rb +2 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 617429f98c42be15b4e4b8e0d25411c5ae58f4c9
|
4
|
+
data.tar.gz: 28e6de83bab3ebe773352b112fe591fb1b56316d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 084d4142687a4667581c82df11ced2977d74b5f261c23215ca788df7018e2f0f2722b917167632420a30413b08e730c159ba6bb481a154606e301a43e711529d
|
7
|
+
data.tar.gz: d2af40131bf86e43498946f5f1264a9f0bf5b8520fbfb9325213aeeaca14fe2cbcfe7b942354563cb90913ac7cfa993260e7921d7c6fcccfb63821e2a82548b2
|
data/lib/yzz.rb
CHANGED
@@ -60,6 +60,9 @@ module Yzz
|
|
60
60
|
include ::Yzz.Dimension missing_dimension # ::Yzz just in case
|
61
61
|
end.new
|
62
62
|
}.tap { |ꜧ| define_singleton_method :zz_dimensions do ꜧ end }
|
63
|
+
# TODO: This second subclassing of SidePair() in effect acts as a
|
64
|
+
# singleton class. How about making it a true singleton class and
|
65
|
+
# just extending the objects with the mixin?
|
63
66
|
end
|
64
67
|
|
65
68
|
# A reader method that returns a parametrized subclass of Yzz::SidePair. This
|
@@ -70,6 +73,11 @@ module Yzz
|
|
70
73
|
def SidePair
|
71
74
|
SidePair.parametrize( zz: self )
|
72
75
|
.tap { |ç| define_singleton_method :SidePair do ç end }
|
76
|
+
# TODO: How about
|
77
|
+
#
|
78
|
+
# SidePair.parametrize zz: self do
|
79
|
+
# def SidePair; self end
|
80
|
+
# end
|
73
81
|
end
|
74
82
|
|
75
83
|
# Returns a SidePair instance along the requested dimension.
|
data/lib/yzz/side_pair.rb
CHANGED
@@ -12,12 +12,14 @@ class Yzz::SidePair
|
|
12
12
|
self.class.zz
|
13
13
|
end
|
14
14
|
|
15
|
-
#
|
16
|
-
# subclassing.
|
15
|
+
# TODO: This is not needed
|
17
16
|
#
|
18
|
-
|
19
|
-
|
20
|
-
|
17
|
+
# # Reader #dimension delegates to the class, relying on parametrized
|
18
|
+
# # subclassing.
|
19
|
+
# #
|
20
|
+
# def dimension
|
21
|
+
# self.class.dimension
|
22
|
+
# end
|
21
23
|
|
22
24
|
# Takes two optional named parameters, :negward_neighbor and :posward_neigbor.
|
23
25
|
# If not given, the sides are constructed not linked to any neigbors.
|
data/lib/yzz/version.rb
CHANGED
data/test/yzz_test.rb
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
require 'minitest/autorun'
|
5
5
|
# Until they alias it in the core.
|
6
6
|
require 'active_support/core_ext/string/starts_ends_with'
|
7
|
-
|
7
|
+
require_relative '../lib/yzz' # tested component itself
|
8
8
|
|
9
9
|
describe Yzz do
|
10
10
|
before do
|
@@ -63,4 +63,4 @@ describe Yzz do
|
|
63
63
|
end
|
64
64
|
end
|
65
65
|
end
|
66
|
-
end
|
66
|
+
end # describe Yzz
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yzz
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- boris
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-06-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: y_support
|
@@ -92,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
92
92
|
version: '0'
|
93
93
|
requirements: []
|
94
94
|
rubyforge_project:
|
95
|
-
rubygems_version: 2.
|
95
|
+
rubygems_version: 2.5.1
|
96
96
|
signing_key:
|
97
97
|
specification_version: 4
|
98
98
|
summary: A domain model of Ted Nelson's ZZ structures.
|