Sha256: 8ffd9cfe2240b255f9c054434fcc4c4ddc3c4549d66a62f7aa66913f0c7a1216
Contents?: true
Size: 564 Bytes
Versions: 1
Compression:
Stored size: 564 Bytes
Contents
require File.dirname(__FILE__) + '/../lib/ninja_decorators' class NinjaClass include NinjaDecorators around_filter :common_around, [:foo, :bar, :nested] around_filter :nested_around, [:nested] attr_accessor :ret def initialize @ret = "" end def foo @ret += "foo" end def bar @ret += "bar" end def nested @ret += "nested" end private def common_around @ret += "common " yield @ret += " around" end def nested_around @ret += "nesting " yield @ret += " completed" end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
haruska-ninja-decorators-0.5.0 | test/ninja_class.rb |