Class: Albacore::NugetModel::IdVersion
- Inherits:
-
Object
- Object
- Albacore::NugetModel::IdVersion
- Defined in:
- lib/albacore/nuget_model.rb
Instance Attribute Summary collapse
-
#group ⇒ Object
readonly
Returns the value of attribute group.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#target_framework ⇒ Object
readonly
Returns the value of attribute target_framework.
-
#version ⇒ Object
readonly
Returns the value of attribute version.
Instance Method Summary collapse
-
#initialize(id, version, group, target_framework) ⇒ IdVersion
constructor
A new instance of IdVersion.
- #to_s ⇒ Object
Constructor Details
#initialize(id, version, group, target_framework) ⇒ IdVersion
Returns a new instance of IdVersion.
14 15 16 |
# File 'lib/albacore/nuget_model.rb', line 14 def initialize id, version, group, target_framework @id, @version, @group, @target_framework = id, version, group, target_framework end |
Instance Attribute Details
#group ⇒ Object (readonly)
Returns the value of attribute group.
12 13 14 |
# File 'lib/albacore/nuget_model.rb', line 12 def group @group end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
12 13 14 |
# File 'lib/albacore/nuget_model.rb', line 12 def id @id end |
#target_framework ⇒ Object (readonly)
Returns the value of attribute target_framework.
12 13 14 |
# File 'lib/albacore/nuget_model.rb', line 12 def target_framework @target_framework end |
#version ⇒ Object (readonly)
Returns the value of attribute version.
12 13 14 |
# File 'lib/albacore/nuget_model.rb', line 12 def version @version end |
Instance Method Details
#to_s ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/albacore/nuget_model.rb', line 18 def to_s if ! target_framework.nil? && target_framework != '' "#{id}@#{version} when #{target_framework}" else "#{id}@#{version} grouped:#{group}" end end |