Results for: "OptionParser"

No documentation available
No documentation available
No documentation available

@macro action

Processes the topmost available {RequirementState} on the stack @return [void]

Unwinds the states stack because a conflict has been encountered @return [void]

@return [Boolean] whether the current spec is satisfied as a new possibility.

This method creates a JSON text from the result of a call to to_json_raw_object of this String.

(see Gem::Resolver::Molinillo::SpecificationProvider#requirement_satisfied_by?)

Adds a new {Edge} to the dependency graph without checking for circularity. @param (see add_edge) @return (see add_edge)

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

Returns an array of two elements: the filename where the calling method is located, and the line number where it is defined.

Takes an optional argument i, which specifies how many callers up the stack to look.

Examples:

require 'rss/utils'

def foo
  p RSS::Utils.get_file_and_line_from_caller
  p RSS::Utils.get_file_and_line_from_caller(1)
end

def bar
  foo
end

def baz
  bar
end

baz
# => ["test.rb", 5]
# => ["test.rb", 9]

If i is not given, or is the default value of 0, it attempts to figure out the correct value. This is useful when in combination with instance_eval. For example:

require 'rss/utils'

def foo
  p RSS::Utils.get_file_and_line_from_caller(1)
end

def bar
  foo
end

instance_eval <<-RUBY, *RSS::Utils.get_file_and_line_from_caller
def baz
  bar
end
RUBY

baz

# => ["test.rb", 8]
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
Search took: 6ms  ·  Total Results: 4252