hypo 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/hypo/component.rb +0 -1
- data/lib/hypo/container.rb +3 -4
- data/lib/hypo/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 570be7a2692c701a65a85bf763ba51cba31ba7cf
|
4
|
+
data.tar.gz: 5f6524db0fa6e97cd66165464739465878a14580
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a3ee766a7b565241e51fc2baf8843e9712657e0d790745ec747c1513f02d1580be11088820e5516a3e594ecae2bcfa34611f6f121242bfd4ce62cff88214cc67
|
7
|
+
data.tar.gz: ab4f9f1f0624d3c39ed6f93d50dc6ff4c98b63c77667e3f98dce7a40122fc8096d3c0f92dffb9259cc801218f260454f56a6a5a0710cfb3c79b0119d4334430b
|
data/lib/hypo/component.rb
CHANGED
data/lib/hypo/container.rb
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
require 'hypo/container_error'
|
2
2
|
require 'hypo/component'
|
3
3
|
require 'hypo/instance'
|
4
|
-
require 'hypo/extensions/string'
|
5
4
|
|
6
5
|
module Hypo
|
7
6
|
class Container
|
@@ -10,8 +9,8 @@ module Hypo
|
|
10
9
|
def initialize
|
11
10
|
@components = {}
|
12
11
|
@life_cycles = {}
|
13
|
-
add_life_cycle(LifeCycle::Transient, :transient)
|
14
|
-
add_life_cycle(LifeCycle::Singleton, :singleton)
|
12
|
+
add_life_cycle(LifeCycle::Transient.new, :transient)
|
13
|
+
add_life_cycle(LifeCycle::Singleton.new, :singleton)
|
15
14
|
register self, :container
|
16
15
|
end
|
17
16
|
|
@@ -35,7 +34,7 @@ module Hypo
|
|
35
34
|
end
|
36
35
|
|
37
36
|
def add_life_cycle(life_cycle, name)
|
38
|
-
@life_cycles[name] = life_cycle
|
37
|
+
@life_cycles[name] = life_cycle
|
39
38
|
|
40
39
|
self
|
41
40
|
end
|
data/lib/hypo/version.rb
CHANGED