Parent

Included Modules

Class Index [+]

Quicksearch

Bundler::LazySpecification

Attributes

name[R]
version[R]
dependencies[R]
platform[R]
source[RW]

Public Class Methods

new(name, version, platform, source = nil) click to toggle source
    # File lib/bundler/lazy_specification.rb, line 11
11:     def initialize(name, version, platform, source = nil)
12:       @name          = name
13:       @version       = version
14:       @dependencies  = []
15:       @platform      = platform
16:       @source        = source
17:       @specification = nil
18:     end

Public Instance Methods

__materialize__() click to toggle source
    # File lib/bundler/lazy_specification.rb, line 47
47:     def __materialize__
48:       @specification = source.specs.search(Gem::Dependency.new(name, version)).last
49:     end
full_name() click to toggle source
    # File lib/bundler/lazy_specification.rb, line 20
20:     def full_name
21:       if platform == Gem::Platform::RUBY or platform.nil? then
22:         "#{@name}-#{@version}"
23:       else
24:         "#{@name}-#{@version}-#{platform}"
25:       end
26:     end
respond_to?(*args) click to toggle source
    # File lib/bundler/lazy_specification.rb, line 51
51:     def respond_to?(*args)
52:       super || @specification.respond_to?(*args)
53:     end
satisfies?(dependency) click to toggle source
    # File lib/bundler/lazy_specification.rb, line 28
28:     def satisfies?(dependency)
29:       @name == dependency.name && dependency.requirement.satisfied_by?(Gem::Version.new(@version))
30:     end
to_lock() click to toggle source
    # File lib/bundler/lazy_specification.rb, line 32
32:     def to_lock
33:       if platform == Gem::Platform::RUBY or platform.nil?
34:         out = "    #{name} (#{version})\n"
35:       else
36:         out = "    #{name} (#{version}-#{platform})\n"
37:       end
38: 
39:       dependencies.sort_by {|d| d.to_s }.each do |dep|
40:         next if dep.type == :development
41:         out << "    #{dep.to_lock}\n"
42:       end
43: 
44:       out
45:     end
to_s() click to toggle source
    # File lib/bundler/lazy_specification.rb, line 55
55:     def to_s
56:       "#{name} (#{version})"
57:     end

Private Instance Methods

method_missing(method, *args, &blk) click to toggle source
    # File lib/bundler/lazy_specification.rb, line 61
61:     def method_missing(method, *args, &blk)
62:       if Gem::Specification.new.respond_to?(method)
63:         raise "LazySpecification has not been materialized yet (calling :#{method} #{args.inspect})" unless @specification
64:         @specification.send(method, *args, &blk)
65:       else
66:         super
67:       end
68:     end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.