Sha256: f30e7520daeff03eae92df6374957ec4e6f54e6a5947ce6cb81e3b8f20031f88

Contents?: true

Size: 821 Bytes

Versions: 97

Compression:

Stored size: 821 Bytes

Contents

class Testing
  # Ignore yields outside methods
  yield x, y, z

  # Should document this
  def mymethod
    yield
  end

  # Has yield and yieldparam documentation
  # @yield [a, b] Blah
  # @yieldparam a Blah
  # @yieldparam b Blah
  def mymethod2
    yield(b, a) # Yield something else
  end

  # Has yield documentation only
  # @yield [a, b]
  def mymethod3
    yield self # Should not be changed
  end

  # Has yieldparam documentation only
  # @yieldparam _self BLAH
  def mymethod4
    yield self
  end

  # Some weird possibilities..
  # Document it all.


  def mymethod5
    yield :a, b, self, File.read('file', 'w'), CONSTANT if x == 2
  end

  def mymethod6
    yield(b, a)
  end

  def mymethod7
    yield a
    yield b
  end

  def mymethod8
    yield self
  end

  def mymethod9
    yield super
  end
end

Version data entries

97 entries across 78 versions & 10 rubygems

Version Path
yard-0.9.24 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.23 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.22 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.21 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.20 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.19 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.16 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.15 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.14 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.13 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.12 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.11 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.10 spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.9 spec/handlers/examples/yield_handler_001.rb.txt
etude_for_ruby-0.1.4 vendor/bundle/ruby/2.4.0/gems/yard-0.9.8/spec/handlers/examples/yield_handler_001.rb.txt
etude_for_ruby-0.1.4 vendor/bundle/ruby/2.2.0/gems/yard-0.9.8/spec/handlers/examples/yield_handler_001.rb.txt
mdg-1.0.1 vendor/bundle/ruby/2.3.0/gems/yard-0.9.8/spec/handlers/examples/yield_handler_001.rb.txt
yard-0.9.8 spec/handlers/examples/yield_handler_001.rb.txt
abaci-0.3.0 vendor/bundle/gems/yard-0.9.1/spec/handlers/examples/yield_handler_001.rb.txt
abaci-0.3.0 vendor/bundle/gems/yard-0.9.7/spec/handlers/examples/yield_handler_001.rb.txt