cabin 0.2.3 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
data/lib/cabin/metrics.rb CHANGED
@@ -54,6 +54,8 @@ class Cabin::Metrics
54
54
 
55
55
  private
56
56
  def create(instance, name, metric_object)
57
+ #p :newmetric => [name, instance]
58
+ #p [instance, instance.class, instance.class.class]
57
59
  return @metrics[[instance, name]] = metric_object
58
60
  end # def create
59
61
 
@@ -47,6 +47,12 @@ class Cabin::Metrics::Timer
47
47
  return @lock.synchronize { @invocations }
48
48
  end # def value
49
49
 
50
+ # TODO(sissel): Until I find a good API.
51
+ public
52
+ def value
53
+ return count
54
+ end # def value
55
+
50
56
  class TimerContext
51
57
  public
52
58
  def initialize(&stop_callback)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cabin
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 19
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
- - 2
9
8
  - 3
10
- version: 0.2.3
9
+ - 0
10
+ version: 0.3.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - Jordan Sissel
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-02-05 00:00:00 -08:00
18
+ date: 2012-02-06 00:00:00 -08:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency