Results for: "OptionParser"

Returns the fractional part of the day in range (Rational(0, 1)…Rational(1, 1)):

DateTime.new(2001,2,3,12).day_fraction # => (1/2)

With a block given, passes each element of self to the block in reverse order:

a = []
(1..4).reverse_each {|element| a.push(element) } # => 1..4
a # => [4, 3, 2, 1]

a = []
(1...4).reverse_each {|element| a.push(element) } # => 1...4
a # => [3, 2, 1]

With no block given, returns an enumerator.

Returns true if the set is a proper subset of the given set.

Returns the Ruby source filename and line number of the binding object.

Returns the location where the Proc was defined. The returned Array contains:

(1) the Ruby source filename
(2) the line number where the definition starts
(3) the column number where the definition starts
(4) the line number where the definition ends
(5) the column number where the definitions ends

This method will return nil if the Proc was not defined in Ruby (i.e. native).

Returns the location where the method was defined. The returned Array contains:

(1) the Ruby source filename
(2) the line number where the definition starts
(3) the column number where the definition starts
(4) the line number where the definition ends
(5) the column number where the definitions ends

This method will return nil if the method was not defined in Ruby (i.e. native).

Returns the location where the method was defined. The returned Array contains:

(1) the Ruby source filename
(2) the line number where the definition starts
(3) the column number where the definition starts
(4) the line number where the definition ends
(5) the column number where the definitions ends

This method will return nil if the method was not defined in Ruby (i.e. native).

Returns the execution stack for the target thread—an array containing backtrace location objects.

See Thread::Backtrace::Location for more information.

This method behaves similarly to Kernel#caller_locations except it applies to a specific thread.

With a block given, calls the block with each element, but in reverse order; returns self:

a = []
(1..4).reverse_each {|element| a.push(-element) } # => 1..4
a # => [-4, -3, -2, -1]

a = []
%w[a b c d].reverse_each {|element| a.push(element) }
# => ["a", "b", "c", "d"]
a # => ["d", "c", "b", "a"]

a = []
h.reverse_each {|element| a.push(element) }
# => {:foo=>0, :bar=>1, :baz=>2}
a # => [[:baz, 2], [:bar, 1], [:foo, 0]]

With no block given, returns an Enumerator.

Returns the source file origin from the given object.

See ::trace_object_allocations for more information and examples.

Returns the original line from source for from the given object.

See ::trace_object_allocations for more information and examples.

Constant time memory comparison. Inputs are hashed using SHA-256 to mask the length of the secret. Returns true if the strings are identical, false otherwise.

Returns the convertible integer type of the given type. You may optionally specify additional headers to search in for the type. convertible means actually the same type, or typedef’d from the same type.

If the type is an integer type and the convertible type is found, the following macros are passed as preprocessor constants to the compiler using the type name, in uppercase.

For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return “unsigned long”, and define these macros:

#define TYPEOF_FOOBAR_T unsigned long
#define FOOBART2NUM ULONG2NUM
#define NUM2FOOBART NUM2ULONG

in foo | bar

Add the –clear-sources option

No documentation available
No documentation available
No documentation available

Invoked by Ruby’s core methods to run a blocking operation in a non-blocking way.

Minimal suggested implementation is:

def blocking_operation_wait(work)
  Thread.new(&work).join
end

Add the –key option

Add the –otp option

Default options for the gem install and update commands.

Add the –http-proxy option

Add the –source option

Add the –platform option to the option parser.

Search took: 5ms  ·  Total Results: 3694