@magic-xpa/engine 4.1100.0-dev4110.26 → 4.1100.0-dev4110.260
Sign up to get free protection for your applications and to get access to all the features.
- package/{esm2020 → esm2022}/index.mjs +188 -188
- package/{esm2020 → esm2022}/magic-xpa-engine.mjs +1 -1
- package/esm2022/src/AccessHelper.mjs +15 -0
- package/esm2022/src/ClientManager.mjs +418 -0
- package/esm2022/src/CommandsProcessorBase.mjs +56 -0
- package/{esm2020 → esm2022}/src/CommandsProcessorManager.mjs +25 -25
- package/esm2022/src/CommandsTable.mjs +162 -0
- package/esm2022/src/ConstInterface.mjs +517 -0
- package/{esm2020 → esm2022}/src/CurrentClientVersion.mjs +2 -2
- package/esm2022/src/FlowMonitorInterface.mjs +16 -0
- package/esm2022/src/GUIManager.mjs +62 -0
- package/esm2022/src/GlobalCommandsManager.mjs +34 -0
- package/esm2022/src/GuiEventsProcessor.mjs +156 -0
- package/{esm2020 → esm2022}/src/ICommandsTable.mjs +1 -1
- package/esm2022/src/ServerConfig.mjs +122 -0
- package/{esm2020 → esm2022}/src/bridge/IGuiEvent.mjs +19 -19
- package/esm2022/src/bridge/MagicBridge.mjs +41 -0
- package/esm2022/src/commands/ClientOriginatedCommandTaskTag.mjs +12 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/AddUserLocateDataViewCommand.mjs +8 -8
- package/{esm2020 → esm2022}/src/commands/ClientToServer/AddUserRangeDataviewCommand.mjs +9 -9
- package/{esm2020 → esm2022}/src/commands/ClientToServer/AddUserSortDataViewCommand.mjs +9 -9
- package/esm2022/src/commands/ClientToServer/BrowserEscEventCommand.mjs +26 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/ClientOriginatedCommand.mjs +14 -14
- package/{esm2020 → esm2022}/src/commands/ClientToServer/ClientOriginatedCommandSerializer.mjs +59 -59
- package/esm2022/src/commands/ClientToServer/ColumnSortEventCommand.mjs +29 -0
- package/esm2022/src/commands/ClientToServer/CommandFactory.mjs +261 -0
- package/esm2022/src/commands/ClientToServer/CommandSerializationHelper.mjs +67 -0
- package/esm2022/src/commands/ClientToServer/ComputeEventCommand.mjs +26 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/ContextTerminationEventCommand.mjs +24 -21
- package/{esm2020 → esm2022}/src/commands/ClientToServer/ContextTimeoutResetCommand.mjs +23 -20
- package/{esm2020 → esm2022}/src/commands/ClientToServer/ControlItemsRefreshCommand.mjs +8 -8
- package/esm2022/src/commands/ClientToServer/DataViewOutputCommand.mjs +13 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/DataviewCommand.mjs +44 -44
- package/esm2022/src/commands/ClientToServer/EvaluateCommand.mjs +40 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/EventCommand.mjs +43 -40
- package/esm2022/src/commands/ClientToServer/ExecOperCommand.mjs +70 -0
- package/esm2022/src/commands/ClientToServer/FetchDataControlValuesEventCommand.mjs +25 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/GlobalParamsQueryCommand.mjs +10 -10
- package/{esm2020 → esm2022}/src/commands/ClientToServer/ICommandTaskTag.mjs +1 -1
- package/esm2022/src/commands/ClientToServer/IndexChangeEventCommand.mjs +24 -0
- package/esm2022/src/commands/ClientToServer/IniputForceWriteCommand.mjs +26 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/NonReversibleExitEventCommand.mjs +26 -23
- package/{esm2020 → esm2022}/src/commands/ClientToServer/QueryCommand.mjs +20 -20
- package/esm2022/src/commands/ClientToServer/RecomputeCommand.mjs +30 -0
- package/esm2022/src/commands/ClientToServer/RefreshEventCommand.mjs +30 -0
- package/esm2022/src/commands/ClientToServer/RefreshScreenEventCommand.mjs +27 -0
- package/esm2022/src/commands/ClientToServer/RollbackEventCommand.mjs +43 -0
- package/esm2022/src/commands/ClientToServer/SelectProgramCommand.mjs +19 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/SetTransactionStateDataviewCommand.mjs +9 -9
- package/esm2022/src/commands/ClientToServer/SubformOpenEventCommand.mjs +24 -0
- package/esm2022/src/commands/ClientToServer/SubformRefreshEventCommand.mjs +27 -0
- package/esm2022/src/commands/ClientToServer/TransactionCommand.mjs +34 -0
- package/{esm2020 → esm2022}/src/commands/ClientToServer/UnloadCommand.mjs +18 -15
- package/esm2022/src/commands/ClientToServer/WriteMessageToServerLogCommand.mjs +18 -0
- package/esm2022/src/commands/DataViewCommandBase.mjs +8 -0
- package/{esm2020 → esm2022}/src/commands/IClientCommand.mjs +1 -1
- package/esm2022/src/commands/IClientTargetedCommand.mjs +13 -0
- package/{esm2020 → esm2022}/src/commands/IClientToServerCommandInfo.mjs +2 -2
- package/esm2022/src/commands/ServerToClient/AbortCommand.mjs +65 -0
- package/{esm2020 → esm2022}/src/commands/ServerToClient/AddLocateCommand.mjs +21 -21
- package/{esm2020 → esm2022}/src/commands/ServerToClient/AddRangeCommand.mjs +62 -62
- package/{esm2020 → esm2022}/src/commands/ServerToClient/AddSortCommand.mjs +33 -33
- package/esm2022/src/commands/ServerToClient/ClientRefreshCommand.mjs +25 -0
- package/esm2022/src/commands/ServerToClient/ClientTargetedCommandBase.mjs +24 -0
- package/esm2022/src/commands/ServerToClient/EnhancedVerifyCommand.mjs +45 -0
- package/esm2022/src/commands/ServerToClient/OpenURLCommand.mjs +221 -0
- package/{esm2020 → esm2022}/src/commands/ServerToClient/ResetLocateCommand.mjs +14 -14
- package/{esm2020 → esm2022}/src/commands/ServerToClient/ResetRangeCommand.mjs +14 -14
- package/{esm2020 → esm2022}/src/commands/ServerToClient/ResetSortCommand.mjs +14 -14
- package/esm2022/src/commands/ServerToClient/ResultCommand.mjs +37 -0
- package/esm2022/src/commands/ServerToClient/VerifyCommand.mjs +83 -0
- package/{esm2020 → esm2022}/src/commands/ServerToClient/XMLBasedCommandBuilder.mjs +132 -132
- package/{esm2020 → esm2022}/src/communications/IConnectionStateManager.mjs +1 -1
- package/esm2022/src/communications/InteractiveCommunicationsFailureHandler.mjs +15 -0
- package/{esm2020 → esm2022}/src/data/DataSourceIdKey.mjs +2 -2
- package/esm2022/src/data/DataView.mjs +1613 -0
- package/{esm2020 → esm2022}/src/data/DataViewBase.mjs +3 -3
- package/esm2022/src/data/DataviewManager.mjs +28 -0
- package/esm2022/src/data/DataviewManagerBase.mjs +15 -0
- package/esm2022/src/data/DvCache.mjs +67 -0
- package/esm2022/src/data/Field.mjs +646 -0
- package/esm2022/src/data/FieldBase.mjs +15 -0
- package/esm2022/src/data/FieldsTable.mjs +103 -0
- package/{esm2020 → esm2022}/src/data/IRecordsTable.mjs +1 -1
- package/{esm2020 → esm2022}/src/data/Key.mjs +88 -88
- package/esm2022/src/data/Record.mjs +880 -0
- package/{esm2020 → esm2022}/src/data/RecordOutOfDataViewException.mjs +15 -15
- package/esm2022/src/data/RecordsTable.mjs +267 -0
- package/{esm2020 → esm2022}/src/data/TaskTransactionManager.mjs +107 -103
- package/{esm2020 → esm2022}/src/data/XMLBasedDcValuesBuilder.mjs +74 -74
- package/{esm2020 → esm2022}/src/enums.mjs +23 -23
- package/esm2022/src/env/EnvVariablesTable.mjs +340 -0
- package/esm2022/src/env/Environment.mjs +487 -0
- package/{esm2020 → esm2022}/src/env/ILanguageData.mjs +1 -1
- package/esm2022/src/env/LanguageData.mjs +227 -0
- package/{esm2020 → esm2022}/src/env/MirrorString.mjs +65 -65
- package/esm2022/src/event/ActionManager.mjs +91 -0
- package/esm2022/src/event/Event.mjs +1333 -0
- package/esm2022/src/event/EventHandler.mjs +766 -0
- package/esm2022/src/event/EventHandlerPosition.mjs +204 -0
- package/esm2022/src/event/EventsManager.mjs +2988 -0
- package/{esm2020 → esm2022}/src/event/IEventsManager.mjs +6 -6
- package/esm2022/src/event/RunTimeEvent.mjs +399 -0
- package/{esm2020 → esm2022}/src/event/RunTimeEventBase.mjs +3 -3
- package/esm2022/src/event/UserEventsTable.mjs +47 -0
- package/esm2022/src/exp/ExpTable.mjs +57 -0
- package/esm2022/src/exp/Expression.mjs +200 -0
- package/esm2022/src/exp/ExpressionDict.mjs +727 -0
- package/esm2022/src/exp/ExpressionEvaluator.mjs +4206 -0
- package/esm2022/src/exp/ExpressionLocalJpn.mjs +314 -0
- package/{esm2020 → esm2022}/src/exp/GlobalParamsTable.mjs +85 -85
- package/esm2022/src/exp/YesNoExp.mjs +36 -0
- package/esm2022/src/gui/CreatedFormVector.mjs +23 -0
- package/esm2022/src/gui/FormsTable.mjs +66 -0
- package/esm2022/src/gui/MgControl.mjs +363 -0
- package/esm2022/src/gui/MgForm.mjs +1224 -0
- package/esm2022/src/http/HttpManager.mjs +97 -0
- package/esm2022/src/http/client/HttpClientAsync.mjs +68 -0
- package/{esm2020 → esm2022}/src/http/client/HttpClientBase.mjs +132 -132
- package/esm2022/src/http/client/HttpClientEvents.mjs +39 -0
- package/esm2022/src/http/client/HttpClientSync.mjs +42 -0
- package/esm2022/src/http/client/HttpUtility.mjs +84 -0
- package/{esm2020 → esm2022}/src/http/client/ICommunicationsFailureHandler.mjs +1 -1
- package/{esm2020 → esm2022}/src/remote/AddUserLocateRemoteDataViewCommand.mjs +18 -18
- package/{esm2020 → esm2022}/src/remote/AddUserRangeRemoteDataViewCommand.mjs +18 -18
- package/{esm2020 → esm2022}/src/remote/AddUserSortRemoteDataViewCommand.mjs +18 -18
- package/esm2022/src/remote/RemoteCommandsProcessor.mjs +883 -0
- package/{esm2020 → esm2022}/src/remote/RemoteControlItemsRefreshCommand.mjs +25 -25
- package/{esm2020 → esm2022}/src/remote/RemoteDataViewCommandBase.mjs +24 -24
- package/{esm2020 → esm2022}/src/remote/RemoteDataViewCommandFactory.mjs +60 -60
- package/{esm2020 → esm2022}/src/remote/RemoteDataViewCommandUpdateNonModifiable.mjs +15 -15
- package/{esm2020 → esm2022}/src/remote/RemoteDataviewManager.mjs +17 -17
- package/{esm2020 → esm2022}/src/remote/RemoteInitDataViewCommand.mjs +10 -10
- package/{esm2020 → esm2022}/src/remote/ResetUserLocateRemoteDataviewCommand.mjs +16 -16
- package/{esm2020 → esm2022}/src/remote/ResetUserRangeRemoteDataviewCommand.mjs +12 -12
- package/{esm2020 → esm2022}/src/remote/ResetUserSortRemoteDataviewCommand.mjs +15 -15
- package/esm2022/src/remote/ServerError.mjs +40 -0
- package/{esm2020 → esm2022}/src/remote/SetTransactionStateRemoteDataViewCommand.mjs +19 -19
- package/esm2022/src/rt/Argument.mjs +265 -0
- package/esm2022/src/rt/ArgumentsList.mjs +103 -0
- package/esm2022/src/rt/Boundary.mjs +152 -0
- package/esm2022/src/rt/CompMainPrgTable.mjs +63 -0
- package/esm2022/src/rt/DataviewHeaderBase.mjs +98 -0
- package/{esm2020 → esm2022}/src/rt/DataviewHeaderFactory.mjs +6 -6
- package/esm2022/src/rt/DataviewHeaders.mjs +53 -0
- package/{esm2020 → esm2022}/src/rt/DataviewHeadersSaxHandler.mjs +38 -38
- package/{esm2020 → esm2022}/src/rt/ExecutionStack.mjs +94 -94
- package/{esm2020 → esm2022}/src/rt/ExecutionStackEntry.mjs +17 -17
- package/{esm2020 → esm2022}/src/rt/HandlersTable.mjs +96 -96
- package/{esm2020 → esm2022}/src/rt/IDataSourceViewDefinition.mjs +1 -1
- package/{esm2020 → esm2022}/src/rt/IDataviewHeader.mjs +1 -1
- package/{esm2020 → esm2022}/src/rt/IResultValue.mjs +1 -1
- package/esm2022/src/rt/LastFocusedManager.mjs +65 -0
- package/esm2022/src/rt/Operation.mjs +735 -0
- package/esm2022/src/rt/OperationTable.mjs +67 -0
- package/esm2022/src/rt/Recompute.mjs +355 -0
- package/{esm2020 → esm2022}/src/rt/RecomputeTable.mjs +62 -62
- package/{esm2020 → esm2022}/src/rt/RemoteDataviewHeader.mjs +108 -108
- package/esm2022/src/rt/ResultValue.mjs +10 -0
- package/esm2022/src/rt/TableCache.mjs +177 -0
- package/esm2022/src/rt/TableCacheManager.mjs +67 -0
- package/esm2022/src/rt/Transaction.mjs +53 -0
- package/esm2022/src/security/UserDetails.mjs +71 -0
- package/{esm2020 → esm2022}/src/tasks/IMGDataCollection.mjs +1 -1
- package/esm2022/src/tasks/MGData.mjs +552 -0
- package/esm2022/src/tasks/MGDataCollection.mjs +252 -0
- package/esm2022/src/tasks/RCTimer.mjs +63 -0
- package/{esm2020 → esm2022}/src/tasks/RemoteTaskService.mjs +44 -44
- package/esm2022/src/tasks/Task.mjs +2499 -0
- package/esm2022/src/tasks/TaskBase.mjs +83 -0
- package/{esm2020 → esm2022}/src/tasks/TaskServiceBase.mjs +24 -24
- package/esm2022/src/tasks/TasksTable.mjs +80 -0
- package/esm2022/src/tasks/sort/Sort.mjs +5 -0
- package/{esm2020 → esm2022}/src/tasks/sort/SortCollection.mjs +67 -67
- package/{esm2020 → esm2022}/src/util/ConstUtils.mjs +13 -13
- package/esm2022/src/util/FlowMonitorQueue.mjs +451 -0
- package/{esm2020 → esm2022}/src/util/HeapSort.mjs +69 -69
- package/{esm2020 → esm2022}/src/util/IMirrorXML.mjs +1 -1
- package/{esm2020 → esm2022}/src/util/IServerConfig.mjs +1 -1
- package/{esm2020 → esm2022}/src/util/MgBlockingQueue.mjs +1 -1
- package/esm2022/src/util/MgPriorityBlockingQueue.mjs +74 -0
- package/esm2022/src/util/MgPriorityQueue.mjs +66 -0
- package/{esm2020 → esm2022}/src/util/ParamParseResult.mjs +7 -7
- package/esm2022/src/util/PrmMap.mjs +152 -0
- package/esm2022/src/util/ReturnResult.mjs +46 -0
- package/esm2022/src/util/ReturnResultBase.mjs +18 -0
- package/esm2022/src/util/Scrambler.mjs +89 -0
- package/esm2022/src/util/UniqueIDUtils.mjs +13 -0
- package/{esm2020 → esm2022}/src/util/cookie.service.mjs +91 -91
- package/{fesm2020 → fesm2022}/magic-xpa-engine.mjs +29885 -29693
- package/fesm2022/magic-xpa-engine.mjs.map +1 -0
- package/index.d.ts +187 -187
- package/package.json +8 -14
- package/src/AccessHelper.d.ts +20 -20
- package/src/ClientManager.d.ts +35 -32
- package/src/CommandsProcessorBase.d.ts +23 -23
- package/src/CommandsProcessorManager.d.ts +6 -6
- package/src/CommandsTable.d.ts +22 -22
- package/src/ConstInterface.d.ts +516 -515
- package/src/CurrentClientVersion.d.ts +1 -1
- package/src/FlowMonitorInterface.d.ts +15 -15
- package/src/GUIManager.d.ts +17 -17
- package/src/GlobalCommandsManager.d.ts +17 -17
- package/src/GuiEventsProcessor.d.ts +24 -24
- package/src/ICommandsTable.d.ts +9 -9
- package/src/ServerConfig.d.ts +35 -34
- package/src/bridge/IGuiEvent.d.ts +19 -19
- package/src/bridge/MagicBridge.d.ts +16 -16
- package/src/commands/ClientOriginatedCommandTaskTag.d.ts +8 -8
- package/src/commands/ClientToServer/AddUserLocateDataViewCommand.d.ts +4 -4
- package/src/commands/ClientToServer/AddUserRangeDataviewCommand.d.ts +6 -6
- package/src/commands/ClientToServer/AddUserSortDataViewCommand.d.ts +6 -6
- package/src/commands/ClientToServer/BrowserEscEventCommand.d.ts +9 -8
- package/src/commands/ClientToServer/ClientOriginatedCommand.d.ts +8 -8
- package/src/commands/ClientToServer/ClientOriginatedCommandSerializer.d.ts +6 -6
- package/src/commands/ClientToServer/ColumnSortEventCommand.d.ts +11 -10
- package/src/commands/ClientToServer/CommandFactory.d.ts +64 -64
- package/src/commands/ClientToServer/CommandSerializationHelper.d.ts +20 -20
- package/src/commands/ClientToServer/ComputeEventCommand.d.ts +9 -8
- package/src/commands/ClientToServer/ContextTerminationEventCommand.d.ts +8 -7
- package/src/commands/ClientToServer/ContextTimeoutResetCommand.d.ts +8 -7
- package/src/commands/ClientToServer/ControlItemsRefreshCommand.d.ts +6 -6
- package/src/commands/ClientToServer/DataViewOutputCommand.d.ts +9 -9
- package/src/commands/ClientToServer/DataviewCommand.d.ts +32 -32
- package/src/commands/ClientToServer/EvaluateCommand.d.ts +16 -15
- package/src/commands/ClientToServer/EventCommand.d.ts +16 -15
- package/src/commands/ClientToServer/ExecOperCommand.d.ts +24 -23
- package/src/commands/ClientToServer/FetchDataControlValuesEventCommand.d.ts +9 -8
- package/src/commands/ClientToServer/GlobalParamsQueryCommand.d.ts +5 -5
- package/src/commands/ClientToServer/ICommandTaskTag.d.ts +3 -3
- package/src/commands/ClientToServer/IndexChangeEventCommand.d.ts +9 -8
- package/src/commands/ClientToServer/IniputForceWriteCommand.d.ts +11 -10
- package/src/commands/ClientToServer/NonReversibleExitEventCommand.d.ts +9 -8
- package/src/commands/ClientToServer/QueryCommand.d.ts +8 -8
- package/src/commands/ClientToServer/RecomputeCommand.d.ts +12 -11
- package/src/commands/ClientToServer/RefreshEventCommand.d.ts +13 -12
- package/src/commands/ClientToServer/RefreshScreenEventCommand.d.ts +11 -10
- package/src/commands/ClientToServer/RollbackEventCommand.d.ts +15 -14
- package/src/commands/ClientToServer/SelectProgramCommand.d.ts +7 -6
- package/src/commands/ClientToServer/SetTransactionStateDataviewCommand.d.ts +5 -5
- package/src/commands/ClientToServer/SubformOpenEventCommand.d.ts +9 -8
- package/src/commands/ClientToServer/SubformRefreshEventCommand.d.ts +10 -9
- package/src/commands/ClientToServer/TransactionCommand.d.ts +14 -12
- package/src/commands/ClientToServer/UnloadCommand.d.ts +8 -7
- package/src/commands/ClientToServer/WriteMessageToServerLogCommand.d.ts +6 -6
- package/src/commands/DataViewCommandBase.d.ts +6 -6
- package/src/commands/IClientCommand.d.ts +2 -2
- package/src/commands/IClientTargetedCommand.d.ts +12 -12
- package/src/commands/IClientToServerCommandInfo.d.ts +4 -3
- package/src/commands/ServerToClient/AbortCommand.d.ts +11 -11
- package/src/commands/ServerToClient/AddLocateCommand.d.ts +6 -6
- package/src/commands/ServerToClient/AddRangeCommand.d.ts +10 -10
- package/src/commands/ServerToClient/AddSortCommand.d.ts +9 -9
- package/src/commands/ServerToClient/ClientRefreshCommand.d.ts +7 -7
- package/src/commands/ServerToClient/ClientTargetedCommandBase.d.ts +12 -12
- package/src/commands/ServerToClient/EnhancedVerifyCommand.d.ts +13 -13
- package/src/commands/ServerToClient/OpenURLCommand.d.ts +21 -21
- package/src/commands/ServerToClient/ResetLocateCommand.d.ts +6 -6
- package/src/commands/ServerToClient/ResetRangeCommand.d.ts +6 -6
- package/src/commands/ServerToClient/ResetSortCommand.d.ts +6 -6
- package/src/commands/ServerToClient/ResultCommand.d.ts +10 -10
- package/src/commands/ServerToClient/VerifyCommand.d.ts +17 -17
- package/src/commands/ServerToClient/XMLBasedCommandBuilder.d.ts +11 -11
- package/src/communications/IConnectionStateManager.d.ts +4 -4
- package/src/communications/InteractiveCommunicationsFailureHandler.d.ts +6 -6
- package/src/data/DataSourceIdKey.d.ts +2 -2
- package/src/data/DataView.d.ts +162 -162
- package/src/data/DataViewBase.d.ts +12 -12
- package/src/data/DataviewManager.d.ts +14 -14
- package/src/data/DataviewManagerBase.d.ts +11 -11
- package/src/data/DvCache.d.ts +15 -15
- package/src/data/Field.d.ts +103 -103
- package/src/data/FieldBase.d.ts +23 -23
- package/src/data/FieldsTable.d.ts +27 -27
- package/src/data/IRecordsTable.d.ts +7 -7
- package/src/data/Key.d.ts +15 -15
- package/src/data/Record.d.ts +157 -156
- package/src/data/RecordOutOfDataViewException.d.ts +10 -10
- package/src/data/RecordsTable.d.ts +38 -38
- package/src/data/TaskTransactionManager.d.ts +17 -17
- package/src/data/XMLBasedDcValuesBuilder.d.ts +11 -11
- package/src/enums.d.ts +21 -21
- package/src/env/EnvVariablesTable.d.ts +17 -17
- package/src/env/Environment.d.ts +118 -118
- package/src/env/ILanguageData.d.ts +3 -3
- package/src/env/LanguageData.d.ts +20 -20
- package/src/env/MirrorString.d.ts +15 -15
- package/src/event/ActionManager.d.ts +14 -14
- package/src/event/Event.d.ts +79 -79
- package/src/event/EventHandler.d.ts +66 -66
- package/src/event/EventHandlerPosition.d.ts +25 -25
- package/src/event/EventsManager.d.ts +205 -204
- package/src/event/IEventsManager.d.ts +77 -77
- package/src/event/RunTimeEvent.d.ts +126 -123
- package/src/event/RunTimeEventBase.d.ts +5 -5
- package/src/event/UserEventsTable.d.ts +11 -11
- package/src/exp/ExpTable.d.ts +11 -11
- package/src/exp/Expression.d.ts +37 -37
- package/src/exp/ExpressionDict.d.ts +12 -12
- package/src/exp/ExpressionEvaluator.d.ts +198 -198
- package/src/exp/ExpressionLocalJpn.d.ts +18 -18
- package/src/exp/GlobalParamsTable.d.ts +19 -19
- package/src/exp/YesNoExp.d.ts +9 -9
- package/src/gui/CreatedFormVector.d.ts +10 -10
- package/src/gui/FormsTable.d.ts +15 -15
- package/src/gui/MgControl.d.ts +60 -60
- package/src/gui/MgForm.d.ts +96 -93
- package/src/http/HttpManager.d.ts +25 -25
- package/src/http/client/HttpClientAsync.d.ts +16 -16
- package/src/http/client/HttpClientBase.d.ts +30 -30
- package/src/http/client/HttpClientEvents.d.ts +18 -18
- package/src/http/client/HttpClientSync.d.ts +17 -17
- package/src/http/client/HttpUtility.d.ts +10 -10
- package/src/http/client/ICommunicationsFailureHandler.d.ts +5 -5
- package/src/remote/AddUserLocateRemoteDataViewCommand.d.ts +8 -8
- package/src/remote/AddUserRangeRemoteDataViewCommand.d.ts +8 -8
- package/src/remote/AddUserSortRemoteDataViewCommand.d.ts +8 -8
- package/src/remote/RemoteCommandsProcessor.d.ts +51 -51
- package/src/remote/RemoteControlItemsRefreshCommand.d.ts +8 -8
- package/src/remote/RemoteDataViewCommandBase.d.ts +10 -10
- package/src/remote/RemoteDataViewCommandFactory.d.ts +6 -6
- package/src/remote/RemoteDataViewCommandUpdateNonModifiable.d.ts +8 -8
- package/src/remote/RemoteDataviewManager.d.ts +9 -9
- package/src/remote/RemoteInitDataViewCommand.d.ts +7 -7
- package/src/remote/ResetUserLocateRemoteDataviewCommand.d.ts +7 -7
- package/src/remote/ResetUserRangeRemoteDataviewCommand.d.ts +7 -7
- package/src/remote/ResetUserSortRemoteDataviewCommand.d.ts +7 -7
- package/src/remote/ServerError.d.ts +16 -16
- package/src/remote/SetTransactionStateRemoteDataViewCommand.d.ts +8 -8
- package/src/rt/Argument.d.ts +36 -36
- package/src/rt/ArgumentsList.d.ts +24 -24
- package/src/rt/Boundary.d.ts +27 -27
- package/src/rt/CompMainPrgTable.d.ts +10 -10
- package/src/rt/DataviewHeaderBase.d.ts +34 -34
- package/src/rt/DataviewHeaderFactory.d.ts +5 -5
- package/src/rt/DataviewHeaders.d.ts +12 -12
- package/src/rt/DataviewHeadersSaxHandler.d.ts +10 -10
- package/src/rt/ExecutionStack.d.ts +22 -22
- package/src/rt/ExecutionStackEntry.d.ts +7 -7
- package/src/rt/HandlersTable.d.ts +19 -19
- package/src/rt/IDataSourceViewDefinition.d.ts +6 -6
- package/src/rt/IDataviewHeader.d.ts +10 -10
- package/src/rt/IResultValue.d.ts +4 -4
- package/src/rt/LastFocusedManager.d.ts +23 -23
- package/src/rt/Operation.d.ts +97 -97
- package/src/rt/OperationTable.d.ts +15 -15
- package/src/rt/Recompute.d.ts +41 -41
- package/src/rt/RecomputeTable.d.ts +9 -9
- package/src/rt/RemoteDataviewHeader.d.ts +14 -14
- package/src/rt/ResultValue.d.ts +7 -7
- package/src/rt/TableCache.d.ts +29 -29
- package/src/rt/TableCacheManager.d.ts +10 -10
- package/src/rt/Transaction.d.ts +23 -23
- package/src/security/UserDetails.d.ts +16 -16
- package/src/tasks/IMGDataCollection.d.ts +26 -26
- package/src/tasks/MGData.d.ts +63 -63
- package/src/tasks/MGDataCollection.d.ts +42 -42
- package/src/tasks/RCTimer.d.ts +13 -13
- package/src/tasks/RemoteTaskService.d.ts +16 -16
- package/src/tasks/Task.d.ts +312 -312
- package/src/tasks/TaskBase.d.ts +123 -123
- package/src/tasks/TaskServiceBase.d.ts +16 -16
- package/src/tasks/TasksTable.d.ts +21 -21
- package/src/tasks/sort/Sort.d.ts +4 -4
- package/src/tasks/sort/SortCollection.d.ts +11 -11
- package/src/util/ConstUtils.d.ts +3 -3
- package/src/util/FlowMonitorQueue.d.ts +70 -70
- package/src/util/HeapSort.d.ts +6 -6
- package/src/util/IMirrorXML.d.ts +6 -6
- package/src/util/IServerConfig.d.ts +11 -11
- package/src/util/MgBlockingQueue.d.ts +5 -5
- package/src/util/MgPriorityBlockingQueue.d.ts +17 -17
- package/src/util/MgPriorityQueue.d.ts +13 -13
- package/src/util/ParamParseResult.d.ts +6 -6
- package/src/util/PrmMap.d.ts +28 -28
- package/src/util/ReturnResult.d.ts +18 -18
- package/src/util/ReturnResultBase.d.ts +11 -11
- package/src/util/Scrambler.d.ts +10 -10
- package/src/util/UniqueIDUtils.d.ts +4 -4
- package/src/util/cookie.service.d.ts +8 -8
- package/esm2020/src/AccessHelper.mjs +0 -9
- package/esm2020/src/ClientManager.mjs +0 -399
- package/esm2020/src/CommandsProcessorBase.mjs +0 -58
- package/esm2020/src/CommandsTable.mjs +0 -162
- package/esm2020/src/ConstInterface.mjs +0 -516
- package/esm2020/src/FlowMonitorInterface.mjs +0 -16
- package/esm2020/src/GUIManager.mjs +0 -62
- package/esm2020/src/GlobalCommandsManager.mjs +0 -34
- package/esm2020/src/GuiEventsProcessor.mjs +0 -154
- package/esm2020/src/ServerConfig.mjs +0 -117
- package/esm2020/src/bridge/MagicBridge.mjs +0 -41
- package/esm2020/src/commands/ClientOriginatedCommandTaskTag.mjs +0 -11
- package/esm2020/src/commands/ClientToServer/BrowserEscEventCommand.mjs +0 -23
- package/esm2020/src/commands/ClientToServer/ColumnSortEventCommand.mjs +0 -26
- package/esm2020/src/commands/ClientToServer/CommandFactory.mjs +0 -260
- package/esm2020/src/commands/ClientToServer/CommandSerializationHelper.mjs +0 -69
- package/esm2020/src/commands/ClientToServer/ComputeEventCommand.mjs +0 -23
- package/esm2020/src/commands/ClientToServer/DataViewOutputCommand.mjs +0 -13
- package/esm2020/src/commands/ClientToServer/EvaluateCommand.mjs +0 -36
- package/esm2020/src/commands/ClientToServer/ExecOperCommand.mjs +0 -67
- package/esm2020/src/commands/ClientToServer/FetchDataControlValuesEventCommand.mjs +0 -22
- package/esm2020/src/commands/ClientToServer/IndexChangeEventCommand.mjs +0 -21
- package/esm2020/src/commands/ClientToServer/IniputForceWriteCommand.mjs +0 -23
- package/esm2020/src/commands/ClientToServer/RecomputeCommand.mjs +0 -27
- package/esm2020/src/commands/ClientToServer/RefreshEventCommand.mjs +0 -27
- package/esm2020/src/commands/ClientToServer/RefreshScreenEventCommand.mjs +0 -24
- package/esm2020/src/commands/ClientToServer/RollbackEventCommand.mjs +0 -39
- package/esm2020/src/commands/ClientToServer/SelectProgramCommand.mjs +0 -15
- package/esm2020/src/commands/ClientToServer/SubformOpenEventCommand.mjs +0 -21
- package/esm2020/src/commands/ClientToServer/SubformRefreshEventCommand.mjs +0 -24
- package/esm2020/src/commands/ClientToServer/TransactionCommand.mjs +0 -28
- package/esm2020/src/commands/ClientToServer/WriteMessageToServerLogCommand.mjs +0 -18
- package/esm2020/src/commands/DataViewCommandBase.mjs +0 -10
- package/esm2020/src/commands/IClientTargetedCommand.mjs +0 -9
- package/esm2020/src/commands/ServerToClient/AbortCommand.mjs +0 -65
- package/esm2020/src/commands/ServerToClient/ClientRefreshCommand.mjs +0 -25
- package/esm2020/src/commands/ServerToClient/ClientTargetedCommandBase.mjs +0 -27
- package/esm2020/src/commands/ServerToClient/EnhancedVerifyCommand.mjs +0 -45
- package/esm2020/src/commands/ServerToClient/OpenURLCommand.mjs +0 -221
- package/esm2020/src/commands/ServerToClient/ResultCommand.mjs +0 -37
- package/esm2020/src/commands/ServerToClient/VerifyCommand.mjs +0 -83
- package/esm2020/src/communications/InteractiveCommunicationsFailureHandler.mjs +0 -17
- package/esm2020/src/data/DataView.mjs +0 -1610
- package/esm2020/src/data/DataviewManager.mjs +0 -28
- package/esm2020/src/data/DataviewManagerBase.mjs +0 -15
- package/esm2020/src/data/DvCache.mjs +0 -67
- package/esm2020/src/data/Field.mjs +0 -646
- package/esm2020/src/data/FieldBase.mjs +0 -18
- package/esm2020/src/data/FieldsTable.mjs +0 -103
- package/esm2020/src/data/Record.mjs +0 -846
- package/esm2020/src/data/RecordsTable.mjs +0 -267
- package/esm2020/src/env/EnvVariablesTable.mjs +0 -340
- package/esm2020/src/env/Environment.mjs +0 -489
- package/esm2020/src/env/LanguageData.mjs +0 -226
- package/esm2020/src/event/ActionManager.mjs +0 -91
- package/esm2020/src/event/Event.mjs +0 -1333
- package/esm2020/src/event/EventHandler.mjs +0 -766
- package/esm2020/src/event/EventHandlerPosition.mjs +0 -204
- package/esm2020/src/event/EventsManager.mjs +0 -2975
- package/esm2020/src/event/RunTimeEvent.mjs +0 -392
- package/esm2020/src/event/UserEventsTable.mjs +0 -47
- package/esm2020/src/exp/ExpTable.mjs +0 -59
- package/esm2020/src/exp/Expression.mjs +0 -200
- package/esm2020/src/exp/ExpressionDict.mjs +0 -727
- package/esm2020/src/exp/ExpressionEvaluator.mjs +0 -4212
- package/esm2020/src/exp/ExpressionLocalJpn.mjs +0 -314
- package/esm2020/src/exp/YesNoExp.mjs +0 -36
- package/esm2020/src/gui/CreatedFormVector.mjs +0 -23
- package/esm2020/src/gui/FormsTable.mjs +0 -66
- package/esm2020/src/gui/MgControl.mjs +0 -353
- package/esm2020/src/gui/MgForm.mjs +0 -1181
- package/esm2020/src/http/HttpManager.mjs +0 -97
- package/esm2020/src/http/client/HttpClientAsync.mjs +0 -67
- package/esm2020/src/http/client/HttpClientEvents.mjs +0 -39
- package/esm2020/src/http/client/HttpClientSync.mjs +0 -42
- package/esm2020/src/http/client/HttpUtility.mjs +0 -84
- package/esm2020/src/remote/RemoteCommandsProcessor.mjs +0 -880
- package/esm2020/src/remote/ServerError.mjs +0 -40
- package/esm2020/src/rt/Argument.mjs +0 -265
- package/esm2020/src/rt/ArgumentsList.mjs +0 -103
- package/esm2020/src/rt/Boundary.mjs +0 -152
- package/esm2020/src/rt/CompMainPrgTable.mjs +0 -65
- package/esm2020/src/rt/DataviewHeaderBase.mjs +0 -96
- package/esm2020/src/rt/DataviewHeaders.mjs +0 -53
- package/esm2020/src/rt/LastFocusedManager.mjs +0 -67
- package/esm2020/src/rt/Operation.mjs +0 -735
- package/esm2020/src/rt/OperationTable.mjs +0 -67
- package/esm2020/src/rt/Recompute.mjs +0 -355
- package/esm2020/src/rt/ResultValue.mjs +0 -12
- package/esm2020/src/rt/TableCache.mjs +0 -177
- package/esm2020/src/rt/TableCacheManager.mjs +0 -67
- package/esm2020/src/rt/Transaction.mjs +0 -53
- package/esm2020/src/security/UserDetails.mjs +0 -71
- package/esm2020/src/tasks/MGData.mjs +0 -552
- package/esm2020/src/tasks/MGDataCollection.mjs +0 -252
- package/esm2020/src/tasks/RCTimer.mjs +0 -63
- package/esm2020/src/tasks/Task.mjs +0 -2495
- package/esm2020/src/tasks/TaskBase.mjs +0 -87
- package/esm2020/src/tasks/TasksTable.mjs +0 -80
- package/esm2020/src/tasks/sort/Sort.mjs +0 -7
- package/esm2020/src/util/FlowMonitorQueue.mjs +0 -453
- package/esm2020/src/util/MgPriorityBlockingQueue.mjs +0 -74
- package/esm2020/src/util/MgPriorityQueue.mjs +0 -66
- package/esm2020/src/util/PrmMap.mjs +0 -151
- package/esm2020/src/util/ReturnResult.mjs +0 -46
- package/esm2020/src/util/ReturnResultBase.mjs +0 -18
- package/esm2020/src/util/Scrambler.mjs +0 -89
- package/esm2020/src/util/UniqueIDUtils.mjs +0 -12
- package/fesm2015/magic-xpa-engine.mjs +0 -30835
- package/fesm2015/magic-xpa-engine.mjs.map +0 -1
- package/fesm2020/magic-xpa-engine.mjs.map +0 -1
@@ -1,152 +0,0 @@
|
|
1
|
-
import { ExpressionEvaluator, NullValueException } from "../exp/ExpressionEvaluator";
|
2
|
-
import { DisplayConvertor, ExpVal } from "@magic-xpa/gui";
|
3
|
-
import { StorageAttribute, StrUtil } from "@magic-xpa/utils";
|
4
|
-
import { Char, NString } from "@magic-xpa/mscorelib";
|
5
|
-
export class Boundary {
|
6
|
-
constructor(task, minIdx, maxIdx, returnType, size, cacheTableId) {
|
7
|
-
this._cacheTableFldId = 0;
|
8
|
-
this._max = null;
|
9
|
-
this._min = null;
|
10
|
-
this._retType = StorageAttribute.NONE;
|
11
|
-
this._size = 0;
|
12
|
-
this._maxExpVal = null;
|
13
|
-
this._minExpVal = null;
|
14
|
-
this.DiscardMin = false;
|
15
|
-
this.DiscardMax = false;
|
16
|
-
this.MaxEqualsMin = false;
|
17
|
-
if (arguments.length === 5)
|
18
|
-
this.constructor_0(task, minIdx, maxIdx, returnType, size);
|
19
|
-
else
|
20
|
-
this.constructor_1(task, minIdx, maxIdx, returnType, size, cacheTableId);
|
21
|
-
}
|
22
|
-
constructor_0(task, minIdx, maxIdx, returnType, size) {
|
23
|
-
this.constructor_1(task, minIdx, maxIdx, returnType, size, -1);
|
24
|
-
}
|
25
|
-
constructor_1(task, minIdx, maxIdx, returnType, size, cacheTableId) {
|
26
|
-
this._retType = returnType;
|
27
|
-
this._size = size;
|
28
|
-
this._cacheTableFldId = cacheTableId;
|
29
|
-
if (minIdx !== -1)
|
30
|
-
this._min = task.getExpById(minIdx);
|
31
|
-
if (maxIdx !== -1)
|
32
|
-
this._max = task.getExpById(maxIdx);
|
33
|
-
}
|
34
|
-
hasMinExp() {
|
35
|
-
return this._min !== null;
|
36
|
-
}
|
37
|
-
hasMaxExp() {
|
38
|
-
return this._max !== null;
|
39
|
-
}
|
40
|
-
getExpType() {
|
41
|
-
return this._retType;
|
42
|
-
}
|
43
|
-
getCacheTableFldId() {
|
44
|
-
return this._cacheTableFldId;
|
45
|
-
}
|
46
|
-
async compute(padValueWithMinMaxCharacters) {
|
47
|
-
if (this.hasMinExp()) {
|
48
|
-
let minVal = await this._min.evaluateWithResultTypeAndLength(this.getExpType(), this._size);
|
49
|
-
if (minVal !== null) {
|
50
|
-
minVal = NString.TrimEnd(minVal, new Array(0));
|
51
|
-
}
|
52
|
-
this._minExpVal = new ExpVal(this.getExpType(), minVal === null, minVal);
|
53
|
-
this.MaxEqualsMin = this.IsMaxEqualsMin();
|
54
|
-
if (!this._minExpVal.IsNull && (this._minExpVal.Attr === StorageAttribute.ALPHA || this._minExpVal.Attr === StorageAttribute.UNICODE)) {
|
55
|
-
if (padValueWithMinMaxCharacters) {
|
56
|
-
this._minExpVal.StrVal = DisplayConvertor.StringValueToMgValue(this._minExpVal.StrVal, this._minExpVal.Attr, Char.MinValue, this._size).toString();
|
57
|
-
this.MaxEqualsMin = false;
|
58
|
-
}
|
59
|
-
this._minExpVal.StrVal = StrUtil.SearchAndReplaceWildChars(this._minExpVal.StrVal, this._size, Char.MinValue);
|
60
|
-
}
|
61
|
-
this.DiscardMin = await this._min.DiscardCndRangeResult();
|
62
|
-
}
|
63
|
-
if (this.hasMaxExp()) {
|
64
|
-
let maxVal = await this._max.evaluateWithResultTypeAndLength(this.getExpType(), this._size);
|
65
|
-
this._maxExpVal = new ExpVal(this.getExpType(), maxVal === null, maxVal);
|
66
|
-
if (!this._maxExpVal.IsNull && (this._maxExpVal.Attr === StorageAttribute.ALPHA || this._maxExpVal.Attr === StorageAttribute.UNICODE)) {
|
67
|
-
if (padValueWithMinMaxCharacters) {
|
68
|
-
this._maxExpVal.StrVal = DisplayConvertor.StringValueToMgValue(this._maxExpVal.StrVal, this._maxExpVal.Attr, Char.MaxValue, this._size);
|
69
|
-
}
|
70
|
-
this._maxExpVal.StrVal = StrUtil.SearchAndReplaceWildChars(this._maxExpVal.StrVal, this._size, Char.MaxValue);
|
71
|
-
}
|
72
|
-
this.DiscardMax = await this._max.DiscardCndRangeResult();
|
73
|
-
}
|
74
|
-
}
|
75
|
-
checkRange(val, IsNull) {
|
76
|
-
let res = true;
|
77
|
-
let cmpVal = new ExpVal(this.getExpType(), IsNull, val);
|
78
|
-
if (cmpVal.IsNull && ((this.hasMinExp() && this._minExpVal.IsNull) || (this.hasMaxExp() && this._maxExpVal.IsNull))) {
|
79
|
-
res = true;
|
80
|
-
}
|
81
|
-
else {
|
82
|
-
if (this.hasMinExp()) {
|
83
|
-
if (!this._minExpVal.IsNull && !cmpVal.IsNull) {
|
84
|
-
try {
|
85
|
-
if (ExpressionEvaluator.val_cmp_any(cmpVal, this._minExpVal) < 0)
|
86
|
-
res = false;
|
87
|
-
}
|
88
|
-
catch (exception) {
|
89
|
-
if (exception instanceof NullValueException) {
|
90
|
-
res = false;
|
91
|
-
}
|
92
|
-
else
|
93
|
-
throw exception;
|
94
|
-
}
|
95
|
-
}
|
96
|
-
else {
|
97
|
-
if (cmpVal.IsNull !== this._minExpVal.IsNull)
|
98
|
-
res = false;
|
99
|
-
}
|
100
|
-
}
|
101
|
-
if (this.hasMaxExp() && res) {
|
102
|
-
if (!this._maxExpVal.IsNull && !cmpVal.IsNull) {
|
103
|
-
try {
|
104
|
-
if (ExpressionEvaluator.val_cmp_any(cmpVal, this._maxExpVal) > 0)
|
105
|
-
res = false;
|
106
|
-
}
|
107
|
-
catch (exception) {
|
108
|
-
if (exception instanceof NullValueException)
|
109
|
-
res = false;
|
110
|
-
else
|
111
|
-
throw exception;
|
112
|
-
}
|
113
|
-
}
|
114
|
-
else if (cmpVal.IsNull !== this._maxExpVal.IsNull)
|
115
|
-
res = false;
|
116
|
-
}
|
117
|
-
}
|
118
|
-
return res;
|
119
|
-
}
|
120
|
-
IsMaxEqualsMin() {
|
121
|
-
let result = false;
|
122
|
-
if (this.hasMaxExp() && this.hasMinExp()) {
|
123
|
-
if (this._min.getId() === this._max.getId()) {
|
124
|
-
if (this._retType === StorageAttribute.ALPHA || this._retType === StorageAttribute.UNICODE)
|
125
|
-
result = !this.WildCharExist();
|
126
|
-
else
|
127
|
-
result = true;
|
128
|
-
}
|
129
|
-
}
|
130
|
-
return result;
|
131
|
-
}
|
132
|
-
WildCharExist() {
|
133
|
-
let wildChars = ["*", "?"];
|
134
|
-
let result = false;
|
135
|
-
if (!this._minExpVal.IsNull) {
|
136
|
-
let stringValue = this._minExpVal.StrVal;
|
137
|
-
for (let i = 0; i < wildChars.length; i = i + 1) {
|
138
|
-
if (stringValue.endsWith(wildChars[i])) {
|
139
|
-
result = true;
|
140
|
-
break;
|
141
|
-
}
|
142
|
-
}
|
143
|
-
}
|
144
|
-
return result;
|
145
|
-
}
|
146
|
-
toString() {
|
147
|
-
return NString.Format("{{Boundary: {0}-{1}, {2}, {3}}}", [
|
148
|
-
this._max, this._max, this._retType, this._size
|
149
|
-
]);
|
150
|
-
}
|
151
|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bCkge1xyXG4gICAgICAgICAgdHJ5IHtcclxuICAgICAgICAgICAgLy8gdGhlIGNvbXBhcmVkIHZhbHVlIG11c3QgYmUgZXF1YWwgb3IgZ3JlYXRlciB0byB0aGUgbWluIHZhbHVlXHJcbiAgICAgICAgICAgIGlmIChFeHByZXNzaW9uRXZhbHVhdG9yLnZhbF9jbXBfYW55KGNtcFZhbCwgdGhpcy5fbWluRXhwVmFsKSA8IDApXHJcbiAgICAgICAgICAgICAgcmVzID0gZmFsc2U7XHJcbiAgICAgICAgICB9XHJcbiAgICAgICAgICBjYXRjaCAoZXhjZXB0aW9uKSB7XHJcbiAgICAgICAgICAgIGlmIChleGNlcHRpb24gaW5zdGFuY2VvZiBOdWxsVmFsdWVFeGNlcHRpb24pIHtcclxuICAgICAgICAgICAgICByZXMgPSBmYWxzZTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICBlbHNlXHJcbiAgICAgICAgICAgICAgdGhyb3cgZXhjZXB0aW9uO1xyXG4gICAgICAgICAgfVxyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgIGlmIChjbXBWYWwuSXNOdWxsICE9PSB0aGlzLl9taW5FeHBWYWwuSXNOdWxsKVxyXG4gICAgICAgICAgICByZXMgPSBmYWxzZTtcclxuICAgICAgICB9XHJcbiAgICAgIH1cclxuICAgICAgLy8gY2hlY2sgbWF4IGV4cHJlc3Npb24gQ29tcGxpYW5jZVxyXG4gICAgICBpZiAodGhpcy5oYXNNYXhFeHAoKSAmJiByZXMpIHtcclxuICAgICAgICAvLyBpZiBib3RoIG9mIHRoZSBjb21wYXJlZCB2YWx1ZXMgYXJlIG5vdCBudWxsXHJcbiAgICAgICAgaWYgKCF0aGlzLl9tYXhFeHBWYWwuSXNOdWxsICYmICFjbXBWYWwuSXNOdWxsKSB7XHJcbiAgICAgICAgICB0cnkge1xyXG4gICAgICAgICAgICAvLyB0aGUgY29tcGFyZWQgdmFsdWUgbXVzdCBiZSBlcX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IChzdHJpbmdWYWx1ZS5lbmRzV2l0aCh3aWxkQ2hhcnNbaV0pKSB7XHJcbiAgICAgICAgICByZXN1bHQgPSB0cnVlO1xyXG4gICAgICAgICAgYnJlYWs7XHJcbiAgICAgICAgfVxyXG4gICAgICB9XHJcbiAgICB9XHJcbiAgICByZXR1cm4gcmVzdWx0O1xyXG4gIH1cclxuXHJcbiAgdG9TdHJpbmcoKTogc3RyaW5nIHtcclxuICAgIHJldHVybiBOU3RyaW5nLkZvcm1hdChcInt7Qm91bmRhcnk6IHswfS17MX0sIHsyfSwgezN9fX1cIiwgW1xyXG4gICAgICB0aGlzLl9tYXgsIHRoaXMuX21heCwgdGhpcy5fcmV0VHlwZSwgdGhpcy5fc2l6ZVxyXG4gICAgXSk7XHJcbiAgfVxyXG59XHJcbiJdfQ==
|
@@ -1,65 +0,0 @@
|
|
1
|
-
import { Logger, StrUtil, XMLConstants, XmlParser } from "@magic-xpa/utils";
|
2
|
-
import { NString, NNumber } from "@magic-xpa/mscorelib";
|
3
|
-
import { ConstInterface } from "../ConstInterface";
|
4
|
-
export class CompMainPrgTable {
|
5
|
-
constructor() {
|
6
|
-
this._ctlIdxTab = null;
|
7
|
-
}
|
8
|
-
fillData(parser) {
|
9
|
-
let endContext = parser.getXMLdata().indexOf(XMLConstants.TAG_TERM, parser.getCurrIndex());
|
10
|
-
if (endContext !== -1 && endContext < parser.getXMLdata().length) {
|
11
|
-
let tag = parser.getXMLsubstring(endContext);
|
12
|
-
parser.add2CurrIndex(tag.indexOf(ConstInterface.MG_TAG_COMPMAINPRG) + ConstInterface.MG_TAG_COMPMAINPRG.length);
|
13
|
-
let tokensVector = XmlParser.getTokens(parser.getXMLsubstring(endContext), XMLConstants.XML_ATTR_DELIM);
|
14
|
-
Logger.Instance.WriteDevToLog("in CompMainPrg.FillData: " + tokensVector.toString());
|
15
|
-
this.initElements(tokensVector);
|
16
|
-
parser.setCurrIndex(endContext + XMLConstants.TAG_TERM.length);
|
17
|
-
return;
|
18
|
-
}
|
19
|
-
Logger.Instance.WriteExceptionToLogWithMsg("in CompMainPrg.FillData() out of string bounds");
|
20
|
-
}
|
21
|
-
initElements(tokensVector) {
|
22
|
-
for (let j = 0; j < tokensVector.length; j += 2) {
|
23
|
-
let attribute = (tokensVector.get_Item(j));
|
24
|
-
let valueStr = (tokensVector.get_Item(j + 1));
|
25
|
-
if (attribute === XMLConstants.MG_ATTR_VALUE) {
|
26
|
-
valueStr = StrUtil.DeleteStringsFromEnds(valueStr, "\"");
|
27
|
-
this.initCtlIdxTab(valueStr);
|
28
|
-
}
|
29
|
-
else
|
30
|
-
Logger.Instance.WriteExceptionToLogWithMsg(NString.Format("There is no such index in CompMainPrg. Add case to CompMainPrg.initElements for {0}", attribute));
|
31
|
-
}
|
32
|
-
Logger.Instance.WriteDevToLog("End CompMainPrg ");
|
33
|
-
}
|
34
|
-
initCtlIdxTab(val) {
|
35
|
-
if (NString.IsNullOrEmpty(val))
|
36
|
-
return;
|
37
|
-
if (val.indexOf(",") !== -1)
|
38
|
-
this._ctlIdxTab = StrUtil.tokenize(val, ",");
|
39
|
-
else {
|
40
|
-
this._ctlIdxTab = new Array(1);
|
41
|
-
this._ctlIdxTab[0] = val;
|
42
|
-
}
|
43
|
-
}
|
44
|
-
getCtlIdx(idx) {
|
45
|
-
if (idx >= 0 && idx < this.getSize()) {
|
46
|
-
let s = this._ctlIdxTab[idx];
|
47
|
-
return NNumber.Parse(s);
|
48
|
-
}
|
49
|
-
return -1;
|
50
|
-
}
|
51
|
-
getIndexOf(ctlIdx) {
|
52
|
-
let i;
|
53
|
-
for (i = 0; i < this.getSize(); i++) {
|
54
|
-
if (ctlIdx === this.getCtlIdx(i))
|
55
|
-
return i;
|
56
|
-
}
|
57
|
-
return -1;
|
58
|
-
}
|
59
|
-
getSize() {
|
60
|
-
if (this._ctlIdxTab === null)
|
61
|
-
return 0;
|
62
|
-
return this._ctlIdxTab.length;
|
63
|
-
}
|
64
|
-
}
|
65
|
-
//# sourceMapping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VdGlsLnRva2VuaXplKHZhbCwgXCIsXCIpO1xyXG4gICAgZWxzZSB7XHJcbiAgICAgIHRoaXMuX2N0bElkeFRhYiA9IG5ldyBBcnJheSgxKTtcclxuICAgICAgdGhpcy5fY3RsSWR4VGFiWzBdID0gdmFsO1xyXG4gICAgfVxyXG4gIH1cclxuXHJcbiAgZ2V0Q3RsSWR4KGlkeDogbnVtYmVyKTogbnVtYmVyIHtcclxuICAgIGlmIChpZHggPj0gMCAmJiBpZHggPCB0aGlzLmdldFNpemUoKSkge1xyXG4gICAgICBsZXQgczogc3RyaW5nID0gdGhpcy5fY3RsSWR4VGFiW2lkeF07XHJcbiAgICAgIHJldHVybiBOTnVtYmVyLlBhcnNlKHMpO1xyXG4gICAgfVxyXG4gICAgcmV0dXJuIC0xO1xyXG4gIH1cclxuXHJcbiAgcHVibGljIGdldEluZGV4T2YoY3RsSWR4OiBudW1iZXIpOiBudW1iZXIge1xyXG4gICAgbGV0IGk6IG51bWJlcjtcclxuICAgIGZvciAoaSA9IDA7IGkgPCB0aGlzLmdldFNpemUoKTsgaSsrKSB7XHJcbiAgICAgIGlmIChjdGxJZHggPT09IHRoaXMuZ2V0Q3RsSWR4KGkpKVxyXG4gICAgICAgIHJldHVybiBpO1xyXG4gICAgfVxyXG4gICAgcmV0dXJuIC0xO1xyXG4gIH1cclxuXHJcbiAgZ2V0U2l6ZSgpOiBudW1iZXIge1xyXG4gICAgaWYgKHRoaXMuX2N0bElkeFRhYiA9PT0gbnVsbClcclxuICAgICAgcmV0dXJuIDA7XHJcbiAgICByZXR1cm4gdGhpcy5fY3RsSWR4VGFiLmxlbmd0aDtcclxuICB9XHJcbn1cclxuIl19
|
@@ -1,96 +0,0 @@
|
|
1
|
-
import { YesNoExp } from '../exp/YesNoExp';
|
2
|
-
import { NString, RefParam } from '@magic-xpa/mscorelib';
|
3
|
-
import { Logger, XMLConstants, XmlParser } from '@magic-xpa/utils';
|
4
|
-
import { ConstInterface } from '../ConstInterface';
|
5
|
-
export class DataviewHeaderBase {
|
6
|
-
get ReturnField() {
|
7
|
-
if (this.returnfield === null && this._retVal !== null)
|
8
|
-
this.returnfield = this.Task.getFieldByValueStr(this._retVal);
|
9
|
-
return this.returnfield;
|
10
|
-
}
|
11
|
-
get IsMainSource() {
|
12
|
-
return this._id === -1;
|
13
|
-
}
|
14
|
-
get Task() {
|
15
|
-
return this._task;
|
16
|
-
}
|
17
|
-
get Fields() {
|
18
|
-
return this._task.DataView.GetFieldsTab().getLinkFields(this._id);
|
19
|
-
}
|
20
|
-
get Id() {
|
21
|
-
return this._id;
|
22
|
-
}
|
23
|
-
get LinkEvaluateCondition() {
|
24
|
-
return this._linkEvalCondition;
|
25
|
-
}
|
26
|
-
constructor(task) {
|
27
|
-
this._cond = null;
|
28
|
-
this._task = null;
|
29
|
-
this.Loc = null;
|
30
|
-
this._dir = '\0';
|
31
|
-
this._id = 0;
|
32
|
-
this._keyIdx = 0;
|
33
|
-
this._retVal = null;
|
34
|
-
this.returnfield = null;
|
35
|
-
this.LinkStartAfterField = 0;
|
36
|
-
this.KeyExpression = 0;
|
37
|
-
this._task = task;
|
38
|
-
this._keyIdx = -1;
|
39
|
-
this._cond = new YesNoExp(true);
|
40
|
-
}
|
41
|
-
SetAttributes(attributes) {
|
42
|
-
let keys = attributes.Keys;
|
43
|
-
keys.forEach((text) => {
|
44
|
-
this.setAttribute(text, attributes.get_Item(text));
|
45
|
-
});
|
46
|
-
}
|
47
|
-
setAttribute(attribute, valueStr) {
|
48
|
-
switch (attribute) {
|
49
|
-
case XMLConstants.MG_ATTR_ID:
|
50
|
-
this._id = XmlParser.getInt(valueStr);
|
51
|
-
break;
|
52
|
-
case ConstInterface.MG_ATTR_KEY:
|
53
|
-
this._keyIdx = XmlParser.getInt(valueStr);
|
54
|
-
break;
|
55
|
-
case ConstInterface.MG_ATTR_KEY_EXP:
|
56
|
-
this.KeyExpression = XmlParser.getInt(valueStr);
|
57
|
-
break;
|
58
|
-
case ConstInterface.MG_ATTR_DIR:
|
59
|
-
this._dir = valueStr[0];
|
60
|
-
break;
|
61
|
-
case ConstInterface.MG_ATTR_COND:
|
62
|
-
case ConstInterface.MG_ATTR_COND_RES:
|
63
|
-
this._cond.setVal(this._task, valueStr);
|
64
|
-
break;
|
65
|
-
case ConstInterface.MG_ATTR_RET_VAL:
|
66
|
-
this._retVal = valueStr;
|
67
|
-
break;
|
68
|
-
case ConstInterface.MG_ATTR_LINK_EVAL_CONDITION:
|
69
|
-
this._linkEvalCondition = valueStr[0];
|
70
|
-
break;
|
71
|
-
case ConstInterface.MG_ATTR_LINK_MODE:
|
72
|
-
this.Mode = valueStr[0];
|
73
|
-
break;
|
74
|
-
case ConstInterface.MG_ATTR_LINK_START:
|
75
|
-
this.LinkStartAfterField = XmlParser.getInt(valueStr);
|
76
|
-
break;
|
77
|
-
default:
|
78
|
-
Logger.Instance.WriteExceptionToLogWithMsg(NString.Format("Unrecognized attribute: '{0}'", attribute));
|
79
|
-
break;
|
80
|
-
}
|
81
|
-
}
|
82
|
-
async getLinkedRecord(curRec) {
|
83
|
-
return Promise.resolve(true);
|
84
|
-
}
|
85
|
-
async InitLinkFields(currRec) {
|
86
|
-
for (let i = 0; i < this.Fields.length; i++) {
|
87
|
-
let field = this.Fields.get_Item(i);
|
88
|
-
let isNull = new RefParam(field.isNull());
|
89
|
-
let result = new RefParam(field.getValue(false));
|
90
|
-
await field.getInitExpVal(result, isNull);
|
91
|
-
currRec.SetFieldValue(field.getId(), isNull.value, result.value);
|
92
|
-
field.invalidate(true, false);
|
93
|
-
}
|
94
|
-
}
|
95
|
-
}
|
96
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiRGF0YXZpZXdIZWFkZXJCYXNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvZW5naW5lL3NyYy9ydC9EYXRhdmlld0hlYWRlckJhc2UudHMiXSwibm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ua1xyXG5cclxuICAgIGZvciAobGV0IGk6IG51bWJlciA9IDA7IGkgPCB0aGlzLkZpZWxkcy5sZW5ndGg7IGkrKykge1xyXG4gICAgICBsZXQgZmllbGQ6IEZpZWxkID0gdGhpcy5GaWVsZHMuZ2V0X0l0ZW0oaSk7XHJcblxyXG4gICAgICBsZXQgaXNOdWxsOiBSZWZQYXJhbTxib29sZWFuPiA9IG5ldyBSZWZQYXJhbShmaWVsZC5pc051bGwoKSk7XHJcbiAgICAgIGxldCByZXN1bHQ6IFJlZlBhcmFtPHN0cmluZz4gPSBuZXcgUmVmUGFyYW0oZmllbGQuZ2V0VmFsdWUoZmFsc2UpKTtcclxuICAgICAgYXdhaXQgZmllbGQuZ2V0SW5pdEV4cFZhbChyZXN1bHQsIGlzTnVsbCk7XHJcbiAgICAgIC8vIHRoaXMgZnVuY3Rpb24ga25vd3MgdG8gdGFrZSBlaXRoZXIgdGhlIG51bGwgdmFsdWUgb3IgdGhlIGRlZnVhbHQgdmFsdWVcclxuICAgICAgKDxSZWNvcmQ+Y3VyclJlYykuU2V0RmllbGRWYWx1ZShmaWVsZC5nZXRJZCgpLCBpc051bGwudmFsdWUsIHJlc3VsdC52YWx1ZSk7XHJcbiAgICAgIGZpZWxkLmludmFsaWRhdGUodHJ1ZSwgZmFsc2UpO1xyXG4gICAgfVxyXG4gIH1cclxufVxyXG4iXX0=
|
@@ -1,53 +0,0 @@
|
|
1
|
-
import { Hashtable, StringBuilder } from "@magic-xpa/mscorelib";
|
2
|
-
import { Logger, XMLConstants, XmlParser } from "@magic-xpa/utils";
|
3
|
-
import { DataviewHeadersSaxHandler } from "./DataviewHeadersSaxHandler";
|
4
|
-
import { RemoteDataviewHeader } from "./RemoteDataviewHeader";
|
5
|
-
import { ConstInterface } from "../ConstInterface";
|
6
|
-
export class DataviewHeaders {
|
7
|
-
constructor(task) {
|
8
|
-
this._dataviewHeaders = null;
|
9
|
-
this._task = null;
|
10
|
-
this._task = task;
|
11
|
-
this._dataviewHeaders = new Hashtable();
|
12
|
-
}
|
13
|
-
fillData(parser) {
|
14
|
-
while (this.initInnerObjects(parser, parser.getNextTag())) {
|
15
|
-
}
|
16
|
-
}
|
17
|
-
initInnerObjects(parser, foundTagName) {
|
18
|
-
if (foundTagName === null)
|
19
|
-
return false;
|
20
|
-
if (foundTagName === ConstInterface.MG_TAG_LINKS) {
|
21
|
-
let endContext = parser.getXMLdata().indexOf(ConstInterface.MG_TAG_LINKS_END, parser.getCurrIndex()) + ConstInterface.MG_TAG_LINKS_END.length + 1;
|
22
|
-
let xml = parser.getXMLsubstring(endContext);
|
23
|
-
xml = XmlParser.escapeUrl(xml);
|
24
|
-
new DataviewHeadersSaxHandler(this._task, this._dataviewHeaders, xml);
|
25
|
-
parser.setCurrIndex(endContext + XMLConstants.TAG_CLOSE.length);
|
26
|
-
}
|
27
|
-
else
|
28
|
-
Logger.Instance.WriteExceptionToLogWithMsg("There is no such tag in LinksTable.initInnerObjects(): " + foundTagName);
|
29
|
-
}
|
30
|
-
getDataviewHeaderById(linkId) {
|
31
|
-
return this._dataviewHeaders.get_Item(linkId);
|
32
|
-
}
|
33
|
-
buildDbPosString() {
|
34
|
-
if (this._dataviewHeaders.Count === 0) {
|
35
|
-
return null;
|
36
|
-
}
|
37
|
-
let buf = new StringBuilder();
|
38
|
-
let dataviewHeaders = this._dataviewHeaders.Values;
|
39
|
-
while (dataviewHeaders.MoveNext()) {
|
40
|
-
let curr = ((dataviewHeaders.Current instanceof RemoteDataviewHeader) ? dataviewHeaders.Current : null);
|
41
|
-
if (curr !== null) {
|
42
|
-
let currDbPosVal = curr.getLastFetchedDbPos();
|
43
|
-
buf.Append("@");
|
44
|
-
if (currDbPosVal !== null) {
|
45
|
-
buf.Append(currDbPosVal);
|
46
|
-
}
|
47
|
-
}
|
48
|
-
}
|
49
|
-
buf.Append("@");
|
50
|
-
return buf.ToString();
|
51
|
-
}
|
52
|
-
}
|
53
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJz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GF0YXZpZXdIZWFkZXJCYXNlPiA9IHRoaXMuX2RhdGF2aWV3SGVhZGVycy5WYWx1ZXM7XHJcblxyXG4gICAgd2hpbGUgKGRhdGF2aWV3SGVhZGVycy5Nb3ZlTmV4dCgpKSB7XHJcbiAgICAgIGxldCBjdXJyOiBSZW1vdGVEYXRhdmlld0hlYWRlciA9ICgoZGF0YXZpZXdIZWFkZXJzLkN1cnJlbnQgaW5zdGFuY2VvZiBSZW1vdGVEYXRhdmlld0hlYWRlcikgPyAgPFJlbW90ZURhdGF2aWV3SGVhZGVyPmRhdGF2aWV3SGVhZGVycy5DdXJyZW50IDogbnVsbCk7XHJcblxyXG4gICAgICBpZiAoY3VyciAhPT0gbnVsbCkge1xyXG4gICAgICAgIGxldCBjdXJyRGJQb3NWYWw6IHN0cmluZyA9IGN1cnIuZ2V0TGFzdEZldGNoZWREYlBvcygpO1xyXG4gICAgICAgIGJ1Zi5BcHBlbmQoXCJAXCIpO1xyXG5cclxuICAgICAgICAvLyBpZiB0aGUgbGFzdCBmZXRjaCBkYiBwb3Mgb2YgdGhlIGxpbmsgaXMgbnVsbCBpdCBtZWFucyB0aGF0IHdlIG5ldmVyIGZldGNoZWQgYSByZWNvcmQgZnJvbSB0aGUgbGlua1xyXG4gICAgICAgIGlmIChjdXJyRGJQb3NWYWwgIT09IG51bGwpIHtcclxuICAgICAgICAgIGJ1Zi5BcHBlbmQoY3VyckRiUG9zVmFsKTtcclxuICAgICAgICB9XHJcbiAgICAgIH1cclxuICAgIH1cclxuICAgIGJ1Zi5BcHBlbmQoXCJAXCIpO1xyXG4gICAgcmV0dXJuIGJ1Zi5Ub1N0cmluZygpO1xyXG4gIH1cclxuXHJcbn1cclxuIl19
|
@@ -1,67 +0,0 @@
|
|
1
|
-
import { Debug } from "@magic-xpa/mscorelib";
|
2
|
-
import { ControlTable } from "@magic-xpa/gui";
|
3
|
-
import { TasksTable } from "../tasks/TasksTable";
|
4
|
-
import { AccessHelper } from "../AccessHelper";
|
5
|
-
export class LastFocusedManager {
|
6
|
-
constructor() {
|
7
|
-
this._lastFocusedTasks = null;
|
8
|
-
this.LastActionTime = 0;
|
9
|
-
}
|
10
|
-
Init(mgDataTable) {
|
11
|
-
this._lastFocusedTasks = new TasksTable();
|
12
|
-
}
|
13
|
-
getCurrTask() {
|
14
|
-
let rtEvnt = AccessHelper.eventsManager.getLastRtEvent();
|
15
|
-
return (rtEvnt !== null && rtEvnt.getTask() !== null && rtEvnt.getTask().GetContextTask() !== null)
|
16
|
-
? this.getLastFocusedTask(rtEvnt.getTask().GetContextTask().getMgdID())
|
17
|
-
: this.getLastFocusedTask();
|
18
|
-
}
|
19
|
-
getLastFocusedTask(mgdID) {
|
20
|
-
if (arguments.length === 0)
|
21
|
-
return this._lastFocusedTasks.getTask(AccessHelper.mgDataTable.currMgdID);
|
22
|
-
else
|
23
|
-
return this._lastFocusedTasks.getTask(mgdID);
|
24
|
-
}
|
25
|
-
setLastFocusedTask(iTask) {
|
26
|
-
let task = iTask;
|
27
|
-
let currMgdID = task.getMgdID();
|
28
|
-
this._lastFocusedTasks.setTaskAt(task, currMgdID);
|
29
|
-
}
|
30
|
-
clean(index) {
|
31
|
-
LastFocusedManager.deleteLastFocusedControlAt(index);
|
32
|
-
if (this._lastFocusedTasks !== null) {
|
33
|
-
this._lastFocusedTasks.setTaskAt(null, index);
|
34
|
-
}
|
35
|
-
}
|
36
|
-
static getLastFocusedControl(mgdID) {
|
37
|
-
if (arguments.length === 1)
|
38
|
-
return LastFocusedManager.getLastFocusedControl_1(mgdID);
|
39
|
-
else
|
40
|
-
return LastFocusedManager.getLastFocusedControl_0();
|
41
|
-
}
|
42
|
-
static getLastFocusedControl_0() {
|
43
|
-
return LastFocusedManager._lastFocusedControls.getCtrl(AccessHelper.mgDataTable.currMgdID);
|
44
|
-
}
|
45
|
-
static getLastFocusedControl_1(mgdID) {
|
46
|
-
return LastFocusedManager._lastFocusedControls.getCtrl(mgdID);
|
47
|
-
}
|
48
|
-
static deleteLastFocusedControlAt(index) {
|
49
|
-
if (LastFocusedManager._lastFocusedControls !== null && LastFocusedManager._lastFocusedControls.getCtrl(index) != null) {
|
50
|
-
LastFocusedManager._lastFocusedControls.deleteControlAt(index);
|
51
|
-
}
|
52
|
-
}
|
53
|
-
static setLastFocusedControlAt(ctrl, currMgdID) {
|
54
|
-
LastFocusedManager._lastFocusedControls.setControlAt(ctrl, currMgdID);
|
55
|
-
}
|
56
|
-
static setLastFocusedControl(task, mgControl) {
|
57
|
-
let currMgdID = task.getMgdID();
|
58
|
-
Debug.Assert(mgControl === null || task === mgControl.getForm().getTask());
|
59
|
-
LastFocusedManager.LastFocusMgdID = currMgdID;
|
60
|
-
LastFocusedManager.setLastFocusedControlAt(mgControl, currMgdID);
|
61
|
-
LastFocusedManager.Instance.setLastFocusedTask(task);
|
62
|
-
}
|
63
|
-
}
|
64
|
-
LastFocusedManager.Instance = new LastFocusedManager();
|
65
|
-
LastFocusedManager._lastFocusedControls = new ControlTable();
|
66
|
-
LastFocusedManager.LastFocusMgdID = 0;
|
67
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiTGFzdEZvY3VzZWRNYW5hZ2VyLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvZW5naW5lL3NyYy9ydC9MYXN0Rm9jdXNlZE1hbmFnZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFDLEtBQUssRUFBQyxNQUFNLHNCQUFzQixDQUFDO0FBQzNDLE9BQU8sRUFBUyxZQUFZLEVBQWlCLE1BQU0sZ0JBQWdCLENBQUM7QUFJcEUsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLHFCQUFxQixDQUFDO0FBR2pELE9BQU8sRUFBRSxZQUFZLEVBQUUsTUFBTSxpQkFBaUIsQ0FBQztBQUcvQyxNQUFNLE9BQU8sa0JB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