http-request-manager 18.10.0 → 18.10.2
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.
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "http-request-manager",
|
|
3
|
-
"version": "18.10.
|
|
3
|
+
"version": "18.10.2",
|
|
4
4
|
"homepage": "https://wavecoders.ca",
|
|
5
5
|
"author": "Mike Bonifacio <wavecoders@gmail.com> (http://wavecoders@gmail.com/)",
|
|
6
6
|
"description": "This is an Angular Module containing Components/Services using Material",
|
|
@@ -12,7 +12,6 @@ import { TranslateService } from '@ngx-translate/core';
|
|
|
12
12
|
import * as _angular_forms from '@angular/forms';
|
|
13
13
|
import { FormArray, FormBuilder, FormControl } from '@angular/forms';
|
|
14
14
|
import { DataSource } from '@angular/cdk/collections';
|
|
15
|
-
import * as http_request_manager from 'http-request-manager';
|
|
16
15
|
import * as i4 from '@angular/common';
|
|
17
16
|
import * as i7 from '@angular/material/button';
|
|
18
17
|
import * as i20 from '@angular/material/tabs';
|
|
@@ -225,17 +224,6 @@ declare class ApiRequest implements ApiRequestInterface {
|
|
|
225
224
|
static adapt(item?: any): ApiRequest;
|
|
226
225
|
}
|
|
227
226
|
|
|
228
|
-
interface ChannelInfoInterface {
|
|
229
|
-
name: string;
|
|
230
|
-
canSubscribe: boolean;
|
|
231
|
-
}
|
|
232
|
-
declare class ChannelInfo implements ChannelInfoInterface {
|
|
233
|
-
name: string;
|
|
234
|
-
canSubscribe: boolean;
|
|
235
|
-
constructor(name?: string, canSubscribe?: boolean);
|
|
236
|
-
static adapt(item?: any): ChannelInfo;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
227
|
interface WSUserInterface {
|
|
240
228
|
id: string;
|
|
241
229
|
ldap?: string;
|
|
@@ -252,10 +240,96 @@ declare class WSUser implements WSUserInterface {
|
|
|
252
240
|
static adapt(item?: any): WSUser;
|
|
253
241
|
}
|
|
254
242
|
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
243
|
+
interface StateMessageInterface {
|
|
244
|
+
sessionId: {
|
|
245
|
+
id: string;
|
|
246
|
+
ldap?: string;
|
|
247
|
+
name?: string;
|
|
248
|
+
email?: string;
|
|
249
|
+
};
|
|
250
|
+
content: any;
|
|
251
|
+
}
|
|
252
|
+
declare class StateMessage implements StateMessageInterface {
|
|
253
|
+
sessionId: {
|
|
254
|
+
id: string;
|
|
255
|
+
ldap?: string;
|
|
256
|
+
name?: string;
|
|
257
|
+
email?: string;
|
|
258
|
+
};
|
|
259
|
+
content: any;
|
|
260
|
+
constructor(sessionId?: {
|
|
261
|
+
id: string;
|
|
262
|
+
ldap?: string;
|
|
263
|
+
name?: string;
|
|
264
|
+
email?: string;
|
|
265
|
+
}, content?: any);
|
|
266
|
+
static adapt(item?: any): StateMessage;
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
interface PublicMessageInterface {
|
|
270
|
+
sessionId: {
|
|
271
|
+
id: string;
|
|
272
|
+
ldap?: string;
|
|
273
|
+
name?: string;
|
|
274
|
+
email?: string;
|
|
275
|
+
};
|
|
276
|
+
content: {
|
|
277
|
+
message: string;
|
|
278
|
+
[key: string]: any;
|
|
279
|
+
};
|
|
280
|
+
}
|
|
281
|
+
declare class PublicMessage implements PublicMessageInterface {
|
|
282
|
+
sessionId: {
|
|
283
|
+
id: string;
|
|
284
|
+
ldap?: string;
|
|
285
|
+
name?: string;
|
|
286
|
+
email?: string;
|
|
287
|
+
};
|
|
288
|
+
content: {
|
|
289
|
+
message: string;
|
|
290
|
+
[key: string]: any;
|
|
291
|
+
};
|
|
292
|
+
constructor(sessionId?: {
|
|
293
|
+
id: string;
|
|
294
|
+
ldap?: string;
|
|
295
|
+
name?: string;
|
|
296
|
+
email?: string;
|
|
297
|
+
}, content?: {
|
|
298
|
+
message: string;
|
|
299
|
+
[key: string]: any;
|
|
300
|
+
});
|
|
301
|
+
static adapt(item?: any): PublicMessage;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
interface NotificationMessageInterface {
|
|
305
|
+
sessionId: {
|
|
306
|
+
id: string;
|
|
307
|
+
ldap?: string;
|
|
308
|
+
name?: string;
|
|
309
|
+
email?: string;
|
|
310
|
+
color?: string;
|
|
311
|
+
};
|
|
312
|
+
message: string;
|
|
313
|
+
[key: string]: any;
|
|
314
|
+
}
|
|
315
|
+
declare class NotificationMessage implements NotificationMessageInterface {
|
|
316
|
+
sessionId: {
|
|
317
|
+
id: string;
|
|
318
|
+
ldap?: string;
|
|
319
|
+
name?: string;
|
|
320
|
+
email?: string;
|
|
321
|
+
color?: string;
|
|
322
|
+
};
|
|
323
|
+
message: string;
|
|
324
|
+
[key: string]: any;
|
|
325
|
+
constructor(sessionId?: {
|
|
326
|
+
id: string;
|
|
327
|
+
ldap?: string;
|
|
328
|
+
name?: string;
|
|
329
|
+
email?: string;
|
|
330
|
+
color?: string;
|
|
331
|
+
}, message?: string, additionalProperties?: any);
|
|
332
|
+
static adapt(item?: any): NotificationMessage;
|
|
259
333
|
}
|
|
260
334
|
|
|
261
335
|
interface DatabaseStorageInterface {
|
|
@@ -366,6 +440,53 @@ declare class ChannelMessage implements ChannelMessageInterface {
|
|
|
366
440
|
static adapt(item?: any): ChannelMessage;
|
|
367
441
|
}
|
|
368
442
|
|
|
443
|
+
/**
|
|
444
|
+
* LoggerService for http-request-manager library
|
|
445
|
+
*
|
|
446
|
+
* Automatically enables debug logging in development mode,
|
|
447
|
+
* disables it in production mode.
|
|
448
|
+
*
|
|
449
|
+
* Usage:
|
|
450
|
+
* ```typescript
|
|
451
|
+
* constructor(private logger: LoggerService) {}
|
|
452
|
+
*
|
|
453
|
+
* this.logger.debug('WebSocket', 'Connected successfully');
|
|
454
|
+
* this.logger.info('HTTP', 'Request completed', { status: 200 });
|
|
455
|
+
* this.logger.warn('State', 'Cache miss for key', { key: 'user' });
|
|
456
|
+
* this.logger.error('Database', 'Connection failed', error);
|
|
457
|
+
* ```
|
|
458
|
+
*/
|
|
459
|
+
declare class LoggerService {
|
|
460
|
+
private debugMode;
|
|
461
|
+
constructor();
|
|
462
|
+
/**
|
|
463
|
+
* Debug level logging - only shown in development mode
|
|
464
|
+
* Use for: Detailed diagnostic information, state changes, connection events
|
|
465
|
+
*/
|
|
466
|
+
debug(context: string, message: string, data?: any): void;
|
|
467
|
+
/**
|
|
468
|
+
* Info level logging - only shown in development mode
|
|
469
|
+
* Use for: Important operational messages, successful operations
|
|
470
|
+
*/
|
|
471
|
+
info(context: string, message: string, data?: any): void;
|
|
472
|
+
/**
|
|
473
|
+
* Warning level logging - always shown
|
|
474
|
+
* Use for: Potential issues, deprecated usage, recoverable errors
|
|
475
|
+
*/
|
|
476
|
+
warn(context: string, message: string, data?: any): void;
|
|
477
|
+
/**
|
|
478
|
+
* Error level logging - always shown
|
|
479
|
+
* Use for: Actual errors, failures, exceptions
|
|
480
|
+
*/
|
|
481
|
+
error(context: string, message: string, data?: any): void;
|
|
482
|
+
/**
|
|
483
|
+
* Check if debug mode is enabled (development mode)
|
|
484
|
+
*/
|
|
485
|
+
isDebugEnabled(): boolean;
|
|
486
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LoggerService, never>;
|
|
487
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<LoggerService>;
|
|
488
|
+
}
|
|
489
|
+
|
|
369
490
|
/**
|
|
370
491
|
* Channel type enum for different communication purposes
|
|
371
492
|
* - STATE: Private channels for state synchronization (SYS- prefix)
|
|
@@ -397,6 +518,7 @@ declare class HTTPManagerStateService<T extends {
|
|
|
397
518
|
dbManagerService: DatabaseManagerService;
|
|
398
519
|
localStorageManagerService: LocalStorageManagerService;
|
|
399
520
|
utils: UtilsService;
|
|
521
|
+
logger: LoggerService;
|
|
400
522
|
error$: Observable<boolean>;
|
|
401
523
|
isPending$: Observable<boolean>;
|
|
402
524
|
private page;
|
|
@@ -587,6 +709,7 @@ declare class HTTPManagerStateService<T extends {
|
|
|
587
709
|
}
|
|
588
710
|
|
|
589
711
|
declare class WebsocketService {
|
|
712
|
+
private logger;
|
|
590
713
|
private socket;
|
|
591
714
|
private messages;
|
|
592
715
|
messages$: Observable<any>;
|
|
@@ -630,25 +753,12 @@ declare class WebsocketService {
|
|
|
630
753
|
* Get all notification channels (in-memory)
|
|
631
754
|
*/
|
|
632
755
|
getNotificationChannels(): void;
|
|
633
|
-
/**
|
|
634
|
-
* Get today's notification channels from database
|
|
635
|
-
* Returns unique channels that have notifications posted today
|
|
636
|
-
*/
|
|
637
756
|
getTodaysNotificationChannels(): void;
|
|
638
|
-
/**
|
|
639
|
-
* Subscribe to a notification channel with optional date filters
|
|
640
|
-
*/
|
|
641
757
|
subscribeToNotificationChannel(channel: string, options?: {
|
|
642
758
|
startEpoch?: number;
|
|
643
759
|
endEpoch?: number;
|
|
644
760
|
}, user?: any): void;
|
|
645
|
-
/**
|
|
646
|
-
* Unsubscribe from a notification channel
|
|
647
|
-
*/
|
|
648
761
|
unsubscribeFromNotificationChannel(channel: string): void;
|
|
649
|
-
/**
|
|
650
|
-
* Send a notification to a channel
|
|
651
|
-
*/
|
|
652
762
|
sendNotification(channel: string, content: any): void;
|
|
653
763
|
static ɵfac: i0.ɵɵFactoryDeclaration<WebsocketService, never>;
|
|
654
764
|
static ɵprov: i0.ɵɵInjectableDeclaration<WebsocketService>;
|
|
@@ -827,6 +937,62 @@ declare class WebSocketManagerService {
|
|
|
827
937
|
static ɵprov: i0.ɵɵInjectableDeclaration<WebSocketManagerService>;
|
|
828
938
|
}
|
|
829
939
|
|
|
940
|
+
/**
|
|
941
|
+
* WebSocketMessageService - Unified service for sending WebSocket messages
|
|
942
|
+
*
|
|
943
|
+
* Provides type-safe methods for sending messages with automatic prefix management.
|
|
944
|
+
* Supports three message types: State (SYS-), Public (PUB-), and Notification (MES-).
|
|
945
|
+
*
|
|
946
|
+
* Features:
|
|
947
|
+
* - Type-safe message models
|
|
948
|
+
* - Automatic prefix management
|
|
949
|
+
* - Runtime validation
|
|
950
|
+
* - Boolean return values for success/failure
|
|
951
|
+
* - Silent failure with console errors
|
|
952
|
+
*/
|
|
953
|
+
declare class WebSocketMessageService {
|
|
954
|
+
private wsManagerService;
|
|
955
|
+
private logger;
|
|
956
|
+
/**
|
|
957
|
+
* Send state message (SYS- prefix)
|
|
958
|
+
* Used for CRUD operations and state synchronization
|
|
959
|
+
*
|
|
960
|
+
* @param path - Path array (e.g., ['ai', 'tests'])
|
|
961
|
+
* @param payload - StateMessage with sessionId and content
|
|
962
|
+
* @returns true if sent successfully, false otherwise
|
|
963
|
+
*/
|
|
964
|
+
sendStateMessage(path: (string | number)[], payload: StateMessage): boolean;
|
|
965
|
+
/**
|
|
966
|
+
* Send public message (PUB- prefix)
|
|
967
|
+
* Used for chat, broadcast, general messaging
|
|
968
|
+
*
|
|
969
|
+
* @param channel - Channel name (without prefix)
|
|
970
|
+
* @param payload - PublicMessage with sessionId and content.message
|
|
971
|
+
* @returns true if sent successfully, false otherwise
|
|
972
|
+
*/
|
|
973
|
+
sendPublicMessage(channel: string, payload: PublicMessage): boolean;
|
|
974
|
+
/**
|
|
975
|
+
* Send notification (MES- prefix)
|
|
976
|
+
* Used for persistent notifications with history
|
|
977
|
+
*
|
|
978
|
+
* @param channel - Channel name (without prefix)
|
|
979
|
+
* @param payload - NotificationMessage with sessionId and message
|
|
980
|
+
* @returns true if sent successfully, false otherwise
|
|
981
|
+
*/
|
|
982
|
+
sendNotification(channel: string, payload: NotificationMessage): boolean;
|
|
983
|
+
/**
|
|
984
|
+
* Send to custom channel (no prefix)
|
|
985
|
+
* User provides full channel name
|
|
986
|
+
*
|
|
987
|
+
* @param channel - Full channel name
|
|
988
|
+
* @param payload - Any message payload
|
|
989
|
+
* @returns true if sent successfully, false otherwise
|
|
990
|
+
*/
|
|
991
|
+
sendToCustomChannel(channel: string, payload: any): boolean;
|
|
992
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WebSocketMessageService, never>;
|
|
993
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<WebSocketMessageService>;
|
|
994
|
+
}
|
|
995
|
+
|
|
830
996
|
declare class RequestService extends WebsocketService {
|
|
831
997
|
private http;
|
|
832
998
|
private pathQueryService;
|
|
@@ -2431,7 +2597,7 @@ declare class MessageServiceDemo {
|
|
|
2431
2597
|
communicationMessages$: rxjs.Observable<any[]>;
|
|
2432
2598
|
latestCommunicationMessages$: rxjs.Observable<any>;
|
|
2433
2599
|
connectionStatus$: rxjs.Observable<boolean>;
|
|
2434
|
-
user$: rxjs.Observable<
|
|
2600
|
+
user$: rxjs.Observable<WSUser | null>;
|
|
2435
2601
|
data$: rxjs.Observable<any>;
|
|
2436
2602
|
/**
|
|
2437
2603
|
* Helper to ensure channel has PUB- prefix
|
|
@@ -2631,7 +2797,8 @@ declare class WsDataControlComponent implements OnInit {
|
|
|
2631
2797
|
user: any;
|
|
2632
2798
|
path: (string | number)[];
|
|
2633
2799
|
stateDataRequestService: StateDataRequestService;
|
|
2634
|
-
|
|
2800
|
+
webSocketMessageService: WebSocketMessageService;
|
|
2801
|
+
user$: rxjs.Observable<WSUser | null>;
|
|
2635
2802
|
users$: rxjs.Observable<any[]>;
|
|
2636
2803
|
userAction$: rxjs.Observable<any>;
|
|
2637
2804
|
data$: rxjs.Observable<any>;
|
|
@@ -2641,10 +2808,156 @@ declare class WsDataControlComponent implements OnInit {
|
|
|
2641
2808
|
onAddData(): void;
|
|
2642
2809
|
onUpdateData(data: any[]): void;
|
|
2643
2810
|
onRemoveData(data: any): void;
|
|
2811
|
+
/**
|
|
2812
|
+
* Test direct state message via WebSocketMessageService
|
|
2813
|
+
* Sends an UPDATE message that should trigger fetchRecord() in the state manager
|
|
2814
|
+
*
|
|
2815
|
+
* @param recordId - The record ID to update (default: 63)
|
|
2816
|
+
* @param useFakeSessionId - If true, uses a fake sessionId to avoid filtering (default: true)
|
|
2817
|
+
* @param customSessionId - Optional custom sessionId (overrides useFakeSessionId if provided)
|
|
2818
|
+
*/
|
|
2819
|
+
onTestDirectStateMessage(recordId?: number, useFakeSessionId?: boolean, customSessionId?: string): void;
|
|
2644
2820
|
static ɵfac: i0.ɵɵFactoryDeclaration<WsDataControlComponent, never>;
|
|
2645
2821
|
static ɵcmp: i0.ɵɵComponentDeclaration<WsDataControlComponent, "app-ws-data-control", never, { "server": { "alias": "server"; "required": false; }; "wsServer": { "alias": "wsServer"; "required": false; }; "jwtToken": { "alias": "jwtToken"; "required": false; }; "user": { "alias": "user"; "required": false; }; "path": { "alias": "path"; "required": false; }; }, {}, never, never, false, never>;
|
|
2646
2822
|
}
|
|
2647
2823
|
|
|
2824
|
+
interface SlideInterface {
|
|
2825
|
+
title: string;
|
|
2826
|
+
message: string;
|
|
2827
|
+
image?: string;
|
|
2828
|
+
icon?: string;
|
|
2829
|
+
}
|
|
2830
|
+
declare class Slide implements SlideInterface {
|
|
2831
|
+
title: string;
|
|
2832
|
+
message: string;
|
|
2833
|
+
image?: string | undefined;
|
|
2834
|
+
icon?: string | undefined;
|
|
2835
|
+
constructor(title?: string, message?: string, image?: string | undefined, icon?: string | undefined);
|
|
2836
|
+
static adapt(item?: any): Slide;
|
|
2837
|
+
}
|
|
2838
|
+
|
|
2839
|
+
interface ActionInterface {
|
|
2840
|
+
label: string;
|
|
2841
|
+
action: 'close' | 'navigate' | 'callback' | 'custom';
|
|
2842
|
+
target?: string;
|
|
2843
|
+
callback?: string;
|
|
2844
|
+
primary?: boolean;
|
|
2845
|
+
}
|
|
2846
|
+
declare class Action implements ActionInterface {
|
|
2847
|
+
label: string;
|
|
2848
|
+
action: 'close' | 'navigate' | 'callback' | 'custom';
|
|
2849
|
+
target?: string | undefined;
|
|
2850
|
+
callback?: string | undefined;
|
|
2851
|
+
primary?: boolean | undefined;
|
|
2852
|
+
constructor(label?: string, action?: 'close' | 'navigate' | 'callback' | 'custom', target?: string | undefined, callback?: string | undefined, primary?: boolean | undefined);
|
|
2853
|
+
static adapt(item?: any): Action;
|
|
2854
|
+
}
|
|
2855
|
+
|
|
2856
|
+
type DisplayType = 'snackbar' | 'dialog' | 'carousel' | 'banner' | 'inline';
|
|
2857
|
+
interface DisplayConfigInterface {
|
|
2858
|
+
type: DisplayType;
|
|
2859
|
+
supportsMarkdown?: boolean;
|
|
2860
|
+
stackable?: boolean;
|
|
2861
|
+
queueBehavior?: 'replace' | 'queue' | 'ignore';
|
|
2862
|
+
autoDismiss?: number;
|
|
2863
|
+
width?: string;
|
|
2864
|
+
height?: string;
|
|
2865
|
+
}
|
|
2866
|
+
declare class DisplayConfig implements DisplayConfigInterface {
|
|
2867
|
+
type: DisplayType;
|
|
2868
|
+
supportsMarkdown?: boolean | undefined;
|
|
2869
|
+
stackable?: boolean | undefined;
|
|
2870
|
+
queueBehavior?: ("replace" | "queue" | "ignore") | undefined;
|
|
2871
|
+
autoDismiss?: number | undefined;
|
|
2872
|
+
width?: string | undefined;
|
|
2873
|
+
height?: string | undefined;
|
|
2874
|
+
constructor(type?: DisplayType, supportsMarkdown?: boolean | undefined, stackable?: boolean | undefined, queueBehavior?: ("replace" | "queue" | "ignore") | undefined, autoDismiss?: number | undefined, width?: string | undefined, height?: string | undefined);
|
|
2875
|
+
static adapt(item?: any): DisplayConfig;
|
|
2876
|
+
}
|
|
2877
|
+
|
|
2878
|
+
interface MessageContentInterface {
|
|
2879
|
+
displayConfig?: DisplayConfig;
|
|
2880
|
+
title?: string;
|
|
2881
|
+
message: string;
|
|
2882
|
+
slides?: Slide[];
|
|
2883
|
+
image?: string;
|
|
2884
|
+
images?: string[];
|
|
2885
|
+
actions?: Action[];
|
|
2886
|
+
messageType?: string;
|
|
2887
|
+
icon?: string;
|
|
2888
|
+
data?: any;
|
|
2889
|
+
}
|
|
2890
|
+
declare class MessageContent implements MessageContentInterface {
|
|
2891
|
+
displayConfig?: DisplayConfig | undefined;
|
|
2892
|
+
title?: string | undefined;
|
|
2893
|
+
message: string;
|
|
2894
|
+
slides?: Slide[] | undefined;
|
|
2895
|
+
image?: string | undefined;
|
|
2896
|
+
images?: string[] | undefined;
|
|
2897
|
+
actions?: Action[] | undefined;
|
|
2898
|
+
messageType?: string | undefined;
|
|
2899
|
+
icon?: string | undefined;
|
|
2900
|
+
data?: any;
|
|
2901
|
+
constructor(displayConfig?: DisplayConfig | undefined, title?: string | undefined, message?: string, slides?: Slide[] | undefined, image?: string | undefined, images?: string[] | undefined, actions?: Action[] | undefined, messageType?: string | undefined, icon?: string | undefined, data?: any);
|
|
2902
|
+
static adapt(item?: any): MessageContent;
|
|
2903
|
+
}
|
|
2904
|
+
interface CommunicationMessageInterface {
|
|
2905
|
+
type: string;
|
|
2906
|
+
messageId?: number;
|
|
2907
|
+
channel?: string;
|
|
2908
|
+
sessionId?: {
|
|
2909
|
+
id: string;
|
|
2910
|
+
};
|
|
2911
|
+
timestamp?: string;
|
|
2912
|
+
content: MessageContent;
|
|
2913
|
+
}
|
|
2914
|
+
declare class CommunicationMessage implements CommunicationMessageInterface {
|
|
2915
|
+
type: string;
|
|
2916
|
+
messageId?: number | undefined;
|
|
2917
|
+
channel?: string | undefined;
|
|
2918
|
+
sessionId?: {
|
|
2919
|
+
id: string;
|
|
2920
|
+
} | undefined;
|
|
2921
|
+
timestamp?: string | undefined;
|
|
2922
|
+
content: MessageContent;
|
|
2923
|
+
constructor(type?: string, messageId?: number | undefined, channel?: string | undefined, sessionId?: {
|
|
2924
|
+
id: string;
|
|
2925
|
+
} | undefined, timestamp?: string | undefined, content?: MessageContent);
|
|
2926
|
+
static adapt(item?: any): CommunicationMessage;
|
|
2927
|
+
}
|
|
2928
|
+
|
|
2929
|
+
interface IDisplayStrategy {
|
|
2930
|
+
name: string;
|
|
2931
|
+
canHandle(message: CommunicationMessage): boolean;
|
|
2932
|
+
display(message: CommunicationMessage, config: DisplayConfig): void;
|
|
2933
|
+
}
|
|
2934
|
+
|
|
2935
|
+
interface DisplayRuleInterface {
|
|
2936
|
+
id: string;
|
|
2937
|
+
name?: string;
|
|
2938
|
+
match: (message: CommunicationMessage) => boolean;
|
|
2939
|
+
display: DisplayConfig;
|
|
2940
|
+
}
|
|
2941
|
+
declare class DisplayRule implements DisplayRuleInterface {
|
|
2942
|
+
id: string;
|
|
2943
|
+
name?: string | undefined;
|
|
2944
|
+
match: (message: CommunicationMessage) => boolean;
|
|
2945
|
+
display: DisplayConfig;
|
|
2946
|
+
constructor(id?: string, name?: string | undefined, match?: (message: CommunicationMessage) => boolean, display?: DisplayConfig);
|
|
2947
|
+
static adapt(item?: any): DisplayRule;
|
|
2948
|
+
}
|
|
2949
|
+
|
|
2950
|
+
declare class MessageDisplayRouterService {
|
|
2951
|
+
private snackbarStrategy;
|
|
2952
|
+
private strategies;
|
|
2953
|
+
private rules;
|
|
2954
|
+
display(message: CommunicationMessage): void;
|
|
2955
|
+
registerStrategies(strategies: IDisplayStrategy[]): void;
|
|
2956
|
+
setRules(rules: DisplayRule[]): void;
|
|
2957
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageDisplayRouterService, never>;
|
|
2958
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<MessageDisplayRouterService>;
|
|
2959
|
+
}
|
|
2960
|
+
|
|
2648
2961
|
declare class WsMessagingComponent implements OnInit, OnDestroy {
|
|
2649
2962
|
server: string;
|
|
2650
2963
|
wsServer: string;
|
|
@@ -2655,7 +2968,7 @@ declare class WsMessagingComponent implements OnInit, OnDestroy {
|
|
|
2655
2968
|
fb: FormBuilder;
|
|
2656
2969
|
messageService: MessageServiceDemo;
|
|
2657
2970
|
stateService: StateServiceDemo;
|
|
2658
|
-
|
|
2971
|
+
messageDisplayService: MessageDisplayRouterService;
|
|
2659
2972
|
channels$: Observable<string[]>;
|
|
2660
2973
|
subscribedChannels$: Observable<string[]>;
|
|
2661
2974
|
user$: Observable<WSUser | null>;
|
|
@@ -2887,5 +3200,5 @@ declare class HttpRequestManagerModule {
|
|
|
2887
3200
|
static ɵinj: i0.ɵɵInjectorDeclaration<HttpRequestManagerModule>;
|
|
2888
3201
|
}
|
|
2889
3202
|
|
|
2890
|
-
export { ApiRequest, AppService, AsymmetricalEncryptionService, CONFIG_SETTINGS_TOKEN,
|
|
2891
|
-
export type { APIStateManagerData, ApiRequestInterface,
|
|
3203
|
+
export { ApiRequest, AppService, AsymmetricalEncryptionService, CONFIG_SETTINGS_TOKEN, ChannelType, ConfigHTTPOptions, ConfigOptions, DataType, DatabaseDataDemoComponent, DatabaseManagerService, DatabaseStorage, DbService, ErrorDisplaySettings, GlobalStoreOptions, HTTPManagerService, HTTPManagerSignalsService, HTTPManagerStateService, HeadersService, HttpRequestManagerModule, HttpRequestServicesDemoComponent, LocalStorageDemoComponent, LocalStorageManagerService, LocalStorageOptions, LocalStorageSignalsManagerService, LoggerService, NotificationMessage, PathQueryService, PublicMessage, Random, RandomHSLColor, RandomHexColor, RandomNumber, RandomNumbers, RandomNumbersUnique, RandomPaletteColor, RandomSignature, RandomStr, RandomVisibleColor, RequestErrorInterceptor, RequestHeadersInterceptor, RequestManagerDemoComponent, RequestManagerStateDemoComponent, RequestOptions, RequestService, RequestSignalsService, RetryOptions, SettingOptions, StateMessage, StateStorageOptions, StorageData, StorageOption, StorageType, StoreStateManagerService, StreamType, SymmetricalEncryptionService, TableSchemaDef, UUID, UUID_STR, UserData, UtilsService, WSOptions, WebSocketMessageService, WithCredentialsInterceptor, countdown, createChannelName, delayedRetry, requestPolling, requestStreaming, streamAI, streamAuto, streamEvents, streamJSON, streamNDJSON };
|
|
3204
|
+
export type { APIStateManagerData, ApiRequestInterface, ConfigHTTPOptionsInterface, ConfigOptionsInterface, DatabaseStorageInterface, ErrorDisplaySettingsInterface, GlobalStoreOptionsInterface, LocalStorageOptionsInterface, NotificationMessageInterface, ParsingResult, PublicMessageInterface, RequestOptionsInterface, RetryOptionsInterface, SettingOptionsInterface, State, StateMessageInterface, StateStorageOptionsInterface, StateStoreManagerData, StorageDataInterface, StorageOptionInterface, StreamConfig, StreamEvent, TableRecord, TableSchemaDefInterface, UserDataInterface, WSOptionsInterface };
|
|
Binary file
|