@magic-xpa/engine 4.1200.0-dev4120.99 → 4.1200.0

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.
package/index.d.ts CHANGED
@@ -26,6 +26,7 @@ export * from "./src/commands/ClientToServer/AddUserLocateDataViewCommand";
26
26
  export * from "./src/commands/ClientToServer/AddUserRangeDataviewCommand";
27
27
  export * from "./src/commands/ClientToServer/AddUserSortDataViewCommand";
28
28
  export * from "./src/commands/ClientToServer/BrowserEscEventCommand";
29
+ export * from "./src/commands/ClientToServer/CachedFileQueryCommand";
29
30
  export * from "./src/commands/ClientToServer/ClientOriginatedCommand";
30
31
  export * from "./src/commands/ClientToServer/ClientOriginatedCommandSerializer";
31
32
  export * from "./src/commands/ClientToServer/ColumnSortEventCommand";
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@magic-xpa/engine",
3
- "version": "4.1200.0-dev4120.99",
3
+ "version": "4.1200.0",
4
4
  "description": "magic engine package",
5
5
  "license": "SEE LICENSE IN EULA.pdf",
6
6
  "dependencies": {
7
- "@magic-xpa/mscorelib": "4.1200.0-dev4120.99",
8
- "@magic-xpa/utils": "4.1200.0-dev4120.99",
9
- "@magic-xpa/gui": "4.1200.0-dev4120.99",
7
+ "@magic-xpa/mscorelib": "4.1200.0",
8
+ "@magic-xpa/utils": "4.1200.0",
9
+ "@magic-xpa/gui": "4.1200.0",
10
10
  "@angular/common": "^19.1.3",
11
11
  "tslib": "^2.3.0"
12
12
  },
