Class: ElmInstall::Dependency
- Extended by:
- Forwardable
- Defined in:
- lib/elm_install/dependency.rb
Overview
Represents a dependency
Instance Attribute Summary collapse
-
#constraints ⇒ Array
readonly
The constraints for the dependency.
-
#name ⇒ String
readonly
The name of the dependency.
-
#source ⇒ Source
readonly
The source to use for resolving (Git, Directory).
- #version ⇒ Object
Instance Method Summary collapse
-
#initialize(name, source, constraints) ⇒ Dependency
constructor
Initializes a new dependency.
Constructor Details
#initialize(name, source, constraints) ⇒ Dependency
Initializes a new dependency.
30 31 32 33 34 35 |
# File 'lib/elm_install/dependency.rb', line 30 def initialize(name, source, constraints) @constraints = constraints @source = source @name = name self end |
Instance Attribute Details
#constraints ⇒ Array (readonly)
Returns The constraints for the dependency.
7 8 9 |
# File 'lib/elm_install/dependency.rb', line 7 def constraints @constraints end |
#name ⇒ String (readonly)
Returns The name of the dependency.
20 21 22 |
# File 'lib/elm_install/dependency.rb', line 20 def name @name end |
#source ⇒ Source (readonly)
Returns The source to use for resolving (Git, Directory).
17 18 19 |
# File 'lib/elm_install/dependency.rb', line 17 def source @source end |
#version ⇒ Semverse::Version #version=(value) ⇒ Object
14 15 16 |
# File 'lib/elm_install/dependency.rb', line 14 def version @version end |