New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@fluidframework/core-interfaces

Package Overview
Dependencies
Maintainers
2
Versions
467
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@fluidframework/core-interfaces - npm Package Compare versions

Comparing version 2.0.0-dev.7.4.0.216897 to 2.0.0-dev.7.4.0.217212

dist/config.d.ts

56

api-report/core-interfaces.api.md

@@ -8,2 +8,5 @@ ## API Report File for "@fluidframework/core-interfaces"

// @internal
export type ConfigTypes = string | number | boolean | number[] | string[] | boolean[] | undefined;
// @alpha
export type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;

@@ -23,3 +26,3 @@

// @internal
// @alpha
export type FluidObject<T = unknown> = {

@@ -32,6 +35,11 @@ [P in FluidObjectProviderKeys<T>]?: T[P];

// @internal
// @alpha
export type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;
// @internal
export interface IConfigProviderBase {
getRawConfig(name: string): ConfigTypes;
}
// @alpha
export interface IDisposable {

@@ -42,3 +50,3 @@ dispose(error?: Error): void;

// @internal
// @alpha
export interface IErrorBase extends Partial<Error> {

@@ -52,3 +60,3 @@ readonly errorType: string;

// @internal
// @alpha
export interface IErrorEvent extends IEvent {

@@ -59,3 +67,3 @@ // @eventProperty

// @internal
// @alpha
export interface IEvent {

@@ -66,3 +74,3 @@ // @eventProperty

// @internal
// @alpha
export interface IEventProvider<TEvent extends IEvent> {

@@ -74,3 +82,3 @@ readonly off: IEventTransformer<this, TEvent>;

// @internal
// @alpha
export type IEventThisPlaceHolder = {

@@ -80,3 +88,3 @@ thisPlaceHolder: "thisPlaceHolder";

// @internal
// @alpha
export type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {

@@ -309,6 +317,6 @@ (event: infer E0, listener: (...args: infer A0) => void): any;

// @internal @deprecated (undocumented)
// @alpha @deprecated (undocumented)
export const IFluidRouter: keyof IProvideFluidRouter;
// @internal @deprecated (undocumented)
// @alpha @deprecated (undocumented)
export interface IFluidRouter extends IProvideFluidRouter {

@@ -366,3 +374,3 @@ // (undocumented)

// @internal @deprecated
// @alpha @deprecated
export interface IProvideFluidRouter {

@@ -379,3 +387,3 @@ // (undocumented)

// @internal (undocumented)
// @alpha (undocumented)
export interface IRequest {

@@ -388,3 +396,3 @@ // (undocumented)

// @internal (undocumented)
// @alpha (undocumented)
export interface IRequestHeader {

@@ -395,3 +403,3 @@ // (undocumented)

// @internal (undocumented)
// @alpha (undocumented)
export interface IResponse {

@@ -426,3 +434,3 @@ // (undocumented)

// @internal
// @alpha
export interface ITelemetryBaseEvent extends ITelemetryBaseProperties {

@@ -435,3 +443,3 @@ // (undocumented)

// @internal
// @alpha
export interface ITelemetryBaseLogger {

@@ -444,3 +452,3 @@ // (undocumented)

// @internal
// @alpha
export type ITelemetryBaseProperties = ITelemetryProperties;

@@ -476,3 +484,3 @@

// @internal @deprecated
// @alpha @deprecated
export interface ITelemetryProperties {

@@ -495,3 +503,3 @@ // (undocumented)

// @internal
// @alpha
export const LogLevel: {

@@ -503,6 +511,6 @@ readonly verbose: 10;

// @internal
// @alpha
export type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];
// @internal
// @alpha
export type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {

@@ -512,3 +520,3 @@ [K in keyof L]: L[K] extends IEventThisPlaceHolder ? TThis : L[K];

// @internal
// @alpha
export interface Tagged<V, T extends string = string> {

@@ -527,6 +535,6 @@ // (undocumented)

// @internal @deprecated
// @alpha @deprecated
export type TelemetryEventPropertyType = string | number | boolean | undefined;
// @internal
// @alpha
export type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;

@@ -533,0 +541,0 @@

@@ -1,25 +0,385 @@

/* Excluded from this release type: ExtendEventProvider */
/* Excluded from this release type: ConfigTypes */
/**
* Allows an interface to extend interfaces that already extend an {@link IEventProvider}.
*
* @example
*
* ``` typescript
* interface AEvents extends IEvent{
* (event: "a-event",listener: (a: number)=>void);
* }
* interface A extends IEventProvider<AEvents>{
* a: object;
* }
*
* interface BEvents extends IEvent{
* (event: "b-event",listener: (b: string)=>void);
* }
* interface B extends ExtendEventProvider<AEvents, A, BEvents>{
* b: boolean;
* };
* ```
*
* interface B will now extend interface A and its events
* @alpha
*/
export declare type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;
/* Excluded from this release type: FluidErrorTypes */
/* Excluded from this release type: FluidObject */
/**
* This utility type take interface(s) that follow the FluidObject pattern, and produces
* a new type that can be used for inspection and discovery of those interfaces.
*
* It is meant to be used with types that are known to implement the FluidObject pattern.
* A common way to specify a type implements the FluidObject pattern is to expose it as a
* FluidObject without a generic argument.
*
* @example
*
* For example, if we have an interface like the following:
*
* ```typescript
* interface IProvideFoo{
* IFoo: IFoo
* }
* interface IFoo extends IProvideFoo{
* foobar();
* }
* ```
*
* and a function that returns a FluidObject. You would do the following
*
* `const maybeFoo: FluidObject<IFoo> = getFluidObject()`;
*
* Either IFoo or IProvideFoo are valid generic arguments. In both case
* maybeFoo will be of type `{IFoo?: IFoo}`. If IFoo is not undefined,
* then the FluidObject provides IFoo, and it can be used.
*
* You can inspect multiple types via a intersection. For example:
* `FluidObject<IFoo & IBar>`
* @alpha
*/
export declare type FluidObject<T = unknown> = {
[P in FluidObjectProviderKeys<T>]?: T[P];
};
/* Excluded from this release type: FluidObjectKeys */
/* Excluded from this release type: FluidObjectProviderKeys */
/**
* Produces a valid FluidObject key given a type and a property.
*
* @remarks
*
* A valid FluidObject key is a property that exists on the incoming type
* as well as on the type of the property itself. For example: `IProvideFoo.IFoo.IFoo`
* This aligns with the FluidObject pattern expected to be used with all FluidObjects.
*
* This utility type is meant for internal use by {@link FluidObject}
*
* @example
*
* ```typescript
* interface IProvideFoo{
* IFoo: IFoo
* }
* interface IFoo extends IProvideFoo{
* foobar();
* }
* ```
*
* This pattern enables discovery, and delegation in a standard way which is central
* to FluidObject pattern.
* @alpha
*/
export declare type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;
/* Excluded from this release type: IDisposable */
/* Excluded from this release type: IConfigProviderBase */
/* Excluded from this release type: IErrorBase */
/**
* Base interface for objects that require lifetime management via explicit disposal.
* @alpha
*/
export declare interface IDisposable {
/**
* Whether or not the object has been disposed.
* If true, the object should be considered invalid, and its other state should be disregarded.
*/
readonly disposed: boolean;
/**
* Dispose of the object and its resources.
* @param error - Optional error indicating the reason for the disposal, if the object was
* disposed as the result of an error.
*/
dispose(error?: Error): void;
}
/* Excluded from this release type: IErrorEvent */
/**
* Base interface for all errors and warnings emitted the container.
*
* @remarks
*
* We are in the process of unifying error types across layers of the Framework. For now we have only migrated
* those from container-definitions. Once fully migrated, this will be a base interface for all errors and
* warnings emitted by the Fluid Framework. Currently only the container layer is using IErrorBase.
* Runtime and others will follow soon.
*
* @alpha
*/
export declare interface IErrorBase extends Partial<Error> {
/**
* A type tag differentiating kinds of errors emitted by the container.
*
* @see See {@link FluidErrorTypes#genericError} for some common examples.
* - container
* - runtime
* - drivers
*/
readonly errorType: string;
/**
* See {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error | Error.message}
*
* @remarks
*
* Privacy Note - This is a freeform string that we may not control in all cases (e.g. a dependency throws an error)
* If there are known cases where this contains privacy-sensitive data it will be tagged and included in the result
* of getTelemetryProperties. When logging, consider fetching it that way rather than straight from this field.
*/
readonly message: string;
/**
* See {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/name | Error.name}
*/
readonly name?: string;
/**
* See {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/stack | Error.stack}
*/
readonly stack?: string;
/**
* Returns all properties of this error object that are fit for logging.
* Some may be tagged to indicate they contain some kind of sensitive data.
*/
getTelemetryProperties?(): ITelemetryBaseProperties;
}
/* Excluded from this release type: IEvent */
/**
* Base interface for error event emitters.
* @alpha
*/
export declare interface IErrorEvent extends IEvent {
/**
* Base error event emitter signature.
*
* @eventProperty
*/
(event: "error", listener: (message: any) => void): any;
}
/* Excluded from this release type: IEventProvider */
/**
* Base interface for event emitters.
* @alpha
*/
export declare interface IEvent {
/**
* Base event emitter signature.
*
* @remarks The event emitter polyfill and the node event emitter have different event types:
* `string | symbol` vs. `string | number`.
*
* So for our typing we'll contrain to string, that way we work with both.
*
* @eventProperty
*/
(event: string, listener: (...args: any[]) => void): any;
}
/* Excluded from this release type: IEventThisPlaceHolder */
/**
* Base interface for event providers.
* @alpha
*/
export declare interface IEventProvider<TEvent extends IEvent> {
/**
* Registers a callback to be invoked when the corresponding event is triggered.
*/
readonly on: IEventTransformer<this, TEvent>;
/**
* Registers a callback to be invoked the first time (after registration) the corresponding event is triggered.
*/
readonly once: IEventTransformer<this, TEvent>;
/**
* Removes the corresponding event if it has been registered.
*/
readonly off: IEventTransformer<this, TEvent>;
}
/* Excluded from this release type: IEventTransformer */
/**
* The placeholder type that should be used instead of `this` in events.
* @alpha
*/
export declare type IEventThisPlaceHolder = {
thisPlaceHolder: "thisPlaceHolder";
};
/**
* This type is a conditional type for transforming all the overloads provided in `TEvent`.
*
* @remarks
* Due to limitations of the TypeScript typing system, we need to handle each number of overload individually.
* It currently supports the max of 15 event overloads which is more than we use anywhere.
* At more than 15 overloads we start to hit {@link https://github.com/microsoft/TypeScript/issues/37209 | TS2589}.
* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @alpha
*/
export declare type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: infer E12, listener: (...args: infer A12) => void): any;
(event: infer E13, listener: (...args: infer A13) => void): any;
(event: infer E14, listener: (...args: infer A14) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> & TransformedEvent<TThis, E12, A12> & TransformedEvent<TThis, E13, A13> & TransformedEvent<TThis, E14, A14> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: infer E12, listener: (...args: infer A12) => void): any;
(event: infer E13, listener: (...args: infer A13) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> & TransformedEvent<TThis, E12, A12> & TransformedEvent<TThis, E13, A13> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: infer E12, listener: (...args: infer A12) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> & TransformedEvent<TThis, E12, A12> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> : TransformedEvent<TThis, string, any[]>;
/* Excluded from this release type: IFluidCodeDetails */

@@ -41,4 +401,16 @@

/* Excluded from this release type: IFluidRouter */
/**
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @alpha
*/
export declare const IFluidRouter: keyof IProvideFluidRouter;
/**
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @alpha
*/
export declare interface IFluidRouter extends IProvideFluidRouter {
request(request: IRequest): Promise<IResponse>;
}
/* Excluded from this release type: IFluidRunnable */

@@ -58,11 +430,40 @@

/* Excluded from this release type: IProvideFluidRouter */
/**
* Request routing
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @alpha
*/
export declare interface IProvideFluidRouter {
readonly IFluidRouter: IFluidRouter;
}
/* Excluded from this release type: IProvideFluidRunnable */
/* Excluded from this release type: IRequest */
/**
* @alpha
*/
export declare interface IRequest {
url: string;
headers?: IRequestHeader;
}
/* Excluded from this release type: IRequestHeader */
/**
* @alpha
*/
export declare interface IRequestHeader {
[index: string]: any;
}
/* Excluded from this release type: IResponse */
/**
* @alpha
*/
export declare interface IResponse {
mimeType: string;
status: number;
value: any;
headers?: {
[key: string]: any;
};
stack?: string;
}

@@ -75,7 +476,29 @@ /* Excluded from this release type: isFluidCodeDetails */

/* Excluded from this release type: ITelemetryBaseEvent */
/**
* Base interface for logging telemetry statements.
* Can contain any number of properties that get serialized as json payload.
* @param category - category of the event, like "error", "performance", "generic", etc.
* @param eventName - name of the event.
* @alpha
*/
export declare interface ITelemetryBaseEvent extends ITelemetryBaseProperties {
category: string;
eventName: string;
}
/* Excluded from this release type: ITelemetryBaseLogger */
/**
* Interface to output telemetry events.
* Implemented by hosting app / loader
* @alpha
*/
export declare interface ITelemetryBaseLogger {
send(event: ITelemetryBaseEvent, logLevel?: LogLevel): void;
minLogLevel?: LogLevel;
}
/* Excluded from this release type: ITelemetryBaseProperties */
/**
* JSON-serializable properties, which will be logged with telemetry.
* @alpha
*/
export declare type ITelemetryBaseProperties = ITelemetryProperties;

@@ -90,3 +513,11 @@ /* Excluded from this release type: ITelemetryErrorEvent */

/* Excluded from this release type: ITelemetryProperties */
/**
* {@inheritDoc ITelemetryBaseProperties}
*
* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @alpha
*/
export declare interface ITelemetryProperties {
[index: string]: TelemetryEventPropertyType | Tagged<TelemetryEventPropertyType>;
}

@@ -97,8 +528,39 @@ /* Excluded from this release type: IThrottlingWarning */

/* Excluded from this release type: LogLevel */
/**
* Specify levels of the logs.
* @alpha
*/
export declare const LogLevel: {
readonly verbose: 10;
readonly default: 20;
readonly error: 30;
};
/* Excluded from this release type: ReplaceIEventThisPlaceHolder */
/**
* Specify a level to the log to filter out logs based on the level.
* @alpha
*/
export declare type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];
/* Excluded from this release type: Tagged */
/**
* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @alpha
*/
export declare type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {
[K in keyof L]: L[K] extends IEventThisPlaceHolder ? TThis : L[K];
} : L;
/**
* A property to be logged to telemetry may require a tag indicating the value may contain sensitive data.
* This type wraps a value of the given type V in an object along with a string tag (type can be further specified as T).
*
* This indicates that the value should be organized or handled differently by loggers in various first or third
* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @alpha
*/
export declare interface Tagged<V, T extends string = string> {
value: V;
tag: T;
}
/* Excluded from this release type: TelemetryBaseEventPropertyType */

@@ -108,6 +570,17 @@

/* Excluded from this release type: TelemetryEventPropertyType */
/**
* {@inheritDoc TelemetryBaseEventPropertyType}
*
* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @alpha
*/
export declare type TelemetryEventPropertyType = string | number | boolean | undefined;
/* Excluded from this release type: TransformedEvent */
/**
* Transforms the event overload by replacing {@link IEventThisPlaceHolder} with `TThis` in the event listener
* arguments and having the overload return `TTHis` as well
* @alpha
*/
export declare type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;
export { }

@@ -0,1 +1,3 @@

/* Excluded from this release type: ConfigTypes */
/* Excluded from this release type: ExtendEventProvider */

@@ -11,2 +13,4 @@

/* Excluded from this release type: IConfigProviderBase */
/* Excluded from this release type: IDisposable */

@@ -13,0 +17,0 @@

@@ -0,1 +1,3 @@

/* Excluded from this release type: ConfigTypes */
/* Excluded from this release type: ExtendEventProvider */

@@ -11,2 +13,4 @@

/* Excluded from this release type: IConfigProviderBase */
/* Excluded from this release type: IDisposable */

@@ -13,0 +17,0 @@

/**
* Types supported by {@link IConfigProviderBase}.
* @internal
*/
export declare type ConfigTypes = string | number | boolean | number[] | string[] | boolean[] | undefined;
/**
* Allows an interface to extend interfaces that already extend an {@link IEventProvider}.

@@ -23,3 +29,3 @@ *

* interface B will now extend interface A and its events
* @internal
* @alpha
*/

@@ -91,3 +97,3 @@ export declare type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;

* `FluidObject<IFoo & IBar>`
* @internal
* @alpha
*/

@@ -133,3 +139,3 @@ export declare type FluidObject<T = unknown> = {

* to FluidObject pattern.
* @internal
* @alpha
*/

@@ -139,5 +145,31 @@ export declare type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;

/**
* Base interface for objects that require lifetime management via explicit disposal.
* Base interface for providing configurations to enable/disable/control features.
* @internal
*/
export declare interface IConfigProviderBase {
/**
* For the specified config name this function gets the value.
*
* This type is meant be easy to implement by Fluid Framework consumers
* so the returned valued needs minimal type coercion, and allows consumers to
* return values in a natural way from whatever source they retrieve them.
*
* For instance a value of 1 maybe be returned as a string or a number.
* For array types a json string or an object are allowable.
*
* It should return undefined if there is no value available for the config name.
*
* @param name - The name of the config to get the value for.
*
* @privateRemarks Generally, this type should only be taken as input, and be wrapped by an
* internal monitoring context from the fluidframework/telemetry-utils package. That will provide
* a wrapper with provides strongly typed access to values via consistent type coercion.
*/
getRawConfig(name: string): ConfigTypes;
}
/**
* Base interface for objects that require lifetime management via explicit disposal.
* @alpha
*/
export declare interface IDisposable {

@@ -166,3 +198,4 @@ /**

* Runtime and others will follow soon.
* @internal
*
* @alpha
*/

@@ -206,3 +239,3 @@ export declare interface IErrorBase extends Partial<Error> {

* Base interface for error event emitters.
* @internal
* @alpha
*/

@@ -220,3 +253,3 @@ export declare interface IErrorEvent extends IEvent {

* Base interface for event emitters.
* @internal
* @alpha
*/

@@ -239,3 +272,3 @@ export declare interface IEvent {

* Base interface for event providers.
* @internal
* @alpha
*/

@@ -259,3 +292,3 @@ export declare interface IEventProvider<TEvent extends IEvent> {

* The placeholder type that should be used instead of `this` in events.
* @internal
* @alpha
*/

@@ -274,3 +307,3 @@ export declare type IEventThisPlaceHolder = {

* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @internal
* @alpha
*/

@@ -643,3 +676,3 @@ export declare type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -650,3 +683,3 @@ export declare const IFluidRouter: keyof IProvideFluidRouter;

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -726,3 +759,3 @@ export declare interface IFluidRouter extends IProvideFluidRouter {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -741,3 +774,3 @@ export declare interface IProvideFluidRouter {

/**
* @internal
* @alpha
*/

@@ -750,3 +783,3 @@ export declare interface IRequest {

/**
* @internal
* @alpha
*/

@@ -758,3 +791,3 @@ export declare interface IRequestHeader {

/**
* @internal
* @alpha
*/

@@ -805,3 +838,3 @@ export declare interface IResponse {

* @param eventName - name of the event.
* @internal
* @alpha
*/

@@ -816,3 +849,3 @@ export declare interface ITelemetryBaseEvent extends ITelemetryBaseProperties {

* Implemented by hosting app / loader
* @internal
* @alpha
*/

@@ -826,3 +859,3 @@ export declare interface ITelemetryBaseLogger {

* JSON-serializable properties, which will be logged with telemetry.
* @internal
* @alpha
*/

@@ -911,3 +944,3 @@ export declare type ITelemetryBaseProperties = ITelemetryProperties;

* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @internal
* @alpha
*/

@@ -943,3 +976,3 @@ export declare interface ITelemetryProperties {

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -954,3 +987,3 @@ export declare const LogLevel: {

* Specify a level to the log to filter out logs based on the level.
* @internal
* @alpha
*/

@@ -961,3 +994,3 @@ export declare type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];

* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @internal
* @alpha
*/

@@ -974,3 +1007,3 @@ export declare type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {

* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @internal
* @alpha
*/

@@ -1004,3 +1037,3 @@ export declare interface Tagged<V, T extends string = string> {

* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @internal
* @alpha
*/

@@ -1012,3 +1045,3 @@ export declare type TelemetryEventPropertyType = string | number | boolean | undefined;

* arguments and having the overload return `TTHis` as well
* @internal
* @alpha
*/

@@ -1015,0 +1048,0 @@ export declare type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;

@@ -7,3 +7,3 @@ /*!

* Base interface for objects that require lifetime management via explicit disposal.
* @internal
* @alpha
*/

@@ -10,0 +10,0 @@ export interface IDisposable {

@@ -45,3 +45,4 @@ /*!

* Runtime and others will follow soon.
* @internal
*
* @alpha
*/

@@ -48,0 +49,0 @@ export interface IErrorBase extends Partial<Error> {

@@ -7,3 +7,3 @@ /*!

* Base interface for event emitters.
* @internal
* @alpha
*/

@@ -25,3 +25,3 @@ export interface IEvent {

* Base interface for error event emitters.
* @internal
* @alpha
*/

@@ -38,3 +38,3 @@ export interface IErrorEvent extends IEvent {

* Base interface for event providers.
* @internal
* @alpha
*/

@@ -77,3 +77,3 @@ export interface IEventProvider<TEvent extends IEvent> {

* interface B will now extend interface A and its events
* @internal
* @alpha
*/

@@ -83,3 +83,3 @@ export type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;

* The placeholder type that should be used instead of `this` in events.
* @internal
* @alpha
*/

@@ -91,3 +91,3 @@ export type IEventThisPlaceHolder = {

* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @internal
* @alpha
*/

@@ -100,3 +100,3 @@ export type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {

* arguments and having the overload return `TTHis` as well
* @internal
* @alpha
*/

@@ -112,3 +112,3 @@ export type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;

* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @internal
* @alpha
*/

@@ -115,0 +115,0 @@ export type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {

@@ -6,3 +6,3 @@ /*!

/**
* @internal
* @alpha
*/

@@ -13,3 +13,3 @@ export interface IRequestHeader {

/**
* @internal
* @alpha
*/

@@ -21,3 +21,3 @@ export interface IRequest {

/**
* @internal
* @alpha
*/

@@ -35,3 +35,3 @@ export interface IResponse {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -42,3 +42,3 @@ export declare const IFluidRouter: keyof IProvideFluidRouter;

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -50,3 +50,3 @@ export interface IProvideFluidRouter {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -53,0 +53,0 @@ export interface IFluidRouter extends IProvideFluidRouter {

@@ -10,5 +10,5 @@ "use strict";

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/
exports.IFluidRouter = "IFluidRouter";
//# sourceMappingURL=fluidRouter.js.map

@@ -22,2 +22,3 @@ /*!

export { FluidObjectProviderKeys, FluidObject, FluidObjectKeys } from "./provider";
export { ConfigTypes, IConfigProviderBase } from "./config";
//# sourceMappingURL=index.d.ts.map

@@ -25,3 +25,3 @@ /*!

* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @internal
* @alpha
*/

@@ -35,3 +35,3 @@ export type TelemetryEventPropertyType = string | number | boolean | undefined;

* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @internal
* @alpha
*/

@@ -54,3 +54,3 @@ export interface Tagged<V, T extends string = string> {

* JSON-serializable properties, which will be logged with telemetry.
* @internal
* @alpha
*/

@@ -62,3 +62,3 @@ export type ITelemetryBaseProperties = ITelemetryProperties;

* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @internal
* @alpha
*/

@@ -73,3 +73,3 @@ export interface ITelemetryProperties {

* @param eventName - name of the event.
* @internal
* @alpha
*/

@@ -82,3 +82,3 @@ export interface ITelemetryBaseEvent extends ITelemetryBaseProperties {

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -92,3 +92,3 @@ export declare const LogLevel: {

* Specify a level to the log to filter out logs based on the level.
* @internal
* @alpha
*/

@@ -99,3 +99,3 @@ export type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];

* Implemented by hosting app / loader
* @internal
* @alpha
*/

@@ -102,0 +102,0 @@ export interface ITelemetryBaseLogger {

@@ -10,3 +10,3 @@ "use strict";

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -13,0 +13,0 @@ exports.LogLevel = {

@@ -29,3 +29,3 @@ /*!

* to FluidObject pattern.
* @internal
* @alpha
*/

@@ -64,3 +64,3 @@ export type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;

* `FluidObject<IFoo & IBar>`
* @internal
* @alpha
*/

@@ -67,0 +67,0 @@ export type FluidObject<T = unknown> = {

@@ -1,25 +0,385 @@

/* Excluded from this release type: ExtendEventProvider */
/* Excluded from this release type: ConfigTypes */
/**
* Allows an interface to extend interfaces that already extend an {@link IEventProvider}.
*
* @example
*
* ``` typescript
* interface AEvents extends IEvent{
* (event: "a-event",listener: (a: number)=>void);
* }
* interface A extends IEventProvider<AEvents>{
* a: object;
* }
*
* interface BEvents extends IEvent{
* (event: "b-event",listener: (b: string)=>void);
* }
* interface B extends ExtendEventProvider<AEvents, A, BEvents>{
* b: boolean;
* };
* ```
*
* interface B will now extend interface A and its events
* @alpha
*/
export declare type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;
/* Excluded from this release type: FluidErrorTypes */
/* Excluded from this release type: FluidObject */
/**
* This utility type take interface(s) that follow the FluidObject pattern, and produces
* a new type that can be used for inspection and discovery of those interfaces.
*
* It is meant to be used with types that are known to implement the FluidObject pattern.
* A common way to specify a type implements the FluidObject pattern is to expose it as a
* FluidObject without a generic argument.
*
* @example
*
* For example, if we have an interface like the following:
*
* ```typescript
* interface IProvideFoo{
* IFoo: IFoo
* }
* interface IFoo extends IProvideFoo{
* foobar();
* }
* ```
*
* and a function that returns a FluidObject. You would do the following
*
* `const maybeFoo: FluidObject<IFoo> = getFluidObject()`;
*
* Either IFoo or IProvideFoo are valid generic arguments. In both case
* maybeFoo will be of type `{IFoo?: IFoo}`. If IFoo is not undefined,
* then the FluidObject provides IFoo, and it can be used.
*
* You can inspect multiple types via a intersection. For example:
* `FluidObject<IFoo & IBar>`
* @alpha
*/
export declare type FluidObject<T = unknown> = {
[P in FluidObjectProviderKeys<T>]?: T[P];
};
/* Excluded from this release type: FluidObjectKeys */
/* Excluded from this release type: FluidObjectProviderKeys */
/**
* Produces a valid FluidObject key given a type and a property.
*
* @remarks
*
* A valid FluidObject key is a property that exists on the incoming type
* as well as on the type of the property itself. For example: `IProvideFoo.IFoo.IFoo`
* This aligns with the FluidObject pattern expected to be used with all FluidObjects.
*
* This utility type is meant for internal use by {@link FluidObject}
*
* @example
*
* ```typescript
* interface IProvideFoo{
* IFoo: IFoo
* }
* interface IFoo extends IProvideFoo{
* foobar();
* }
* ```
*
* This pattern enables discovery, and delegation in a standard way which is central
* to FluidObject pattern.
* @alpha
*/
export declare type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;
/* Excluded from this release type: IDisposable */
/* Excluded from this release type: IConfigProviderBase */
/* Excluded from this release type: IErrorBase */
/**
* Base interface for objects that require lifetime management via explicit disposal.
* @alpha
*/
export declare interface IDisposable {
/**
* Whether or not the object has been disposed.
* If true, the object should be considered invalid, and its other state should be disregarded.
*/
readonly disposed: boolean;
/**
* Dispose of the object and its resources.
* @param error - Optional error indicating the reason for the disposal, if the object was
* disposed as the result of an error.
*/
dispose(error?: Error): void;
}
/* Excluded from this release type: IErrorEvent */
/**
* Base interface for all errors and warnings emitted the container.
*
* @remarks
*
* We are in the process of unifying error types across layers of the Framework. For now we have only migrated
* those from container-definitions. Once fully migrated, this will be a base interface for all errors and
* warnings emitted by the Fluid Framework. Currently only the container layer is using IErrorBase.
* Runtime and others will follow soon.
*
* @alpha
*/
export declare interface IErrorBase extends Partial<Error> {
/**
* A type tag differentiating kinds of errors emitted by the container.
*
* @see See {@link FluidErrorTypes#genericError} for some common examples.
* - container
* - runtime
* - drivers
*/
readonly errorType: string;
/**
* See {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error | Error.message}
*
* @remarks
*
* Privacy Note - This is a freeform string that we may not control in all cases (e.g. a dependency throws an error)
* If there are known cases where this contains privacy-sensitive data it will be tagged and included in the result
* of getTelemetryProperties. When logging, consider fetching it that way rather than straight from this field.
*/
readonly message: string;
/**
* See {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/name | Error.name}
*/
readonly name?: string;
/**
* See {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/stack | Error.stack}
*/
readonly stack?: string;
/**
* Returns all properties of this error object that are fit for logging.
* Some may be tagged to indicate they contain some kind of sensitive data.
*/
getTelemetryProperties?(): ITelemetryBaseProperties;
}
/* Excluded from this release type: IEvent */
/**
* Base interface for error event emitters.
* @alpha
*/
export declare interface IErrorEvent extends IEvent {
/**
* Base error event emitter signature.
*
* @eventProperty
*/
(event: "error", listener: (message: any) => void): any;
}
/* Excluded from this release type: IEventProvider */
/**
* Base interface for event emitters.
* @alpha
*/
export declare interface IEvent {
/**
* Base event emitter signature.
*
* @remarks The event emitter polyfill and the node event emitter have different event types:
* `string | symbol` vs. `string | number`.
*
* So for our typing we'll contrain to string, that way we work with both.
*
* @eventProperty
*/
(event: string, listener: (...args: any[]) => void): any;
}
/* Excluded from this release type: IEventThisPlaceHolder */
/**
* Base interface for event providers.
* @alpha
*/
export declare interface IEventProvider<TEvent extends IEvent> {
/**
* Registers a callback to be invoked when the corresponding event is triggered.
*/
readonly on: IEventTransformer<this, TEvent>;
/**
* Registers a callback to be invoked the first time (after registration) the corresponding event is triggered.
*/
readonly once: IEventTransformer<this, TEvent>;
/**
* Removes the corresponding event if it has been registered.
*/
readonly off: IEventTransformer<this, TEvent>;
}
/* Excluded from this release type: IEventTransformer */
/**
* The placeholder type that should be used instead of `this` in events.
* @alpha
*/
export declare type IEventThisPlaceHolder = {
thisPlaceHolder: "thisPlaceHolder";
};
/**
* This type is a conditional type for transforming all the overloads provided in `TEvent`.
*
* @remarks
* Due to limitations of the TypeScript typing system, we need to handle each number of overload individually.
* It currently supports the max of 15 event overloads which is more than we use anywhere.
* At more than 15 overloads we start to hit {@link https://github.com/microsoft/TypeScript/issues/37209 | TS2589}.
* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @alpha
*/
export declare type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: infer E12, listener: (...args: infer A12) => void): any;
(event: infer E13, listener: (...args: infer A13) => void): any;
(event: infer E14, listener: (...args: infer A14) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> & TransformedEvent<TThis, E12, A12> & TransformedEvent<TThis, E13, A13> & TransformedEvent<TThis, E14, A14> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: infer E12, listener: (...args: infer A12) => void): any;
(event: infer E13, listener: (...args: infer A13) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> & TransformedEvent<TThis, E12, A12> & TransformedEvent<TThis, E13, A13> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: infer E12, listener: (...args: infer A12) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> & TransformedEvent<TThis, E12, A12> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: infer E11, listener: (...args: infer A11) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> & TransformedEvent<TThis, E11, A11> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: infer E10, listener: (...args: infer A10) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> & TransformedEvent<TThis, E10, A10> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: infer E9, listener: (...args: infer A9) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> & TransformedEvent<TThis, E9, A9> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: infer E8, listener: (...args: infer A8) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> & TransformedEvent<TThis, E8, A8> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: infer E7, listener: (...args: infer A7) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> & TransformedEvent<TThis, E7, A7> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: infer E6, listener: (...args: infer A6) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> & TransformedEvent<TThis, E6, A6> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: infer E5, listener: (...args: infer A5) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> & TransformedEvent<TThis, E5, A5> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: infer E4, listener: (...args: infer A4) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> & TransformedEvent<TThis, E4, A4> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: infer E3, listener: (...args: infer A3) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> & TransformedEvent<TThis, E3, A3> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: infer E2, listener: (...args: infer A2) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> & TransformedEvent<TThis, E2, A2> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: infer E1, listener: (...args: infer A1) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> & TransformedEvent<TThis, E1, A1> : TEvent extends {
(event: infer E0, listener: (...args: infer A0) => void): any;
(event: string, listener: (...args: any[]) => void): any;
} ? TransformedEvent<TThis, E0, A0> : TransformedEvent<TThis, string, any[]>;
/* Excluded from this release type: IFluidCodeDetails */

@@ -41,4 +401,16 @@

/* Excluded from this release type: IFluidRouter */
/**
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @alpha
*/
export declare const IFluidRouter: keyof IProvideFluidRouter;
/**
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @alpha
*/
export declare interface IFluidRouter extends IProvideFluidRouter {
request(request: IRequest): Promise<IResponse>;
}
/* Excluded from this release type: IFluidRunnable */

@@ -58,11 +430,40 @@

/* Excluded from this release type: IProvideFluidRouter */
/**
* Request routing
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @alpha
*/
export declare interface IProvideFluidRouter {
readonly IFluidRouter: IFluidRouter;
}
/* Excluded from this release type: IProvideFluidRunnable */
/* Excluded from this release type: IRequest */
/**
* @alpha
*/
export declare interface IRequest {
url: string;
headers?: IRequestHeader;
}
/* Excluded from this release type: IRequestHeader */
/**
* @alpha
*/
export declare interface IRequestHeader {
[index: string]: any;
}
/* Excluded from this release type: IResponse */
/**
* @alpha
*/
export declare interface IResponse {
mimeType: string;
status: number;
value: any;
headers?: {
[key: string]: any;
};
stack?: string;
}

@@ -75,7 +476,29 @@ /* Excluded from this release type: isFluidCodeDetails */

/* Excluded from this release type: ITelemetryBaseEvent */
/**
* Base interface for logging telemetry statements.
* Can contain any number of properties that get serialized as json payload.
* @param category - category of the event, like "error", "performance", "generic", etc.
* @param eventName - name of the event.
* @alpha
*/
export declare interface ITelemetryBaseEvent extends ITelemetryBaseProperties {
category: string;
eventName: string;
}
/* Excluded from this release type: ITelemetryBaseLogger */
/**
* Interface to output telemetry events.
* Implemented by hosting app / loader
* @alpha
*/
export declare interface ITelemetryBaseLogger {
send(event: ITelemetryBaseEvent, logLevel?: LogLevel): void;
minLogLevel?: LogLevel;
}
/* Excluded from this release type: ITelemetryBaseProperties */
/**
* JSON-serializable properties, which will be logged with telemetry.
* @alpha
*/
export declare type ITelemetryBaseProperties = ITelemetryProperties;

@@ -90,3 +513,11 @@ /* Excluded from this release type: ITelemetryErrorEvent */

/* Excluded from this release type: ITelemetryProperties */
/**
* {@inheritDoc ITelemetryBaseProperties}
*
* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @alpha
*/
export declare interface ITelemetryProperties {
[index: string]: TelemetryEventPropertyType | Tagged<TelemetryEventPropertyType>;
}

@@ -97,8 +528,39 @@ /* Excluded from this release type: IThrottlingWarning */

/* Excluded from this release type: LogLevel */
/**
* Specify levels of the logs.
* @alpha
*/
export declare const LogLevel: {
readonly verbose: 10;
readonly default: 20;
readonly error: 30;
};
/* Excluded from this release type: ReplaceIEventThisPlaceHolder */
/**
* Specify a level to the log to filter out logs based on the level.
* @alpha
*/
export declare type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];
/* Excluded from this release type: Tagged */
/**
* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @alpha
*/
export declare type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {
[K in keyof L]: L[K] extends IEventThisPlaceHolder ? TThis : L[K];
} : L;
/**
* A property to be logged to telemetry may require a tag indicating the value may contain sensitive data.
* This type wraps a value of the given type V in an object along with a string tag (type can be further specified as T).
*
* This indicates that the value should be organized or handled differently by loggers in various first or third
* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @alpha
*/
export declare interface Tagged<V, T extends string = string> {
value: V;
tag: T;
}
/* Excluded from this release type: TelemetryBaseEventPropertyType */

@@ -108,6 +570,17 @@

/* Excluded from this release type: TelemetryEventPropertyType */
/**
* {@inheritDoc TelemetryBaseEventPropertyType}
*
* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @alpha
*/
export declare type TelemetryEventPropertyType = string | number | boolean | undefined;
/* Excluded from this release type: TransformedEvent */
/**
* Transforms the event overload by replacing {@link IEventThisPlaceHolder} with `TThis` in the event listener
* arguments and having the overload return `TTHis` as well
* @alpha
*/
export declare type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;
export { }

@@ -0,1 +1,3 @@

/* Excluded from this release type: ConfigTypes */
/* Excluded from this release type: ExtendEventProvider */

@@ -11,2 +13,4 @@

/* Excluded from this release type: IConfigProviderBase */
/* Excluded from this release type: IDisposable */

@@ -13,0 +17,0 @@

@@ -0,1 +1,3 @@

/* Excluded from this release type: ConfigTypes */
/* Excluded from this release type: ExtendEventProvider */

@@ -11,2 +13,4 @@

/* Excluded from this release type: IConfigProviderBase */
/* Excluded from this release type: IDisposable */

@@ -13,0 +17,0 @@

/**
* Types supported by {@link IConfigProviderBase}.
* @internal
*/
export declare type ConfigTypes = string | number | boolean | number[] | string[] | boolean[] | undefined;
/**
* Allows an interface to extend interfaces that already extend an {@link IEventProvider}.

@@ -23,3 +29,3 @@ *

* interface B will now extend interface A and its events
* @internal
* @alpha
*/

@@ -91,3 +97,3 @@ export declare type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;

* `FluidObject<IFoo & IBar>`
* @internal
* @alpha
*/

@@ -133,3 +139,3 @@ export declare type FluidObject<T = unknown> = {

* to FluidObject pattern.
* @internal
* @alpha
*/

@@ -139,5 +145,31 @@ export declare type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;

/**
* Base interface for objects that require lifetime management via explicit disposal.
* Base interface for providing configurations to enable/disable/control features.
* @internal
*/
export declare interface IConfigProviderBase {
/**
* For the specified config name this function gets the value.
*
* This type is meant be easy to implement by Fluid Framework consumers
* so the returned valued needs minimal type coercion, and allows consumers to
* return values in a natural way from whatever source they retrieve them.
*
* For instance a value of 1 maybe be returned as a string or a number.
* For array types a json string or an object are allowable.
*
* It should return undefined if there is no value available for the config name.
*
* @param name - The name of the config to get the value for.
*
* @privateRemarks Generally, this type should only be taken as input, and be wrapped by an
* internal monitoring context from the fluidframework/telemetry-utils package. That will provide
* a wrapper with provides strongly typed access to values via consistent type coercion.
*/
getRawConfig(name: string): ConfigTypes;
}
/**
* Base interface for objects that require lifetime management via explicit disposal.
* @alpha
*/
export declare interface IDisposable {

@@ -166,3 +198,4 @@ /**

* Runtime and others will follow soon.
* @internal
*
* @alpha
*/

@@ -206,3 +239,3 @@ export declare interface IErrorBase extends Partial<Error> {

* Base interface for error event emitters.
* @internal
* @alpha
*/

@@ -220,3 +253,3 @@ export declare interface IErrorEvent extends IEvent {

* Base interface for event emitters.
* @internal
* @alpha
*/

@@ -239,3 +272,3 @@ export declare interface IEvent {

* Base interface for event providers.
* @internal
* @alpha
*/

@@ -259,3 +292,3 @@ export declare interface IEventProvider<TEvent extends IEvent> {

* The placeholder type that should be used instead of `this` in events.
* @internal
* @alpha
*/

@@ -274,3 +307,3 @@ export declare type IEventThisPlaceHolder = {

* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @internal
* @alpha
*/

@@ -643,3 +676,3 @@ export declare type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -650,3 +683,3 @@ export declare const IFluidRouter: keyof IProvideFluidRouter;

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -726,3 +759,3 @@ export declare interface IFluidRouter extends IProvideFluidRouter {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -741,3 +774,3 @@ export declare interface IProvideFluidRouter {

/**
* @internal
* @alpha
*/

@@ -750,3 +783,3 @@ export declare interface IRequest {

/**
* @internal
* @alpha
*/

@@ -758,3 +791,3 @@ export declare interface IRequestHeader {

/**
* @internal
* @alpha
*/

@@ -805,3 +838,3 @@ export declare interface IResponse {

* @param eventName - name of the event.
* @internal
* @alpha
*/

@@ -816,3 +849,3 @@ export declare interface ITelemetryBaseEvent extends ITelemetryBaseProperties {

* Implemented by hosting app / loader
* @internal
* @alpha
*/

@@ -826,3 +859,3 @@ export declare interface ITelemetryBaseLogger {

* JSON-serializable properties, which will be logged with telemetry.
* @internal
* @alpha
*/

@@ -911,3 +944,3 @@ export declare type ITelemetryBaseProperties = ITelemetryProperties;

* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @internal
* @alpha
*/

@@ -943,3 +976,3 @@ export declare interface ITelemetryProperties {

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -954,3 +987,3 @@ export declare const LogLevel: {

* Specify a level to the log to filter out logs based on the level.
* @internal
* @alpha
*/

@@ -961,3 +994,3 @@ export declare type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];

* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @internal
* @alpha
*/

@@ -974,3 +1007,3 @@ export declare type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {

* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @internal
* @alpha
*/

@@ -1004,3 +1037,3 @@ export declare interface Tagged<V, T extends string = string> {

* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @internal
* @alpha
*/

@@ -1012,3 +1045,3 @@ export declare type TelemetryEventPropertyType = string | number | boolean | undefined;

* arguments and having the overload return `TTHis` as well
* @internal
* @alpha
*/

@@ -1015,0 +1048,0 @@ export declare type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;

@@ -7,3 +7,3 @@ /*!

* Base interface for objects that require lifetime management via explicit disposal.
* @internal
* @alpha
*/

@@ -10,0 +10,0 @@ export interface IDisposable {

@@ -45,3 +45,4 @@ /*!

* Runtime and others will follow soon.
* @internal
*
* @alpha
*/

@@ -48,0 +49,0 @@ export interface IErrorBase extends Partial<Error> {

@@ -7,3 +7,3 @@ /*!

* Base interface for event emitters.
* @internal
* @alpha
*/

@@ -25,3 +25,3 @@ export interface IEvent {

* Base interface for error event emitters.
* @internal
* @alpha
*/

@@ -38,3 +38,3 @@ export interface IErrorEvent extends IEvent {

* Base interface for event providers.
* @internal
* @alpha
*/

@@ -77,3 +77,3 @@ export interface IEventProvider<TEvent extends IEvent> {

* interface B will now extend interface A and its events
* @internal
* @alpha
*/

@@ -83,3 +83,3 @@ export type ExtendEventProvider<TBaseEvent extends IEvent, TBase extends IEventProvider<TBaseEvent>, TEvent extends TBaseEvent> = Omit<Omit<Omit<TBase, "on">, "once">, "off"> & IEventProvider<TBaseEvent> & IEventProvider<TEvent>;

* The placeholder type that should be used instead of `this` in events.
* @internal
* @alpha
*/

@@ -91,3 +91,3 @@ export type IEventThisPlaceHolder = {

* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @internal
* @alpha
*/

@@ -100,3 +100,3 @@ export type ReplaceIEventThisPlaceHolder<L extends any[], TThis> = L extends any[] ? {

* arguments and having the overload return `TTHis` as well
* @internal
* @alpha
*/

@@ -112,3 +112,3 @@ export type TransformedEvent<TThis, E, A extends any[]> = (event: E, listener: (...args: ReplaceIEventThisPlaceHolder<A, TThis>) => void) => TThis;

* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @internal
* @alpha
*/

@@ -115,0 +115,0 @@ export type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {

@@ -6,3 +6,3 @@ /*!

/**
* @internal
* @alpha
*/

@@ -13,3 +13,3 @@ export interface IRequestHeader {

/**
* @internal
* @alpha
*/

@@ -21,3 +21,3 @@ export interface IRequest {

/**
* @internal
* @alpha
*/

@@ -35,3 +35,3 @@ export interface IResponse {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -42,3 +42,3 @@ export declare const IFluidRouter: keyof IProvideFluidRouter;

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -50,3 +50,3 @@ export interface IProvideFluidRouter {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -53,0 +53,0 @@ export interface IFluidRouter extends IProvideFluidRouter {

@@ -7,5 +7,5 @@ /*!

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/
export const IFluidRouter = "IFluidRouter";
//# sourceMappingURL=fluidRouter.js.map

@@ -22,2 +22,3 @@ /*!

export { FluidObjectProviderKeys, FluidObject, FluidObjectKeys } from "./provider";
export { ConfigTypes, IConfigProviderBase } from "./config";
//# sourceMappingURL=index.d.ts.map

@@ -25,3 +25,3 @@ /*!

* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @internal
* @alpha
*/

@@ -35,3 +35,3 @@ export type TelemetryEventPropertyType = string | number | boolean | undefined;

* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @internal
* @alpha
*/

@@ -54,3 +54,3 @@ export interface Tagged<V, T extends string = string> {

* JSON-serializable properties, which will be logged with telemetry.
* @internal
* @alpha
*/

@@ -62,3 +62,3 @@ export type ITelemetryBaseProperties = ITelemetryProperties;

* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @internal
* @alpha
*/

@@ -73,3 +73,3 @@ export interface ITelemetryProperties {

* @param eventName - name of the event.
* @internal
* @alpha
*/

@@ -82,3 +82,3 @@ export interface ITelemetryBaseEvent extends ITelemetryBaseProperties {

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -92,3 +92,3 @@ export declare const LogLevel: {

* Specify a level to the log to filter out logs based on the level.
* @internal
* @alpha
*/

@@ -99,3 +99,3 @@ export type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];

* Implemented by hosting app / loader
* @internal
* @alpha
*/

@@ -102,0 +102,0 @@ export interface ITelemetryBaseLogger {

@@ -7,3 +7,3 @@ /*!

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -10,0 +10,0 @@ export const LogLevel = {

@@ -29,3 +29,3 @@ /*!

* to FluidObject pattern.
* @internal
* @alpha
*/

@@ -64,3 +64,3 @@ export type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp ? never : number extends TProp ? never : TProp extends keyof Required<T>[TProp] ? Required<T>[TProp] extends Required<Required<T>[TProp]>[TProp] ? TProp : never : never;

* `FluidObject<IFoo & IBar>`
* @internal
* @alpha
*/

@@ -67,0 +67,0 @@ export type FluidObject<T = unknown> = {

{
"name": "@fluidframework/core-interfaces",
"version": "2.0.0-dev.7.4.0.216897",
"version": "2.0.0-dev.7.4.0.217212",
"description": "Fluid object interfaces",

@@ -5,0 +5,0 @@ "homepage": "https://fluidframework.com",

@@ -8,3 +8,3 @@ /*!

* Base interface for objects that require lifetime management via explicit disposal.
* @internal
* @alpha
*/

@@ -11,0 +11,0 @@ export interface IDisposable {

@@ -52,3 +52,4 @@ /*!

* Runtime and others will follow soon.
* @internal
*
* @alpha
*/

@@ -55,0 +56,0 @@ export interface IErrorBase extends Partial<Error> {

@@ -8,3 +8,3 @@ /*!

* Base interface for event emitters.
* @internal
* @alpha
*/

@@ -28,3 +28,3 @@ export interface IEvent {

* Base interface for error event emitters.
* @internal
* @alpha
*/

@@ -43,3 +43,3 @@ export interface IErrorEvent extends IEvent {

* Base interface for event providers.
* @internal
* @alpha
*/

@@ -85,3 +85,3 @@ export interface IEventProvider<TEvent extends IEvent> {

* interface B will now extend interface A and its events
* @internal
* @alpha
*/

@@ -108,3 +108,3 @@ export type ExtendEventProvider<

* The placeholder type that should be used instead of `this` in events.
* @internal
* @alpha
*/

@@ -116,3 +116,3 @@ // eslint-disable-next-line @typescript-eslint/consistent-type-definitions

* Does the type replacement by changing types of {@link IEventThisPlaceHolder} to `TThis`
* @internal
* @alpha
*/

@@ -127,3 +127,3 @@ // eslint-disable-next-line @typescript-eslint/no-explicit-any

* arguments and having the overload return `TTHis` as well
* @internal
* @alpha
*/

@@ -144,3 +144,3 @@ // eslint-disable-next-line @typescript-eslint/no-explicit-any

* If we need to move beyond 15 we should evaluate using a mapped type pattern like `{"event":(listenerArgs)=>void}`
* @internal
* @alpha
*/

@@ -147,0 +147,0 @@ export type IEventTransformer<TThis, TEvent extends IEvent> = TEvent extends {

@@ -7,3 +7,3 @@ /*!

/**
* @internal
* @alpha
*/

@@ -17,3 +17,3 @@ export interface IRequestHeader {

/**
* @internal
* @alpha
*/

@@ -26,3 +26,3 @@ export interface IRequest {

/**
* @internal
* @alpha
*/

@@ -43,3 +43,3 @@ export interface IResponse {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -51,3 +51,3 @@ export const IFluidRouter: keyof IProvideFluidRouter = "IFluidRouter";

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -60,3 +60,3 @@ export interface IProvideFluidRouter {

* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
* @internal
* @alpha
*/

@@ -63,0 +63,0 @@ export interface IFluidRouter extends IProvideFluidRouter {

@@ -81,1 +81,2 @@ /*!

export { FluidObjectProviderKeys, FluidObject, FluidObjectKeys } from "./provider";
export { ConfigTypes, IConfigProviderBase } from "./config";

@@ -28,3 +28,3 @@ /*!

* @deprecated Renamed to {@link TelemetryBaseEventPropertyType}
* @internal
* @alpha
*/

@@ -39,3 +39,3 @@ export type TelemetryEventPropertyType = string | number | boolean | undefined;

* party scenarios. For example, tags are used to mark data that should not be stored in logs for privacy reasons.
* @internal
* @alpha
*/

@@ -60,3 +60,3 @@ export interface Tagged<V, T extends string = string> {

* JSON-serializable properties, which will be logged with telemetry.
* @internal
* @alpha
*/

@@ -69,3 +69,3 @@ export type ITelemetryBaseProperties = ITelemetryProperties;

* @deprecated Renamed to {@link ITelemetryBaseProperties}
* @internal
* @alpha
*/

@@ -81,3 +81,3 @@ export interface ITelemetryProperties {

* @param eventName - name of the event.
* @internal
* @alpha
*/

@@ -91,3 +91,3 @@ export interface ITelemetryBaseEvent extends ITelemetryBaseProperties {

* Specify levels of the logs.
* @internal
* @alpha
*/

@@ -102,3 +102,3 @@ export const LogLevel = {

* Specify a level to the log to filter out logs based on the level.
* @internal
* @alpha
*/

@@ -110,3 +110,3 @@ export type LogLevel = (typeof LogLevel)[keyof typeof LogLevel];

* Implemented by hosting app / loader
* @internal
* @alpha
*/

@@ -113,0 +113,0 @@ export interface ITelemetryBaseLogger {

@@ -30,3 +30,3 @@ /*!

* to FluidObject pattern.
* @internal
* @alpha
*/

@@ -74,3 +74,3 @@ export type FluidObjectProviderKeys<T, TProp extends keyof T = keyof T> = string extends TProp

* `FluidObject<IFoo & IBar>`
* @internal
* @alpha
*/

@@ -77,0 +77,0 @@ export type FluidObject<T = unknown> = {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc