taskjuggler 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (432) hide show
  1. data/Rakefile +1 -0
  2. data/benchmarks/depends.tjp +2 -1
  3. data/benchmarks/htmltaskreport.tjp +2 -1
  4. data/doc/classes/AppConfig.html +124 -120
  5. data/doc/classes/Arguments.html +10 -6
  6. data/doc/classes/Object.html +229 -0
  7. data/doc/classes/String.html +35 -31
  8. data/doc/classes/TaskJuggler/Account.html +18 -18
  9. data/doc/classes/TaskJuggler/AccountAttribute.html +261 -0
  10. data/doc/classes/TaskJuggler/AccountScenario.html +12 -12
  11. data/doc/classes/TaskJuggler/Allocation.html +34 -30
  12. data/doc/classes/TaskJuggler/AllocationAttribute.html +70 -70
  13. data/doc/classes/TaskJuggler/AttributeBase.html +131 -147
  14. data/doc/classes/TaskJuggler/AttributeDefinition.html +38 -21
  15. data/doc/classes/TaskJuggler/BatchProcessor.html +313 -0
  16. data/doc/classes/TaskJuggler/Booking.html +22 -18
  17. data/doc/classes/TaskJuggler/BookingListAttribute.html +42 -42
  18. data/doc/classes/TaskJuggler/BooleanAttribute.html +40 -40
  19. data/doc/classes/TaskJuggler/CSVFile.html +28 -24
  20. data/doc/classes/TaskJuggler/Charge.html +22 -18
  21. data/doc/classes/TaskJuggler/ChargeListAttribute.html +30 -30
  22. data/doc/classes/TaskJuggler/ChargeSet.html +41 -37
  23. data/doc/classes/TaskJuggler/ChargeSetListAttribute.html +46 -46
  24. data/doc/classes/TaskJuggler/ColumnListAttribute.html +231 -0
  25. data/doc/classes/TaskJuggler/ColumnTable.html +23 -21
  26. data/doc/classes/TaskJuggler/DateAttribute.html +20 -20
  27. data/doc/classes/TaskJuggler/DefinitionListAttribute.html +162 -0
  28. data/doc/classes/TaskJuggler/DependencyListAttribute.html +46 -46
  29. data/doc/classes/TaskJuggler/DurationAttribute.html +30 -30
  30. data/doc/classes/TaskJuggler/FixnumAttribute.html +20 -20
  31. data/doc/classes/TaskJuggler/FlagListAttribute.html +42 -42
  32. data/doc/classes/TaskJuggler/FloatAttribute.html +30 -30
  33. data/doc/classes/TaskJuggler/FormatListAttribute.html +197 -0
  34. data/doc/classes/TaskJuggler/GanttChart.html +236 -207
  35. data/doc/classes/TaskJuggler/GanttContainer.html +46 -42
  36. data/doc/classes/TaskJuggler/GanttHeader.html +16 -12
  37. data/doc/classes/TaskJuggler/GanttHeaderScaleItem.html +16 -12
  38. data/doc/classes/TaskJuggler/GanttLine.html +28 -24
  39. data/doc/classes/TaskJuggler/GanttLoadStack.html +22 -18
  40. data/doc/classes/TaskJuggler/GanttMilestone.html +46 -42
  41. data/doc/classes/TaskJuggler/GanttRouter.html +104 -98
  42. data/doc/classes/TaskJuggler/GanttTaskBar.html +46 -42
  43. data/doc/classes/TaskJuggler/HTMLDocument.html +12 -12
  44. data/doc/classes/TaskJuggler/HTMLGraphics.html +12 -12
  45. data/doc/classes/TaskJuggler/Interval.html +126 -120
  46. data/doc/classes/TaskJuggler/IntervalListAttribute.html +46 -46
  47. data/doc/classes/TaskJuggler/JobInfo.html +284 -0
  48. data/doc/classes/TaskJuggler/Journal.html +197 -0
  49. data/doc/classes/TaskJuggler/JournalEntry.html +218 -0
  50. data/doc/classes/TaskJuggler/KeywordArray.html +179 -0
  51. data/doc/classes/TaskJuggler/KeywordDocumentation.html +445 -396
  52. data/doc/classes/TaskJuggler/Limits/Limit.html +34 -30
  53. data/doc/classes/TaskJuggler/Limits.html +68 -62
  54. data/doc/classes/TaskJuggler/LimitsAttribute.html +40 -40
  55. data/doc/classes/TaskJuggler/ListAttributeBase.html +207 -0
  56. data/doc/classes/TaskJuggler/Log.html +72 -68
  57. data/doc/classes/TaskJuggler/LogicalAttribute.html +38 -34
  58. data/doc/classes/TaskJuggler/LogicalExpression.html +16 -12
  59. data/doc/classes/TaskJuggler/LogicalExpressionAttribute.html +194 -0
  60. data/doc/classes/TaskJuggler/LogicalFlag.html +32 -32
  61. data/doc/classes/TaskJuggler/LogicalFunction.html +28 -24
  62. data/doc/classes/TaskJuggler/LogicalOperation.html +17 -13
  63. data/doc/classes/TaskJuggler/Macro.html +10 -6
  64. data/doc/classes/TaskJuggler/MacroParser.html +36 -36
  65. data/doc/classes/TaskJuggler/MacroTable.html +40 -36
  66. data/doc/classes/TaskJuggler/Message.html +16 -12
  67. data/doc/classes/TaskJuggler/MessageHandler.html +16 -12
  68. data/doc/classes/TaskJuggler/Navigator.html +249 -0
  69. data/doc/classes/TaskJuggler/OnShiftCache.html +316 -0
  70. data/doc/classes/TaskJuggler/Project.html +1064 -678
  71. data/doc/classes/TaskJuggler/ProjectFileParser.html +90 -85
  72. data/doc/classes/TaskJuggler/PropertyAttribute.html +194 -0
  73. data/doc/classes/TaskJuggler/PropertyList.html +114 -113
  74. data/doc/classes/TaskJuggler/PropertySet.html +355 -312
  75. data/doc/classes/TaskJuggler/PropertyTreeNode.html +527 -474
  76. data/doc/classes/TaskJuggler/Query.html +90 -85
  77. data/doc/classes/TaskJuggler/RTPNavigator.html +292 -0
  78. data/doc/classes/TaskJuggler/RTPReport.html +301 -0
  79. data/doc/classes/TaskJuggler/RealFormat.html +114 -57
  80. data/doc/classes/TaskJuggler/RealFormatAttribute.html +162 -0
  81. data/doc/classes/TaskJuggler/ReferenceAttribute.html +87 -20
  82. data/doc/classes/TaskJuggler/Report.html +82 -291
  83. data/doc/classes/TaskJuggler/ReportBase.html +448 -0
  84. data/doc/classes/TaskJuggler/ReportContext.html +243 -0
  85. data/doc/classes/TaskJuggler/ReportTable.html +158 -129
  86. data/doc/classes/TaskJuggler/ReportTableCell.html +30 -26
  87. data/doc/classes/TaskJuggler/ReportTableColumn.html +29 -25
  88. data/doc/classes/TaskJuggler/ReportTableLegend.html +28 -24
  89. data/doc/classes/TaskJuggler/ReportTableLine.html +34 -30
  90. data/doc/classes/TaskJuggler/Resource.html +12 -12
  91. data/doc/classes/TaskJuggler/ResourceListAttribute.html +46 -46
  92. data/doc/classes/TaskJuggler/ResourceListRE.html +49 -57
  93. data/doc/classes/TaskJuggler/ResourceScenario.html +126 -126
  94. data/doc/classes/TaskJuggler/RichText.html +52 -48
  95. data/doc/classes/TaskJuggler/RichTextAttribute.html +30 -30
  96. data/doc/classes/TaskJuggler/RichTextDocument.html +41 -37
  97. data/doc/classes/TaskJuggler/RichTextElement.html +274 -264
  98. data/doc/classes/TaskJuggler/RichTextException.html +13 -13
  99. data/doc/classes/TaskJuggler/RichTextParser.html +48 -47
  100. data/doc/classes/TaskJuggler/RichTextProtocolExample.html +52 -55
  101. data/doc/classes/TaskJuggler/RichTextProtocolHandler.html +55 -10
  102. data/doc/classes/TaskJuggler/RichTextScanner.html +106 -245
  103. data/doc/classes/TaskJuggler/RichTextSnip.html +28 -24
  104. data/doc/classes/TaskJuggler/RichTextSyntaxRules.html +381 -301
  105. data/doc/classes/TaskJuggler/Scenario.html +6 -6
  106. data/doc/classes/TaskJuggler/ScenarioData.html +40 -36
  107. data/doc/classes/TaskJuggler/ScenarioListAttribute.html +229 -0
  108. data/doc/classes/TaskJuggler/Scoreboard.html +70 -66
  109. data/doc/classes/TaskJuggler/Shift.html +18 -18
  110. data/doc/classes/TaskJuggler/ShiftAssignment.html +58 -54
  111. data/doc/classes/TaskJuggler/ShiftAssignments.html +82 -78
  112. data/doc/classes/TaskJuggler/ShiftAssignmentsAttribute.html +40 -40
  113. data/doc/classes/TaskJuggler/ShiftScenario.html +24 -24
  114. data/doc/classes/TaskJuggler/SortListAttribute.html +196 -0
  115. data/doc/classes/TaskJuggler/SourceFileInfo.html +16 -12
  116. data/doc/classes/TaskJuggler/StringAttribute.html +30 -30
  117. data/doc/classes/TaskJuggler/SymbolAttribute.html +20 -20
  118. data/doc/classes/TaskJuggler/SyntaxReference.html +46 -42
  119. data/doc/classes/TaskJuggler/TOCEntry.html +16 -12
  120. data/doc/classes/TaskJuggler/TableColumnDefinition.html +48 -33
  121. data/doc/classes/TaskJuggler/TableOfContents.html +22 -18
  122. data/doc/classes/TaskJuggler/TableReport.html +1036 -0
  123. data/doc/classes/TaskJuggler/Task.html +12 -12
  124. data/doc/classes/TaskJuggler/TaskDependency.html +16 -12
  125. data/doc/classes/TaskJuggler/TaskListAttribute.html +46 -46
  126. data/doc/classes/TaskJuggler/TaskListRE.html +49 -58
  127. data/doc/classes/TaskJuggler/TaskScenario.html +1270 -1180
  128. data/doc/classes/TaskJuggler/TextParser/Pattern.html +100 -96
  129. data/doc/classes/TaskJuggler/TextParser/Rule.html +88 -84
  130. data/doc/classes/TaskJuggler/TextParser/StackElement.html +16 -12
  131. data/doc/classes/TaskJuggler/TextParser/TextParserResultArray.html +12 -12
  132. data/doc/classes/TaskJuggler/TextParser/TokenDoc.html +10 -6
  133. data/doc/classes/TaskJuggler/TextParser.html +203 -140
  134. data/doc/classes/TaskJuggler/TextReport.html +364 -0
  135. data/doc/classes/TaskJuggler/TextScanner/BufferStreamHandle.html +70 -70
  136. data/doc/classes/TaskJuggler/TextScanner/FileStreamHandle.html +50 -42
  137. data/doc/classes/TaskJuggler/TextScanner/StreamHandle.html +16 -12
  138. data/doc/classes/TaskJuggler/TextScanner.html +334 -240
  139. data/doc/classes/TaskJuggler/TjException.html +6 -6
  140. data/doc/classes/TaskJuggler/TjTime.html +547 -497
  141. data/doc/classes/TaskJuggler/TjpExample.html +29 -25
  142. data/doc/classes/TaskJuggler/TjpExportRE.html +77 -97
  143. data/doc/classes/TaskJuggler/TjpSyntaxRules.html +3911 -3886
  144. data/doc/classes/TaskJuggler/UserManual.html +54 -54
  145. data/doc/classes/TaskJuggler/WorkingHours.html +53 -49
  146. data/doc/classes/TaskJuggler/WorkingHoursAttribute.html +53 -85
  147. data/doc/classes/TaskJuggler/XMLBlob.html +21 -21
  148. data/doc/classes/TaskJuggler/XMLComment.html +21 -21
  149. data/doc/classes/TaskJuggler/XMLDocument.html +28 -24
  150. data/doc/classes/TaskJuggler/XMLElement.html +70 -58
  151. data/doc/classes/TaskJuggler/XMLNamedText.html +11 -11
  152. data/doc/classes/TaskJuggler/XMLText.html +36 -36
  153. data/doc/classes/TaskJuggler.html +266 -183
  154. data/doc/files/COPYING.html +1 -1
  155. data/doc/files/README.html +1 -1
  156. data/doc/files/lib/AccountScenario_rb.html +1 -1
  157. data/doc/files/lib/Account_rb.html +1 -1
  158. data/doc/files/lib/Allocation_rb.html +1 -1
  159. data/doc/files/lib/AppConfig_rb.html +1 -1
  160. data/doc/files/lib/AttributeBase_rb.html +11 -1
  161. data/doc/files/lib/AttributeDefinition_rb.html +1 -1
  162. data/doc/files/lib/Attributes_rb.html +1 -1
  163. data/doc/files/lib/{LogicalFlag_rb.html → BatchProcessor_rb.html} +8 -6
  164. data/doc/files/lib/Booking_rb.html +1 -1
  165. data/doc/files/lib/ChargeSet_rb.html +1 -1
  166. data/doc/files/lib/Charge_rb.html +1 -1
  167. data/doc/files/lib/HTMLDocument_rb.html +1 -1
  168. data/doc/files/lib/Interval_rb.html +1 -1
  169. data/doc/files/lib/Journal_rb.html +106 -0
  170. data/doc/files/lib/KeywordArray_rb.html +106 -0
  171. data/doc/files/lib/KeywordDocumentation_rb.html +1 -1
  172. data/doc/files/lib/Limits_rb.html +1 -1
  173. data/doc/files/lib/Log_rb.html +1 -1
  174. data/doc/files/lib/LogicalExpression_rb.html +1 -3
  175. data/doc/files/lib/LogicalFunction_rb.html +1 -1
  176. data/doc/files/lib/LogicalOperation_rb.html +1 -1
  177. data/doc/files/lib/MacroParser_rb.html +1 -1
  178. data/doc/files/lib/MacroTable_rb.html +1 -1
  179. data/doc/files/lib/MessageHandler_rb.html +1 -1
  180. data/doc/files/lib/Message_rb.html +1 -1
  181. data/doc/files/lib/ProjectFileParser_rb.html +5 -1
  182. data/doc/files/lib/Project_rb.html +5 -1
  183. data/doc/files/lib/PropertyList_rb.html +1 -1
  184. data/doc/files/lib/PropertySet_rb.html +1 -1
  185. data/doc/files/lib/PropertyTreeNode_rb.html +1 -1
  186. data/doc/files/lib/Query_rb.html +1 -1
  187. data/doc/files/lib/RTPNavigator_rb.html +120 -0
  188. data/doc/files/lib/RTPReport_rb.html +118 -0
  189. data/doc/files/lib/RealFormat_rb.html +1 -1
  190. data/doc/files/lib/ResourceScenario_rb.html +1 -1
  191. data/doc/files/lib/Resource_rb.html +1 -1
  192. data/doc/files/lib/RichTextDocument_rb.html +1 -1
  193. data/doc/files/lib/RichTextElement_rb.html +1 -1
  194. data/doc/files/lib/RichTextParser_rb.html +1 -1
  195. data/doc/files/lib/RichTextProtocolExample_rb.html +1 -1
  196. data/doc/files/lib/RichTextProtocolHandler_rb.html +1 -1
  197. data/doc/files/lib/RichTextScanner_rb.html +1 -1
  198. data/doc/files/lib/RichTextSnip_rb.html +1 -1
  199. data/doc/files/lib/RichTextSyntaxRules_rb.html +1 -1
  200. data/doc/files/lib/RichText_rb.html +1 -1
  201. data/doc/files/lib/ScenarioData_rb.html +1 -1
  202. data/doc/files/lib/Scenario_rb.html +1 -1
  203. data/doc/files/lib/Scoreboard_rb.html +1 -1
  204. data/doc/files/lib/ShiftAssignments_rb.html +1 -1
  205. data/doc/files/lib/ShiftScenario_rb.html +1 -1
  206. data/doc/files/lib/Shift_rb.html +1 -1
  207. data/doc/files/lib/SourceFileInfo_rb.html +1 -1
  208. data/doc/files/lib/SyntaxReference_rb.html +1 -1
  209. data/doc/files/lib/TOCEntry_rb.html +1 -1
  210. data/doc/files/lib/TableColumnDefinition_rb.html +1 -1
  211. data/doc/files/lib/TableOfContents_rb.html +1 -1
  212. data/doc/files/lib/TaskDependency_rb.html +1 -1
  213. data/doc/files/lib/TaskJuggler_rb.html +1 -1
  214. data/doc/files/lib/TaskScenario_rb.html +1 -1
  215. data/doc/files/lib/Task_rb.html +1 -1
  216. data/doc/files/lib/TextParser/Pattern_rb.html +1 -1
  217. data/doc/files/lib/TextParser/Rule_rb.html +1 -1
  218. data/doc/files/lib/TextParser/StackElement_rb.html +1 -1
  219. data/doc/files/lib/TextParser/TokenDoc_rb.html +1 -1
  220. data/doc/files/lib/TextParser_rb.html +1 -1
  221. data/doc/files/lib/TextScanner_rb.html +1 -1
  222. data/doc/files/lib/Tj3Config_rb.html +1 -1
  223. data/doc/files/lib/TjException_rb.html +1 -1
  224. data/doc/files/lib/TjTime_rb.html +1 -1
  225. data/doc/files/lib/TjpExample_rb.html +1 -1
  226. data/doc/files/lib/TjpSyntaxRules_rb.html +1 -1
  227. data/doc/files/lib/UTF8String_rb.html +1 -1
  228. data/doc/files/lib/UserManual_rb.html +1 -1
  229. data/doc/files/lib/WorkingHours_rb.html +1 -1
  230. data/doc/files/lib/XMLDocument_rb.html +1 -1
  231. data/doc/files/lib/XMLElement_rb.html +1 -1
  232. data/doc/files/lib/deep_copy_rb.html +106 -0
  233. data/doc/files/lib/ms_test_rb.html +90 -0
  234. data/doc/files/lib/reports/CSVFile_rb.html +1 -1
  235. data/doc/files/lib/reports/ColumnTable_rb.html +1 -1
  236. data/doc/files/lib/reports/GanttChart_rb.html +1 -1
  237. data/doc/files/lib/reports/GanttContainer_rb.html +1 -1
  238. data/doc/files/lib/reports/GanttHeaderScaleItem_rb.html +1 -1
  239. data/doc/files/lib/reports/GanttHeader_rb.html +1 -1
  240. data/doc/files/lib/reports/GanttLine_rb.html +1 -1
  241. data/doc/files/lib/reports/GanttLoadStack_rb.html +1 -1
  242. data/doc/files/lib/reports/GanttMilestone_rb.html +1 -1
  243. data/doc/files/lib/reports/GanttRouter_rb.html +1 -1
  244. data/doc/files/lib/reports/GanttTaskBar_rb.html +1 -1
  245. data/doc/files/lib/reports/HTMLGraphics_rb.html +1 -1
  246. data/doc/files/lib/reports/{ReportElement_rb.html → Navigator_rb.html} +6 -8
  247. data/doc/files/lib/reports/ReportBase_rb.html +106 -0
  248. data/doc/files/lib/reports/ReportContext_rb.html +106 -0
  249. data/doc/files/lib/reports/ReportTableCell_rb.html +1 -1
  250. data/doc/files/lib/reports/ReportTableColumn_rb.html +1 -1
  251. data/doc/files/lib/reports/ReportTableLegend_rb.html +1 -1
  252. data/doc/files/lib/reports/ReportTableLine_rb.html +1 -1
  253. data/doc/files/lib/reports/ReportTable_rb.html +1 -1
  254. data/doc/files/lib/reports/Report_rb.html +8 -2
  255. data/doc/files/lib/reports/ResourceListRE_rb.html +2 -2
  256. data/doc/files/lib/reports/{ReportTableElement_rb.html → TableReport_rb.html} +7 -5
  257. data/doc/files/lib/reports/TaskListRE_rb.html +2 -2
  258. data/doc/files/lib/reports/TextReport_rb.html +116 -0
  259. data/doc/files/lib/reports/TjpExportRE_rb.html +2 -2
  260. data/doc/files/lib/taskjuggler3_rb.html +61 -56
  261. data/doc/files/lib/tj3man_rb.html +1 -1
  262. data/doc/fr_class_index.html +41 -3
  263. data/doc/fr_file_index.html +21 -5
  264. data/doc/fr_method_index.html +1069 -959
  265. data/examples/ContactList.html +1467 -0
  266. data/examples/Deliveries.html +485 -0
  267. data/examples/Development.html +2525 -0
  268. data/examples/Overview.html +747 -0
  269. data/examples/Resource Graph.html +616 -0
  270. data/examples/tutorial.tjp +63 -67
  271. data/lib/AttributeBase.rb +27 -31
  272. data/lib/AttributeDefinition.rb +12 -7
  273. data/lib/Attributes.rb +134 -34
  274. data/lib/Interval.rb +2 -0
  275. data/lib/Journal.rb +44 -0
  276. data/lib/{LogicalFlag.rb → KeywordArray.rb} +5 -13
  277. data/lib/KeywordDocumentation.rb +84 -47
  278. data/lib/Limits.rb +7 -5
  279. data/lib/LogicalExpression.rb +1 -1
  280. data/lib/LogicalOperation.rb +33 -0
  281. data/lib/Project.rb +313 -99
  282. data/lib/ProjectFileParser.rb +88 -11
  283. data/lib/PropertyList.rb +2 -1
  284. data/lib/PropertySet.rb +13 -4
  285. data/lib/PropertyTreeNode.rb +34 -15
  286. data/lib/Query.rb +2 -1
  287. data/lib/RTPNavigator.rb +53 -0
  288. data/lib/RTPReport.rb +62 -0
  289. data/lib/RealFormat.rb +28 -10
  290. data/lib/RichTextElement.rb +18 -12
  291. data/lib/RichTextParser.rb +1 -0
  292. data/lib/RichTextProtocolExample.rb +8 -11
  293. data/lib/RichTextProtocolHandler.rb +11 -1
  294. data/lib/RichTextScanner.rb +308 -164
  295. data/lib/RichTextSyntaxRules.rb +24 -0
  296. data/lib/TableColumnDefinition.rb +5 -1
  297. data/lib/TaskJuggler.rb +3 -2
  298. data/lib/TaskScenario.rb +123 -31
  299. data/lib/TextParser.rb +14 -3
  300. data/lib/TextScanner.rb +210 -34
  301. data/lib/Tj3Config.rb +1 -1
  302. data/lib/TjTime.rb +15 -0
  303. data/lib/TjpExample.rb +1 -1
  304. data/lib/TjpSyntaxRules.rb +674 -473
  305. data/lib/WorkingHours.rb +1 -1
  306. data/lib/XMLElement.rb +11 -3
  307. data/lib/deep_copy.rb +72 -0
  308. data/lib/ms_test.rb +27 -0
  309. data/lib/reports/ColumnTable.rb +7 -5
  310. data/lib/reports/GanttChart.rb +60 -34
  311. data/lib/reports/GanttHeader.rb +1 -1
  312. data/lib/reports/GanttRouter.rb +7 -5
  313. data/lib/reports/Navigator.rb +72 -0
  314. data/lib/reports/Report.rb +58 -73
  315. data/lib/reports/ReportBase.rb +241 -0
  316. data/lib/reports/ReportContext.rb +41 -0
  317. data/lib/reports/ReportTable.rb +7 -2
  318. data/lib/reports/ReportTableCell.rb +3 -3
  319. data/lib/reports/ResourceListRE.rb +19 -26
  320. data/lib/reports/{ReportTableElement.rb → TableReport.rb} +297 -97
  321. data/lib/reports/TaskListRE.rb +16 -24
  322. data/lib/reports/TextReport.rb +87 -0
  323. data/lib/reports/TjpExportRE.rb +55 -50
  324. data/lib/taskjuggler3.rb +6 -1
  325. data/manual/Getting_Started +57 -6
  326. data/manual/How_To_Contribute +2 -4
  327. data/manual/Intro +2 -2
  328. data/manual/Reporting_Bugs +9 -2
  329. data/manual/Rich_Text_Attributes +41 -0
  330. data/manual/Tutorial +219 -173
  331. data/tasks/test.rake +3 -0
  332. data/test/TestSuite/CSV-Reports/celltext.tjp +2 -1
  333. data/test/TestSuite/CSV-Reports/resourcereport.tjp +2 -1
  334. data/test/TestSuite/CSV-Reports/resourcereport_with_tasks.tjp +2 -1
  335. data/test/TestSuite/CSV-Reports/sortByTree.tjp +2 -1
  336. data/test/TestSuite/CSV-Reports/sortBy_duration.down.tjp +2 -1
  337. data/test/TestSuite/CSV-Reports/sortBy_effort.up.tjp +2 -1
  338. data/test/TestSuite/CSV-Reports/sortBy_plan.start.down.tjp +2 -1
  339. data/test/TestSuite/CSV-Reports/taskreport.tjp +2 -1
  340. data/test/TestSuite/CSV-Reports/taskreport_with_resources.tjp +2 -1
  341. data/test/TestSuite/HTML-Reports/depArrows.tjp +72 -0
  342. data/test/TestSuite/HTML-Reports/reference-export.html +187 -0
  343. data/test/TestSuite/HTML-Reports/reference.tjp +21 -0
  344. data/test/TestSuite/Scheduler/Correct/Allocate.tjp +2 -1
  345. data/test/TestSuite/Scheduler/Correct/AutomaticMilestones.tjp +3 -3
  346. data/test/TestSuite/Scheduler/Correct/Booking.tjp +3 -3
  347. data/test/TestSuite/Scheduler/Correct/Container-2.tjp +37 -0
  348. data/test/TestSuite/Scheduler/Correct/Container.tjp +40 -0
  349. data/test/TestSuite/Scheduler/Correct/Depends.tjp +9 -14
  350. data/test/TestSuite/Scheduler/Correct/Duration.tjp +2 -1
  351. data/test/TestSuite/Scheduler/Correct/InheritStartEnd.tjp +20 -29
  352. data/test/TestSuite/Scheduler/Correct/Limits.tjp +11 -13
  353. data/test/TestSuite/Scheduler/Correct/Optimize-1.tjp +6 -5
  354. data/test/TestSuite/Scheduler/Correct/Optimize-2.tjp +10 -6
  355. data/test/TestSuite/Scheduler/Correct/Optimize-3.tjp +9 -6
  356. data/test/TestSuite/Scheduler/Correct/Optimize-4.tjp +9 -6
  357. data/test/TestSuite/Scheduler/Correct/Optimize-5.tjp +13 -10
  358. data/test/TestSuite/Scheduler/Correct/Precedes.tjp +9 -14
  359. data/test/TestSuite/Scheduler/Correct/Shift.tjp +9 -8
  360. data/test/TestSuite/Scheduler/Correct/checks.tji +4 -0
  361. data/test/TestSuite/Scheduler/Errors/weak_end_dep.tjp +16 -0
  362. data/test/TestSuite/Scheduler/Errors/weak_start_dep.tjp +16 -0
  363. data/test/TestSuite/Syntax/Correct/Account.tjp +1 -1
  364. data/test/TestSuite/Syntax/Correct/AutoID.tjp +21 -0
  365. data/test/TestSuite/Syntax/Correct/AutoMacros.tjp +2 -1
  366. data/test/TestSuite/Syntax/Correct/Caption.tjp +7 -6
  367. data/test/TestSuite/Syntax/Correct/Celltext.tjp +7 -4
  368. data/test/TestSuite/Syntax/Correct/Comments.tjp +1 -1
  369. data/test/TestSuite/Syntax/Correct/CompletedWork.tji +11 -19
  370. data/test/TestSuite/Syntax/Correct/CriticalPath.tjp +4 -3
  371. data/test/TestSuite/Syntax/Correct/Export.tjp +3 -1
  372. data/test/TestSuite/Syntax/Correct/Flags.tjp +2 -1
  373. data/test/TestSuite/Syntax/Correct/HtmlTaskReport.tjp +2 -1
  374. data/test/TestSuite/Syntax/Correct/Journal.tjp +18 -0
  375. data/test/TestSuite/Syntax/Correct/LoadUnits.tjp +2 -1
  376. data/test/TestSuite/Syntax/Correct/LogicalExpression.tjp +16 -0
  377. data/test/TestSuite/Syntax/Correct/Period.tjp +2 -1
  378. data/test/TestSuite/Syntax/Correct/RawHTML.tjp +4 -2
  379. data/test/TestSuite/Syntax/Correct/Reports.tjp +4 -2
  380. data/test/TestSuite/Syntax/Correct/ResourcePrefix.tji +2 -0
  381. data/test/TestSuite/Syntax/Correct/ResourcePrefix.tjp +23 -0
  382. data/test/TestSuite/Syntax/Correct/Responsible.tjp +1 -1
  383. data/test/TestSuite/Syntax/Correct/Simple.tjp +1 -1
  384. data/test/TestSuite/Syntax/Correct/String.tjp +1 -1
  385. data/test/TestSuite/Syntax/Correct/TaskRoot.tjp +2 -1
  386. data/test/TestSuite/Syntax/Correct/tutorial.tjp +92 -70
  387. data/test/TestSuite/Syntax/Errors/bad_comment.tjp +7 -0
  388. data/test/TestSuite/Syntax/Errors/bad_include.tjp +1 -1
  389. data/test/TestSuite/Syntax/Errors/bad_time_zone.tjp +6 -0
  390. data/test/TestSuite/Syntax/Errors/bad_timing_res.tjp +5 -0
  391. data/test/TestSuite/Syntax/Errors/chargeset_master.tjp +1 -1
  392. data/test/TestSuite/Syntax/Errors/container_attribute.tjp +1 -1
  393. data/test/TestSuite/Syntax/Errors/cost_acct_no_top.tjp +3 -2
  394. data/test/TestSuite/Syntax/Errors/cost_rev_same.tjp +1 -1
  395. data/test/TestSuite/Syntax/Errors/eof_in_istring1.tjp +5 -0
  396. data/test/TestSuite/Syntax/Errors/eof_in_istring2.tjp +5 -0
  397. data/test/TestSuite/Syntax/Errors/eof_in_istring3.tjp +6 -0
  398. data/test/TestSuite/Syntax/Errors/eof_in_istring4.tjp +6 -0
  399. data/test/TestSuite/Syntax/Errors/eof_in_istring5.tjp +6 -0
  400. data/test/TestSuite/Syntax/Errors/include_recursion.tji +1 -0
  401. data/test/TestSuite/Syntax/Errors/include_recursion.tjp +7 -0
  402. data/test/TestSuite/Syntax/Errors/junk_after_cut.tjp +6 -0
  403. data/test/TestSuite/Syntax/Errors/navigator_exists.tjp +10 -0
  404. data/test/TestSuite/Syntax/Errors/operand_unkn_flag.tjp +1 -1
  405. data/test/TestSuite/Syntax/Errors/report_end.tjp +1 -1
  406. data/test/TestSuite/Syntax/Errors/report_exists.tjp +10 -0
  407. data/test/TestSuite/Syntax/Errors/report_start.tjp +1 -1
  408. data/test/TestSuite/Syntax/Errors/rev_acct_no_top.tjp +1 -1
  409. data/test/TestSuite/Syntax/Errors/sort_direction.tjp +1 -1
  410. data/test/TestSuite/Syntax/Errors/sort_unknown_scen.tjp +1 -1
  411. data/test/TestSuite/Syntax/Errors/sorting_crit_exptd1.tjp +1 -1
  412. data/test/TestSuite/Syntax/Errors/sorting_crit_exptd2.tjp +1 -1
  413. data/test/TestSuite/Syntax/Errors/sorting_wbs.tjp +1 -1
  414. data/test/TestSuite/Syntax/Errors/too_large_timing_res.tjp +7 -0
  415. data/test/TestSuite/Syntax/Errors/unknown_scenario_idx.tjp +1 -1
  416. data/test/TestSuite/Syntax/Errors/unknown_task.tjp +1 -1
  417. data/test/all.rb +1 -16
  418. data/test/test_CSV-Reports.rb +8 -5
  419. data/test/test_Query.rb +2 -2
  420. data/test/test_RichText.rb +95 -0
  421. data/test/test_Scheduler.rb +8 -4
  422. data/test/test_Syntax.rb +8 -4
  423. data/test/test_deep_copy.rb +83 -0
  424. metadata +549 -487
  425. data/benchmarks/UTF-8-Strings.rb +0 -58
  426. data/doc/classes/TaskJuggler/ReportElement.html +0 -1070
  427. data/doc/classes/TaskJuggler/ReportTableElement.html +0 -644
  428. data/lib/reports/ReportElement.rb +0 -427
  429. data/test/TestSuite/Syntax/Correct/csvtest +0 -16
  430. data/test/TestSuite/Syntax/Errors/no_csv_suffix.tjp +0 -10
  431. data/test/TestSuite/Syntax/Errors/no_html_suffix.tjp +0 -10
  432. data/test/TestSuite/Syntax/Errors/report_redifinition.tjp +0 -10
@@ -5,12 +5,12 @@
5
5
  * TaskJuggler. Please see the TaskJuggler manual for a more detailed
6
6
  * description of the various syntax elements.
7
7
  */
8
- project acso "Accounting Software" "1.0" 2002-01-16 - 2002-04-28 {
8
+ project "Accounting Software" 2002-01-16 +4m {
9
9
  # Hide the clock time. Only show the date.
10
10
  timeformat "%Y-%m-%d"
11
11
  # Use US format for numbers
12
12
  numberformat "-" "" "," "." 1
13
- # Use US financial format for currency values. Don't show pence.
13
+ # Use US financial format for currency values. Don't show cents.
14
14
  currencyformat "(" ")" "," "." 0
15
15
  # Pick a day during the project that will be reported as 'today' in
16
16
  # the project reports. If not specified, the current day will be
@@ -41,7 +41,6 @@ rate 390.0
41
41
 
42
42
  # Register Good Friday as a global holiday for all resources.
43
43
  vacation "Good Friday" 2002-03-29
44
-
45
44
  flags team
46
45
 
47
46
  # This is one way to form teams
@@ -223,11 +222,13 @@ task AcSo "Accounting Software" {
223
222
  task prev "Technology Preview" {
224
223
  depends !!software.backend
225
224
  startcredit 31000.0
225
+ note "All '''major''' features should be usable."
226
226
  }
227
227
 
228
228
  task beta "Beta version" {
229
229
  depends !!test.alpha
230
230
  charge 13000.0 onstart
231
+ note "Fully functional, may contain bugs."
231
232
  }
232
233
 
233
234
  task done "Ship Product to Customer" {
@@ -239,6 +240,7 @@ task AcSo "Accounting Software" {
239
240
  # maxend 2002-04-17
240
241
  depends !!test.beta, !!manual
241
242
  charge 33000.0 onstart
243
+ note "All priority 1 and 2 bugs must be fixed."
242
244
  }
243
245
  }
244
246
  }
@@ -248,23 +250,49 @@ task AcSo "Accounting Software" {
248
250
  # scheduled. But no reports would be generated to visualize the
249
251
  # results.
250
252
 
251
- # A traditional Gantt chart with a project overview.
252
- htmltaskreport "ProjectPlanOverview.html" {
253
- prolog '
254
- == Accounting Software Project ==
255
- ----
256
- === Project Overview ===
253
+ navigator navbar {
254
+ hidereport 0
255
+ }
257
256
 
258
- The project is structured into 3 phases.
257
+ textreport "Overview" {
258
+ formats html
259
+ header -8<-
260
+ == Accounting Software Project ==
261
+ ----
262
+ <[navigator id="navbar"]>
263
+ ----
264
+ ->8-
265
+ center '<[report id="overview"]>'
266
+
267
+ textreport "Development" {
268
+ center '<[report id="development"]>'
269
+ }
259
270
 
260
- # Specification
261
- # [[Development]]
262
- # Testing
271
+ textreport "Deliveries" {
272
+ center '<[report id="deliveries"]>'
273
+ }
263
274
 
264
- === Project Plan ===
265
- '
275
+ textreport "ContactList" {
276
+ center '<[report id="contactList"]>'
277
+ }
278
+ textreport "Resource Graph" {
279
+ center '<[report id="resourceGraph"]>'
280
+ }
281
+ }
266
282
 
267
- headline "Project Plan Overview"
283
+ # A traditional Gantt chart with a project overview.
284
+ taskreport overview "" {
285
+ header -8<-
286
+ === Project Overview ===
287
+
288
+ The project is structured into 3 phases.
289
+
290
+ # Specification
291
+ # [[Development]]
292
+ # Testing
293
+
294
+ === Project Plan ===
295
+ ->8-
268
296
  columns hierarchindex, name, start, end, effort, duration, cost,
269
297
  revenue, chart
270
298
  # For this report we like to have the abbreviated weekday in front
@@ -273,48 +301,43 @@ The project is structured into 3 phases.
273
301
  loadunit days
274
302
  hideresource 1
275
303
  balance cost rev
276
- caption '
277
- All effort values are in man days.
278
- '
279
-
280
- epilog '
281
- === Staffing ===
282
-
283
- All project phases are properly staffed. See [[ResourceGraph]] for
284
- detailed resource allocations.
285
-
286
- === Current Status ===
287
-
288
- The project started off with a delay of 4 days. This slightly affected
289
- the original schedule. See [[Deliveries]] for the impact on the
290
- delivery dates.
291
- '
304
+ caption 'All effort values are in man days.'
305
+
306
+ footer -8<-
307
+ === Staffing ===
308
+
309
+ All project phases are properly staffed. See [[ResourceGraph]] for
310
+ detailed resource allocations.
311
+
312
+ === Current Status ===
313
+
314
+ The project started off with a delay of 4 days. This slightly affected
315
+ the original schedule. See [[Deliveries]] for the impact on the
316
+ delivery dates.
317
+ ->8-
292
318
  }
293
319
 
294
320
  # A list of tasks showing the resources assigned to each task.
295
- htmltaskreport "Development.html" {
321
+ taskreport development "" {
296
322
  headline "Development - Resource Allocation Report"
297
323
  columns hierarchindex, name, start, end, effort { title "Work" },
298
324
  duration, chart { scale day }
299
325
  timeformat "%Y-%m-%d"
300
- loadunit days
301
326
  hideresource ~isleaf()
302
327
  sortresources name.up
303
328
  }
304
329
 
305
330
  # A list of all tasks with the percentage completed for each task
306
- htmltaskreport "Deliveries.html" {
331
+ taskreport deliveries "" {
307
332
  headline "Project Deliveries"
308
- columns hierarchindex, name, start, end, complete, chart
309
- timeformat "%a %Y-%m-%d"
333
+ columns hierarchindex, name, start, end, note, complete, chart
310
334
  taskroot AcSo.deliveries
311
335
  loadunit days
312
336
  hideresource 1
313
337
  scenarios plan, delayed
314
338
  }
315
-
316
339
  # A list of all employees with their contact details.
317
- htmlresourcereport "ContactList.html" {
340
+ resourcereport contactList "" {
318
341
  headline "Contact list and duty plan"
319
342
  columns name, Email { cellurl "mailto:$${Email}" }, Phone,
320
343
  chart { scale day }
@@ -325,37 +348,10 @@ htmlresourcereport "ContactList.html" {
325
348
 
326
349
  # A graph showing resource allocation. It identifies whether each
327
350
  # resource is under- or over-allocated for.
328
- htmlresourcereport "ResourceGraph.html" {
351
+ resourcereport resourceGraph "" {
329
352
  headline "Resource Allocation Graph"
330
353
  columns no, name, effort, rate, weekly #, utilization, freeload, chart
331
354
  loadunit shortauto
332
355
  hidetask ~isleaf()
333
356
  sorttasks plan.start.up
334
357
  }
335
-
336
- # A list of all project resources, both human and material resources,
337
- # together with the associated costs.
338
- htmlresourcereport "ResourceSheet.html" {
339
- headline "Resource Sheet"
340
- columns no, name, id, effort, weekly, rate, cost
341
- loadunit days
342
- hidetask ~isleaf()
343
- sorttasks plan.start.up
344
- balance cost rev
345
- }
346
-
347
- # A list of resources and each task associated with each resource.
348
- htmlresourcereport "ResourceUsage.html" {
349
- headline "Resource Usage Report"
350
- columns no, name, chart { scale day } #, utilization, freeload, cost, chart
351
- loadunit days
352
- sorttasks plan.start.up
353
- hidetask ~isleaf()
354
- end 2002-02-10
355
- }
356
-
357
- csvtaskreport "csvtest.csv" {
358
- columns no, name, id, effort, revenue, cost
359
- loadunit days
360
- }
361
-
data/lib/AttributeBase.rb CHANGED
@@ -10,6 +10,8 @@
10
10
  # published by the Free Software Foundation.
11
11
  #
12
12
 
13
+ require 'deep_copy'
14
+
13
15
  class TaskJuggler
14
16
 
15
17
  # This class is the base for all property attribute types. Each property can
@@ -21,8 +23,8 @@ class TaskJuggler
21
23
  # The class can track wheter the attribute value was provided by the project
22
24
  # file, inherited from another property or computed during scheduling.
23
25
  #
24
- # Attributes that are of an inheritable type will be copied from a parent
25
- # property.
26
+ # Attributes that are of an inherited type will be copied from a parent
27
+ # property or the global scope.
26
28
  class AttributeBase
27
29
  attr_reader :property, :type, :provided, :inherited, :value
28
30
 
@@ -38,39 +40,19 @@ class TaskJuggler
38
40
  # Flat that marks whether the value of this attribute was provided by the
39
41
  # user (in contrast to being calculated).
40
42
  @provided = false
41
- # Some types can provide the default value as result of a initValue()
42
- # method. If that does not exists, the default value from the
43
- # AttributeDefinition.
44
- if respond_to?('initValue')
45
- @value = initValue(@type.default)
46
- else
47
- @value = @type.default
48
- end
49
- # The mode is flag that controls how value assignements affect the flags.
43
+ # Create the initial value according to the specified default for this
44
+ # type.
45
+ @value = @type.default.deep_clone
46
+ # The mode is flag that controls how value assignments affect the flags.
50
47
  @@mode = 0
51
48
  end
52
49
 
53
- # Call this function to inherit _value_ from another property. It is very
54
- # important that the values are deep copied as they may be modified later
55
- # on.
50
+ # Call this function to inherit _value_ from the parent property. It is
51
+ # very important that the values are deep copied as they may be modified
52
+ # later on.
56
53
  def inherit(value)
57
54
  @inherited = true
58
- if value.is_a?(Fixnum) || value.is_a?(Float) ||
59
- value.is_a?(TrueClass) || value.is_a?(FalseClass)
60
- @value = value
61
- elsif value.is_a?(Limits)
62
- @value = Limits.new(value)
63
- elsif value.is_a?(ShiftAssignments)
64
- @value = ShiftAssignments.new(value)
65
- elsif value.is_a?(String) || value.is_a?(TjTime)
66
- @value = value.clone
67
- elsif value.is_a?(WorkingHours)
68
- @value = WorkingHours.new(value)
69
- elsif value.is_a?(Array)
70
- @value = Array.new(value)
71
- else
72
- raise "Don't know how to copy values of class #{value.class}"
73
- end
55
+ @value = value.deep_clone
74
56
  end
75
57
 
76
58
  # Change the @@mode. 0 means values are provided, 1 means values are
@@ -127,5 +109,19 @@ class TaskJuggler
127
109
 
128
110
  end
129
111
 
130
- end
112
+ # The ListAttributeBase is a specialized form of AttributeBase for a list of
113
+ # values instead of a single value. It will be used as a base class for all
114
+ # attributes that hold lists.
115
+ class ListAttributeBase < AttributeBase
131
116
 
117
+ def initialize(property, type)
118
+ super
119
+ end
120
+
121
+ def to_s
122
+ @value.join(', ')
123
+ end
124
+
125
+ end
126
+
127
+ end
@@ -17,28 +17,33 @@ class TaskJuggler
17
17
  # these bits of information, the PropertySet objects generate the attribute
18
18
  # lists for each PropertyTreeNode upon creation of the node.
19
19
  class AttributeDefinition
20
- attr_reader :id, :name, :objClass, :inheritable, :scenarioSpecific,
21
- :userDefined, :default
20
+ attr_reader :id, :name, :objClass, :inheritedFromParent,
21
+ :inheritedFromProject, :scenarioSpecific, :userDefined, :default
22
22
 
23
23
  # Create a new AttributeDefinition. _id_ is the ID of the attribute. It must
24
24
  # be unique within the PropertySet where it is used. _name_ is a more
25
25
  # descriptive text that will be used in report columns and the like.
26
26
  # _objClass_ is a reference to the class (not the object itself) of the
27
27
  # attribute. The possible classes all have names ending in Attribute.
28
- # _inheritable_ is a boolean flag that needs to be true if the node can
29
- # inherit the setting from the attribute of the parent node.
28
+ # _inheritedFromParent_ is a boolean flag that needs to be true if the
29
+ # node can inherit the setting from the attribute of the parent node.
30
+ # _inheritedFromProject_ is a boolen flag that needs to be true if the
31
+ # node can inherit the setting from an attribute in the global scope.
30
32
  # _scenarioSpecific_ is a boolean flag that is set to true if the attribute
31
33
  # can have different values for each scenario. _default_ is the default
32
34
  # value that is set upon creation of the attribute.
33
- def initialize(id, name, objClass, inheritable, scenarioSpecific, default,
34
- userDefined = false)
35
+ def initialize(id, name, objClass, inheritedFromParent, inheritedFromProject,
36
+ scenarioSpecific, default, userDefined = false)
35
37
  @id = id
36
38
  @name = name
37
39
  @objClass = objClass
38
- @inheritable = inheritable
40
+ @inheritedFromParent = inheritedFromParent
41
+ @inheritedFromProject = inheritedFromProject
39
42
  @scenarioSpecific = scenarioSpecific
40
43
  @default = default
41
44
  @userDefined = userDefined
45
+ # Prevent objects from being deep copied.
46
+ freeze
42
47
  end
43
48
 
44
49
  end
data/lib/Attributes.rb CHANGED
@@ -21,9 +21,28 @@ require 'WorkingHours'
21
21
 
22
22
  class TaskJuggler
23
23
 
24
+ class AccountAttribute < AttributeBase
25
+ def initialize(property, type)
26
+ super
27
+ end
28
+
29
+ def AccountAttribute::tjpId
30
+ 'account'
31
+ end
32
+
33
+ def to_s
34
+ @value ? @value.id : ''
35
+ end
36
+
37
+ def to_tjp
38
+ @value ? @value.id : ''
39
+ end
40
+
41
+ end
42
+
24
43
  class AllocationAttribute < AttributeBase
25
44
  def initialize(property, type)
26
- super(property, type)
45
+ super
27
46
 
28
47
  @value = Array.new
29
48
  end
@@ -93,7 +112,7 @@ class TaskJuggler
93
112
 
94
113
  class BooleanAttribute < AttributeBase
95
114
  def initialize(property, type)
96
- super(property, type)
115
+ super
97
116
  end
98
117
 
99
118
  def BooleanAttribute::tjpId
@@ -112,7 +131,7 @@ class TaskJuggler
112
131
 
113
132
  class ChargeListAttribute < AttributeBase
114
133
  def initialize(property, type)
115
- super(property, type)
134
+ super
116
135
  end
117
136
 
118
137
  def ChargeListAttribute::tjpId
@@ -130,7 +149,7 @@ class TaskJuggler
130
149
  class ChargeSetListAttribute < AttributeBase
131
150
 
132
151
  def initialize(property, type)
133
- super(property, type)
152
+ super
134
153
 
135
154
  @value = Array.new
136
155
  end
@@ -153,9 +172,26 @@ class TaskJuggler
153
172
 
154
173
  end
155
174
 
175
+ class ColumnListAttribute < AttributeBase
176
+
177
+ def initialize(property, type)
178
+ super
179
+
180
+ @value = Array.new
181
+ end
182
+
183
+ def ColumnListAttribute::tjpId
184
+ 'columns'
185
+ end
186
+
187
+ def to_s
188
+ "TODO"
189
+ end
190
+ end
191
+
156
192
  class DateAttribute < AttributeBase
157
193
  def initialize(property, type)
158
- super(property, type)
194
+ super
159
195
  end
160
196
 
161
197
  def DateAttribute::tjpId
@@ -163,9 +199,15 @@ class TaskJuggler
163
199
  end
164
200
  end
165
201
 
202
+ class DefinitionListAttribute < ListAttributeBase
203
+ def initialize(property, type)
204
+ super
205
+ end
206
+ end
207
+
166
208
  class DependencyListAttribute < AttributeBase
167
209
  def initialize(property, type)
168
- super(property, type)
210
+ super
169
211
 
170
212
  @value = Array.new
171
213
  end
@@ -190,7 +232,7 @@ class TaskJuggler
190
232
 
191
233
  class DurationAttribute < AttributeBase
192
234
  def initialize(property, type)
193
- super(property, type)
235
+ super
194
236
  end
195
237
 
196
238
  def DurationAttribute::tjpId
@@ -205,7 +247,7 @@ class TaskJuggler
205
247
 
206
248
  class FixnumAttribute < AttributeBase
207
249
  def initialize(property, type)
208
- super(property, type)
250
+ super
209
251
  end
210
252
 
211
253
  def FixnumAttribute::tjpId
@@ -215,7 +257,7 @@ class TaskJuggler
215
257
 
216
258
  class FlagListAttribute < AttributeBase
217
259
  def initialize(property, type)
218
- super(property, type)
260
+ super
219
261
 
220
262
  @value = Array.new
221
263
  end
@@ -236,7 +278,7 @@ class TaskJuggler
236
278
 
237
279
  class FloatAttribute < AttributeBase
238
280
  def initialize(property, type)
239
- super(property, type)
281
+ super
240
282
  end
241
283
 
242
284
  def FloatAttribute::tjpId
@@ -249,9 +291,21 @@ class TaskJuggler
249
291
 
250
292
  end
251
293
 
294
+ class FormatListAttribute < AttributeBase
295
+
296
+ def initialize(property, type)
297
+ super
298
+ end
299
+
300
+ def to_s
301
+ @value.join(', ')
302
+ end
303
+
304
+ end
305
+
252
306
  class IntervalListAttribute < AttributeBase
253
307
  def initialize(property, type)
254
- super(property, type)
308
+ super
255
309
 
256
310
  @value = Array.new
257
311
  end
@@ -277,7 +331,7 @@ class TaskJuggler
277
331
  class LimitsAttribute < AttributeBase
278
332
 
279
333
  def initialize(property, type)
280
- super(property, type)
334
+ super
281
335
  end
282
336
 
283
337
  def setProject(project)
@@ -294,20 +348,32 @@ class TaskJuggler
294
348
 
295
349
  end
296
350
 
351
+ class LogicalExpressionAttribute < AttributeBase
297
352
 
298
- class LogicalAttribute
353
+ def initialize(property, type)
354
+ super
355
+ end
299
356
 
300
- def initialize(attribute, scenario)
301
- @scenarioIdx = scenario
302
- super(attribute)
357
+ def LogicalExpressionAttribute::tjpId
358
+ 'logicalexpression'
303
359
  end
304
360
 
305
- def LogicalAttribute::tjpId
306
- 'logical'
361
+ end
362
+
363
+ class PropertyAttribute < AttributeBase
364
+ def initialize(property, type)
365
+ super
366
+ end
367
+
368
+ def PropertyAttribute::tjpId
369
+ 'property'
307
370
  end
371
+ end
372
+
373
+ class RealFormatAttribute < AttributeBase
308
374
 
309
- def eval(expr)
310
- expr.property[@operand1, @scenarioIdx]
375
+ def initialize(property, type)
376
+ super
311
377
  end
312
378
 
313
379
  end
@@ -320,11 +386,19 @@ class TaskJuggler
320
386
  def ReferenceAttribute::tjpId
321
387
  'reference'
322
388
  end
389
+
390
+ def url
391
+ @value ? @value[0] : nil
392
+ end
393
+
394
+ def label
395
+ @value ? @value[1][0] : nil
396
+ end
323
397
  end
324
398
 
325
399
  class ResourceListAttribute < AttributeBase
326
400
  def initialize(property, type)
327
- super(property, type)
401
+ super
328
402
 
329
403
  @value = Array.new
330
404
  end
@@ -349,7 +423,7 @@ class TaskJuggler
349
423
 
350
424
  class RichTextAttribute < AttributeBase
351
425
  def initialize(property, type)
352
- super(property, type)
426
+ super
353
427
  end
354
428
 
355
429
  def RichTextAttribute::tjpId
@@ -362,10 +436,26 @@ class TaskJuggler
362
436
 
363
437
  end
364
438
 
439
+ class ScenarioListAttribute < AttributeBase
440
+ def initialize(property, type)
441
+ super
442
+ end
443
+
444
+ def ScenarioListAttribute::tjpId
445
+ 'scenarios'
446
+ end
447
+
448
+ def to_s
449
+ @value.join(', ')
450
+ end
451
+
452
+ end
453
+
454
+
365
455
  class ShiftAssignmentsAttribute < AttributeBase
366
456
 
367
457
  def initialize(property, type)
368
- super(property, type)
458
+ super
369
459
  end
370
460
 
371
461
  def setProject(project)
@@ -382,9 +472,23 @@ class TaskJuggler
382
472
 
383
473
  end
384
474
 
475
+ class SortListAttribute < AttributeBase
476
+
477
+ def initialize(property, type)
478
+ super
479
+
480
+ @value = Array.new
481
+ end
482
+
483
+ def SortListAttribute::tjpId
484
+ 'sorting'
485
+ end
486
+
487
+ end
488
+
385
489
  class StringAttribute < AttributeBase
386
490
  def initialize(property, type)
387
- super(property, type)
491
+ super
388
492
  end
389
493
 
390
494
  def StringAttribute::tjpId
@@ -399,7 +503,7 @@ class TaskJuggler
399
503
 
400
504
  class SymbolAttribute < AttributeBase
401
505
  def initialize(property, type)
402
- super(property, type)
506
+ super
403
507
  end
404
508
 
405
509
  def SymbolAttribute::tjpId
@@ -409,7 +513,7 @@ class TaskJuggler
409
513
 
410
514
  class TaskListAttribute < AttributeBase
411
515
  def initialize(property, type)
412
- super(property, type)
516
+ super
413
517
 
414
518
  @value = Array.new
415
519
  end
@@ -434,11 +538,7 @@ class TaskJuggler
434
538
 
435
539
  class WorkingHoursAttribute < AttributeBase
436
540
  def initialize(property, type)
437
- super(property, type)
438
- end
439
-
440
- def initValue(arg)
441
- WorkingHours.new
541
+ super
442
542
  end
443
543
 
444
544
  def WorkingHoursAttribute::tjpId
@@ -447,13 +547,13 @@ class TaskJuggler
447
547
 
448
548
  def to_tjp
449
549
  dayNames = %w( sun mon tue wed thu fri sat )
450
- str = 'workinghours '
550
+ str = ''
451
551
  7.times do |day|
452
- str += "#{dayNames[day]} "
552
+ str += "workinghours #{dayNames[day]} "
453
553
  whs = @value.getWorkingHours(day)
454
554
  if whs.empty?
455
555
  str += "off"
456
- str += ",\n" if day < 6
556
+ str += "\n" if day < 6
457
557
  next
458
558
  end
459
559
  first = true
data/lib/Interval.rb CHANGED
@@ -45,6 +45,8 @@ class TaskJuggler
45
45
  # Two arguments, a start and end date
46
46
  @start = args[0]
47
47
  @end = args[1]
48
+ raise "Interval start must be a date" unless @start.is_a?(TjTime)
49
+ raise "Interval end must be a date" unless @end.is_a?(TjTime)
48
50
  if @end < @start
49
51
  raise "Invalid interval"
50
52
  end