taskjuggler 0.0.5 → 0.0.6
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.
- data/CHANGELOG +2086 -0
- data/benchmarks/666tasks.tjp +3183 -0
- data/benchmarks/booking.tjp +14 -10
- data/doc/AppConfig.html +95 -73
- data/doc/Arguments.html +22 -2
- data/doc/CHANGELOG.html +2587 -0
- data/doc/COPYING.html +21 -1
- data/doc/Object.html +161 -122
- data/doc/README.html +21 -1
- data/doc/RuntimeConfig.html +26 -6
- data/doc/String.html +38 -18
- data/doc/StringIO.html +579 -0
- data/doc/TaskJuggler.html +251 -143
- data/doc/TaskJuggler/Account.html +26 -6
- data/doc/TaskJuggler/AccountAttribute.html +28 -8
- data/doc/TaskJuggler/AccountScenario.html +24 -4
- data/doc/TaskJuggler/Allocation.html +30 -10
- data/doc/TaskJuggler/AllocationAttribute.html +28 -8
- data/doc/TaskJuggler/AttributeBase.html +46 -26
- data/doc/TaskJuggler/AttributeDefinition.html +22 -2
- data/doc/TaskJuggler/BatchProcessor.html +40 -20
- data/doc/TaskJuggler/Booking.html +26 -6
- data/doc/TaskJuggler/BookingListAttribute.html +28 -8
- data/doc/TaskJuggler/BooleanAttribute.html +28 -8
- data/doc/TaskJuggler/CSVFile.html +308 -146
- data/doc/TaskJuggler/CellSettingPattern.html +22 -2
- data/doc/TaskJuggler/CellSettingPatternList.html +26 -6
- data/doc/TaskJuggler/Charge.html +26 -6
- data/doc/TaskJuggler/ChargeListAttribute.html +26 -6
- data/doc/TaskJuggler/ChargeSet.html +33 -13
- data/doc/TaskJuggler/ChargeSetListAttribute.html +28 -8
- data/doc/TaskJuggler/ColumnListAttribute.html +26 -6
- data/doc/TaskJuggler/ColumnTable.html +24 -4
- data/doc/TaskJuggler/Daemon.html +26 -6
- data/doc/TaskJuggler/DateAttribute.html +26 -6
- data/doc/TaskJuggler/DefinitionListAttribute.html +22 -2
- data/doc/TaskJuggler/DependencyListAttribute.html +28 -8
- data/doc/TaskJuggler/DurationAttribute.html +28 -8
- data/doc/TaskJuggler/FixnumAttribute.html +24 -4
- data/doc/TaskJuggler/FlagListAttribute.html +28 -8
- data/doc/TaskJuggler/FloatAttribute.html +26 -6
- data/doc/TaskJuggler/FormatListAttribute.html +24 -4
- data/doc/TaskJuggler/GanttChart.html +147 -126
- data/doc/TaskJuggler/GanttContainer.html +34 -14
- data/doc/TaskJuggler/GanttHeader.html +28 -8
- data/doc/TaskJuggler/GanttHeaderScaleItem.html +24 -4
- data/doc/TaskJuggler/GanttLine.html +38 -18
- data/doc/TaskJuggler/GanttLoadStack.html +26 -6
- data/doc/TaskJuggler/GanttMilestone.html +34 -14
- data/doc/TaskJuggler/GanttRouter.html +50 -30
- data/doc/TaskJuggler/GanttTaskBar.html +34 -14
- data/doc/TaskJuggler/HTMLDocument.html +26 -6
- data/doc/TaskJuggler/HTMLGraphics.html +30 -10
- data/doc/TaskJuggler/Interval.html +40 -22
- data/doc/TaskJuggler/IntervalListAttribute.html +28 -8
- data/doc/TaskJuggler/JobInfo.html +24 -4
- data/doc/TaskJuggler/Journal.html +226 -147
- data/doc/TaskJuggler/JournalEntry.html +22 -2
- data/doc/TaskJuggler/JournalEntryList.html +129 -112
- data/doc/TaskJuggler/KeywordArray.html +26 -6
- data/doc/TaskJuggler/KeywordDocumentation.html +46 -26
- data/doc/TaskJuggler/Limits.html +152 -123
- data/doc/TaskJuggler/Limits/Limit.html +149 -70
- data/doc/TaskJuggler/LimitsAttribute.html +36 -51
- data/doc/TaskJuggler/ListAttributeBase.html +24 -4
- data/doc/TaskJuggler/Log.html +50 -32
- data/doc/TaskJuggler/LogFile.html +37 -17
- data/doc/TaskJuggler/LogicalAttribute.html +53 -33
- data/doc/TaskJuggler/LogicalExpression.html +26 -6
- data/doc/TaskJuggler/LogicalExpressionAttribute.html +32 -12
- data/doc/TaskJuggler/LogicalFlag.html +42 -22
- data/doc/TaskJuggler/LogicalFunction.html +204 -140
- data/doc/TaskJuggler/LogicalOperation.html +135 -111
- data/doc/TaskJuggler/Macro.html +22 -2
- data/doc/TaskJuggler/MacroParser.html +32 -12
- data/doc/TaskJuggler/MacroTable.html +32 -12
- data/doc/TaskJuggler/ManagerResponsibilities.html +24 -4
- data/doc/TaskJuggler/ManagerStatusRecord.html +24 -4
- data/doc/TaskJuggler/Message.html +24 -4
- data/doc/TaskJuggler/MessageHandler.html +24 -4
- data/doc/TaskJuggler/Navigator.html +104 -71
- data/doc/TaskJuggler/NavigatorElement.html +32 -12
- data/doc/TaskJuggler/NikuProject.html +22 -2
- data/doc/TaskJuggler/NikuReport.html +310 -228
- data/doc/TaskJuggler/NikuResource.html +22 -2
- data/doc/TaskJuggler/NodeListAttribute.html +615 -0
- data/doc/TaskJuggler/OnShiftCache.html +32 -12
- data/doc/TaskJuggler/ProcessIntercom.html +205 -78
- data/doc/TaskJuggler/ProcessIntercomIface.html +26 -6
- data/doc/TaskJuggler/Project.html +708 -660
- data/doc/TaskJuggler/ProjectBroker.html +506 -304
- data/doc/TaskJuggler/ProjectBrokerIface.html +61 -41
- data/doc/TaskJuggler/ProjectFileParser.html +429 -373
- data/doc/TaskJuggler/ProjectFileScanner.html +1790 -0
- data/doc/TaskJuggler/ProjectRecord.html +80 -60
- data/doc/TaskJuggler/ProjectServer.html +312 -237
- data/doc/TaskJuggler/ProjectServerIface.html +101 -43
- data/doc/TaskJuggler/PropertyAttribute.html +32 -12
- data/doc/TaskJuggler/PropertyList.html +166 -145
- data/doc/TaskJuggler/PropertySet.html +254 -224
- data/doc/TaskJuggler/PropertyTreeNode.html +670 -536
- data/doc/TaskJuggler/Query.html +169 -148
- data/doc/TaskJuggler/RTFHandlers.html +622 -0
- data/doc/TaskJuggler/RTFNavigator.html +28 -8
- data/doc/TaskJuggler/RTFQuery.html +40 -20
- data/doc/TaskJuggler/RTFReport.html +62 -25
- data/doc/TaskJuggler/RTFReportLink.html +765 -0
- data/doc/TaskJuggler/RealFormat.html +26 -6
- data/doc/TaskJuggler/RealFormatAttribute.html +26 -6
- data/doc/TaskJuggler/ReferenceAttribute.html +59 -39
- data/doc/TaskJuggler/Report.html +402 -251
- data/doc/TaskJuggler/ReportBase.html +162 -137
- data/doc/TaskJuggler/ReportContext.html +112 -29
- data/doc/TaskJuggler/ReportServer.html +89 -64
- data/doc/TaskJuggler/ReportServerIface.html +75 -55
- data/doc/TaskJuggler/ReportServerRecord.html +54 -31
- data/doc/TaskJuggler/ReportServlet.html +980 -0
- data/doc/TaskJuggler/ReportTable.html +41 -21
- data/doc/TaskJuggler/ReportTableCell.html +214 -170
- data/doc/TaskJuggler/ReportTableColumn.html +30 -10
- data/doc/TaskJuggler/ReportTableLegend.html +36 -16
- data/doc/TaskJuggler/ReportTableLine.html +32 -12
- data/doc/TaskJuggler/Resource.html +99 -87
- data/doc/TaskJuggler/ResourceListAttribute.html +59 -39
- data/doc/TaskJuggler/ResourceListRE.html +47 -26
- data/doc/TaskJuggler/ResourceScenario.html +403 -437
- data/doc/TaskJuggler/RichText.html +26 -6
- data/doc/TaskJuggler/RichTextAttribute.html +50 -30
- data/doc/TaskJuggler/RichTextDocument.html +37 -17
- data/doc/TaskJuggler/RichTextElement.html +475 -413
- data/doc/TaskJuggler/RichTextException.html +22 -2
- data/doc/TaskJuggler/RichTextFunctionExample.html +28 -8
- data/doc/TaskJuggler/RichTextFunctionHandler.html +24 -4
- data/doc/TaskJuggler/RichTextImage.html +22 -2
- data/doc/TaskJuggler/RichTextIntermediate.html +38 -18
- data/doc/TaskJuggler/RichTextParser.html +56 -34
- data/doc/TaskJuggler/RichTextScanner.html +82 -61
- data/doc/TaskJuggler/RichTextSnip.html +34 -14
- data/doc/TaskJuggler/RichTextSyntaxRules.html +507 -353
- data/doc/TaskJuggler/Scenario.html +22 -2
- data/doc/TaskJuggler/ScenarioData.html +30 -46
- data/doc/TaskJuggler/ScenarioListAttribute.html +38 -18
- data/doc/TaskJuggler/Scoreboard.html +42 -22
- data/doc/TaskJuggler/SheetHandlerBase.html +40 -20
- data/doc/TaskJuggler/SheetReceiver.html +333 -295
- data/doc/TaskJuggler/SheetSender.html +253 -230
- data/doc/TaskJuggler/Shift.html +26 -6
- data/doc/TaskJuggler/ShiftAssignment.html +89 -73
- data/doc/TaskJuggler/ShiftAssignments.html +226 -234
- data/doc/TaskJuggler/ShiftAssignmentsAttribute.html +39 -54
- data/doc/TaskJuggler/ShiftScenario.html +28 -8
- data/doc/TaskJuggler/SortListAttribute.html +34 -14
- data/doc/TaskJuggler/SourceFileInfo.html +24 -4
- data/doc/TaskJuggler/StatusSheetReceiver.html +24 -3
- data/doc/TaskJuggler/StatusSheetReport.html +168 -153
- data/doc/TaskJuggler/StatusSheetSender.html +24 -3
- data/doc/TaskJuggler/StringAttribute.html +38 -18
- data/doc/TaskJuggler/SymbolAttribute.html +32 -12
- data/doc/TaskJuggler/SyntaxReference.html +40 -20
- data/doc/TaskJuggler/TOCEntry.html +26 -6
- data/doc/TaskJuggler/TSResourceRecord.html +22 -2
- data/doc/TaskJuggler/TSTaskRecord.html +22 -2
- data/doc/TaskJuggler/TableColumnDefinition.html +59 -22
- data/doc/TaskJuggler/TableOfContents.html +26 -6
- data/doc/TaskJuggler/TableReport.html +937 -904
- data/doc/TaskJuggler/Task.html +55 -36
- data/doc/TaskJuggler/TaskDependency.html +24 -4
- data/doc/TaskJuggler/TaskListAttribute.html +50 -30
- data/doc/TaskJuggler/TaskListRE.html +27 -7
- data/doc/TaskJuggler/TaskScenario.html +1273 -1153
- data/doc/TaskJuggler/TextFormatter.html +28 -8
- data/doc/TaskJuggler/TextParser.html +585 -338
- data/doc/TaskJuggler/TextParser/Pattern.html +54 -34
- data/doc/TaskJuggler/TextParser/Rule.html +95 -73
- data/doc/TaskJuggler/TextParser/StackElement.html +39 -17
- data/doc/TaskJuggler/TextParser/TextParserResultArray.html +24 -4
- data/doc/TaskJuggler/TextParser/TokenDoc.html +22 -2
- data/doc/TaskJuggler/TextReport.html +28 -8
- data/doc/TaskJuggler/TextScanner.html +400 -1404
- data/doc/TaskJuggler/TextScanner/BufferStreamHandle.html +28 -240
- data/doc/TaskJuggler/TextScanner/FileStreamHandle.html +37 -184
- data/doc/TaskJuggler/TextScanner/MacroStackEntry.html +682 -0
- data/doc/TaskJuggler/TextScanner/StreamHandle.html +342 -67
- data/doc/TaskJuggler/TimeSheet.html +48 -28
- data/doc/TaskJuggler/TimeSheetReceiver.html +24 -3
- data/doc/TaskJuggler/TimeSheetRecord.html +47 -27
- data/doc/TaskJuggler/TimeSheetReport.html +154 -133
- data/doc/TaskJuggler/TimeSheetSender.html +24 -3
- data/doc/TaskJuggler/TimeSheetSummary.html +137 -91
- data/doc/TaskJuggler/TimeSheets.html +26 -6
- data/doc/TaskJuggler/Tj3AppBase.html +85 -58
- data/doc/TaskJuggler/Tj3Client.html +292 -238
- data/doc/TaskJuggler/Tj3Daemon.html +159 -74
- data/doc/TaskJuggler/Tj3SheetAppBase.html +26 -6
- data/doc/TaskJuggler/Tj3SsReceiver.html +26 -6
- data/doc/TaskJuggler/Tj3SsSender.html +53 -26
- data/doc/TaskJuggler/Tj3TsReceiver.html +28 -7
- data/doc/TaskJuggler/Tj3TsSender.html +26 -6
- data/doc/TaskJuggler/Tj3TsSummary.html +26 -6
- data/doc/TaskJuggler/TjException.html +22 -2
- data/doc/TaskJuggler/TjTime.html +216 -160
- data/doc/TaskJuggler/TjpExample.html +34 -14
- data/doc/TaskJuggler/TjpExportRE.html +403 -407
- data/doc/TaskJuggler/TjpSyntaxRules.html +4805 -4408
- data/doc/TaskJuggler/URLParameter.html +649 -0
- data/doc/TaskJuggler/UserManual.html +42 -22
- data/doc/TaskJuggler/WebServer.html +702 -0
- data/doc/TaskJuggler/WorkingHours.html +38 -18
- data/doc/TaskJuggler/WorkingHoursAttribute.html +61 -41
- data/doc/TaskJuggler/XMLBlob.html +24 -4
- data/doc/TaskJuggler/XMLComment.html +24 -4
- data/doc/TaskJuggler/XMLDocument.html +30 -10
- data/doc/TaskJuggler/XMLElement.html +34 -14
- data/doc/TaskJuggler/XMLNamedText.html +22 -2
- data/doc/TaskJuggler/XMLText.html +24 -4
- data/doc/index.html +1841 -1666
- data/doc/lib/AccountScenario_rb.html +1 -1
- data/doc/lib/Account_rb.html +1 -1
- data/doc/lib/Allocation_rb.html +1 -1
- data/doc/lib/AppConfig_rb.html +2 -2
- data/doc/lib/AttributeBase_rb.html +1 -1
- data/doc/lib/AttributeDefinition_rb.html +1 -1
- data/doc/lib/Attributes_rb.html +2 -2
- data/doc/lib/BatchProcessor_rb.html +1 -1
- data/doc/lib/Booking_rb.html +1 -1
- data/doc/lib/ChargeSet_rb.html +1 -1
- data/doc/lib/Charge_rb.html +1 -1
- data/doc/lib/HTMLDocument_rb.html +1 -1
- data/doc/lib/Interval_rb.html +1 -1
- data/doc/lib/Journal_rb.html +2 -2
- data/doc/lib/KeywordArray_rb.html +1 -1
- data/doc/lib/KeywordDocumentation_rb.html +1 -1
- data/doc/lib/Limits_rb.html +2 -2
- data/doc/lib/LogFile_rb.html +2 -2
- data/doc/lib/Log_rb.html +1 -1
- data/doc/lib/LogicalExpression_rb.html +1 -1
- data/doc/lib/LogicalFunction_rb.html +2 -2
- data/doc/lib/LogicalOperation_rb.html +2 -2
- data/doc/lib/MacroParser_rb.html +1 -1
- data/doc/lib/MacroTable_rb.html +1 -1
- data/doc/lib/MessageHandler_rb.html +1 -1
- data/doc/lib/Message_rb.html +1 -1
- data/doc/lib/ProjectFileParser_rb.html +4 -8
- data/doc/lib/ProjectFileScanner_rb.html +67 -0
- data/doc/lib/Project_rb.html +2 -2
- data/doc/lib/PropertyList_rb.html +2 -2
- data/doc/lib/PropertySet_rb.html +2 -2
- data/doc/lib/PropertyTreeNode_rb.html +2 -2
- data/doc/lib/Query_rb.html +2 -2
- data/doc/lib/RTFHandlers_rb.html +73 -0
- data/doc/lib/RTFNavigator_rb.html +1 -1
- data/doc/lib/RTFQuery_rb.html +1 -1
- data/doc/lib/RTFReportLink_rb.html +71 -0
- data/doc/lib/RTFReport_rb.html +2 -2
- data/doc/lib/RealFormat_rb.html +1 -1
- data/doc/lib/ResourceScenario_rb.html +2 -2
- data/doc/lib/Resource_rb.html +2 -2
- data/doc/lib/RichTextDocument_rb.html +1 -1
- data/doc/lib/RichTextElement_rb.html +2 -2
- data/doc/lib/RichTextFunctionExample_rb.html +1 -1
- data/doc/lib/RichTextFunctionHandler_rb.html +1 -1
- data/doc/lib/RichTextParser_rb.html +2 -2
- data/doc/lib/RichTextScanner_rb.html +2 -2
- data/doc/lib/RichTextSnip_rb.html +1 -1
- data/doc/lib/RichTextSyntaxRules_rb.html +2 -2
- data/doc/lib/RichText_rb.html +1 -1
- data/doc/lib/RuntimeConfig_rb.html +1 -1
- data/doc/lib/ScenarioData_rb.html +2 -2
- data/doc/lib/Scenario_rb.html +1 -1
- data/doc/lib/Scoreboard_rb.html +1 -1
- data/doc/lib/SheetHandlerBase_rb.html +1 -1
- data/doc/lib/SheetReceiver_rb.html +2 -2
- data/doc/lib/SheetSender_rb.html +4 -2
- data/doc/lib/ShiftAssignments_rb.html +4 -2
- data/doc/lib/ShiftScenario_rb.html +1 -1
- data/doc/lib/Shift_rb.html +1 -1
- data/doc/lib/SourceFileInfo_rb.html +1 -1
- data/doc/lib/StatusSheetReceiver_rb.html +2 -2
- data/doc/lib/StatusSheetSender_rb.html +2 -2
- data/doc/lib/SyntaxReference_rb.html +1 -1
- data/doc/lib/TOCEntry_rb.html +1 -1
- data/doc/lib/TableColumnDefinition_rb.html +2 -2
- data/doc/lib/TableOfContents_rb.html +1 -1
- data/doc/lib/TaskDependency_rb.html +1 -1
- data/doc/lib/TaskJuggler_rb.html +2 -2
- data/doc/lib/TaskScenario_rb.html +2 -2
- data/doc/lib/Task_rb.html +2 -2
- data/doc/lib/TextFormatter_rb.html +1 -1
- data/doc/lib/TextParser/Pattern_rb.html +1 -1
- data/doc/lib/TextParser/Rule_rb.html +2 -2
- data/doc/lib/TextParser/StackElement_rb.html +2 -2
- data/doc/lib/TextParser/TokenDoc_rb.html +1 -1
- data/doc/lib/TextParser_rb.html +2 -2
- data/doc/lib/TextScanner_rb.html +6 -2
- data/doc/lib/TimeSheetReceiver_rb.html +2 -2
- data/doc/lib/TimeSheetSender_rb.html +2 -2
- data/doc/lib/TimeSheetSummary_rb.html +2 -2
- data/doc/lib/TimeSheets_rb.html +2 -2
- data/doc/lib/Tj3AppBase_rb.html +2 -2
- data/doc/lib/Tj3Config_rb.html +2 -2
- data/doc/lib/Tj3SheetAppBase_rb.html +2 -2
- data/doc/lib/TjException_rb.html +1 -1
- data/doc/lib/TjTime_rb.html +2 -2
- data/doc/lib/TjpExample_rb.html +1 -1
- data/doc/lib/TjpSyntaxRules_rb.html +2 -2
- data/doc/lib/URLParameter_rb.html +67 -0
- data/doc/lib/UTF8String_rb.html +1 -1
- data/doc/lib/UserManual_rb.html +1 -1
- data/doc/lib/WorkingHours_rb.html +1 -1
- data/doc/lib/XMLDocument_rb.html +2 -2
- data/doc/lib/XMLElement_rb.html +1 -1
- data/doc/lib/daemon/Daemon_rb.html +1 -1
- data/doc/lib/daemon/ProcessIntercom_rb.html +2 -2
- data/doc/lib/daemon/ProjectBroker_rb.html +4 -2
- data/doc/lib/daemon/ProjectServer_rb.html +2 -2
- data/doc/lib/daemon/ReportServer_rb.html +2 -2
- data/doc/lib/daemon/WebServer_rb.html +75 -0
- data/doc/lib/deep_copy_rb.html +2 -2
- data/doc/lib/reports/CSVFile_rb.html +2 -2
- data/doc/lib/reports/ColumnTable_rb.html +1 -1
- data/doc/lib/reports/GanttChart_rb.html +2 -2
- data/doc/lib/reports/GanttContainer_rb.html +1 -1
- data/doc/lib/reports/GanttHeaderScaleItem_rb.html +1 -1
- data/doc/lib/reports/GanttHeader_rb.html +1 -1
- data/doc/lib/reports/GanttLine_rb.html +1 -1
- data/doc/lib/reports/GanttLoadStack_rb.html +1 -1
- data/doc/lib/reports/GanttMilestone_rb.html +1 -1
- data/doc/lib/reports/GanttRouter_rb.html +1 -1
- data/doc/lib/reports/GanttTaskBar_rb.html +1 -1
- data/doc/lib/reports/HTMLGraphics_rb.html +1 -1
- data/doc/lib/reports/Navigator_rb.html +2 -2
- data/doc/lib/reports/NikuReport_rb.html +2 -2
- data/doc/lib/reports/ReportBase_rb.html +2 -2
- data/doc/lib/reports/ReportContext_rb.html +2 -2
- data/doc/lib/reports/ReportTableCell_rb.html +2 -2
- data/doc/lib/reports/ReportTableColumn_rb.html +1 -1
- data/doc/lib/reports/ReportTableLegend_rb.html +1 -1
- data/doc/lib/reports/ReportTableLine_rb.html +1 -1
- data/doc/lib/reports/ReportTable_rb.html +2 -2
- data/doc/lib/reports/Report_rb.html +2 -2
- data/doc/lib/reports/ResourceListRE_rb.html +2 -2
- data/doc/lib/reports/StatusSheetReport_rb.html +2 -2
- data/doc/lib/reports/TableReport_rb.html +2 -2
- data/doc/lib/reports/TaskListRE_rb.html +2 -2
- data/doc/lib/reports/TextReport_rb.html +1 -1
- data/doc/lib/reports/TimeSheetReport_rb.html +2 -2
- data/doc/lib/reports/TjpExportRE_rb.html +2 -2
- data/doc/lib/ruby-signal-bug_rb.html +1 -1
- data/doc/lib/taskjuggler3_rb.html +2 -2
- data/doc/lib/tj3client_rb.html +2 -2
- data/doc/lib/tj3d_rb.html +2 -2
- data/doc/lib/tj3man_rb.html +1 -1
- data/doc/lib/tj3ss_receiver_rb.html +1 -1
- data/doc/lib/tj3ss_sender_rb.html +2 -2
- data/doc/lib/tj3ts_receiver_rb.html +2 -2
- data/doc/lib/tj3ts_sender_rb.html +1 -1
- data/doc/lib/tj3ts_summary_rb.html +1 -1
- data/doc/rdoc.css +9 -4
- data/examples/tutorial.tjp +17 -15
- data/gem_spec.rb +3 -0
- data/lib/AppConfig.rb +3 -1
- data/lib/Attributes.rb +10 -8
- data/lib/Journal.rb +55 -20
- data/lib/Limits.rb +72 -46
- data/lib/LogFile.rb +3 -3
- data/lib/LogicalFunction.rb +19 -6
- data/lib/LogicalOperation.rb +5 -1
- data/lib/Project.rb +37 -9
- data/lib/ProjectFileParser.rb +25 -22
- data/lib/ProjectFileScanner.rb +365 -0
- data/lib/PropertyList.rb +2 -1
- data/lib/PropertySet.rb +14 -4
- data/lib/PropertyTreeNode.rb +42 -29
- data/lib/Query.rb +3 -1
- data/lib/RTFHandlers.rb +35 -0
- data/lib/RTFReport.rb +23 -6
- data/lib/RTFReportLink.rb +72 -0
- data/lib/Resource.rb +8 -16
- data/lib/ResourceScenario.rb +1 -22
- data/lib/RichTextElement.rb +42 -0
- data/lib/RichTextParser.rb +6 -4
- data/lib/RichTextScanner.rb +5 -5
- data/lib/RichTextSyntaxRules.rb +48 -10
- data/lib/ScenarioData.rb +5 -3
- data/lib/SheetReceiver.rb +24 -6
- data/lib/SheetSender.rb +17 -13
- data/lib/ShiftAssignments.rb +56 -52
- data/lib/StatusSheetReceiver.rb +1 -0
- data/lib/StatusSheetSender.rb +1 -0
- data/lib/TableColumnDefinition.rb +4 -2
- data/lib/Task.rb +8 -9
- data/lib/TaskJuggler.rb +21 -11
- data/lib/TaskScenario.rb +61 -26
- data/lib/TextParser.rb +268 -106
- data/lib/TextParser/Rule.rb +4 -2
- data/lib/TextParser/StackElement.rb +6 -4
- data/lib/TextScanner.rb +283 -700
- data/lib/TimeSheetReceiver.rb +1 -0
- data/lib/TimeSheetSender.rb +1 -0
- data/lib/TimeSheetSummary.rb +51 -26
- data/lib/TimeSheets.rb +1 -1
- data/lib/Tj3AppBase.rb +8 -1
- data/lib/Tj3Config.rb +1 -1
- data/lib/TjTime.rb +5 -0
- data/lib/TjpSyntaxRules.rb +360 -144
- data/lib/URLParameter.rb +30 -0
- data/lib/XMLDocument.rb +2 -2
- data/lib/daemon/ProcessIntercom.rb +50 -9
- data/lib/daemon/ProjectBroker.rb +63 -10
- data/lib/daemon/ProjectServer.rb +47 -16
- data/lib/daemon/ReportServer.rb +9 -4
- data/lib/daemon/WebServer.rb +204 -0
- data/lib/deep_copy.rb +4 -1
- data/lib/reports/CSVFile.rb +150 -66
- data/lib/reports/GanttChart.rb +2 -1
- data/lib/reports/Navigator.rb +18 -5
- data/lib/reports/NikuReport.rb +32 -2
- data/lib/reports/Report.rb +65 -37
- data/lib/reports/ReportBase.rb +14 -9
- data/lib/reports/ReportContext.rb +19 -4
- data/lib/reports/ReportTable.rb +2 -2
- data/lib/reports/ReportTableCell.rb +54 -30
- data/lib/reports/ResourceListRE.rb +4 -3
- data/lib/reports/StatusSheetReport.rb +8 -13
- data/lib/reports/TableReport.rb +47 -32
- data/lib/reports/TaskListRE.rb +3 -3
- data/lib/reports/TimeSheetReport.rb +14 -5
- data/lib/reports/TjpExportRE.rb +14 -19
- data/lib/taskjuggler3.rb +15 -0
- data/lib/tj3client.rb +9 -7
- data/lib/tj3d.rb +38 -10
- data/lib/tj3ss_sender.rb +7 -0
- data/lib/tj3ts_receiver.rb +1 -0
- data/manual/Day_To_Day_Juggling +1 -1
- data/manual/Rich_Text_Attributes +8 -0
- data/manual/TaskJuggler_2x_Migration +7 -0
- data/manual/The_TaskJuggler_Syntax +20 -6
- data/prj_cfg.rb +3 -2
- data/tasks/changelog.rake +36 -0
- data/tasks/csts.rake +2 -3
- data/tasks/gem.rake +10 -0
- data/tasks/missing.rake +0 -17
- data/test/TestSuite/ReportGenerator/Correct/Journal.html +63 -0
- data/test/TestSuite/ReportGenerator/Correct/Journal.tjp +14 -0
- data/test/TestSuite/{HTML-Reports/LogicalFunctions.tjp → ReportGenerator/Correct/LogicalFunctions1.tjp} +2 -2
- data/test/TestSuite/ReportGenerator/Correct/LogicalFunctions2.csv +3 -0
- data/test/TestSuite/ReportGenerator/Correct/LogicalFunctions2.tjp +19 -0
- data/test/TestSuite/ReportGenerator/Correct/css/tjmanual.css +66 -0
- data/test/TestSuite/ReportGenerator/Correct/css/tjreport.css +407 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/details.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/flag-green.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/flag-red.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/flag-yellow.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/resource.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/resourcegroup.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/task.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/taskgroup.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/trend-down.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/trend-flat.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/icons/trend-up.png +0 -0
- data/test/TestSuite/ReportGenerator/Correct/opennodes.csv +2 -0
- data/test/TestSuite/ReportGenerator/Correct/opennodes.tjp +26 -0
- data/test/TestSuite/ReportGenerator/Correct/refs/Journal-1.csv +6 -0
- data/test/TestSuite/ReportGenerator/Correct/refs/LogicalFunctions1-1.csv +7 -0
- data/test/TestSuite/ReportGenerator/Correct/refs/LogicalFunctions2-1.csv +2 -0
- data/test/TestSuite/ReportGenerator/Correct/refs/opennodes-1.csv +2 -0
- data/test/TestSuite/ReportGenerator/Correct/scripts/wz_tooltip.js +1301 -0
- data/test/TestSuite/ReportGenerator/Errors/rtp_report_recursion.tjp +20 -0
- data/test/TestSuite/Scheduler/Correct/Container.html +349 -0
- data/test/TestSuite/Scheduler/Correct/Limits.tjp +11 -4
- data/test/TestSuite/Scheduler/Correct/Shift2.html +464 -150
- data/test/TestSuite/Scheduler/Correct/TimeSheet2.html +108 -0
- data/test/TestSuite/Scheduler/Correct/TimeSheet2.tjp +7 -0
- data/test/TestSuite/Scheduler/Correct/css/tjmanual.css +14 -0
- data/test/TestSuite/Scheduler/Correct/css/tjreport.css +233 -21
- data/test/TestSuite/Scheduler/Correct/scripts/wz_tooltip.js +20 -20
- data/test/TestSuite/StatusSheetTemplates/project.tji +35 -0
- data/test/TestSuite/StatusSheetTemplates/project.tjp +56 -0
- data/test/TestSuite/StatusSheets/run +3 -2
- data/test/TestSuite/Syntax/Correct/Include.tjp +1 -1
- data/test/TestSuite/Syntax/Correct/Macro-1.tjp +1 -1
- data/test/TestSuite/Syntax/Correct/Macro-2.tjp +6 -0
- data/test/TestSuite/Syntax/Correct/Macro-3.tjp +14 -0
- data/test/TestSuite/Syntax/Correct/ResourcePrefix.html +32 -0
- data/test/TestSuite/Syntax/Correct/css/tjmanual.css +66 -0
- data/test/TestSuite/Syntax/Correct/css/tjreport.css +407 -0
- data/test/TestSuite/Syntax/Correct/icons/details.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/flag-green.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/flag-red.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/flag-yellow.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/resource.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/resourcegroup.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/task.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/taskgroup.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/trend-down.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/trend-flat.png +0 -0
- data/test/TestSuite/Syntax/Correct/icons/trend-up.png +0 -0
- data/test/TestSuite/Syntax/Correct/include/dir1/file2.tji +3 -0
- data/test/TestSuite/Syntax/Correct/include/dir1/file5.tji +2 -0
- data/test/TestSuite/Syntax/Correct/include/dir3/all.tji +3 -0
- data/test/TestSuite/Syntax/Correct/include/dir3/file1.tji +2 -0
- data/test/TestSuite/Syntax/Correct/include/dir3/file2.tji +1 -0
- data/test/TestSuite/Syntax/Correct/scripts/wz_tooltip.js +1301 -0
- data/test/TestSuite/Syntax/Correct/tutorial.tjp +13 -13
- data/test/TestSuite/Syntax/Errors/empty.tjp +1 -1
- data/test/TestSuite/Syntax/Errors/include_recursion.tjp +1 -0
- data/test/TestSuite/Syntax/Errors/macro_stack_overflow.tjp +2 -1
- data/test/TestSuite/Syntax/Errors/{eof_in_istring1.tjp → no_token_match1.tjp} +2 -2
- data/test/TestSuite/Syntax/Errors/{eof_in_istring2.tjp → no_token_match2.tjp} +2 -2
- data/test/TestSuite/Syntax/Errors/{eof_in_istring3.tjp → no_token_match3.tjp} +1 -1
- data/test/TestSuite/Syntax/Errors/{eof_in_istring4.tjp → no_token_match4.tjp} +1 -1
- data/test/TestSuite/Syntax/Errors/{eof_in_istring5.tjp → no_token_match5.tjp} +1 -1
- data/test/TestSuite/Syntax/Errors/not_scheduled.tjp +13 -0
- data/test/TestSuite/Syntax/Errors/unsupported_token.tjp +1 -1
- data/test/TestSuite/TimeSheets/run +5 -5
- data/test/test_CSVFile.rb +75 -0
- data/test/test_Limits.rb +63 -5
- data/test/test_ProjectFileScanner.rb +163 -0
- data/test/test_ReportGenerator.rb +81 -0
- data/test/test_RichText.rb +21 -3
- data/test/test_Scheduler.rb +1 -1
- data/test/test_ShiftAssignments.rb +4 -4
- data/test/test_Syntax.rb +1 -1
- data/test/test_URLParameter.rb +30 -0
- metadata +126 -32
- data/test/TestSuite/Scheduler/Errors/not_scheduled.tjp +0 -8
- data/test/TestSuite/Syntax/Errors/bad_comment.tjp +0 -7
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/boss_2002-03-01.tji +0 -36
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/dev1_2002-03-01.tji +0 -48
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/dev2_2002-03-01.tji +0 -67
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/dev3_2002-03-01.tji +0 -67
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/doc_2002-03-01.tji +0 -48
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/resources.yml +0 -31
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/2002-03-01/test_2002-03-01.tji +0 -36
- data/test/TestSuite/TimeSheets/TimeSheetTemplates/acceptable_intervals +0 -1
- data/test/TestSuite/TimeSheets/TimeSheets/2002-03-01/all.tji +0 -1
- data/test/TestSuite/TimeSheets/TimeSheets/2002-03-01/dev2_2002-03-01.tji +0 -54
- data/test/TestSuite/TimeSheets/TimeSheets/all.tji +0 -2
- data/test/TestSuite/TimeSheets/receiver.log +0 -102
- data/test/TestSuite/TimeSheets/sender.log +0 -794
- data/test/TestSuite/TimeSheets/summary.log +0 -884
- data/test/TestSuite/TimeSheets/timesheets.log +0 -45
- data/test/TestSuite/TimeSheets/tj3d.log +0 -292
- data/test/test_TextScanner.rb +0 -95
|
@@ -0,0 +1,365 @@
|
|
|
1
|
+
#!/usr/bin/env ruby -w
|
|
2
|
+
# encoding: UTF-8
|
|
3
|
+
#
|
|
4
|
+
# = ProjectFileScanner.rb -- The TaskJuggler III Project Management Software
|
|
5
|
+
#
|
|
6
|
+
# Copyright (c) 2006, 2007, 2008, 2009, 2010 by Chris Schlaeger <cs@kde.org>
|
|
7
|
+
#
|
|
8
|
+
# This program is free software; you can redistribute it and/or modify
|
|
9
|
+
# it under the terms of version 2 of the GNU General Public License as
|
|
10
|
+
# published by the Free Software Foundation.
|
|
11
|
+
#
|
|
12
|
+
|
|
13
|
+
require 'TextScanner'
|
|
14
|
+
|
|
15
|
+
class TaskJuggler
|
|
16
|
+
|
|
17
|
+
# This class specializes the TextScanner class to detect the tokens of the
|
|
18
|
+
# TJP syntax.
|
|
19
|
+
class ProjectFileScanner < TextScanner
|
|
20
|
+
|
|
21
|
+
def initialize(masterFile, messageHandler)
|
|
22
|
+
super
|
|
23
|
+
|
|
24
|
+
tokenPatterns = [
|
|
25
|
+
# Any white spaces
|
|
26
|
+
[ nil, /\s+/, :tjp, method('newPos') ],
|
|
27
|
+
|
|
28
|
+
# Single line comments starting with #
|
|
29
|
+
[ nil, /#.*\n?/, :tjp, method('newPos') ],
|
|
30
|
+
|
|
31
|
+
# C++ style single line comments starting with //
|
|
32
|
+
[ nil, /\/\/.*\n?/, :tjp, method('newPos') ],
|
|
33
|
+
|
|
34
|
+
# C style single line comment /* .. */.
|
|
35
|
+
[ nil, /\/\*.*\*\//, :tjp, method('newPos') ],
|
|
36
|
+
|
|
37
|
+
# C style multi line comment: We need three patterns here. The first
|
|
38
|
+
# one is for the start of the string. It switches the scanner mode to
|
|
39
|
+
# the :cppComment mode.
|
|
40
|
+
[ nil, /\/\*([^*]*[^\/]|.*)\n/, :tjp, method('startComment') ],
|
|
41
|
+
# This is the string end pattern. It switches back to tjp mode.
|
|
42
|
+
[ nil, /.*\*\//, :cppComment, method('endComment') ],
|
|
43
|
+
# This pattern matches string lines that contain neither the start,
|
|
44
|
+
# nor the end of the string.
|
|
45
|
+
[ nil, /^.*\n/, :cppComment ],
|
|
46
|
+
|
|
47
|
+
# Macro Call: This case is more complicated because we want to replace
|
|
48
|
+
# macro calls inside of numbers, strings and identifiers. For this to
|
|
49
|
+
# work, macro calls may have a prefix that looks like a number, a part
|
|
50
|
+
# of a string or an identifier. This prefix is preserved and
|
|
51
|
+
# re-injected into the scanner together with the expanded text. Macro
|
|
52
|
+
# calls may span multiple lines. The ${ and the macro name must be in
|
|
53
|
+
# the first line. Arguments that span multiple lines are not
|
|
54
|
+
# supported. As above, we need rules for the start, the end and lines
|
|
55
|
+
# with neither start nor end. Macro calls inside of strings need a
|
|
56
|
+
# special start pattern that is active in the string modes. Both
|
|
57
|
+
# patterns switch the scanner to macroCall mode.
|
|
58
|
+
[ nil, /([-a-zA-Z_0-9>:.+]*|"(\\"|[^"])*|'(\\'|[^'])*|-8<-.*)?\$\{\s*([a-zA-Z_]\w*)(\s*"(\\"|[^"])*")*/,
|
|
59
|
+
:tjp, method('startMacroCall') ],
|
|
60
|
+
# This pattern is similar to the previous one, but is active inside of
|
|
61
|
+
# multi-line strings. The corresponding rule for sizzors strings
|
|
62
|
+
# can be found below.
|
|
63
|
+
[ nil, /(\\"|[^"])*\$\{\s*([a-zA-Z_]\w*)(\s*"(\\"|[^"])*")*/,
|
|
64
|
+
:dqString, method('startMacroCall') ],
|
|
65
|
+
[ nil, /(\\'|[^'])*\$\{\s*([a-zA-Z_]\w*)(\s*"(\\"|[^"])*")*/,
|
|
66
|
+
:sqString, method('startMacroCall') ],
|
|
67
|
+
# This pattern matches the end of a macro call. It injects the prefix
|
|
68
|
+
# and the expanded macro into the scanner again. The mode is restored
|
|
69
|
+
# to the previous mode.
|
|
70
|
+
[ nil, /(\s*"(\\"|[^"])*")*\s*\}/, :macroCall, method('endMacroCall') ],
|
|
71
|
+
# This pattern collects macro call arguments in lines that contain
|
|
72
|
+
# neither the start nor the end of the macro.
|
|
73
|
+
[ nil, /.*\n/, :macroCall, method('midMacroCall') ],
|
|
74
|
+
|
|
75
|
+
# An ID with a colon suffix: foo:
|
|
76
|
+
[ 'ID_WITH_COLON', /[a-zA-Z_]\w*:/, :tjp, method('chop') ],
|
|
77
|
+
|
|
78
|
+
# An absolute ID: a.b.c
|
|
79
|
+
[ 'ABSOLUTE_ID', /[a-zA-Z_]\w*(\.[a-zA-Z_]\w*)+/ ],
|
|
80
|
+
|
|
81
|
+
# A normal ID: bar
|
|
82
|
+
[ 'ID', /[a-zA-Z_]\w*/ ],
|
|
83
|
+
|
|
84
|
+
# A date
|
|
85
|
+
[ 'DATE', /\d{4}-\d{1,2}-\d{1,2}(-\d{1,2}:\d{1,2}(:\d{1,2})?(-[-+]?\d{4})?)?/, :tjp, method('to_date') ],
|
|
86
|
+
|
|
87
|
+
# A time of day
|
|
88
|
+
[ 'TIME', /\d{1,2}:\d{2}/, :tjp, method('to_time') ],
|
|
89
|
+
|
|
90
|
+
# A floating point number (e. g. 3.143)
|
|
91
|
+
[ 'FLOAT', /\d*\.\d+/, :tjp, method('to_f') ],
|
|
92
|
+
|
|
93
|
+
# An integer number
|
|
94
|
+
[ 'INTEGER', /\d+/, :tjp, method('to_i') ],
|
|
95
|
+
|
|
96
|
+
# Multi line string enclosed with double quotes. The string may
|
|
97
|
+
# contain double quotes prefixed by a backslash. The first rule
|
|
98
|
+
# switches the scanner to dqString mode.
|
|
99
|
+
[ 'nil', /"(\\"|[^"])*/, :tjp, method('startStringDQ') ],
|
|
100
|
+
# Any line not containing the start or end.
|
|
101
|
+
[ 'nil', /^(\\"|[^"])*\n/, :dqString, method('midStringDQ') ],
|
|
102
|
+
# The end of the string.
|
|
103
|
+
[ 'STRING', /(\\"|[^"])*"/, :dqString, method('endStringDQ') ],
|
|
104
|
+
|
|
105
|
+
# Multi line string enclosed with single quotes.
|
|
106
|
+
[ 'nil', /'(\\'|[^'])*/, :tjp, method('startStringSQ') ],
|
|
107
|
+
# Any line not containing the start or end.
|
|
108
|
+
[ 'nil', /^(\\'|[^'])*\n/, :sqString, method('midStringSQ') ],
|
|
109
|
+
# The end of the string.
|
|
110
|
+
[ 'STRING', /(\\'|[^'])*'/, :sqString, method('endStringSQ') ],
|
|
111
|
+
|
|
112
|
+
# Scizzors marked string -8<- ... ->8-: The opening mark must be the
|
|
113
|
+
# last thing in the line. The indentation of the first line after the
|
|
114
|
+
# opening mark determines the indentation for all following lines. So,
|
|
115
|
+
# we first switch the scanner to szrString1 mode.
|
|
116
|
+
[ 'nil', /-8<-.*\n/, :tjp, method('startStringSZR') ],
|
|
117
|
+
# Since the first line can be the last line (empty string case), we
|
|
118
|
+
# need to detect the end in szrString1 and szrString mode. The
|
|
119
|
+
# patterns switch the scanner back to tjp mode.
|
|
120
|
+
[ 'STRING', /\s*->8-/, :szrString1, method('endStringSZR') ],
|
|
121
|
+
[ 'STRING', /\s*->8-/, :szrString, method('endStringSZR') ],
|
|
122
|
+
# This rule handles macros inside of sizzors strings.
|
|
123
|
+
[ nil, /.*\$\{\s*([a-zA-Z_]\w*)(\s*"(\\"|[^"])*")*/,
|
|
124
|
+
[ :szrString, :szrString1 ], method('startMacroCall') ],
|
|
125
|
+
# Any line not containing the start or end.
|
|
126
|
+
[ 'nil', /.*\n/, :szrString1, method('firstStringSZR') ],
|
|
127
|
+
[ 'nil', /.*\n/, :szrString, method('midStringSZR') ],
|
|
128
|
+
|
|
129
|
+
# Single line macro definition
|
|
130
|
+
[ 'MACRO', /\[.*\]\n/, :tjp, method('chop2nl') ],
|
|
131
|
+
|
|
132
|
+
# Multi line macro definition: The pattern switches the scanner into
|
|
133
|
+
# macroDef mode.
|
|
134
|
+
[ nil, /\[.*\n/, :tjp, method('startMacroDef') ],
|
|
135
|
+
# The end of the macro is marked by a ']' that is immediately followed
|
|
136
|
+
# by a line break. It switches the scanner back to tjp mode.
|
|
137
|
+
[ 'MACRO', /.*\]\n/, :macroDef, method('endMacroDef') ],
|
|
138
|
+
# Any line not containing the start or end.
|
|
139
|
+
[ nil, /.*\n/, :macroDef, method('midMacroDef') ],
|
|
140
|
+
|
|
141
|
+
# Some multi-char literals.
|
|
142
|
+
[ 'LITERAL', /<=?/ ],
|
|
143
|
+
[ 'LITERAL', />=?/ ],
|
|
144
|
+
[ 'LITERAL', /!=?/ ],
|
|
145
|
+
|
|
146
|
+
# Everything else is returned as a single-char literal.
|
|
147
|
+
[ 'LITERAL', /./ ]
|
|
148
|
+
]
|
|
149
|
+
|
|
150
|
+
tokenPatterns.each do |pat|
|
|
151
|
+
type = pat[0]
|
|
152
|
+
regExp = pat[1]
|
|
153
|
+
mode = pat[2] || :tjp
|
|
154
|
+
postProc = pat[3]
|
|
155
|
+
addPattern(type, regExp, mode, postProc)
|
|
156
|
+
end
|
|
157
|
+
self.mode = :tjp
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
private
|
|
161
|
+
|
|
162
|
+
def to_i(type, match)
|
|
163
|
+
[ type, match.to_i ]
|
|
164
|
+
end
|
|
165
|
+
|
|
166
|
+
def to_f(type, match)
|
|
167
|
+
[ type, match.to_f ]
|
|
168
|
+
end
|
|
169
|
+
|
|
170
|
+
def to_time(type, match)
|
|
171
|
+
h, m, s = match.split(':')
|
|
172
|
+
h = h.to_i
|
|
173
|
+
m = m.to_i
|
|
174
|
+
s = 0 if s.nil?
|
|
175
|
+
[ type, h * 3600 + m * 60 + s ]
|
|
176
|
+
end
|
|
177
|
+
|
|
178
|
+
def to_date(type, match)
|
|
179
|
+
[ type, TjTime.new(match) ]
|
|
180
|
+
end
|
|
181
|
+
|
|
182
|
+
def newPos(type, match)
|
|
183
|
+
@startOfToken = sourceFileInfo
|
|
184
|
+
[ nil, '' ]
|
|
185
|
+
end
|
|
186
|
+
|
|
187
|
+
def chop(type, match)
|
|
188
|
+
[ type, match[0..-2] ]
|
|
189
|
+
end
|
|
190
|
+
|
|
191
|
+
def chop2(type, match)
|
|
192
|
+
# Remove first and last character.
|
|
193
|
+
[ type, match[1..-2] ]
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
def chop2nl(type, match)
|
|
197
|
+
# remove first and last 2 characters.
|
|
198
|
+
[ type, match[1..-3] ]
|
|
199
|
+
end
|
|
200
|
+
|
|
201
|
+
def startComment(type, match)
|
|
202
|
+
self.mode = :cppComment
|
|
203
|
+
[ nil, '' ]
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
def endComment(type, match)
|
|
207
|
+
self.mode = :tjp
|
|
208
|
+
[ nil, '' ]
|
|
209
|
+
end
|
|
210
|
+
|
|
211
|
+
def startStringDQ(type, match)
|
|
212
|
+
self.mode = :dqString
|
|
213
|
+
# Remove the opening " and remove the backslashes from escaped ".
|
|
214
|
+
@string = match[1..-1].gsub(/\\"/, '"')
|
|
215
|
+
[ nil, '' ]
|
|
216
|
+
end
|
|
217
|
+
|
|
218
|
+
def midStringDQ(type, match)
|
|
219
|
+
# Remove the backslashes from escaped ".
|
|
220
|
+
@string += match.gsub(/\\"/, '"')
|
|
221
|
+
[ nil, '' ]
|
|
222
|
+
end
|
|
223
|
+
|
|
224
|
+
def endStringDQ(type, match)
|
|
225
|
+
self.mode = :tjp
|
|
226
|
+
# Remove the trailing " and remove the backslashes from escaped ".
|
|
227
|
+
@string += match[0..-2].gsub(/\\"/, '"')
|
|
228
|
+
[ 'STRING', @string ]
|
|
229
|
+
end
|
|
230
|
+
|
|
231
|
+
def startStringSQ(type, match)
|
|
232
|
+
self.mode = :sqString
|
|
233
|
+
# Remove the opening ' and remove the backslashes from escaped '.
|
|
234
|
+
@string = match[1..-1].gsub(/\\'/, "'")
|
|
235
|
+
[ nil, '' ]
|
|
236
|
+
end
|
|
237
|
+
|
|
238
|
+
def midStringSQ(type, match)
|
|
239
|
+
# Remove the backslashes from escaped '.
|
|
240
|
+
@string += match.gsub(/\\'/, "'")
|
|
241
|
+
[ nil, '' ]
|
|
242
|
+
end
|
|
243
|
+
|
|
244
|
+
def endStringSQ(type, match)
|
|
245
|
+
self.mode = :tjp
|
|
246
|
+
# Remove the trailing ' and remove the backslashes from escaped '.
|
|
247
|
+
@string += match[0..-2].gsub(/\\'/, "'")
|
|
248
|
+
[ 'STRING', @string ]
|
|
249
|
+
end
|
|
250
|
+
|
|
251
|
+
def startStringSZR(type, match)
|
|
252
|
+
# There should be a line break after the cut mark, but we allow some
|
|
253
|
+
# spaces between the mark and the line break as well.
|
|
254
|
+
if match.length != 5 && /-8<-\s*\n$/.match(match).nil?
|
|
255
|
+
@lineDelta = 1
|
|
256
|
+
error('junk_after_cut',
|
|
257
|
+
'The cut mark -8<- must be immediately followed by a ' +
|
|
258
|
+
'line break.')
|
|
259
|
+
end
|
|
260
|
+
self.mode = :szrString1
|
|
261
|
+
@startOfToken = sourceFileInfo
|
|
262
|
+
@string = ''
|
|
263
|
+
[ nil, '' ]
|
|
264
|
+
end
|
|
265
|
+
|
|
266
|
+
def firstStringSZR(type, match)
|
|
267
|
+
self.mode = :szrString
|
|
268
|
+
# Split the leading indentation and the rest of the string.
|
|
269
|
+
foo, @indent, @string = */(\s*)(.*\n)/.match(match)
|
|
270
|
+
[ nil, '' ]
|
|
271
|
+
end
|
|
272
|
+
|
|
273
|
+
def midStringSZR(type, match)
|
|
274
|
+
# Ignore all the characters from the begining of match that are the same
|
|
275
|
+
# in @indent.
|
|
276
|
+
i = 0
|
|
277
|
+
while i < @indent.length && @indent[i] == match[i]
|
|
278
|
+
i += 1
|
|
279
|
+
end
|
|
280
|
+
@string += match[i..-1]
|
|
281
|
+
[ nil, '' ]
|
|
282
|
+
end
|
|
283
|
+
|
|
284
|
+
def endStringSZR(type, match)
|
|
285
|
+
self.mode = :tjp
|
|
286
|
+
[ 'STRING', @string ]
|
|
287
|
+
end
|
|
288
|
+
|
|
289
|
+
def startMacroDef(type, match)
|
|
290
|
+
self.mode = :macroDef
|
|
291
|
+
# Remove the opening '['
|
|
292
|
+
@macroDef = match[1..-1]
|
|
293
|
+
[ nil, '' ]
|
|
294
|
+
end
|
|
295
|
+
|
|
296
|
+
def midMacroDef(type, match)
|
|
297
|
+
@macroDef += match
|
|
298
|
+
[ nil, '' ]
|
|
299
|
+
end
|
|
300
|
+
|
|
301
|
+
def endMacroDef(type, match)
|
|
302
|
+
self.mode = :tjp
|
|
303
|
+
# Remove "]\n"
|
|
304
|
+
@macroDef += match[0..-3]
|
|
305
|
+
[ 'MACRO', @macroDef ]
|
|
306
|
+
end
|
|
307
|
+
|
|
308
|
+
def startMacroCall(type, match)
|
|
309
|
+
@macroCallPreviousMode = @scannerMode
|
|
310
|
+
self.mode = :macroCall
|
|
311
|
+
@macroCall = match
|
|
312
|
+
[ nil, '' ]
|
|
313
|
+
end
|
|
314
|
+
|
|
315
|
+
def midMacroCall(type, match)
|
|
316
|
+
@macroCall += match
|
|
317
|
+
[ nil, '' ]
|
|
318
|
+
end
|
|
319
|
+
|
|
320
|
+
def endMacroCall(type, match)
|
|
321
|
+
self.mode = @macroCallPreviousMode
|
|
322
|
+
@macroCall += match
|
|
323
|
+
|
|
324
|
+
# Store any characters that precede the ${ in prefix and remove it from
|
|
325
|
+
# @macroCall.
|
|
326
|
+
if (macroStart = @macroCall.index('${')) > 0
|
|
327
|
+
prefix = @macroCall[0..(macroStart - 1)]
|
|
328
|
+
@macroCall = @macroCall[macroStart..-1]
|
|
329
|
+
else
|
|
330
|
+
prefix = ''
|
|
331
|
+
end
|
|
332
|
+
|
|
333
|
+
# Remove '${' and '}'
|
|
334
|
+
argsStr = @macroCall[2..-2]
|
|
335
|
+
# Extract the macro name.
|
|
336
|
+
if (nameEnd = argsStr.index(' ')).nil?
|
|
337
|
+
expandMacro(prefix, [ argsStr ])
|
|
338
|
+
else
|
|
339
|
+
macroName = argsStr[0, argsStr.index(' ')]
|
|
340
|
+
# Remove the name part from argsStr
|
|
341
|
+
argsStr = argsStr[macroName.length..-1]
|
|
342
|
+
# Array to hold the arguments
|
|
343
|
+
args = []
|
|
344
|
+
# We use another StringScanner to clean the double quotes.
|
|
345
|
+
scanner = StringScanner.new(argsStr)
|
|
346
|
+
while (scanner.scan(/\s*"/))
|
|
347
|
+
args << scanner.scan(/(\\"|[^"])*/).gsub(/\\"/, '"')
|
|
348
|
+
scanner.scan(/"\s*/)
|
|
349
|
+
end
|
|
350
|
+
|
|
351
|
+
unless scanner.eos?
|
|
352
|
+
raise "Junk found at end of macro: #{argsStr[scanner.pos..-1]}"
|
|
353
|
+
end
|
|
354
|
+
|
|
355
|
+
# Expand the macro and inject it into the scanner.
|
|
356
|
+
expandMacro(prefix, [ macroName ] + args)
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
[ nil, '' ]
|
|
360
|
+
end
|
|
361
|
+
|
|
362
|
+
end
|
|
363
|
+
|
|
364
|
+
end
|
|
365
|
+
|
data/lib/PropertyList.rb
CHANGED
|
@@ -111,7 +111,8 @@ class TaskJuggler
|
|
|
111
111
|
raise TjException.new, "Unknown scenario index #{scIdx} used."
|
|
112
112
|
end
|
|
113
113
|
if !@propertySet.scenarioSpecific?(criteria)
|
|
114
|
-
raise TjException.new, "Attribute #{criteria} is not scenario
|
|
114
|
+
raise TjException.new, "Attribute #{criteria} is not scenario " +
|
|
115
|
+
"specific"
|
|
115
116
|
end
|
|
116
117
|
end
|
|
117
118
|
@sortingCriteria.push(criteria)
|
data/lib/PropertySet.rb
CHANGED
|
@@ -113,10 +113,20 @@ class TaskJuggler
|
|
|
113
113
|
|
|
114
114
|
# Return whether the attribute with _attrId_ is scenario specific or not.
|
|
115
115
|
def scenarioSpecific?(attrId)
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
@
|
|
116
|
+
if @attributeDefinitions[attrId]
|
|
117
|
+
# Check the 'scenarioSpecific' flag of the attribute definition.
|
|
118
|
+
@attributeDefinitions[attrId].scenarioSpecific
|
|
119
|
+
elsif (property = @properties.first) &&
|
|
120
|
+
property && property.data &&
|
|
121
|
+
property.data[0].respond_to?("query_#{attrId}")
|
|
122
|
+
# We've found a query_ function for the attrId that is scenario
|
|
123
|
+
# specific.
|
|
124
|
+
true
|
|
125
|
+
else
|
|
126
|
+
# All hardwired, non-existing and non-scenario-specific query_
|
|
127
|
+
# candidates.
|
|
128
|
+
false
|
|
129
|
+
end
|
|
120
130
|
end
|
|
121
131
|
|
|
122
132
|
# Return whether the attribute with _attrId_ is inherited from the global
|
data/lib/PropertyTreeNode.rb
CHANGED
|
@@ -26,9 +26,9 @@ class TaskJuggler
|
|
|
26
26
|
# attribute like an URL that contains more details about the task.
|
|
27
27
|
class PropertyTreeNode
|
|
28
28
|
|
|
29
|
-
attr_reader :propertySet, :id, :
|
|
29
|
+
attr_reader :propertySet, :id, :parent, :project, :sequenceNo,
|
|
30
30
|
:children
|
|
31
|
-
attr_accessor :sourceFileInfo
|
|
31
|
+
attr_accessor :name, :sourceFileInfo
|
|
32
32
|
attr_reader :data
|
|
33
33
|
|
|
34
34
|
# Create a new PropertyTreeNode object. _propertySet_ is the PropertySet
|
|
@@ -93,6 +93,18 @@ class TaskJuggler
|
|
|
93
93
|
self
|
|
94
94
|
end
|
|
95
95
|
|
|
96
|
+
# This method creates a shallow copy of all attributes and returns them as
|
|
97
|
+
# an Array that can be used with restoreAttributes().
|
|
98
|
+
def backupAttributes
|
|
99
|
+
[ @attributes.clone, @scenarioAttributes.clone ]
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
# Restore the attributes to a previously saved state. _backup_ is an Array
|
|
103
|
+
# generated by backupAttributes().
|
|
104
|
+
def restoreAttributes(backup)
|
|
105
|
+
@attributes, @scenarioAttributes = backup
|
|
106
|
+
end
|
|
107
|
+
|
|
96
108
|
# Return the index of the child _node_.
|
|
97
109
|
def levelSeqNo(node)
|
|
98
110
|
@children.index(node) + 1
|
|
@@ -320,11 +332,11 @@ class TaskJuggler
|
|
|
320
332
|
def declareAttribute(attributeType)
|
|
321
333
|
if attributeType.scenarioSpecific
|
|
322
334
|
@project.scenarioCount.times do |i|
|
|
323
|
-
attribute =
|
|
335
|
+
attribute = attributeType.objClass.new(self, attributeType)
|
|
324
336
|
@scenarioAttributes[i][attribute.id] = attribute
|
|
325
337
|
end
|
|
326
338
|
else
|
|
327
|
-
attribute =
|
|
339
|
+
attribute = attributeType.objClass.new(self, attributeType)
|
|
328
340
|
@attributes[attribute.id] = attribute
|
|
329
341
|
end
|
|
330
342
|
end
|
|
@@ -380,14 +392,14 @@ class TaskJuggler
|
|
|
380
392
|
def getAttribute(attributeId, scenarioIdx = nil)
|
|
381
393
|
case attributeId
|
|
382
394
|
when 'id'
|
|
383
|
-
StringAttribute.new(self,
|
|
395
|
+
StringAttribute.new(self, fullId)
|
|
384
396
|
when 'name'
|
|
385
397
|
StringAttribute.new(self, @name)
|
|
386
398
|
when 'seqno'
|
|
387
399
|
FixnumAttribute.new(self, @sequenceNo)
|
|
388
400
|
else
|
|
389
401
|
@attributes[attributeId] ||
|
|
390
|
-
@scenarioAttributes[scenarioIdx][attributeId]
|
|
402
|
+
(scenarioIdx && @scenarioAttributes[scenarioIdx][attributeId])
|
|
391
403
|
end
|
|
392
404
|
end
|
|
393
405
|
|
|
@@ -467,12 +479,28 @@ class TaskJuggler
|
|
|
467
479
|
query.string = @project.alertLevelName(alert)
|
|
468
480
|
end
|
|
469
481
|
|
|
470
|
-
def
|
|
471
|
-
|
|
482
|
+
def query_alertmessages(query)
|
|
483
|
+
journalMessages(@project['journal'].alertEntries(query.end, self, 1,
|
|
484
|
+
query.start),
|
|
485
|
+
query, true)
|
|
486
|
+
end
|
|
487
|
+
|
|
488
|
+
def query_alertsummaries(query)
|
|
489
|
+
journalMessages(@project['journal'].alertEntries(query.end, self, 1,
|
|
490
|
+
query.start),
|
|
491
|
+
query, false)
|
|
472
492
|
end
|
|
473
493
|
|
|
474
|
-
def
|
|
475
|
-
|
|
494
|
+
def query_journalmessages(query)
|
|
495
|
+
journalMessages(@project['journal'].currentEntries(query.end, self, 0,
|
|
496
|
+
query.start),
|
|
497
|
+
query, true)
|
|
498
|
+
end
|
|
499
|
+
|
|
500
|
+
def query_journalsummaries(query)
|
|
501
|
+
journalMessages(@project['journal'].currentEntries(query.end, self, 0,
|
|
502
|
+
query.start),
|
|
503
|
+
query, false)
|
|
476
504
|
end
|
|
477
505
|
|
|
478
506
|
def query_alerttrend(query)
|
|
@@ -537,13 +565,12 @@ class TaskJuggler
|
|
|
537
565
|
private
|
|
538
566
|
|
|
539
567
|
# Create a blog-style list of all alert messages that match the Query.
|
|
540
|
-
def
|
|
568
|
+
def journalMessages(entries, query, longVersion)
|
|
541
569
|
# The components of the message are either UTF-8 text or RichText. For
|
|
542
570
|
# the RichText components, we use the originally provided markup since
|
|
543
571
|
# we compose the result as RichText markup first.
|
|
544
572
|
rText = ''
|
|
545
|
-
|
|
546
|
-
query.start).each do |entry|
|
|
573
|
+
entries.each do |entry|
|
|
547
574
|
rText += "=== <nowiki>" + entry.headline + "</nowiki> ===\n"
|
|
548
575
|
rText += "''Reported on #{entry.date.to_s(query.timeFormat)}'' "
|
|
549
576
|
if entry.author
|
|
@@ -559,13 +586,9 @@ class TaskJuggler
|
|
|
559
586
|
end
|
|
560
587
|
# Now convert the RichText markup String into RichTextIntermediate
|
|
561
588
|
# format.
|
|
562
|
-
handlers = [
|
|
563
|
-
RTFNavigator.new(@project),
|
|
564
|
-
RTFQuery.new(@project),
|
|
565
|
-
RTFReport.new(@project)
|
|
566
|
-
]
|
|
567
589
|
begin
|
|
568
|
-
rti = RichText.new(rText,
|
|
590
|
+
rti = RichText.new(rText, RTFHandlers.create(@project)).
|
|
591
|
+
generateIntermediateFormat
|
|
569
592
|
rescue RichTextException => msg
|
|
570
593
|
$stderr.puts "Error while processing Rich Text\n" +
|
|
571
594
|
"Line #{msg.lineNo}: #{msg.text}\n" +
|
|
@@ -579,16 +602,6 @@ class TaskJuggler
|
|
|
579
602
|
query.rti = rti
|
|
580
603
|
end
|
|
581
604
|
|
|
582
|
-
def newAttribute(attributeType)
|
|
583
|
-
attribute = attributeType.objClass.new(self, attributeType)
|
|
584
|
-
# If the attribute requires a pointer to the project, we'll hand it over.
|
|
585
|
-
if !attribute.value.nil? && attribute.respond_to?('setProject')
|
|
586
|
-
attribute.setProject(@project)
|
|
587
|
-
end
|
|
588
|
-
|
|
589
|
-
attribute
|
|
590
|
-
end
|
|
591
|
-
|
|
592
605
|
def indent(tag, str)
|
|
593
606
|
tag + str.gsub(/\n/, "\n#{' ' * tag.length}") + "\n"
|
|
594
607
|
end
|