Sets the preset dictionary and returns string
. This method is available just only after a Zlib::NeedDict
exception was raised. See zlib.h for details.
Terminate the application with exit code status
, running any exit handlers that might have been defined.
Terminates the RubyGems process with the given exit_code
Get the indentation level.
Set
the indentation level to level
. The level must be less than 10 and greater than 1.
Returns true if argument is optional.
tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook') method = WIN32OLE_METHOD.new(tobj, 'SaveAs') param1 = method.params[0] puts "#{param1.name} #{param1.optional?}" # => Filename true
Create a DRbUnknownError
exception containing this object.
Sends an Options
request to the server; returns an instance of a subclass of Net::HTTPResponse
.
The request is based on the Net::HTTP::Options
object created from string path
and initial headers hash initheader
.
http = Net::HTTP.new(hostname) http.options('/')
Override to display a longer description of what this command does.
A detailed description of this gem. See also summary
Example:
combination([:a, :b, :c, :d]) # => [[:a], [:b], [:c], [:d], [:a, :b], [:a, :c], [:a, :d], [:b, :c], [:b, :d], [:c, :d], [:a, :b, :c], [:a, :b, :d], [:a, :c, :d], [:b, :c, :d], [:a, :b, :c, :d]]
Creates a class to wrap the C union described by signature
.
MyUnion = union ['int i', 'char c']
Generate a Table Caption element as a string.
align
can be a string, giving the alignment of the caption (one of top, bottom, left, or right). It can be a hash of all the attributes of the element. Or it can be omitted.
The body of the element is provided by the passed-in no-argument block.
caption("left") { "Capital Cities" } # => <CAPTION ALIGN=\"left\">Capital Cities</CAPTION>
Sets OptionParser
object, when opt
is false
or nil
, methods OptionParser::Arguable#options
and OptionParser::Arguable#options=
are undefined. Thus, there is no ways to access the OptionParser
object via the receiver object.
Actual OptionParser
object, automatically created if nonexistent.
If called with a block, yields the OptionParser
object and returns the result of the block. If an OptionParser::ParseError
exception occurs in the block, it is rescued, a error message printed to STDERR and nil
returned.
Create a new Location
object
Sets the Fiber
scheduler for the current thread. If the scheduler is set, non-blocking fibers (created by Fiber.new
with blocking: false
, or by Fiber.schedule
) call that scheduler’s hook methods on potentially blocking operations, and the current thread will call scheduler’s close
method on finalization (allowing the scheduler to properly manage all non-finished fibers).
scheduler
can be an object of any class corresponding to Fiber::Scheduler
. Its implementation is up to the user.
See also the “Non-blocking fibers” section in class docs.
Returns the Fiber
scheduler, that was last set for the current thread with Fiber.set_scheduler
if and only if the current fiber is non-blocking.
Adds to array
all elements from each Array in other_arrays
; returns self
:
a = [0, 1] a.concat([2, 3], [4, 5]) # => [0, 1, 2, 3, 4, 5]