@@ -24,6 +24,7 @@ export declare class ClientManager {
24
24
  GetGlobalUniqueSessionID(): string;
25
25
  static GetControlPictureMask(taskId: string, controlName: string): PIC;
26
26
  static UploadFileToServer(fileContent: any, serverFileName: string): any;
27
+ static DownloadFileFromServer(serverFileName: string): Promise<ArrayBuffer>;
27
28
  static GetFormattedValue(taskId: string, controlName: string, value: any, rowId?: string): string;
28
29
  static GetRangedValue(taskId: string, controlName: string, value: string): string;
29
30
  static ValidateControlValue(taskId: string, controlName: string, value: any): string;
@@ -17,7 +17,8 @@ export declare abstract class CommandsProcessorBase {
17
17
  Execute(sendingInstruction: CommandsProcessorBase_SendingInstruction, sessionStage: CommandsProcessorBase_SessionStage, res: IResultValue): Promise<void>;
18
18
  private Execute_0;
19
19
  Execute_1(sendingInstruction: CommandsProcessorBase_SendingInstruction, sessionStage: CommandsProcessorBase_SessionStage, res: IResultValue): Promise<void>;
20
- GetContent(requestedURL: string, useCache: boolean): Promise<string | ArrayBuffer>;
20
+ GetContent(requestedURL: string, useCache: boolean): Promise<ArrayBuffer>;
21
+ GetContentAsString(requestedURL: string, useCache: boolean): Promise<string>;
21
22
  abstract SendMonitorOnly(): void;
22
23
  static UnScramble(respBuf: string): string;
23
24
  }
@@ -1,6 +1,7 @@
1
1
  import { CommandsProcessorBase } from "./CommandsProcessorBase";
2
2
  export declare class CommandsProcessorManager {
3
3
  static GetCommandsProcessor(): CommandsProcessorBase;
4
- static GetContent(requestedURL: string, useCache: boolean): Promise<string | ArrayBuffer>;
4
+ static GetContent(requestedURL: string, useCache: boolean): Promise<ArrayBuffer>;
5
+ static GetContentString(requestedURL: string, useCache: boolean): Promise<string>;
5
6
  static StartSession(): Promise<boolean>;
6
7
  }
@@ -226,6 +226,9 @@ export declare class ConstInterface {
226
226
  static MG_ATTR_CPY_GLB_PRMS: string;
227
227
  static MG_TAG_GLOBALPARAMS: string;
228
228
  static MG_TAG_GLOBALPARAMSCHANGES: string;
229
+ static MG_ATTR_FILE_PATH: string;
230
+ static MG_TAG_CACHED_FILE: string;
231
+ static MG_ATTR_CACHE_URL: string;
229
232
  static MG_TAG_PARAM: string;
230
233
  static MG_ATTR_IME_AUTO_OFF: string;
231
234
  static MG_ATTR_LOCAL_AS400SET: string;
@@ -250,6 +253,7 @@ export declare class ConstInterface {
250
253
  static MG_ATTR_HANDLER_ONFORM: string;
251
254
  static MG_ATTR_DROP_USERFORMATS: string;
252
255
  static MG_ATTR_CONTROL_NAME: string;
256
+ static MG_ATTR_SEARCH_STR: string;
253
257
  static MG_TAG_HIDDEN_CONTOLS: string;
254
258
  static MG_ATTR_ISNS: string;
255
259
  static MG_ATTR_SPECIAL_CANCEL_ON_CREATE: string;
@@ -498,6 +502,7 @@ export declare class ConstInterface {
498
502
  static MG_ATTR_VAL_EVENT: string;
499
503
  static MG_ATTR_VAL_EXEC_OPER: string;
500
504
  static MG_ATTR_VAL_QUERY: string;
505
+ static MG_ATTR_VAL_QUERY_CACHED_FILE: string;
501
506
  static MG_ATTR_VAL_QUERY_GLOBAL_PARAMS: string;
502
507
  static MG_ATTR_VAL_QUERY_TYPE: string;
503
508
  static MG_ATTR_VAL_RECOMP: string;
@@ -514,4 +519,5 @@ export declare class ConstInterface {
514
519
  static MG_ATTR_SPECIAL_DOTNET_ALLOW_ZERO_DATE: string;
515
520
  static MG_ATTR_SPECIAL_REUSE_TABLE_EDITOR: string;
516
521
  static MG_TAG_LAST_ROUTE: string;
522
+ static RC_TOKEN_CACHED_FILE: string;
517
523
  }
@@ -8,6 +8,7 @@ export declare class MagicBridge {
8
8
  static insertEvent(guiEvent: IGuiEvent): void;
9
9
  static GetControlPictureMask(taskId: string, controlName: string): any;
10
10
  static UploadFileToServer(fileContent: any, serverFileName: string): any;
11
+ static DownloadFileFromServer(serverFileName: string): Promise<ArrayBuffer>;
11
12
  static GetFormattedValue(taskId: string, controlName: string, value: any, rowId?: string): string;
12
13
  static GetRangedValue(taskId: string, controlName: string, value: string): string;
13
14
  static ValidateControlValue(taskId: string, controlName: string, value: any): string;
@@ -0,0 +1,9 @@
1
+ import { QueryCommand } from "./QueryCommand";
2
+ export declare class CachedFileQueryCommand extends QueryCommand {
3
+ text: string;
4
+ constructor(text: string);
5
+ /**
6
+ * Serializes the query command data
7
+ */
8
+ SerializeQueryCommandData(): string;
9
+ }
@@ -31,18 +31,19 @@ import { IniputForceWriteCommand } from './IniputForceWriteCommand';
31
31
  import { ContextTerminationEventCommand } from './ContextTerminationEventCommand';
32
32
  import { ContextTimeoutResetCommand } from './ContextTimeoutResetCommand';
33
33
  import { ControlItemsRefreshCommand } from './ControlItemsRefreshCommand';
34
+ import { CachedFileQueryCommand } from "./CachedFileQueryCommand";
34
35
  export declare class CommandFactory {
35
36
  static CreateEventCommand(taskTag: string, magicEvent: number): EventCommand;
36
37
  static CreateRollbackEventCommand(taskTag: string, rollbackType: RollbackEventCommand_RollbackType): RollbackEventCommand;
37
38
  static CreateDataViewCommand(taskId: string, commandType: DataViewCommandType): DataviewCommand;
38
- static CreateControlItemsRefreshCommand(taskId: string, control: MgControlBase): ControlItemsRefreshCommand;
39
+ static CreateControlItemsRefreshCommand(taskId: string, control: MgControlBase, filterData: string): ControlItemsRefreshCommand;
39
40
  static CreateAddUserRangeDataviewCommand(taskId: string, userRange: UserRange): AddUserRangeDataviewCommand;
40
41
  static CreateAddUserSortDataviewCommand(taskId: string, sort: Sort): AddUserSortDataViewCommand;
41
42
  static CreateAddUserLocateDataviewCommand(taskId: string, userRange: UserRange): AddUserLocateDataViewCommand;
42
43
  static CreateSetTransactionStateDataviewCommand(taskId: string, transactionIsOpened: boolean): SetTransactionStateDataviewCommand;
43
44
  static CreateInternalRefreshCommand(taskId: string, magicEvent: number, currentRecId: number, currentRow: number): RefreshEventCommand;
44
45
  static CreateRealRefreshCommand(taskId: string, magicEvent: number, currentRow: number, argList: ArgumentsList, currentRecId: number): Promise<RefreshEventCommand>;
45
- static CreatecFetchDataControlValuesCommand(taskTag: string, controlName: string): FetchDataControlValuesEventCommand;
46
+ static CreatecFetchDataControlValuesCommand(taskTag: string, controlName: string, filterData: string): FetchDataControlValuesEventCommand;
46
47
  static CreateSubformRefreshCommand(taskTag: string, subformTaskTag: string, explicitSubformRefresh: boolean): SubformRefreshEventCommand;
47
48
  static CreateSubformOpenCommand(taskTag: string, subformDitIdx: number): SubformOpenEventCommand;
48
49
  static CreateScreenRefreshCommand(taskTag: string, topRecIdx: number, clientRecId: number): RefreshScreenEventCommand;
@@ -61,4 +62,5 @@ export declare class CommandFactory {
61
62
  static CreateEvaluateCommand(taskTag: string, expType: StorageAttribute, expIdx: number, expValLen: number, mprgCreator: Task): EvaluateCommand;
62
63
  static CreateQueryGlobalParamsCommand(): GlobalParamsQueryCommand;
63
64
  static CreateIniputForceWriteCommand(param: string): IniputForceWriteCommand;
65
+ static CreateQueryCachedFileCommand(cachedFileName: string): CachedFileQueryCommand;
64
66
  }
@@ -2,5 +2,6 @@ import { DataviewCommand } from "./DataviewCommand";
2
2
  import { MgControlBase } from "@magic-xpa/gui";
3
3
  export declare class ControlItemsRefreshCommand extends DataviewCommand {
4
4
  Control: MgControlBase;
5
+ FilterData: string;
5
6
  constructor();
6
7
  }
@@ -2,6 +2,7 @@ import { EventCommand } from './EventCommand';
2
2
  import { IClientToServerCommandInfo } from '../IClientToServerCommandInfo';
3
3
  export declare class FetchDataControlValuesEventCommand extends EventCommand implements IClientToServerCommandInfo {
4
4
  ControlName: string;
5
+ FilterData: string;
5
6
  constructor();
6
7
  SerializeCommandData(): string;
7
8
  getCommandInfo(): string;
@@ -22,6 +22,8 @@ export declare class EventHandler {
22
22
  private _scope;
23
23
  private _task;
24
24
  private _taskMgdID;
25
+ private _defRouteName;
26
+ private _isExecutingDefaultRoute;
25
27
  constructor();
26
28
  getCtrlName(): string;
27
29
  fillData(taskRef: Task, parser: XmlParser): void;
@@ -34,6 +36,7 @@ export declare class EventHandler {
34
36
  isGlobalHandlerOf(rtEvt: RunTimeEvent): boolean;
35
37
  isGlobalSpecificHandlerOf(rtEvt: RunTimeEvent): boolean;
36
38
  execute(rtEvt: RunTimeEvent, returnedFromServer: boolean, enabledCndCheckedAndTrue: boolean): Promise<RetVals>;
39
+ isExecutingDefaultRoute(): boolean;
37
40
  private executeOperations;
38
41
  private getSignificantBlock;
39
42
  private getStartBlockIdxByEnd;
@@ -41,6 +44,8 @@ export declare class EventHandler {
41
44
  private getStartBlockIfIdxByOper;
42
45
  getLevel(): string;
43
46
  getEvent(): Event;
47
+ private isRouteHandler;
48
+ getDefaultRouteName(): string;
44
49
  getId(): number;
45
50
  isEnabled(): Promise<boolean>;
46
51
  private resetLocalVariables;
@@ -9,6 +9,9 @@ export declare class ExpressionEvaluator extends GuiExpressionEvaluator {
9
9
  static PARENT_LEN: number;
10
10
  static SHORT_OBJECT_LEN: number;
11
11
  static LONG_OBJECT_LEN: number;
12
+ private static MD5_ALGO_NUM;
13
+ private static SHA1_ALGO_NUM;
14
+ private static SHA2_ALGO_NUM;
12
15
  private static _recursiveExpCalcCount;
13
16
  private _charsToTrim;
14
17
  private _expressionLocalJpn;
@@ -170,6 +173,8 @@ export declare class ExpressionEvaluator extends GuiExpressionEvaluator {
170
173
  eval_op_delete_cookie(cookieName: string, resVal: ExpVal): void;
171
174
  eval_op_route_get(resVal: ExpVal): void;
172
175
  private params2arguments;
176
+ private eval_op_Hash;
177
+ private toWordArray;
173
178
  }
174
179
  export declare class NullValueException extends Exception {
175
180
  private _attr;
@@ -19,7 +19,8 @@ export declare class HttpManager {
19
19
  private RegisterBasicDelegates;
20
20
  GetHttpCommunicationTimeoutMS(): number;
21
21
  SetCommunicationsFailureHandler(handler: ICommunicationsFailureHandler): void;
22
- GetContent(requestedURL: string, requestContent: string | ArrayBuffer, requestContentType: string, useCache: boolean, isError: RefParam<boolean>): Promise<string | ArrayBuffer>;
22
+ GetContent(requestedURL: string, requestContent: string | ArrayBuffer, requestContentType: string, useCache: boolean, isError: RefParam<boolean>): Promise<ArrayBuffer>;
23
23
  private static CheckAndGetErrorResponse;
24
24
  private static LogAccessToServer;
25
+ private static GetRequestContentLength;
25
26
  }
@@ -7,8 +7,8 @@ export declare class HttpClientAsync extends HttpClientBase {
7
7
  constructor(httpClient: HttpClient);
8
8
  prepareRequest(): void;
9
9
  addHeaders(urlString: string, useCache: boolean, httpHeaders: HttpHeaders, clientID: string): HttpHeaders;
10
- sendRequestToServer(httpMethod: RequestMethod, urlString: string, httpHeaders: HttpHeaders, requestContent: string | ArrayBuffer, contentFromServer: RefParam<string>): Promise<any>;
11
- logResponse(httpResponse: HttpResponse<string | ArrayBuffer>, clientID: string, urlString: string, contentFromServer: RefParam<any>, timeBeforeRequest: number): void;
10
+ sendRequestToServer(httpMethod: RequestMethod, urlString: string, httpHeaders: HttpHeaders, requestContent: string | ArrayBuffer, contentFromServer: RefParam<ArrayBuffer>): Promise<any>;
11
+ logResponse(httpResponse: HttpResponse<ArrayBuffer>, clientID: string, urlString: string, contentFromServer: RefParam<any>, timeBeforeRequest: number): void;
12
12
  handleHttpErrorException(ex: any, urlString: string): void;
13
13
  shouldRetry(httpCommunicationTimeoutMS: number, urlString: string, communicationsFailureHandler: ICommunicationsFailureHandler, ex: any, startTimeRef: RefParam<number>): Promise<boolean>;
14
14
  logAndThrowException(ex: any): void;
@@ -15,14 +15,14 @@ export declare abstract class HttpClientBase {
15
15
  CommunicationsFailureHandler: ICommunicationsFailureHandler;
16
16
  constructor();
17
17
  private DecideOnRequestMethod;
18
- GetContent(requestURL: string, requestContent: any, requestContentType: string, useCache: boolean): Promise<string | ArrayBuffer>;
18
+ GetContent(requestURL: string, requestContent: any, requestContentType: string, useCache: boolean): Promise<ArrayBuffer>;
19
19
  private ExecuteHttpRequest;
20
20
  private LogRequestInfo;
21
21
  private static HeadersToString;
22
22
  abstract prepareRequest(): any;
23
23
  abstract addHeaders(urlString: string, useCache: boolean, httpHeaders: HttpHeaders, clientID: string): HttpHeaders;
24
- sendRequestToServer(httpMethod: RequestMethod, urlString: string, httpHeaders: HttpHeaders, requestContent: string, contentFromServer: RefParam<string>): Promise<any>;
25
- abstract logResponse(httpResponse: HttpResponse<string | ArrayBuffer>, clientID: string, urlString: string, contentFromServer: RefParam<any>, timeBeforeRequest: number): any;
24
+ sendRequestToServer(httpMethod: RequestMethod, urlString: string, httpHeaders: HttpHeaders, requestContent: string, contentFromServer: RefParam<ArrayBuffer>): Promise<any>;
25
+ abstract logResponse(httpResponse: HttpResponse<ArrayBuffer>, clientID: string, urlString: string, contentFromServer: RefParam<any>, timeBeforeRequest: number): any;
26
26
  abstract handleHttpErrorException(ex: any, urlString: string): any;
27
27
  shouldRetry(httpCommunicationTimeoutMS: number, urlString: string, communicationsFailureHandler: ICommunicationsFailureHandler, ex: any, startTimeRef: RefParam<number>): Promise<boolean>;
28
28
  abstract logAndThrowException(ex: any): any;
@@ -8,8 +8,8 @@ export declare class HttpClientSync extends HttpClientBase {
8
8
  constructor();
9
9
  prepareRequest(): void;
10
10
  addHeaders(urlString: string, useCache: boolean, httpHeaders: HttpHeaders, clientID: string): HttpHeaders;
11
- sendRequestToServer(httpMethod: RequestMethod, urlString: string, httpHeaders: HttpHeaders, requestContent: string, contentFromServer: RefParam<string>): Promise<any>;
12
- logResponse(httpResponse: HttpResponse<string | ArrayBuffer>, clientID: string, urlString: string, contentFromServer: RefParam<any>, timeBeforeRequest: number): void;
11
+ sendRequestToServer(httpMethod: RequestMethod, urlString: string, httpHeaders: HttpHeaders, requestContent: string, contentFromServer: RefParam<ArrayBuffer>): Promise<any>;
12
+ logResponse(httpResponse: HttpResponse<ArrayBuffer>, clientID: string, urlString: string, contentFromServer: RefParam<any>, timeBeforeRequest: number): void;
13
13
  handleHttpErrorException(ex: any, urlString: string): void;
14
14
  shouldRetry(httpCommunicationTimeoutMS: number, urlString: string, communicationsFailureHandler: ICommunicationsFailureHandler, ex: any, startTimeRef: RefParam<number>): Promise<boolean>;
15
15
  logAndThrowException(ex: any): void;
@@ -1,4 +1,4 @@
1
- import { Logger_LogLevels } from "@magic-xpa/utils";
1
+ import { Logger_LogLevels, XmlParser } from "@magic-xpa/utils";
2
2
  import { CommandsProcessorBase, CommandsProcessorBase_SendingInstruction, CommandsProcessorBase_SessionStage } from "../CommandsProcessorBase";
3
3
  import { IResultValue } from "../rt/IResultValue";
4
4
  import { OpeningTaskDetails } from "../tasks/TaskBase";
@@ -15,6 +15,7 @@ export declare class RemoteCommandsProcessor extends CommandsProcessorBase {
15
15
  SessionId: string;
16
16
  DelayCommandExecution: boolean;
17
17
  private _requestInfo;
18
+ serverFilesToClientFiles: Map<string, string>;
18
19
  static GetInstance(): RemoteCommandsProcessor;
19
20
  private constructor();
20
21
  CheckAndSetSessionCounter(newSessionCounter: number): void;
@@ -32,11 +33,15 @@ export declare class RemoteCommandsProcessor extends CommandsProcessorBase {
32
33
  private BuildXMLForMainProgramDataView;
33
34
  Execute_1(sendingInstruction: CommandsProcessorBase_SendingInstruction, sessionStage: CommandsProcessorBase_SessionStage, res: IResultValue): Promise<void>;
34
35
  private DispatchRequest;
36
+ DownloadFileFromServer(serverFileName: string): Promise<ArrayBuffer>;
37
+ fillCacheFilesMap(parser: XmlParser): void;
35
38
  clearLocalStorage(): void;
36
39
  private HandleErrorResponse;
37
40
  private ArrayBufferToString;
38
41
  private ExecuteRequest;
39
- GetContent(requestedURL: string, useCache: boolean, requestContent?: string, requestContentType?: string): Promise<string | ArrayBuffer>;
42
+ GetContentAsString(requestedURL: string, useCache: boolean, requestContent?: string, requestContentType?: string): Promise<string>;
43
+ GetContent(requestedURL: string, useCache: boolean, requestContent?: string, requestContentType?: string): Promise<ArrayBuffer>;
44
+ validateURL(url: string, sessionCounter: number, sessionId: string | null): string;
40
45
  UploadFileToServer(fileContent: any, serverFileName: string): Promise<any>;
41
46
  ClientActivated(): void;
42
47
  private BuildUrlSuffix;
@@ -3,6 +3,7 @@ import { ControlItemsRefreshCommand } from "../commands/ClientToServer/ControlIt
3
3
  import { ReturnResultBase } from "../util/ReturnResultBase";
4
4
  export declare class RemoteControlItemsRefreshCommand extends RemoteDataViewCommandBase {
5
5
  private control;
6
+ filterData: string;
6
7
  constructor(command: ControlItemsRefreshCommand);
7
8
  Execute(): Promise<ReturnResultBase>;
8
9
  }
@@ -42,6 +42,7 @@ export declare class Operation {
42
42
  private _undo;
43
43
  private _isRoute;
44
44
  private _routerPath;
45
+ private _subformExp;
45
46
  private _originalRouterOutletName;
46
47
  private _routeParams;
47
48
  constructor();
@@ -57,7 +58,7 @@ export declare class Operation {
57
58
  InitTaskDefinitionID(parser: XmlParser): void;
58
59
  private SetTaskDefinitionId;
59
60
  static InitField(valueStr: string, task: Task): Field;
60
- execute(returnedFromServer: boolean): Promise<boolean>;
61
+ execute(returnedFromServer: boolean, desiredRouteName?: string): Promise<boolean>;
61
62
  private operCallParallel;
62
63
  static callParallel(): void;
63
64
  private getCondVal;
@@ -88,6 +89,7 @@ export declare class Operation {
88
89
  setExecOnServer(val: boolean): void;
89
90
  getExecOnClient(): boolean;
90
91
  private canExecute;
92
+ private isOperationAllowedWhileExecutingDefaultRoute;
91
93
  AddFlowDescription(buffer: StringBuilder): Promise<void>;
92
94
  GetArgList(): ArgumentsList;
93
95
  GetReturnValueField(): Field;