Class: TaskJuggler::ChargeSetListAttribute

Inherits:
ListAttributeBase show all
Defined in:
lib/taskjuggler/Attributes.rb

Overview

A ChargeSetListAttribute encapsulates a list of ChargeSet objects as PropertyTreeNode attributes.

Instance Attribute Summary

Attributes inherited from AttributeBase

#inherited, #property, #provided, #type

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from ListAttributeBase

#isList?, isList?

Methods inherited from AttributeBase

#get, #id, #inherit, isList?, #isList?, mode, #name, #nil?, #reset, #set, setMode, #to_num, #to_rti, #to_sort

Constructor Details

#initialize(property, type, container) ⇒ ChargeSetListAttribute

Returns a new instance of ChargeSetListAttribute.



163
164
165
# File 'lib/taskjuggler/Attributes.rb', line 163

def initialize(property, type, container)
  super
end

Class Method Details

.tjpIdObject



167
168
169
# File 'lib/taskjuggler/Attributes.rb', line 167

def ChargeSetListAttribute::tjpId
  'chargeset'
end

Instance Method Details

#to_s(query = nil) ⇒ Object



171
172
173
174
175
# File 'lib/taskjuggler/Attributes.rb', line 171

def to_s(query = nil)
  out = []
  get.each { |i| out << i.to_s }
  out.join(", ")
end

#to_tjpObject



177
178
179
180
181
# File 'lib/taskjuggler/Attributes.rb', line 177

def to_tjp
  out = []
  get.each { |i| out << i.to_s }
  @type.id + " " + out.join(', ')
end