tamashii 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 637575c817bd71e84045a69c5e5c3072ed5f3688
|
4
|
+
data.tar.gz: d268102ce32b07fc745f7a422552a5ce8860037a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 85289e69ebb52ae24d099713519bd77f18d91de41ca1cb1b08a643123a1d4705202ea079774758cf2a2501ddfc1d731b2079576cd8f39daa9d62c3f483864f63
|
7
|
+
data.tar.gz: 9b7f4a4f4e3e9968bae607177544a10ff13679e77bab0f0c39caf9a8149ca233d50af0c4d20826e4dd8ae6dea1ab04476323088ed1b0eb5313f8b5022a72ed50
|
data/lib/tamashii/server.rb
CHANGED
@@ -18,6 +18,17 @@ module Tamashii
|
|
18
18
|
@spawn_mutex = Mutex.new
|
19
19
|
end
|
20
20
|
|
21
|
+
def timer(interval, &block)
|
22
|
+
Concurrent::TimerTask.new(
|
23
|
+
execution_interval: interval, &block
|
24
|
+
).tap(&:execute)
|
25
|
+
end
|
26
|
+
|
27
|
+
def post(task = nil, &block)
|
28
|
+
task ||= block
|
29
|
+
Concurrent.global_io_executor << task
|
30
|
+
end
|
31
|
+
|
21
32
|
def attach(io, stream)
|
22
33
|
@todo << lambda do
|
23
34
|
@streams[io] = @nio.register(io, :r)
|
data/lib/tamashii/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tamashii
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- 蒼時弦也
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date: 2017-05-
|
13
|
+
date: 2017-05-26 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: concurrent-ruby
|