npm package diff
Package: @forge/runtime
Versions: 6.0.0-next.0-experimental-97e4b11 - 6.0.0-next.1
File: package/out/sandbox/invocation-event.d.ts
Index: package/out/sandbox/invocation-event.d.ts
===================================================================
--- package/out/sandbox/invocation-event.d.ts
+++ package/out/sandbox/invocation-event.d.ts
@@ -1,63 +1,21 @@
/// <reference types="node" resolution-mode="require"/>
import { EventEmitter } from 'events';
-import { InvocationRequest } from './invocation-request';
-import { LogLevel } from '../logger';
+export declare enum LogLevel {
+ DEBUG = 20,
+ INFO = 30,
+ WARN = 40,
+ ERROR = 50,
+ FATAL = 60
+}
declare class InvocationEventEmitter extends EventEmitter {
}
export declare const StaticInvocationEventEmitter: InvocationEventEmitter;
export declare const EVENT_P3_LOG = "p3-log";
-export declare const EVENT_NETWORK_REQUEST_START = "network-request-start";
-export declare const EVENT_NETWORK_REQUEST_FINISH = "network-request-finish";
export declare type NonEmptyArray = [any, ...any[]];
-export declare function isNonEmptyArray(arr: any[]): arr is NonEmptyArray;
-export interface NetworkStartEventData {
- url: string;
- request: {
- body: ArrayBuffer | null;
- headers: {
- [k: string]: string[];
- };
- };
-}
-export interface NetworkFinishEventData {
- url: string;
- error?: string;
- response?: {
- body: ArrayBuffer;
- headers: {
- [k: string]: string[];
- };
- };
-}
-export interface NetworkRequestStartEvent {
- invocationId: string;
- hostname: string;
- request: {
- body: ArrayBuffer | null;
- headers: {
- [k: string]: string[];
- };
- };
-}
-export interface NetworkRequestFinishEvent {
- invocationId: string;
- hostname: string;
- error?: string;
- response?: {
- body: ArrayBuffer;
- headers: {
- [k: string]: string[];
- };
- };
-}
export interface P3LogEvent {
invocationId: string;
logLevel: number;
logArguments: NonEmptyArray;
}
-export declare function getHostname(url: string): string;
-export declare function invokeNetworkRequestStartEvent(invocation: InvocationRequest, networkEvent: NetworkStartEventData): void;
-export declare function invokeNetworkRequestFinishEvent(invocation: InvocationRequest, networkEvent: NetworkFinishEventData): void;
-export declare function p3LogEvent(invocation: InvocationRequest, logLevel: LogLevel, logArguments: NonEmptyArray): void;
export {};
//# sourceMappingURL=invocation-event.d.ts.map
\ No newline at end of file