class Gem::DependencyResolver::InstalledSpecification

Attributes

spec[R]

Public Class Methods

new(set, spec, source=nil) click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 5
def initialize set, spec, source=nil
  @set    = set
  @source = source
  @spec   = spec
end

Public Instance Methods

dependencies() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 17
def dependencies
  @spec.dependencies
end
full_name() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 21
def full_name
  "#{@spec.name}-#{@spec.version}"
end
installable_platform?() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 33
def installable_platform?
  # BACKCOMPAT If the file is coming out of a specified file, then we
  # ignore the platform. This code can be removed in RG 3.0.
  if @source.kind_of? Gem::Source::SpecificFile
    return true
  else
    Gem::Platform.match @spec.platform
  end
end
name() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 25
def name
  @spec.name
end
platform() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 29
def platform
  @spec.platform
end
source() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 43
def source
  @source ||= Gem::Source::Installed.new
end
version() click to toggle source
# File lib/rubygems/dependency_resolver/installed_specification.rb, line 47
def version
  @spec.version
end