Results for: "module_function"

Sets the nonce (number used once) that the server shall include in its response. If the nonce is set, the server must return the same nonce value in a valid Response.

Returns the nonce (number used once) that the server shall include in its response.

No documentation available

The version of this activation request’s specification

The version of the gem for this specification.

Create a new ModuleNode node

No documentation available

Returns the Fiber scheduler, that was last set for the current thread with Fiber.set_scheduler. Returns nil if no scheduler is set (which is the default), and non-blocking fibers’ behavior is the same as blocking. (see “Non-blocking fibers” section in class docs for details about the scheduler concept).

The method is expected to immediately run the provided block of code in a separate non-blocking fiber.

puts "Go to sleep!"

Fiber.set_scheduler(MyScheduler.new)

Fiber.schedule do
  puts "Going to sleep"
  sleep(1)
  puts "I slept well"
end

puts "Wakey-wakey, sleepyhead"

Assuming MyScheduler is properly implemented, this program will produce:

Go to sleep!
Going to sleep
Wakey-wakey, sleepyhead
...1 sec pause here...
I slept well

…e.g. on the first blocking operation inside the Fiber (sleep(1)), the control is yielded to the outside code (main fiber), and at the end of that execution, the scheduler takes care of properly resuming all the blocked fibers.

Note that the behavior described above is how the method is expected to behave, actual behavior is up to the current scheduler’s implementation of Fiber::Scheduler#fiber method. Ruby doesn’t enforce this method to behave in any particular way.

If the scheduler is not set, the method raises RuntimeError (No scheduler is available!).

No documentation available

Because we have mutated the AST to allow for newlines in the middle of a rational, we need to manually handle the value here.

Parse a rational from the string representation.

Waits up to the continue timeout for a response from the server provided we’re speaking HTTP 1.1 and are expecting a 100-continue response.

No documentation available
No documentation available
No documentation available
No documentation available

The version of Ruby required by this gem. The ruby version can be specified to the patch-level:

$ ruby -v -e 'p Gem.ruby_version'
ruby 2.0.0p247 (2013-06-27 revision 41674) [x86_64-darwin12.4.0]
#<Gem::Version "2.0.0.247">

Prereleases can also be specified.

Usage:

# This gem will work with 1.8.6 or greater...
spec.required_ruby_version = '>= 1.8.6'

# Only with final releases of major version 2 where minor version is at least 3
spec.required_ruby_version = '~> 2.3'

# Only prereleases or final releases after 2.6.0.preview2
spec.required_ruby_version = '> 2.6.0.preview2'

# This gem will work with 2.3.0 or greater, including major version 3, but lesser than 4.0.0
spec.required_ruby_version = '>= 2.3', '< 4'

The RubyGems version required by this gem

No documentation available
No documentation available

Returns URL-unescaped string following RFC 3986.

No documentation available
No documentation available
No documentation available
Search took: 7ms  ·  Total Results: 5313