Sha256: 2ed5e1fa3c20f00e5f3e8b54e44dc0020ff42e91681dcc891720578e905eadf9

Contents?: true

Size: 305 Bytes

Versions: 67

Compression:

Stored size: 305 Bytes

Contents

module RBS
  module Test
    module Observer
      @@observers = {}

      class <<self
        def notify(key, *args)
          @@observers[key]&.call(*args)
        end

        def register(key, object = nil, &block)
          @@observers[key] = object || block
        end
      end
    end
  end
end

Version data entries

67 entries across 67 versions & 1 rubygems

Version Path
rbs-2.6.0 lib/rbs/test/observer.rb
rbs-2.5.1 lib/rbs/test/observer.rb
rbs-2.5.0 lib/rbs/test/observer.rb
rbs-2.4.0 lib/rbs/test/observer.rb
rbs-2.3.2 lib/rbs/test/observer.rb
rbs-2.3.1 lib/rbs/test/observer.rb
rbs-2.3.0 lib/rbs/test/observer.rb
rbs-2.2.2 lib/rbs/test/observer.rb
rbs-2.2.1 lib/rbs/test/observer.rb
rbs-2.2.0 lib/rbs/test/observer.rb
rbs-2.1.0 lib/rbs/test/observer.rb
rbs-2.0.0 lib/rbs/test/observer.rb
rbs-2.0.0.pre2 lib/rbs/test/observer.rb
rbs-2.0.0.pre1 lib/rbs/test/observer.rb
rbs-1.8.1 lib/rbs/test/observer.rb
rbs-1.8.0 lib/rbs/test/observer.rb
rbs-1.7.1 lib/rbs/test/observer.rb
rbs-1.7.0 lib/rbs/test/observer.rb
rbs-1.7.0.beta.5 lib/rbs/test/observer.rb
rbs-1.7.0.beta.4 lib/rbs/test/observer.rb