@fluidframework/container-definitions 2.53.0 → 2.60.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/api-report/{container-definitions.legacy.alpha.api.md → container-definitions.legacy.beta.api.md} +44 -44
  3. package/dist/audience.d.ts +1 -2
  4. package/dist/audience.d.ts.map +1 -1
  5. package/dist/audience.js.map +1 -1
  6. package/dist/browserPackage.d.ts +3 -6
  7. package/dist/browserPackage.d.ts.map +1 -1
  8. package/dist/browserPackage.js +1 -2
  9. package/dist/browserPackage.js.map +1 -1
  10. package/dist/deltas.d.ts +7 -14
  11. package/dist/deltas.d.ts.map +1 -1
  12. package/dist/deltas.js.map +1 -1
  13. package/dist/error.d.ts +3 -6
  14. package/dist/error.d.ts.map +1 -1
  15. package/dist/error.js +1 -2
  16. package/dist/error.js.map +1 -1
  17. package/dist/fluidModule.d.ts +1 -2
  18. package/dist/fluidModule.d.ts.map +1 -1
  19. package/dist/fluidModule.js.map +1 -1
  20. package/dist/fluidPackage.d.ts +8 -16
  21. package/dist/fluidPackage.d.ts.map +1 -1
  22. package/dist/fluidPackage.js +2 -4
  23. package/dist/fluidPackage.js.map +1 -1
  24. package/dist/loader.d.ts +12 -24
  25. package/dist/loader.d.ts.map +1 -1
  26. package/dist/loader.js +1 -2
  27. package/dist/loader.js.map +1 -1
  28. package/dist/runtime.d.ts +8 -16
  29. package/dist/runtime.d.ts.map +1 -1
  30. package/dist/runtime.js +1 -2
  31. package/dist/runtime.js.map +1 -1
  32. package/lib/audience.d.ts +1 -2
  33. package/lib/audience.d.ts.map +1 -1
  34. package/lib/audience.js.map +1 -1
  35. package/lib/browserPackage.d.ts +3 -6
  36. package/lib/browserPackage.d.ts.map +1 -1
  37. package/lib/browserPackage.js +1 -2
  38. package/lib/browserPackage.js.map +1 -1
  39. package/lib/deltas.d.ts +7 -14
  40. package/lib/deltas.d.ts.map +1 -1
  41. package/lib/deltas.js.map +1 -1
  42. package/lib/error.d.ts +3 -6
  43. package/lib/error.d.ts.map +1 -1
  44. package/lib/error.js +1 -2
  45. package/lib/error.js.map +1 -1
  46. package/lib/fluidModule.d.ts +1 -2
  47. package/lib/fluidModule.d.ts.map +1 -1
  48. package/lib/fluidModule.js.map +1 -1
  49. package/lib/fluidPackage.d.ts +8 -16
  50. package/lib/fluidPackage.d.ts.map +1 -1
  51. package/lib/fluidPackage.js +2 -4
  52. package/lib/fluidPackage.js.map +1 -1
  53. package/lib/loader.d.ts +12 -24
  54. package/lib/loader.d.ts.map +1 -1
  55. package/lib/loader.js +1 -2
  56. package/lib/loader.js.map +1 -1
  57. package/lib/runtime.d.ts +8 -16
  58. package/lib/runtime.d.ts.map +1 -1
  59. package/lib/runtime.js +1 -2
  60. package/lib/runtime.js.map +1 -1
  61. package/package.json +5 -5
  62. package/src/audience.ts +1 -2
  63. package/src/browserPackage.ts +3 -6
  64. package/src/deltas.ts +7 -14
  65. package/src/error.ts +3 -6
  66. package/src/fluidModule.ts +1 -2
  67. package/src/fluidPackage.ts +8 -16
  68. package/src/loader.ts +12 -24
  69. package/src/runtime.ts +8 -16
@@ -1 +1 @@
1
- {"version":3,"file":"runtime.js","sourceRoot":"","sources":["../src/runtime.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAiCH;;;;GAIG;AACH,IAAY,WAiBX;AAjBD,WAAY,WAAW;IACtB;;;OAGG;IACH,oCAAqB,CAAA;IAErB;;OAEG;IACH,sCAAuB,CAAA;IAEvB;;;OAGG;IACH,oCAAqB,CAAA;AACtB,CAAC,EAjBW,WAAW,2BAAX,WAAW,QAiBtB;AA4SD;;;GAGG;AACU,QAAA,eAAe,GAAiC,iBAAiB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tFluidObject,\n\tIDisposable,\n\tITelemetryBaseLogger,\n} from \"@fluidframework/core-interfaces\";\nimport type {\n\tIClientDetails,\n\tIQuorumClients,\n\tISummaryTree,\n} from \"@fluidframework/driver-definitions\";\nimport type {\n\tISnapshot,\n\tIDocumentMessage,\n\tISnapshotTree,\n\tISummaryContent,\n\tIVersion,\n\tMessageType,\n\tISequencedDocumentMessage,\n\tICreateBlobResponse,\n\tISummaryContext,\n\tISnapshotFetchOptions,\n\tFetchSource,\n\tIDocumentStorageServicePolicies,\n\tISummaryHandle,\n} from \"@fluidframework/driver-definitions/internal\";\n\nimport type { IAudience } from \"./audience.js\";\nimport type { IDeltaManager } from \"./deltas.js\";\nimport type { ICriticalContainerError } from \"./error.js\";\nimport type { ConnectionState, ILoader } from \"./loader.js\";\n\n/**\n * The attachment state of some Fluid data (e.g. a container or data store), denoting whether it is uploaded to the\n * service. The transition from detached to attached state is a one-way transition.\n * @public\n */\nexport enum AttachState {\n\t/**\n\t * In detached state, the data is only present on the local client's machine. It has not yet been uploaded\n\t * to the service.\n\t */\n\tDetached = \"Detached\",\n\n\t/**\n\t * In attaching state, the data has started the upload to the service, but has not yet completed.\n\t */\n\tAttaching = \"Attaching\",\n\n\t/**\n\t * In attached state, the data has completed upload to the service. It can be accessed by other clients after\n\t * reaching attached state.\n\t */\n\tAttached = \"Attached\",\n}\n\n/**\n * The IRuntime represents an instantiation of a code package within a Container.\n * Primarily held by the ContainerContext to be able to interact with the running instance of the Container.\n *\n * @legacy\n * @alpha\n */\nexport interface IRuntime extends IDisposable {\n\t/**\n\t * Notifies the runtime of a change in the connection state\n\t * @param canSendOps - true if the runtime is allowed to send ops\n\t * @param clientId - the ID of the client that is connecting or disconnecting\n\t */\n\tsetConnectionState(canSendOps: boolean, clientId?: string);\n\n\t/**\n\t * Processes the given op (message)\n\t * @param message - delta message received from the server\n\t * @param local - true if the message was originally generated by the client receiving it.\n\t */\n\tprocess(message: ISequencedDocumentMessage, local: boolean);\n\n\t/**\n\t * Processes the given signal\n\t */\n\t// TODO: use `unknown` instead (API breaking)\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\tprocessSignal(message: any, local: boolean);\n\n\t/**\n\t * Create a summary. Used when attaching or serializing a detached container.\n\t *\n\t * @param blobRedirectTable - A table passed during the attach process. While detached, blob upload is supported\n\t * using IDs generated locally. After attach, these IDs cannot be used, so this table maps the old local IDs to the\n\t * new storage IDs so requests can be redirected.\n\t */\n\tcreateSummary(blobRedirectTable?: Map<string, string>): ISummaryTree;\n\n\t/**\n\t * Propagate the container state when container is attaching or attached.\n\t * @param attachState - State of the container.\n\t */\n\tsetAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;\n\n\t/**\n\t * Get pending local state in a serializable format to be given back to a newly loaded container\n\t */\n\tgetPendingLocalState(props?: IGetPendingLocalStateProps): unknown;\n\n\t/**\n\t * Notify runtime that we have processed a saved message, so that it can do async work (applying\n\t * stashed ops) after having processed it.\n\t */\n\tnotifyOpReplay?(message: ISequencedDocumentMessage): Promise<void>;\n\n\t/**\n\t * Exposes the entryPoint for the container runtime.\n\t * Use this as the primary way of getting access to the user-defined logic within the container runtime.\n\t *\n\t * @see {@link IContainer.getEntryPoint}\n\t */\n\tgetEntryPoint(): Promise<FluidObject>;\n}\n\n/**\n * Payload type for IContainerContext.submitBatchFn()\n * @legacy\n * @alpha\n */\nexport interface IBatchMessage {\n\tcontents?: string;\n\tmetadata?: Record<string, unknown>;\n\tcompression?: string;\n\treferenceSequenceNumber?: number;\n}\n\n/**\n * Interface to provide access to snapshots and policies to the Runtime layer. This should follow the Loader / Runtime\n * layer compatibility rules.\n *\n * @remarks It contains a subset of APIs from {@link @fluidframework/driver-definitions#IDocumentStorageService} but\n * allows the Runtime to not support layer compatibility with the Driver layer. Instead, it supports compatibility\n * with the Loader layer which it already does.\n *\n * @legacy\n * @alpha\n */\nexport interface IContainerStorageService {\n\t/**\n\t * Whether or not the object has been disposed.\n\t * If true, the object should be considered invalid, and its other state should be disregarded.\n\t *\n\t * @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as\n\t * it is unused in the Runtime layer.\n\t */\n\treadonly disposed?: boolean;\n\n\t/**\n\t * Dispose of the object and its resources.\n\t * @param error - Optional error indicating the reason for the disposal, if the object was\n\t * disposed as the result of an error.\n\t *\n\t * @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as\n\t * it is unused in the Runtime layer.\n\t */\n\tdispose?(error?: Error): void;\n\n\t/**\n\t * Policies implemented/instructed by driver.\n\t *\n\t * @deprecated - This will be removed in a future release. The Runtime layer only needs `maximumCacheDurationMs`\n\t * policy which is added as a separate property.\n\t */\n\treadonly policies?: IDocumentStorageServicePolicies | undefined;\n\n\t/**\n\t * See {@link @fluidframework/driver-definitions#IDocumentStorageServicePolicies.maximumCacheDurationMs}\n\t */\n\treadonly maximumCacheDurationMs?: IDocumentStorageServicePolicies[\"maximumCacheDurationMs\"];\n\n\t/**\n\t * Returns the snapshot tree.\n\t * @param version - Version of the snapshot to be fetched.\n\t * @param scenarioName - scenario in which this api is called. This will be recorded by server and would help\n\t * in debugging purposes to see why this call was made.\n\t */\n\t// TODO: use `undefined` instead.\n\t// eslint-disable-next-line @rushstack/no-new-null\n\tgetSnapshotTree(version?: IVersion, scenarioName?: string): Promise<ISnapshotTree | null>;\n\n\t/**\n\t * Returns the snapshot which can contain other artifacts too like blob contents, ops etc. It is different from\n\t * `getSnapshotTree` api in that, that API only returns the snapshot tree from the snapshot.\n\t * @param snapshotFetchOptions - Options specified by the caller to specify and want certain behavior from the\n\t * driver when fetching the snapshot.\n\t */\n\tgetSnapshot?(snapshotFetchOptions?: ISnapshotFetchOptions): Promise<ISnapshot>;\n\n\t/**\n\t * Retrieves all versions of the document starting at the specified versionId - or null if from the head\n\t * @param versionId - Version id of the requested version.\n\t * @param count - Number of the versions to be fetched.\n\t * @param scenarioName - scenario in which this api is called. This will be recorded by server and would help\n\t * in debugging purposes to see why this call was made.\n\t * @param fetchSource - Callers can specify the source of the response. For ex. Driver may choose to cache\n\t * requests and serve data from cache. That will result in stale info returned. Callers can disable this\n\t * functionality by passing fetchSource = noCache and ensuring that driver will return latest information\n\t * from storage.\n\t */\n\tgetVersions(\n\t\t// TODO: use `undefined` instead.\n\t\t// eslint-disable-next-line @rushstack/no-new-null\n\t\tversionId: string | null,\n\t\tcount: number,\n\t\tscenarioName?: string,\n\t\tfetchSource?: FetchSource,\n\t): Promise<IVersion[]>;\n\n\t/**\n\t * Creates a blob out of the given buffer\n\t */\n\tcreateBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse>;\n\n\t/**\n\t * Reads the object with the given ID, returns content in arrayBufferLike\n\t */\n\treadBlob(id: string): Promise<ArrayBufferLike>;\n\n\t/**\n\t * Uploads a summary tree to storage using the given context for reference of previous summary handle.\n\t * The ISummaryHandles in the uploaded tree should have paths to indicate which summary object they are\n\t * referencing from the previously acked summary.\n\t * Returns the uploaded summary handle.\n\t */\n\tuploadSummaryWithContext(summary: ISummaryTree, context: ISummaryContext): Promise<string>;\n\n\t/**\n\t * Retrieves the commit that matches the packfile handle. If the packfile has already been committed and the\n\t * server has deleted it this call may result in a broken promise.\n\t *\n\t * @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as\n\t * it is unused in the Runtime and below layers.\n\t */\n\tdownloadSummary(handle: ISummaryHandle): Promise<ISummaryTree>;\n}\n\n/**\n * IContainerContext is fundamentally just the set of things that an IRuntimeFactory (and IRuntime) will consume from the\n * loader layer.\n * It gets passed into the {@link (IRuntimeFactory:interface).instantiateRuntime} call.\n *\n * @privateremarks\n * Only include members on this interface if you intend them to be consumed/called from the runtime layer.\n *\n * TODO: once `@alpha` tag is removed, `unknown` should be removed from submitSignalFn.\n * See {@link https://dev.azure.com/fluidframework/internal/_workitems/edit/7462}\n *\n * @legacy\n * @alpha\n */\nexport interface IContainerContext {\n\t/**\n\t * Not recommended for general use, is used in some cases to control various runtime behaviors.\n\t *\n\t * @remarks\n\t * Used to be ILoaderOptions, this is staging for eventual removal.\n\t */\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\treadonly options: Record<string | number, any>;\n\treadonly clientId: string | undefined;\n\treadonly clientDetails: IClientDetails;\n\treadonly storage: IContainerStorageService;\n\treadonly connected: boolean;\n\treadonly baseSnapshot: ISnapshotTree | undefined;\n\n\t/**\n\t * Gets the current connection state of the container.\n\t *\n\t * @remarks\n\t * This provides more detailed connection state information beyond the simple boolean `connected` property.\n\t * Available starting from version 2.52.0. Property is not present in older versions.\n\t */\n\treadonly getConnectionState?: () => ConnectionState;\n\t/**\n\t * @deprecated Please use submitBatchFn & submitSummaryFn\n\t */\n\treadonly submitFn: (\n\t\ttype: MessageType,\n\t\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\t\tcontents: any,\n\t\tbatch: boolean,\n\t\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\t\tappData?: any,\n\t) => number;\n\t/**\n\t * @returns clientSequenceNumber of last message in a batch\n\t */\n\treadonly submitBatchFn: (batch: IBatchMessage[], referenceSequenceNumber?: number) => number;\n\treadonly submitSummaryFn: (\n\t\tsummaryOp: ISummaryContent,\n\t\treferenceSequenceNumber?: number,\n\t) => number;\n\treadonly submitSignalFn: (contents: unknown, targetClientId?: string) => void;\n\treadonly disposeFn?: (error?: ICriticalContainerError) => void;\n\treadonly closeFn: (error?: ICriticalContainerError) => void;\n\treadonly deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;\n\treadonly quorum: IQuorumClients;\n\treadonly audience: IAudience;\n\treadonly loader: ILoader;\n\t// The logger implementation, which would support tagged events, should be provided by the loader.\n\treadonly taggedLogger: ITelemetryBaseLogger;\n\tpendingLocalState?: unknown;\n\n\t/**\n\t * Ambient services provided with the context\n\t */\n\treadonly scope: FluidObject;\n\n\t/**\n\t * Get an absolute url for a provided container-relative request.\n\t * @param relativeUrl - A relative request within the container\n\t *\n\t * TODO: Optional for backwards compatibility. Make non-optional in version 0.19\n\t */\n\tgetAbsoluteUrl?(relativeUrl: string): Promise<string | undefined>;\n\n\t/**\n\t * Indicates the attachment state of the container to a host service.\n\t */\n\treadonly attachState: AttachState;\n\n\tgetLoadedFromVersion(): IVersion | undefined;\n\n\tupdateDirtyContainerState(dirty: boolean): void;\n\n\t/**\n\t * @deprecated - This has been deprecated. It was used internally and there is no replacement.\n\t */\n\treadonly supportedFeatures?: ReadonlyMap<string, unknown>;\n\n\t/**\n\t * WARNING: this id is meant for telemetry usages ONLY, not recommended for other consumption\n\t * This id is not supposed to be exposed anywhere else. It is dependant on usage or drivers\n\t * and scenarios which can change in the future.\n\t * @deprecated 2.0.0-internal.5.2.0 - The docId is already logged by the {@link IContainerContext.taggedLogger} for\n\t * telemetry purposes, so this is generally unnecessary for telemetry.\n\t * If the id is needed for other purposes it should be passed to the consumer explicitly.\n\t *\n\t * @privateremarks Tracking in AB#5714\n\t */\n\treadonly id: string;\n\n\t/**\n\t * This contains all parts of a snapshot like blobContents, ops etc.\n\t */\n\treadonly snapshotWithContents?: ISnapshot;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport const IRuntimeFactory: keyof IProvideRuntimeFactory = \"IRuntimeFactory\";\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IProvideRuntimeFactory {\n\treadonly IRuntimeFactory: IRuntimeFactory;\n}\n\n/**\n * Exported module definition\n *\n * Provides the entry point for the ContainerContext to load the proper IRuntime\n * to start up the running instance of the Container.\n * @legacy\n * @alpha\n */\nexport interface IRuntimeFactory extends IProvideRuntimeFactory {\n\t/**\n\t * Instantiates a new IRuntime for the given IContainerContext to proxy to\n\t * This is the main entry point to the Container's business logic\n\t *\n\t * @param context - container context to be supplied to the runtime\n\t * @param existing - whether to instantiate for the first time or from an existing context\n\t */\n\tinstantiateRuntime(context: IContainerContext, existing: boolean): Promise<IRuntime>;\n}\n\n/**\n * Defines list of properties expected for getPendingLocalState\n * @legacy\n * @alpha\n */\nexport interface IGetPendingLocalStateProps {\n\t/**\n\t * Indicates the container will close after getting the pending state. Used internally\n\t * to wait for blobs to be attached to a DDS and collect generated ops before closing.\n\t */\n\treadonly notifyImminentClosure: boolean;\n\n\t/**\n\t * Abort signal to stop waiting for blobs to get attached to a DDS. When triggered,\n\t * only blobs attached will be collected in the pending state.\n\t * Intended to be used in the very rare scenario in which getLocalPendingState go stale due\n\t * to a blob failed to be referenced. Such a blob will be lost but the rest of the state will\n\t * be preserved and collected.\n\t */\n\treadonly stopBlobAttachingSignal?: AbortSignal;\n\n\t/**\n\t * Date to be used as the starting time of a session. This date is updated in case we refresh the\n\t * base snapshot since we won't be referencing ops older than the new snapshot.\n\t */\n\treadonly sessionExpiryTimerStarted?: number;\n\n\t/**\n\t * Snapshot sequence number. It will help the runtime to know which ops should still be stashed.\n\t */\n\treadonly snapshotSequenceNumber?: number;\n}\n"]}
1
+ {"version":3,"file":"runtime.js","sourceRoot":"","sources":["../src/runtime.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAiCH;;;;GAIG;AACH,IAAY,WAiBX;AAjBD,WAAY,WAAW;IACtB;;;OAGG;IACH,oCAAqB,CAAA;IAErB;;OAEG;IACH,sCAAuB,CAAA;IAEvB;;;OAGG;IACH,oCAAqB,CAAA;AACtB,CAAC,EAjBW,WAAW,2BAAX,WAAW,QAiBtB;AAwSD;;GAEG;AACU,QAAA,eAAe,GAAiC,iBAAiB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tFluidObject,\n\tIDisposable,\n\tITelemetryBaseLogger,\n} from \"@fluidframework/core-interfaces\";\nimport type {\n\tIClientDetails,\n\tIQuorumClients,\n\tISummaryTree,\n} from \"@fluidframework/driver-definitions\";\nimport type {\n\tISnapshot,\n\tIDocumentMessage,\n\tISnapshotTree,\n\tISummaryContent,\n\tIVersion,\n\tMessageType,\n\tISequencedDocumentMessage,\n\tICreateBlobResponse,\n\tISummaryContext,\n\tISnapshotFetchOptions,\n\tFetchSource,\n\tIDocumentStorageServicePolicies,\n\tISummaryHandle,\n} from \"@fluidframework/driver-definitions/internal\";\n\nimport type { IAudience } from \"./audience.js\";\nimport type { IDeltaManager } from \"./deltas.js\";\nimport type { ICriticalContainerError } from \"./error.js\";\nimport type { ConnectionState, ILoader } from \"./loader.js\";\n\n/**\n * The attachment state of some Fluid data (e.g. a container or data store), denoting whether it is uploaded to the\n * service. The transition from detached to attached state is a one-way transition.\n * @public\n */\nexport enum AttachState {\n\t/**\n\t * In detached state, the data is only present on the local client's machine. It has not yet been uploaded\n\t * to the service.\n\t */\n\tDetached = \"Detached\",\n\n\t/**\n\t * In attaching state, the data has started the upload to the service, but has not yet completed.\n\t */\n\tAttaching = \"Attaching\",\n\n\t/**\n\t * In attached state, the data has completed upload to the service. It can be accessed by other clients after\n\t * reaching attached state.\n\t */\n\tAttached = \"Attached\",\n}\n\n/**\n * The IRuntime represents an instantiation of a code package within a Container.\n * Primarily held by the ContainerContext to be able to interact with the running instance of the Container.\n *\n * @legacy @beta\n */\nexport interface IRuntime extends IDisposable {\n\t/**\n\t * Notifies the runtime of a change in the connection state\n\t * @param canSendOps - true if the runtime is allowed to send ops\n\t * @param clientId - the ID of the client that is connecting or disconnecting\n\t */\n\tsetConnectionState(canSendOps: boolean, clientId?: string);\n\n\t/**\n\t * Processes the given op (message)\n\t * @param message - delta message received from the server\n\t * @param local - true if the message was originally generated by the client receiving it.\n\t */\n\tprocess(message: ISequencedDocumentMessage, local: boolean);\n\n\t/**\n\t * Processes the given signal\n\t */\n\t// TODO: use `unknown` instead (API breaking)\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\tprocessSignal(message: any, local: boolean);\n\n\t/**\n\t * Create a summary. Used when attaching or serializing a detached container.\n\t *\n\t * @param blobRedirectTable - A table passed during the attach process. While detached, blob upload is supported\n\t * using IDs generated locally. After attach, these IDs cannot be used, so this table maps the old local IDs to the\n\t * new storage IDs so requests can be redirected.\n\t */\n\tcreateSummary(blobRedirectTable?: Map<string, string>): ISummaryTree;\n\n\t/**\n\t * Propagate the container state when container is attaching or attached.\n\t * @param attachState - State of the container.\n\t */\n\tsetAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;\n\n\t/**\n\t * Get pending local state in a serializable format to be given back to a newly loaded container\n\t */\n\tgetPendingLocalState(props?: IGetPendingLocalStateProps): unknown;\n\n\t/**\n\t * Notify runtime that we have processed a saved message, so that it can do async work (applying\n\t * stashed ops) after having processed it.\n\t */\n\tnotifyOpReplay?(message: ISequencedDocumentMessage): Promise<void>;\n\n\t/**\n\t * Exposes the entryPoint for the container runtime.\n\t * Use this as the primary way of getting access to the user-defined logic within the container runtime.\n\t *\n\t * @see {@link IContainer.getEntryPoint}\n\t */\n\tgetEntryPoint(): Promise<FluidObject>;\n}\n\n/**\n * Payload type for IContainerContext.submitBatchFn()\n * @legacy @beta\n */\nexport interface IBatchMessage {\n\tcontents?: string;\n\tmetadata?: Record<string, unknown>;\n\tcompression?: string;\n\treferenceSequenceNumber?: number;\n}\n\n/**\n * Interface to provide access to snapshots and policies to the Runtime layer. This should follow the Loader / Runtime\n * layer compatibility rules.\n *\n * @remarks It contains a subset of APIs from {@link @fluidframework/driver-definitions#IDocumentStorageService} but\n * allows the Runtime to not support layer compatibility with the Driver layer. Instead, it supports compatibility\n * with the Loader layer which it already does.\n *\n * @legacy @beta\n */\nexport interface IContainerStorageService {\n\t/**\n\t * Whether or not the object has been disposed.\n\t * If true, the object should be considered invalid, and its other state should be disregarded.\n\t *\n\t * @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as\n\t * it is unused in the Runtime layer.\n\t */\n\treadonly disposed?: boolean;\n\n\t/**\n\t * Dispose of the object and its resources.\n\t * @param error - Optional error indicating the reason for the disposal, if the object was\n\t * disposed as the result of an error.\n\t *\n\t * @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as\n\t * it is unused in the Runtime layer.\n\t */\n\tdispose?(error?: Error): void;\n\n\t/**\n\t * Policies implemented/instructed by driver.\n\t *\n\t * @deprecated - This will be removed in a future release. The Runtime layer only needs `maximumCacheDurationMs`\n\t * policy which is added as a separate property.\n\t */\n\treadonly policies?: IDocumentStorageServicePolicies | undefined;\n\n\t/**\n\t * See {@link @fluidframework/driver-definitions#IDocumentStorageServicePolicies.maximumCacheDurationMs}\n\t */\n\treadonly maximumCacheDurationMs?: IDocumentStorageServicePolicies[\"maximumCacheDurationMs\"];\n\n\t/**\n\t * Returns the snapshot tree.\n\t * @param version - Version of the snapshot to be fetched.\n\t * @param scenarioName - scenario in which this api is called. This will be recorded by server and would help\n\t * in debugging purposes to see why this call was made.\n\t */\n\t// TODO: use `undefined` instead.\n\t// eslint-disable-next-line @rushstack/no-new-null\n\tgetSnapshotTree(version?: IVersion, scenarioName?: string): Promise<ISnapshotTree | null>;\n\n\t/**\n\t * Returns the snapshot which can contain other artifacts too like blob contents, ops etc. It is different from\n\t * `getSnapshotTree` api in that, that API only returns the snapshot tree from the snapshot.\n\t * @param snapshotFetchOptions - Options specified by the caller to specify and want certain behavior from the\n\t * driver when fetching the snapshot.\n\t */\n\tgetSnapshot?(snapshotFetchOptions?: ISnapshotFetchOptions): Promise<ISnapshot>;\n\n\t/**\n\t * Retrieves all versions of the document starting at the specified versionId - or null if from the head\n\t * @param versionId - Version id of the requested version.\n\t * @param count - Number of the versions to be fetched.\n\t * @param scenarioName - scenario in which this api is called. This will be recorded by server and would help\n\t * in debugging purposes to see why this call was made.\n\t * @param fetchSource - Callers can specify the source of the response. For ex. Driver may choose to cache\n\t * requests and serve data from cache. That will result in stale info returned. Callers can disable this\n\t * functionality by passing fetchSource = noCache and ensuring that driver will return latest information\n\t * from storage.\n\t */\n\tgetVersions(\n\t\t// TODO: use `undefined` instead.\n\t\t// eslint-disable-next-line @rushstack/no-new-null\n\t\tversionId: string | null,\n\t\tcount: number,\n\t\tscenarioName?: string,\n\t\tfetchSource?: FetchSource,\n\t): Promise<IVersion[]>;\n\n\t/**\n\t * Creates a blob out of the given buffer\n\t */\n\tcreateBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse>;\n\n\t/**\n\t * Reads the object with the given ID, returns content in arrayBufferLike\n\t */\n\treadBlob(id: string): Promise<ArrayBufferLike>;\n\n\t/**\n\t * Uploads a summary tree to storage using the given context for reference of previous summary handle.\n\t * The ISummaryHandles in the uploaded tree should have paths to indicate which summary object they are\n\t * referencing from the previously acked summary.\n\t * Returns the uploaded summary handle.\n\t */\n\tuploadSummaryWithContext(summary: ISummaryTree, context: ISummaryContext): Promise<string>;\n\n\t/**\n\t * Retrieves the commit that matches the packfile handle. If the packfile has already been committed and the\n\t * server has deleted it this call may result in a broken promise.\n\t *\n\t * @deprecated - This API is deprecated and will be removed in a future release. No replacement is planned as\n\t * it is unused in the Runtime and below layers.\n\t */\n\tdownloadSummary(handle: ISummaryHandle): Promise<ISummaryTree>;\n}\n\n/**\n * IContainerContext is fundamentally just the set of things that an IRuntimeFactory (and IRuntime) will consume from the\n * loader layer.\n * It gets passed into the {@link (IRuntimeFactory:interface).instantiateRuntime} call.\n *\n * @privateremarks\n * Only include members on this interface if you intend them to be consumed/called from the runtime layer.\n *\n * TODO: once `@alpha` tag is removed, `unknown` should be removed from submitSignalFn.\n * See {@link https://dev.azure.com/fluidframework/internal/_workitems/edit/7462}\n *\n * @legacy @beta\n */\nexport interface IContainerContext {\n\t/**\n\t * Not recommended for general use, is used in some cases to control various runtime behaviors.\n\t *\n\t * @remarks\n\t * Used to be ILoaderOptions, this is staging for eventual removal.\n\t */\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\treadonly options: Record<string | number, any>;\n\treadonly clientId: string | undefined;\n\treadonly clientDetails: IClientDetails;\n\treadonly storage: IContainerStorageService;\n\treadonly connected: boolean;\n\treadonly baseSnapshot: ISnapshotTree | undefined;\n\n\t/**\n\t * Gets the current connection state of the container.\n\t *\n\t * @remarks\n\t * This provides more detailed connection state information beyond the simple boolean `connected` property.\n\t * Available starting from version 2.52.0. Property is not present in older versions.\n\t */\n\treadonly getConnectionState?: () => ConnectionState;\n\t/**\n\t * @deprecated Please use submitBatchFn & submitSummaryFn\n\t */\n\treadonly submitFn: (\n\t\ttype: MessageType,\n\t\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\t\tcontents: any,\n\t\tbatch: boolean,\n\t\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\t\tappData?: any,\n\t) => number;\n\t/**\n\t * @returns clientSequenceNumber of last message in a batch\n\t */\n\treadonly submitBatchFn: (batch: IBatchMessage[], referenceSequenceNumber?: number) => number;\n\treadonly submitSummaryFn: (\n\t\tsummaryOp: ISummaryContent,\n\t\treferenceSequenceNumber?: number,\n\t) => number;\n\treadonly submitSignalFn: (contents: unknown, targetClientId?: string) => void;\n\treadonly disposeFn?: (error?: ICriticalContainerError) => void;\n\treadonly closeFn: (error?: ICriticalContainerError) => void;\n\treadonly deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;\n\treadonly quorum: IQuorumClients;\n\treadonly audience: IAudience;\n\treadonly loader: ILoader;\n\t// The logger implementation, which would support tagged events, should be provided by the loader.\n\treadonly taggedLogger: ITelemetryBaseLogger;\n\tpendingLocalState?: unknown;\n\n\t/**\n\t * Ambient services provided with the context\n\t */\n\treadonly scope: FluidObject;\n\n\t/**\n\t * Get an absolute url for a provided container-relative request.\n\t * @param relativeUrl - A relative request within the container\n\t *\n\t * TODO: Optional for backwards compatibility. Make non-optional in version 0.19\n\t */\n\tgetAbsoluteUrl?(relativeUrl: string): Promise<string | undefined>;\n\n\t/**\n\t * Indicates the attachment state of the container to a host service.\n\t */\n\treadonly attachState: AttachState;\n\n\tgetLoadedFromVersion(): IVersion | undefined;\n\n\tupdateDirtyContainerState(dirty: boolean): void;\n\n\t/**\n\t * @deprecated - This has been deprecated. It was used internally and there is no replacement.\n\t */\n\treadonly supportedFeatures?: ReadonlyMap<string, unknown>;\n\n\t/**\n\t * WARNING: this id is meant for telemetry usages ONLY, not recommended for other consumption\n\t * This id is not supposed to be exposed anywhere else. It is dependant on usage or drivers\n\t * and scenarios which can change in the future.\n\t * @deprecated 2.0.0-internal.5.2.0 - The docId is already logged by the {@link IContainerContext.taggedLogger} for\n\t * telemetry purposes, so this is generally unnecessary for telemetry.\n\t * If the id is needed for other purposes it should be passed to the consumer explicitly.\n\t *\n\t * @privateremarks Tracking in AB#5714\n\t */\n\treadonly id: string;\n\n\t/**\n\t * This contains all parts of a snapshot like blobContents, ops etc.\n\t */\n\treadonly snapshotWithContents?: ISnapshot;\n}\n\n/**\n * @legacy @beta\n */\nexport const IRuntimeFactory: keyof IProvideRuntimeFactory = \"IRuntimeFactory\";\n\n/**\n * @legacy @beta\n */\nexport interface IProvideRuntimeFactory {\n\treadonly IRuntimeFactory: IRuntimeFactory;\n}\n\n/**\n * Exported module definition\n *\n * Provides the entry point for the ContainerContext to load the proper IRuntime\n * to start up the running instance of the Container.\n * @legacy @beta\n */\nexport interface IRuntimeFactory extends IProvideRuntimeFactory {\n\t/**\n\t * Instantiates a new IRuntime for the given IContainerContext to proxy to\n\t * This is the main entry point to the Container's business logic\n\t *\n\t * @param context - container context to be supplied to the runtime\n\t * @param existing - whether to instantiate for the first time or from an existing context\n\t */\n\tinstantiateRuntime(context: IContainerContext, existing: boolean): Promise<IRuntime>;\n}\n\n/**\n * Defines list of properties expected for getPendingLocalState\n * @legacy @beta\n */\nexport interface IGetPendingLocalStateProps {\n\t/**\n\t * Indicates the container will close after getting the pending state. Used internally\n\t * to wait for blobs to be attached to a DDS and collect generated ops before closing.\n\t */\n\treadonly notifyImminentClosure: boolean;\n\n\t/**\n\t * Abort signal to stop waiting for blobs to get attached to a DDS. When triggered,\n\t * only blobs attached will be collected in the pending state.\n\t * Intended to be used in the very rare scenario in which getLocalPendingState go stale due\n\t * to a blob failed to be referenced. Such a blob will be lost but the rest of the state will\n\t * be preserved and collected.\n\t */\n\treadonly stopBlobAttachingSignal?: AbortSignal;\n\n\t/**\n\t * Date to be used as the starting time of a session. This date is updated in case we refresh the\n\t * base snapshot since we won't be referencing ops older than the new snapshot.\n\t */\n\treadonly sessionExpiryTimerStarted?: number;\n\n\t/**\n\t * Snapshot sequence number. It will help the runtime to know which ops should still be stashed.\n\t */\n\treadonly snapshotSequenceNumber?: number;\n}\n"]}
package/lib/audience.d.ts CHANGED
@@ -6,8 +6,7 @@ import type { IEvent, IEventProvider } from "@fluidframework/core-interfaces";
6
6
  import type { IClient } from "@fluidframework/driver-definitions";
7
7
  /**
8
8
  * Manages the state and the members for {@link IAudience}
9
- * @legacy
10
- * @alpha
9
+ * @legacy @beta
11
10
  */
12
11
  export interface IAudienceOwner extends IAudience {
13
12
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"audience.d.ts","sourceRoot":"","sources":["../src/audience.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAC9E,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAClE;;;;GAIG;AACH,MAAM,WAAW,cAAe,SAAQ,SAAS;IAChD;;OAEG;IACH,SAAS,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC;IAEpD;;;OAGG;IACH,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC;IAExC;;;OAGG;IACH,kBAAkB,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CAC3C;AAED;;;GAGG;AACH,MAAM,WAAW,eAAgB,SAAQ,MAAM;IAC9C;;;;;;;OAOG;IACH,CAAC,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,KAAK,IAAI,GAAG,IAAI,CAAC;IAElF;;;;;;;OAOG;IACH,CAAC,KAAK,EAAE,cAAc,EAAE,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,KAAK,IAAI,GAAG,IAAI,CAAC;IACrF;;;;;;OAMG;IACH,CACC,KAAK,EAAE,aAAa,EACpB,QAAQ,EAAE,C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AC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,KAAK,IAAI,GAAG,IAAI,CAAC;IAElF;;;;;;;OAOG;IACH,CAAC,KAAK,EAAE,cAAc,EAAE,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,KAAK,IAAI,GAAG,IAAI,CAAC;IACrF;;;;;;OAMG;IACH,CACC,KAAK,EAAE,aAAa,EACpB,QAAQ,EAAE,CAAC,QAAQ,EAAE,KAAK,GAAG,SAAS,EAAE,QAAQ,EAAE,KAAK,KAAK,IAAI,GAC9D,IAAI,CAAC;CACR;AAED;;;GAGG;AACH,MAAM,WAAW,KAAK;IACrB;;;OAGG;IACH,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAE1B;;;;;;;;;OASG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,SAAU,SAAQ,cAAc,CAAC,eAAe,CAAC;IACjE;;;;;;;;;;OAUG;IACH,UAAU,IAAI,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAEnC;;;;;;;;;;OAUG;IACH,SAAS,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;IAEjD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA8BG;IACH,OAAO,IAAI,KAAK,GAAG,SAAS,CAAC;CAC7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"audience.js","sourceRoot":"","sources":["../src/audience.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IEvent, IEventProvider } from \"@fluidframework/core-interfaces\";\nimport type { IClient } from \"@fluidframework/driver-definitions\";\n/**\n * Manages the state and the members for {@link IAudience}\n * @legacy\n * @alpha\n */\nexport interface IAudienceOwner extends IAudience {\n\t/**\n\t * Adds a new client to the audience\n\t */\n\taddMember(clientId: string, details: IClient): void;\n\n\t/**\n\t * Removes a client from the audience. Only emits an event if a client is actually removed\n\t * @returns if a client was removed from the audience\n\t */\n\tremoveMember(clientId: string): boolean;\n\n\t/**\n\t * Notifies Audience that current clientId has changed.\n\t * See {@link IAudience.getSelf} and {@link IAudienceEvents}'s \"selfChanged\" event for more details.\n\t */\n\tsetCurrentClientId(clientId: string): void;\n}\n\n/**\n * Interface describing Audience events\n * @public\n */\nexport interface IAudienceEvents extends IEvent {\n\t/**\n\t * Raised when a new user joins collaborative session.\n\t *\n\t * @param clientId - clientId of the new user that joined.\n\t * @param client - Information about the new user that joined (including user identity, connection properties).\n\t *\n\t * @eventProperty\n\t */\n\t(event: \"addMember\", listener: (clientId: string, client: IClient) => void): void;\n\n\t/**\n\t * Raised when a user leaves collaborative session.\n\t *\n\t * @param clientId - clientId of the user that left.\n\t * @param client - Information about the user that left (including user identity, connection properties).\n\t *\n\t * @eventProperty\n\t */\n\t(event: \"removeMember\", listener: (clientId: string, client: IClient) => void): void;\n\t/**\n\t * Notifies that client established new connection and caught-up on ops.\n\t * @param oldValue - represents old connection. Please note that oldValue.client in almost all cases will be undefined,\n\t * due to specifics how Audience refreshes on reconnect. In the future we could improve it and always provide client information.\n\t * @param newValue - represents newly established connection. While {@link IAudience.getSelf} is experimental, it's not guaranteed that\n\t * newValue.client is present. Same is true if you are consuming audience from container runtime layer and running against old version of loader.\n\t */\n\t(\n\t\tevent: \"selfChanged\",\n\t\tlistener: (oldValue: ISelf | undefined, newValue: ISelf) => void,\n\t): void;\n}\n\n/**\n * Return type of {@link IAudience.getSelf}. Please see remarks for {@link IAudience.getSelf} to learn more details on promises.\n * @public\n */\nexport interface ISelf {\n\t/**\n\t * clientId of current or previous connection (if client is in disconnected or reconnecting / catching up state)\n\t * It changes only when client has reconnected, caught up with latest ops.\n\t */\n\treadonly clientId: string;\n\n\t/**\n\t * Information about current client (including user identity, connection properties), supplied by ordering service when\n\t * client connected to it and received {@link ISelf.clientId}.\n\t * If present (not undefined), it's same value as calling IAudience.getMember(clientId).\n\t * This property could be undefined even if there is non-undefined clientId.\n\t * This could happen in the following cases:\n\t * 1) Container was loaded from stash, by providing IPendingContainerState state to Container.load().\n\t * 2) Container is in the process of establishing new connection. Information about old connection is already reset\n\t * (old clientId is no longer in list of members), but clientId has not yet changed to a new value.\n\t */\n\treadonly client?: IClient;\n}\n\n/**\n * Represents all clients connected to the op stream, both read-only and read/write.\n *\n * @remarks Access to the Audience when a container is disconnected is a tricky subject.\n * See the remarks on specific methods for more details.\n *\n * @public\n */\nexport interface IAudience extends IEventProvider<IAudienceEvents> {\n\t/**\n\t * List all clients connected to the op stream, keyed off their clientId.\n\t *\n\t * @remarks When the container is disconnected, there are no guarantees about the correctness of what this method returns.\n\t * The default implementation in Fluid Framework continues to return the list of members as it last saw it before the\n\t * container disconnected, but this could change in the future. Other implementations could decide to return an empty\n\t * list, or a list that only includes the local client.\n\t *\n\t * Note that the clientId that a disconnected container might see for itself is an old one. A disconnected container\n\t * does not technically have a clientId tied to an active connection to the service.\n\t */\n\tgetMembers(): Map<string, IClient>;\n\n\t/**\n\t * Get details about the connected client with the specified clientId, or undefined if the specified client isn't connected.\n\t *\n\t * @remarks When the container is disconnected, there are no guarantees about the correctness of what this method returns.\n\t * The default implementation in Fluid Framework continues to return members that were part of the audience when the\n\t * container disconnected, but this could change in the future. Other implementations could decide to always return\n\t * undefined, or only return an IClient when the local client is requested.\n\t *\n\t * Note that the clientId that a disconnected container might see for itself is an old one. A disconnected container\n\t * does not technically have a clientId tied to an active connection to the service.\n\t */\n\tgetMember(clientId: string): IClient | undefined;\n\n\t/**\n\t * Returns information about client's connection. Please see {@link ISelf} member descriptions for more details.\n\t * undefined if this client has never connected to the ordering service.\n\t * Please see {@link ISelf.clientId} for more details on when values returned by this function change over time.\n\t *\n\t * @experimental\n\t *\n\t * @remarks\n\t * This API is experimental.\n\t *\n\t * Reconnection process will have these phases:\n\t * 1. Establishing connection phase:\n\t * - new connection clientId is added to member's list. That said, self.clientId still reflects old information.\n\t * - The old client's information is removed from members' list. getMember(self.clientId) will return undefined.\n\t * 2. Catch-up phase. Client catches up on latest ops and becomes current.\n\t * 3. \"connect\" phase - the following happens synchronously:\n\t * - getSelf() information changes to reflect new connection\n\t * - \"selfChanged\" event on this object fires\n\t * - Various API surfaces may expose \"connected\" event. This event fires at the same time as self changes. That said, \"connected\" event will not fire at IContainerRuntime layer if container is read-only.\n\t *\n\t * That said, at the moment this is an experimental API. It depends on some experimental settings that might change in the future.\n\t * Events described in phase #3 may not happen at the same time if kill-bit feature gates are engaged due to a bug discovered in new logic\n\t * that delivers this functionality. Once it's proven (at scale) that everything works well, experimental tag will be removed.\n\t * Also application that deploy loader & container runtime bundles independently will see new (synchronized) behavior only when loader changes are deployed.\n\t * Newer runtimes will continue to observe old (non-synchronized) behavior when paired with older loader code.\n\t *\n\t * When promises in phase #3 are broken (due to conditions described above), consumers could experience current clientId being changed\n\t * (and \"selfChanged\" event fired) while\n\t * 1. Such clientId is not present in Audience\n\t * 2. Client is not fully caught up\n\t */\n\tgetSelf(): ISelf | undefined;\n}\n"]}
1
+ {"version":3,"file":"audience.js","sourceRoot":"","sources":["../src/audience.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IEvent, IEventProvider } from \"@fluidframework/core-interfaces\";\nimport type { IClient } from \"@fluidframework/driver-definitions\";\n/**\n * Manages the state and the members for {@link IAudience}\n * @legacy @beta\n */\nexport interface IAudienceOwner extends IAudience {\n\t/**\n\t * Adds a new client to the audience\n\t */\n\taddMember(clientId: string, details: IClient): void;\n\n\t/**\n\t * Removes a client from the audience. Only emits an event if a client is actually removed\n\t * @returns if a client was removed from the audience\n\t */\n\tremoveMember(clientId: string): boolean;\n\n\t/**\n\t * Notifies Audience that current clientId has changed.\n\t * See {@link IAudience.getSelf} and {@link IAudienceEvents}'s \"selfChanged\" event for more details.\n\t */\n\tsetCurrentClientId(clientId: string): void;\n}\n\n/**\n * Interface describing Audience events\n * @public\n */\nexport interface IAudienceEvents extends IEvent {\n\t/**\n\t * Raised when a new user joins collaborative session.\n\t *\n\t * @param clientId - clientId of the new user that joined.\n\t * @param client - Information about the new user that joined (including user identity, connection properties).\n\t *\n\t * @eventProperty\n\t */\n\t(event: \"addMember\", listener: (clientId: string, client: IClient) => void): void;\n\n\t/**\n\t * Raised when a user leaves collaborative session.\n\t *\n\t * @param clientId - clientId of the user that left.\n\t * @param client - Information about the user that left (including user identity, connection properties).\n\t *\n\t * @eventProperty\n\t */\n\t(event: \"removeMember\", listener: (clientId: string, client: IClient) => void): void;\n\t/**\n\t * Notifies that client established new connection and caught-up on ops.\n\t * @param oldValue - represents old connection. Please note that oldValue.client in almost all cases will be undefined,\n\t * due to specifics how Audience refreshes on reconnect. In the future we could improve it and always provide client information.\n\t * @param newValue - represents newly established connection. While {@link IAudience.getSelf} is experimental, it's not guaranteed that\n\t * newValue.client is present. Same is true if you are consuming audience from container runtime layer and running against old version of loader.\n\t */\n\t(\n\t\tevent: \"selfChanged\",\n\t\tlistener: (oldValue: ISelf | undefined, newValue: ISelf) => void,\n\t): void;\n}\n\n/**\n * Return type of {@link IAudience.getSelf}. Please see remarks for {@link IAudience.getSelf} to learn more details on promises.\n * @public\n */\nexport interface ISelf {\n\t/**\n\t * clientId of current or previous connection (if client is in disconnected or reconnecting / catching up state)\n\t * It changes only when client has reconnected, caught up with latest ops.\n\t */\n\treadonly clientId: string;\n\n\t/**\n\t * Information about current client (including user identity, connection properties), supplied by ordering service when\n\t * client connected to it and received {@link ISelf.clientId}.\n\t * If present (not undefined), it's same value as calling IAudience.getMember(clientId).\n\t * This property could be undefined even if there is non-undefined clientId.\n\t * This could happen in the following cases:\n\t * 1) Container was loaded from stash, by providing IPendingContainerState state to Container.load().\n\t * 2) Container is in the process of establishing new connection. Information about old connection is already reset\n\t * (old clientId is no longer in list of members), but clientId has not yet changed to a new value.\n\t */\n\treadonly client?: IClient;\n}\n\n/**\n * Represents all clients connected to the op stream, both read-only and read/write.\n *\n * @remarks Access to the Audience when a container is disconnected is a tricky subject.\n * See the remarks on specific methods for more details.\n *\n * @public\n */\nexport interface IAudience extends IEventProvider<IAudienceEvents> {\n\t/**\n\t * List all clients connected to the op stream, keyed off their clientId.\n\t *\n\t * @remarks When the container is disconnected, there are no guarantees about the correctness of what this method returns.\n\t * The default implementation in Fluid Framework continues to return the list of members as it last saw it before the\n\t * container disconnected, but this could change in the future. Other implementations could decide to return an empty\n\t * list, or a list that only includes the local client.\n\t *\n\t * Note that the clientId that a disconnected container might see for itself is an old one. A disconnected container\n\t * does not technically have a clientId tied to an active connection to the service.\n\t */\n\tgetMembers(): Map<string, IClient>;\n\n\t/**\n\t * Get details about the connected client with the specified clientId, or undefined if the specified client isn't connected.\n\t *\n\t * @remarks When the container is disconnected, there are no guarantees about the correctness of what this method returns.\n\t * The default implementation in Fluid Framework continues to return members that were part of the audience when the\n\t * container disconnected, but this could change in the future. Other implementations could decide to always return\n\t * undefined, or only return an IClient when the local client is requested.\n\t *\n\t * Note that the clientId that a disconnected container might see for itself is an old one. A disconnected container\n\t * does not technically have a clientId tied to an active connection to the service.\n\t */\n\tgetMember(clientId: string): IClient | undefined;\n\n\t/**\n\t * Returns information about client's connection. Please see {@link ISelf} member descriptions for more details.\n\t * undefined if this client has never connected to the ordering service.\n\t * Please see {@link ISelf.clientId} for more details on when values returned by this function change over time.\n\t *\n\t * @experimental\n\t *\n\t * @remarks\n\t * This API is experimental.\n\t *\n\t * Reconnection process will have these phases:\n\t * 1. Establishing connection phase:\n\t * - new connection clientId is added to member's list. That said, self.clientId still reflects old information.\n\t * - The old client's information is removed from members' list. getMember(self.clientId) will return undefined.\n\t * 2. Catch-up phase. Client catches up on latest ops and becomes current.\n\t * 3. \"connect\" phase - the following happens synchronously:\n\t * - getSelf() information changes to reflect new connection\n\t * - \"selfChanged\" event on this object fires\n\t * - Various API surfaces may expose \"connected\" event. This event fires at the same time as self changes. That said, \"connected\" event will not fire at IContainerRuntime layer if container is read-only.\n\t *\n\t * That said, at the moment this is an experimental API. It depends on some experimental settings that might change in the future.\n\t * Events described in phase #3 may not happen at the same time if kill-bit feature gates are engaged due to a bug discovered in new logic\n\t * that delivers this functionality. Once it's proven (at scale) that everything works well, experimental tag will be removed.\n\t * Also application that deploy loader & container runtime bundles independently will see new (synchronized) behavior only when loader changes are deployed.\n\t * Newer runtimes will continue to observe old (non-synchronized) behavior when paired with older loader code.\n\t *\n\t * When promises in phase #3 are broken (due to conditions described above), consumers could experience current clientId being changed\n\t * (and \"selfChanged\" event fired) while\n\t * 1. Such clientId is not present in Audience\n\t * 2. Client is not fully caught up\n\t */\n\tgetSelf(): ISelf | undefined;\n}\n"]}
@@ -5,8 +5,7 @@
5
5
  import type { IFluidPackage, IFluidPackageEnvironment } from "./fluidPackage.js";
6
6
  /**
7
7
  * A specific Fluid package environment for browsers
8
- * @legacy
9
- * @alpha
8
+ * @legacy @beta
10
9
  */
11
10
  export interface IFluidBrowserPackageEnvironment extends IFluidPackageEnvironment {
12
11
  /**
@@ -28,8 +27,7 @@ export interface IFluidBrowserPackageEnvironment extends IFluidPackageEnvironmen
28
27
  }
29
28
  /**
30
29
  * A Fluid package for specification for browser environments
31
- * @legacy
32
- * @alpha
30
+ * @legacy @beta
33
31
  */
34
32
  export interface IFluidBrowserPackage extends IFluidPackage {
35
33
  /**
@@ -49,8 +47,7 @@ export interface IFluidBrowserPackage extends IFluidPackage {
49
47
  /**
50
48
  * Determines if any object is an IFluidBrowserPackage
51
49
  * @param maybePkg - The object to check for compatibility with IFluidBrowserPackage
52
- * @legacy
53
- * @alpha
50
+ * @legacy @beta
54
51
  */
55
52
  export declare const isFluidBrowserPackage: (maybePkg: unknown) => maybePkg is Readonly<IFluidBrowserPackage>;
56
53
  //# sourceMappingURL=browserPackage.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"browserPackage.d.ts","sourceRoot":"","sources":["../src/browserPackage.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAGjF;;;;GAIG;AACH,MAAM,WAAW,+BAAgC,SAAQ,wBAAwB;IAChF;;;OAGG;IACH,GAAG,EAAE;QACJ;;;WAGG;QACH,KAAK,EAAE,MAAM,EAAE,CAAC;QAEhB;;;WAGG;QACH,OAAO,EAAE,MAAM,CAAC;KAChB,CAAC;CACF;AAED;;;;GAIG;AACH,MAAM,WAAW,oBAAqB,SAAQ,aAAa;IAC1D;;OAEG;IACH,KAAK,EAAE;QACN;;WAEG;QACH,OAAO,EAAE,+BAA+B,CAAC;QACzC;;WAEG;QACH,CAAC,WAAW,EAAE,MAAM,GAAG,wBAAwB,CAAC;KAChD,CAAC;CACF;AAED;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,aACvB,OAAO,+CAIkC,CAAC"}
1
+ {"version":3,"file":"browserPackage.d.ts","sourceRoot":"","sources":["../src/browserPackage.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAGjF;;;GAGG;AACH,MAAM,WAAW,+BAAgC,SAAQ,wBAAwB;IAChF;;;OAGG;IACH,GAAG,EAAE;QACJ;;;WAGG;QACH,KAAK,EAAE,MAAM,EAAE,CAAC;QAEhB;;;WAGG;QACH,OAAO,EAAE,MAAM,CAAC;KAChB,CAAC;CACF;AAED;;;GAGG;AACH,MAAM,WAAW,oBAAqB,SAAQ,aAAa;IAC1D;;OAEG;IACH,KAAK,EAAE;QACN;;WAEG;QACH,OAAO,EAAE,+BAA+B,CAAC;QACzC;;WAEG;QACH,CAAC,WAAW,EAAE,MAAM,GAAG,wBAAwB,CAAC;KAChD,CAAC;CACF;AAED;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,aACvB,OAAO,+CAIkC,CAAC"}
@@ -6,8 +6,7 @@ import { isFluidPackage } from "./fluidPackage.js";
6
6
  /**
7
7
  * Determines if any object is an IFluidBrowserPackage
8
8
  * @param maybePkg - The object to check for compatibility with IFluidBrowserPackage
9
- * @legacy
10
- * @alpha
9
+ * @legacy @beta
11
10
  */
12
11
  export const isFluidBrowserPackage = (maybePkg) => isFluidPackage(maybePkg) &&
13
12
  typeof maybePkg?.fluid?.browser?.umd?.library === "string" &&
@@ -1 +1 @@
1
- {"version":3,"file":"browserPackage.js","sourceRoot":"","sources":["../src/browserPackage.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAgDnD;;;;;GAKG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CACpC,QAAiB,EAC4B,EAAE,CAC/C,cAAc,CAAC,QAAQ,CAAC;IACxB,OAAO,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,KAAK,QAAQ;IAC1D,KAAK,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IFluidPackage, IFluidPackageEnvironment } from \"./fluidPackage.js\";\nimport { isFluidPackage } from \"./fluidPackage.js\";\n\n/**\n * A specific Fluid package environment for browsers\n * @legacy\n * @alpha\n */\nexport interface IFluidBrowserPackageEnvironment extends IFluidPackageEnvironment {\n\t/**\n\t * The Universal Module Definition (umd) target specifics the scripts necessary for\n\t * loading a packages in a browser environment and finding its entry point.\n\t */\n\tumd: {\n\t\t/**\n\t\t * The bundled js files for loading this package.\n\t\t * These files will be loaded and executed in order.\n\t\t */\n\t\tfiles: string[];\n\n\t\t/**\n\t\t * The global name that the script entry points will be exposed.\n\t\t * This entry point should be an {@link @fluidframework/container-definitions#IFluidModule}.\n\t\t */\n\t\tlibrary: string;\n\t};\n}\n\n/**\n * A Fluid package for specification for browser environments\n * @legacy\n * @alpha\n */\nexport interface IFluidBrowserPackage extends IFluidPackage {\n\t/**\n\t * {@inheritDoc @fluidframework/core-interfaces#IFluidPackage.fluid}\n\t */\n\tfluid: {\n\t\t/**\n\t\t * The browser specific package information for this package\n\t\t */\n\t\tbrowser: IFluidBrowserPackageEnvironment;\n\t\t/**\n\t\t * {@inheritDoc @fluidframework/core-interfaces#IFluidPackage.fluid.environment}\n\t\t */\n\t\t[environment: string]: IFluidPackageEnvironment;\n\t};\n}\n\n/**\n * Determines if any object is an IFluidBrowserPackage\n * @param maybePkg - The object to check for compatibility with IFluidBrowserPackage\n * @legacy\n * @alpha\n */\nexport const isFluidBrowserPackage = (\n\tmaybePkg: unknown,\n): maybePkg is Readonly<IFluidBrowserPackage> =>\n\tisFluidPackage(maybePkg) &&\n\ttypeof maybePkg?.fluid?.browser?.umd?.library === \"string\" &&\n\tArray.isArray(maybePkg?.fluid?.browser?.umd?.files);\n"]}
1
+ {"version":3,"file":"browserPackage.js","sourceRoot":"","sources":["../src/browserPackage.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AA8CnD;;;;GAIG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CACpC,QAAiB,EAC4B,EAAE,CAC/C,cAAc,CAAC,QAAQ,CAAC;IACxB,OAAO,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,KAAK,QAAQ;IAC1D,KAAK,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IFluidPackage, IFluidPackageEnvironment } from \"./fluidPackage.js\";\nimport { isFluidPackage } from \"./fluidPackage.js\";\n\n/**\n * A specific Fluid package environment for browsers\n * @legacy @beta\n */\nexport interface IFluidBrowserPackageEnvironment extends IFluidPackageEnvironment {\n\t/**\n\t * The Universal Module Definition (umd) target specifics the scripts necessary for\n\t * loading a packages in a browser environment and finding its entry point.\n\t */\n\tumd: {\n\t\t/**\n\t\t * The bundled js files for loading this package.\n\t\t * These files will be loaded and executed in order.\n\t\t */\n\t\tfiles: string[];\n\n\t\t/**\n\t\t * The global name that the script entry points will be exposed.\n\t\t * This entry point should be an {@link @fluidframework/container-definitions#IFluidModule}.\n\t\t */\n\t\tlibrary: string;\n\t};\n}\n\n/**\n * A Fluid package for specification for browser environments\n * @legacy @beta\n */\nexport interface IFluidBrowserPackage extends IFluidPackage {\n\t/**\n\t * {@inheritDoc @fluidframework/core-interfaces#IFluidPackage.fluid}\n\t */\n\tfluid: {\n\t\t/**\n\t\t * The browser specific package information for this package\n\t\t */\n\t\tbrowser: IFluidBrowserPackageEnvironment;\n\t\t/**\n\t\t * {@inheritDoc @fluidframework/core-interfaces#IFluidPackage.fluid.environment}\n\t\t */\n\t\t[environment: string]: IFluidPackageEnvironment;\n\t};\n}\n\n/**\n * Determines if any object is an IFluidBrowserPackage\n * @param maybePkg - The object to check for compatibility with IFluidBrowserPackage\n * @legacy @beta\n */\nexport const isFluidBrowserPackage = (\n\tmaybePkg: unknown,\n): maybePkg is Readonly<IFluidBrowserPackage> =>\n\tisFluidPackage(maybePkg) &&\n\ttypeof maybePkg?.fluid?.browser?.umd?.library === \"string\" &&\n\tArray.isArray(maybePkg?.fluid?.browser?.umd?.files);\n"]}
package/lib/deltas.d.ts CHANGED
@@ -7,8 +7,7 @@ import type { IClientDetails } from "@fluidframework/driver-definitions";
7
7
  import type { IAnyDriverError, IClientConfiguration, IDocumentMessage, ITokenClaims, ISequencedDocumentMessage, ISignalMessage } from "@fluidframework/driver-definitions/internal";
8
8
  /**
9
9
  * Contract representing the result of a newly established connection to the server for syncing deltas.
10
- * @legacy
11
- * @alpha
10
+ * @legacy @beta
12
11
  */
13
12
  export interface IConnectionDetails {
14
13
  /**
@@ -34,8 +33,7 @@ export interface IConnectionDetails {
34
33
  /**
35
34
  * Contract supporting delivery of outbound messages to the server
36
35
  * @sealed
37
- * @legacy
38
- * @alpha
36
+ * @legacy @beta
39
37
  */
40
38
  export interface IDeltaSender {
41
39
  /**
@@ -46,8 +44,7 @@ export interface IDeltaSender {
46
44
  /**
47
45
  * Events emitted by {@link IDeltaManager}.
48
46
  * @sealed
49
- * @legacy
50
- * @alpha
47
+ * @legacy @beta
51
48
  */
52
49
  export interface IDeltaManagerEvents extends IEvent {
53
50
  /**
@@ -117,8 +114,7 @@ export interface IDeltaManagerEvents extends IEvent {
117
114
  /**
118
115
  * Manages the transmission of ops between the runtime and storage.
119
116
  * @sealed
120
- * @legacy
121
- * @alpha
117
+ * @legacy @beta
122
118
  */
123
119
  export interface IDeltaManager<T, U> extends IEventProvider<IDeltaManagerEvents>, IDeltaSender {
124
120
  /**
@@ -198,8 +194,7 @@ export declare function isIDeltaManagerFull(deltaManager: IDeltaManager<ISequenc
198
194
  /**
199
195
  * Events emitted by {@link IDeltaQueue}.
200
196
  * @sealed
201
- * @legacy
202
- * @alpha
197
+ * @legacy @beta
203
198
  */
204
199
  export interface IDeltaQueueEvents<T> extends IErrorEvent {
205
200
  /**
@@ -240,8 +235,7 @@ export interface IDeltaQueueEvents<T> extends IErrorEvent {
240
235
  /**
241
236
  * Queue of ops to be sent to or processed from storage
242
237
  * @sealed
243
- * @legacy
244
- * @alpha
238
+ * @legacy @beta
245
239
  */
246
240
  export interface IDeltaQueue<T> extends IEventProvider<IDeltaQueueEvents<T>>, IDisposable {
247
241
  /**
@@ -285,8 +279,7 @@ export interface IDeltaQueue<T> extends IEventProvider<IDeltaQueueEvents<T>>, ID
285
279
  }>;
286
280
  }
287
281
  /**
288
- * @legacy
289
- * @alpha
282
+ * @legacy @beta
290
283
  */
291
284
  export type ReadOnlyInfo = {
292
285
  readonly readonly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AGG;IACH,sBAAsB,IAAI,OAAO,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CACvE;AAED;;GAEG;AACH,MAAM,MAAM,YAAY,GACrB;IACA,QAAQ,CAAC,QAAQ,EAAE,KAAK,GAAG,SAAS,CAAC;CACpC,GACD;IACA,QAAQ,CAAC,QAAQ,EAAE,IAAI,CAAC;IAExB;;OAEG;IACH,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IAEzB;;OAEG;IACH,QAAQ,CAAC,WAAW,EAAE,OAAO,GAAG,SAAS,CAAC;IAE1C;;OAEG;IACH,QAAQ,CAAC,WAAW,EAAE,OAAO,CAAC;IAE9B;;;;OAIG;IACH,QAAQ,CAAC,iBAAiB,CAAC,EAAE,MAAM,CAAC;CACnC,CAAC"}
package/lib/deltas.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"deltas.js","sourceRoot":"","sources":["../src/deltas.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAmPH;;;GAGG;AACH,MAAM,UAAU,mBAAmB,CAClC,YAAwE;IAExE,OAAO,SAAS,IAAI,YAAY,IAAI,UAAU,IAAI,YAAY,CAAC;AAChE,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tIDisposable,\n\tIErrorBase,\n\tIErrorEvent,\n\tIEvent,\n\tIEventProvider,\n} from \"@fluidframework/core-interfaces\";\nimport type { IClientDetails } from \"@fluidframework/driver-definitions\";\nimport type {\n\tIAnyDriverError,\n\tIClientConfiguration,\n\tIDocumentMessage,\n\tITokenClaims,\n\tISequencedDocumentMessage,\n\tISignalMessage,\n} from \"@fluidframework/driver-definitions/internal\";\n\n/**\n * Contract representing the result of a newly established connection to the server for syncing deltas.\n * @legacy\n * @alpha\n */\nexport interface IConnectionDetails {\n\t/**\n\t * The client's unique identifier assigned by the service.\n\t *\n\t * @remarks It is not stable across reconnections.\n\t */\n\tclientId: string;\n\n\tclaims: ITokenClaims;\n\tserviceConfiguration: IClientConfiguration;\n\n\t/**\n\t * Last known sequence number to ordering service at the time of connection.\n\t *\n\t * @remarks\n\t *\n\t * It may lag behind the actual last sequence number (quite a bit, if the container is very active),\n\t * but it's the best information the client has to figure out how far behind it is, at least\n\t * for \"read\" connections. \"write\" connections may use the client's own \"join\" op to obtain similar\n\t * information which is likely to be more up-to-date.\n\t */\n\tcheckpointSequenceNumber: number | undefined;\n}\n\n/**\n * Contract supporting delivery of outbound messages to the server\n * @sealed\n * @legacy\n * @alpha\n */\nexport interface IDeltaSender {\n\t/**\n\t * Flush all pending messages through the outbound queue\n\t */\n\tflush(): void;\n}\n\n/**\n * Events emitted by {@link IDeltaManager}.\n * @sealed\n * @legacy\n * @alpha\n */\nexport interface IDeltaManagerEvents extends IEvent {\n\t/**\n\t * @deprecated No replacement API recommended.\n\t */\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\t(event: \"prepareSend\", listener: (messageBuffer: any[]) => void);\n\n\t/**\n\t * @deprecated No replacement API recommended.\n\t */\n\t(event: \"submitOp\", listener: (message: IDocumentMessage) => void);\n\n\t/**\n\t * Emitted immediately after processing an incoming operation (op).\n\t *\n\t * @remarks\n\t *\n\t * Note: this event is not intended for general use.\n\t * Prefer to listen to events on the appropriate ultimate recipients of the ops, rather than listening to the\n\t * ops directly on the {@link IDeltaManager}.\n\t *\n\t * Listener parameters:\n\t *\n\t * - `message`: The op that was processed.\n\t *\n\t * - `processingTime`: The amount of time it took to process the inbound operation (op), expressed in milliseconds.\n\t */\n\t(\n\t\tevent: \"op\",\n\t\tlistener: (message: ISequencedDocumentMessage, processingTime: number) => void,\n\t);\n\n\t/**\n\t * Emitted periodically with latest information on network roundtrip latency\n\t */\n\t(event: \"pong\", listener: (latency: number) => void);\n\n\t/**\n\t * Emitted when the {@link IDeltaManager} completes connecting to the Fluid service.\n\t *\n\t * @remarks\n\t * This occurs once we've received the connect_document_success message from the server,\n\t * and happens prior to the client's join message (if there is a join message).\n\t *\n\t * Listener parameters:\n\t *\n\t * - `details`: Connection metadata.\n\t *\n\t * - `opsBehind`: An estimate of far behind the client is relative to the service in terms of ops.\n\t * Will not be specified if an estimate cannot be determined.\n\t */\n\t(event: \"connect\", listener: (details: IConnectionDetails, opsBehind?: number) => void);\n\n\t/**\n\t * Emitted when the {@link IDeltaManager} becomes disconnected from the Fluid service.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `reason`: Describes the reason for which the delta manager was disconnected.\n\t * - `error` : error if any for the disconnect.\n\t */\n\t(event: \"disconnect\", listener: (reason: string, error?: IAnyDriverError) => void);\n\n\t/**\n\t * Emitted when read/write permissions change.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `readonly`: Whether or not the delta manager is now read-only.\n\t */\n\t(\n\t\tevent: \"readonly\",\n\t\tlistener: (\n\t\t\treadonly: boolean,\n\t\t\treadonlyConnectionReason?: { reason: string; error?: IErrorBase },\n\t\t) => void,\n\t);\n}\n\n/**\n * Manages the transmission of ops between the runtime and storage.\n * @sealed\n * @legacy\n * @alpha\n */\nexport interface IDeltaManager<T, U>\n\textends IEventProvider<IDeltaManagerEvents>,\n\t\tIDeltaSender {\n\t/**\n\t * The queue of inbound delta signals\n\t */\n\treadonly inboundSignal: IDeltaQueue<ISignalMessage>;\n\n\t/**\n\t * The current minimum sequence number\n\t */\n\treadonly minimumSequenceNumber: number;\n\n\t/**\n\t * The last sequence number processed by the delta manager\n\t */\n\treadonly lastSequenceNumber: number;\n\n\t/**\n\t * The last message processed by the delta manager\n\t */\n\treadonly lastMessage: ISequencedDocumentMessage | undefined;\n\n\t/**\n\t * The latest sequence number the delta manager is aware of\n\t */\n\treadonly lastKnownSeqNumber: number;\n\n\t/**\n\t * The initial sequence number set when attaching the op handler\n\t */\n\treadonly initialSequenceNumber: number;\n\n\t/**\n\t * Tells if current connection has checkpoint information.\n\t * I.e. we know how far behind the client was at the time of establishing connection\n\t */\n\treadonly hasCheckpointSequenceNumber: boolean;\n\n\t/**\n\t * Details of client\n\t */\n\treadonly clientDetails: IClientDetails;\n\n\t/**\n\t * Protocol version being used to communicate with the service\n\t */\n\treadonly version: string;\n\n\t/**\n\t * Max message size allowed to the delta manager\n\t */\n\treadonly maxMessageSize: number;\n\n\t/**\n\t * Service configuration provided by the service.\n\t */\n\treadonly serviceConfiguration: IClientConfiguration | undefined;\n\n\t/**\n\t * Flag to indicate whether the client can write or not.\n\t */\n\treadonly active: boolean;\n\n\treadonly readOnlyInfo: ReadOnlyInfo;\n\n\t/**\n\t * Submit a signal to the service to be broadcast to other connected clients, but not persisted\n\t */\n\t// TODO: use `unknown` instead (API breaking)\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\tsubmitSignal(content: any, targetClientId?: string): void;\n}\n\n/**\n * DeltaManager which is used internally by the Fluid layers and not exposed to the end users.\n * @internal\n */\nexport interface IDeltaManagerFull<T = ISequencedDocumentMessage, U = IDocumentMessage>\n\textends IDeltaManager<T, U> {\n\t/**\n\t * The queue of inbound delta messages\n\t */\n\treadonly inbound: IDeltaQueue<T>;\n\n\t/**\n\t * The queue of outbound delta messages\n\t */\n\treadonly outbound: IDeltaQueue<U[]>;\n}\n\n/**\n * Type guard to check if the given deltaManager is of type {@link @fluidframework/container-definitions#IDeltaManagerFull}.\n * @internal\n */\nexport function isIDeltaManagerFull(\n\tdeltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>,\n): deltaManager is IDeltaManagerFull {\n\treturn \"inbound\" in deltaManager && \"outbound\" in deltaManager;\n}\n\n/**\n * Events emitted by {@link IDeltaQueue}.\n * @sealed\n * @legacy\n * @alpha\n */\nexport interface IDeltaQueueEvents<T> extends IErrorEvent {\n\t/**\n\t * Emitted when a task is enqueued.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `task`: The task being enqueued.\n\t */\n\t(event: \"push\", listener: (task: T) => void);\n\n\t/**\n\t * Emitted immediately after processing an enqueued task and removing it from the queue.\n\t *\n\t * @remarks\n\t *\n\t * Note: this event is not intended for general use.\n\t * Prefer to listen to events on the appropriate ultimate recipients of the ops, rather than listening to the\n\t * ops directly on the {@link IDeltaQueue}.\n\t *\n\t * Listener parameters:\n\t *\n\t * - `task`: The task that was processed.\n\t */\n\t(event: \"op\", listener: (task: T) => void);\n\n\t/**\n\t * Emitted when the queue of tasks to process is emptied.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `count`: The number of events (`T`) processed before becoming idle.\n\t *\n\t * - `duration`: The amount of time it took to process elements (in milliseconds).\n\t *\n\t * @see {@link IDeltaQueue.idle}\n\t */\n\t(event: \"idle\", listener: (count: number, duration: number) => void);\n}\n\n/**\n * Queue of ops to be sent to or processed from storage\n * @sealed\n * @legacy\n * @alpha\n */\nexport interface IDeltaQueue<T> extends IEventProvider<IDeltaQueueEvents<T>>, IDisposable {\n\t/**\n\t * Flag indicating whether or not the queue was paused\n\t */\n\tpaused: boolean;\n\n\t/**\n\t * The number of messages remaining in the queue\n\t */\n\tlength: number;\n\n\t/**\n\t * Flag indicating whether or not the queue is idle.\n\t * I.e. there are no remaining messages to processes.\n\t */\n\tidle: boolean;\n\n\t/**\n\t * Pauses processing on the queue.\n\t *\n\t * @returns A promise which resolves when processing has been paused.\n\t */\n\tpause(): Promise<void>;\n\n\t/**\n\t * Resumes processing on the queue\n\t */\n\tresume(): void;\n\n\t/**\n\t * Peeks at the next message in the queue\n\t */\n\tpeek(): T | undefined;\n\n\t/**\n\t * Returns all the items in the queue as an array. Does not remove them from the queue.\n\t */\n\ttoArray(): T[];\n\n\t/**\n\t * returns number of ops processed and time it took to process these ops.\n\t * Zeros if queue did not process anything (had no messages, was paused or had hit an error before)\n\t */\n\twaitTillProcessingDone(): Promise<{ count: number; duration: number }>;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport type ReadOnlyInfo =\n\t| {\n\t\t\treadonly readonly: false | undefined;\n\t }\n\t| {\n\t\t\treadonly readonly: true;\n\n\t\t\t/**\n\t\t\t * Read-only because `forceReadOnly()` was called.\n\t\t\t */\n\t\t\treadonly forced: boolean;\n\n\t\t\t/**\n\t\t\t * Read-only because client does not have write permissions for document.\n\t\t\t */\n\t\t\treadonly permissions: boolean | undefined;\n\n\t\t\t/**\n\t\t\t * Read-only with no delta stream connection.\n\t\t\t */\n\t\t\treadonly storageOnly: boolean;\n\n\t\t\t/**\n\t\t\t * Extra info on why connection to delta stream is not possible.\n\t\t\t *\n\t\t\t * @remarks This info might be provided if {@link ReadOnlyInfo.storageOnly} is set to `true`.\n\t\t\t */\n\t\t\treadonly storageOnlyReason?: string;\n\t };\n"]}
1
+ {"version":3,"file":"deltas.js","sourceRoot":"","sources":["../src/deltas.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA+OH;;;GAGG;AACH,MAAM,UAAU,mBAAmB,CAClC,YAAwE;IAExE,OAAO,SAAS,IAAI,YAAY,IAAI,UAAU,IAAI,YAAY,CAAC;AAChE,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tIDisposable,\n\tIErrorBase,\n\tIErrorEvent,\n\tIEvent,\n\tIEventProvider,\n} from \"@fluidframework/core-interfaces\";\nimport type { IClientDetails } from \"@fluidframework/driver-definitions\";\nimport type {\n\tIAnyDriverError,\n\tIClientConfiguration,\n\tIDocumentMessage,\n\tITokenClaims,\n\tISequencedDocumentMessage,\n\tISignalMessage,\n} from \"@fluidframework/driver-definitions/internal\";\n\n/**\n * Contract representing the result of a newly established connection to the server for syncing deltas.\n * @legacy @beta\n */\nexport interface IConnectionDetails {\n\t/**\n\t * The client's unique identifier assigned by the service.\n\t *\n\t * @remarks It is not stable across reconnections.\n\t */\n\tclientId: string;\n\n\tclaims: ITokenClaims;\n\tserviceConfiguration: IClientConfiguration;\n\n\t/**\n\t * Last known sequence number to ordering service at the time of connection.\n\t *\n\t * @remarks\n\t *\n\t * It may lag behind the actual last sequence number (quite a bit, if the container is very active),\n\t * but it's the best information the client has to figure out how far behind it is, at least\n\t * for \"read\" connections. \"write\" connections may use the client's own \"join\" op to obtain similar\n\t * information which is likely to be more up-to-date.\n\t */\n\tcheckpointSequenceNumber: number | undefined;\n}\n\n/**\n * Contract supporting delivery of outbound messages to the server\n * @sealed\n * @legacy @beta\n */\nexport interface IDeltaSender {\n\t/**\n\t * Flush all pending messages through the outbound queue\n\t */\n\tflush(): void;\n}\n\n/**\n * Events emitted by {@link IDeltaManager}.\n * @sealed\n * @legacy @beta\n */\nexport interface IDeltaManagerEvents extends IEvent {\n\t/**\n\t * @deprecated No replacement API recommended.\n\t */\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\t(event: \"prepareSend\", listener: (messageBuffer: any[]) => void);\n\n\t/**\n\t * @deprecated No replacement API recommended.\n\t */\n\t(event: \"submitOp\", listener: (message: IDocumentMessage) => void);\n\n\t/**\n\t * Emitted immediately after processing an incoming operation (op).\n\t *\n\t * @remarks\n\t *\n\t * Note: this event is not intended for general use.\n\t * Prefer to listen to events on the appropriate ultimate recipients of the ops, rather than listening to the\n\t * ops directly on the {@link IDeltaManager}.\n\t *\n\t * Listener parameters:\n\t *\n\t * - `message`: The op that was processed.\n\t *\n\t * - `processingTime`: The amount of time it took to process the inbound operation (op), expressed in milliseconds.\n\t */\n\t(\n\t\tevent: \"op\",\n\t\tlistener: (message: ISequencedDocumentMessage, processingTime: number) => void,\n\t);\n\n\t/**\n\t * Emitted periodically with latest information on network roundtrip latency\n\t */\n\t(event: \"pong\", listener: (latency: number) => void);\n\n\t/**\n\t * Emitted when the {@link IDeltaManager} completes connecting to the Fluid service.\n\t *\n\t * @remarks\n\t * This occurs once we've received the connect_document_success message from the server,\n\t * and happens prior to the client's join message (if there is a join message).\n\t *\n\t * Listener parameters:\n\t *\n\t * - `details`: Connection metadata.\n\t *\n\t * - `opsBehind`: An estimate of far behind the client is relative to the service in terms of ops.\n\t * Will not be specified if an estimate cannot be determined.\n\t */\n\t(event: \"connect\", listener: (details: IConnectionDetails, opsBehind?: number) => void);\n\n\t/**\n\t * Emitted when the {@link IDeltaManager} becomes disconnected from the Fluid service.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `reason`: Describes the reason for which the delta manager was disconnected.\n\t * - `error` : error if any for the disconnect.\n\t */\n\t(event: \"disconnect\", listener: (reason: string, error?: IAnyDriverError) => void);\n\n\t/**\n\t * Emitted when read/write permissions change.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `readonly`: Whether or not the delta manager is now read-only.\n\t */\n\t(\n\t\tevent: \"readonly\",\n\t\tlistener: (\n\t\t\treadonly: boolean,\n\t\t\treadonlyConnectionReason?: { reason: string; error?: IErrorBase },\n\t\t) => void,\n\t);\n}\n\n/**\n * Manages the transmission of ops between the runtime and storage.\n * @sealed\n * @legacy @beta\n */\nexport interface IDeltaManager<T, U>\n\textends IEventProvider<IDeltaManagerEvents>,\n\t\tIDeltaSender {\n\t/**\n\t * The queue of inbound delta signals\n\t */\n\treadonly inboundSignal: IDeltaQueue<ISignalMessage>;\n\n\t/**\n\t * The current minimum sequence number\n\t */\n\treadonly minimumSequenceNumber: number;\n\n\t/**\n\t * The last sequence number processed by the delta manager\n\t */\n\treadonly lastSequenceNumber: number;\n\n\t/**\n\t * The last message processed by the delta manager\n\t */\n\treadonly lastMessage: ISequencedDocumentMessage | undefined;\n\n\t/**\n\t * The latest sequence number the delta manager is aware of\n\t */\n\treadonly lastKnownSeqNumber: number;\n\n\t/**\n\t * The initial sequence number set when attaching the op handler\n\t */\n\treadonly initialSequenceNumber: number;\n\n\t/**\n\t * Tells if current connection has checkpoint information.\n\t * I.e. we know how far behind the client was at the time of establishing connection\n\t */\n\treadonly hasCheckpointSequenceNumber: boolean;\n\n\t/**\n\t * Details of client\n\t */\n\treadonly clientDetails: IClientDetails;\n\n\t/**\n\t * Protocol version being used to communicate with the service\n\t */\n\treadonly version: string;\n\n\t/**\n\t * Max message size allowed to the delta manager\n\t */\n\treadonly maxMessageSize: number;\n\n\t/**\n\t * Service configuration provided by the service.\n\t */\n\treadonly serviceConfiguration: IClientConfiguration | undefined;\n\n\t/**\n\t * Flag to indicate whether the client can write or not.\n\t */\n\treadonly active: boolean;\n\n\treadonly readOnlyInfo: ReadOnlyInfo;\n\n\t/**\n\t * Submit a signal to the service to be broadcast to other connected clients, but not persisted\n\t */\n\t// TODO: use `unknown` instead (API breaking)\n\t// eslint-disable-next-line @typescript-eslint/no-explicit-any\n\tsubmitSignal(content: any, targetClientId?: string): void;\n}\n\n/**\n * DeltaManager which is used internally by the Fluid layers and not exposed to the end users.\n * @internal\n */\nexport interface IDeltaManagerFull<T = ISequencedDocumentMessage, U = IDocumentMessage>\n\textends IDeltaManager<T, U> {\n\t/**\n\t * The queue of inbound delta messages\n\t */\n\treadonly inbound: IDeltaQueue<T>;\n\n\t/**\n\t * The queue of outbound delta messages\n\t */\n\treadonly outbound: IDeltaQueue<U[]>;\n}\n\n/**\n * Type guard to check if the given deltaManager is of type {@link @fluidframework/container-definitions#IDeltaManagerFull}.\n * @internal\n */\nexport function isIDeltaManagerFull(\n\tdeltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>,\n): deltaManager is IDeltaManagerFull {\n\treturn \"inbound\" in deltaManager && \"outbound\" in deltaManager;\n}\n\n/**\n * Events emitted by {@link IDeltaQueue}.\n * @sealed\n * @legacy @beta\n */\nexport interface IDeltaQueueEvents<T> extends IErrorEvent {\n\t/**\n\t * Emitted when a task is enqueued.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `task`: The task being enqueued.\n\t */\n\t(event: \"push\", listener: (task: T) => void);\n\n\t/**\n\t * Emitted immediately after processing an enqueued task and removing it from the queue.\n\t *\n\t * @remarks\n\t *\n\t * Note: this event is not intended for general use.\n\t * Prefer to listen to events on the appropriate ultimate recipients of the ops, rather than listening to the\n\t * ops directly on the {@link IDeltaQueue}.\n\t *\n\t * Listener parameters:\n\t *\n\t * - `task`: The task that was processed.\n\t */\n\t(event: \"op\", listener: (task: T) => void);\n\n\t/**\n\t * Emitted when the queue of tasks to process is emptied.\n\t *\n\t * @remarks Listener parameters:\n\t *\n\t * - `count`: The number of events (`T`) processed before becoming idle.\n\t *\n\t * - `duration`: The amount of time it took to process elements (in milliseconds).\n\t *\n\t * @see {@link IDeltaQueue.idle}\n\t */\n\t(event: \"idle\", listener: (count: number, duration: number) => void);\n}\n\n/**\n * Queue of ops to be sent to or processed from storage\n * @sealed\n * @legacy @beta\n */\nexport interface IDeltaQueue<T> extends IEventProvider<IDeltaQueueEvents<T>>, IDisposable {\n\t/**\n\t * Flag indicating whether or not the queue was paused\n\t */\n\tpaused: boolean;\n\n\t/**\n\t * The number of messages remaining in the queue\n\t */\n\tlength: number;\n\n\t/**\n\t * Flag indicating whether or not the queue is idle.\n\t * I.e. there are no remaining messages to processes.\n\t */\n\tidle: boolean;\n\n\t/**\n\t * Pauses processing on the queue.\n\t *\n\t * @returns A promise which resolves when processing has been paused.\n\t */\n\tpause(): Promise<void>;\n\n\t/**\n\t * Resumes processing on the queue\n\t */\n\tresume(): void;\n\n\t/**\n\t * Peeks at the next message in the queue\n\t */\n\tpeek(): T | undefined;\n\n\t/**\n\t * Returns all the items in the queue as an array. Does not remove them from the queue.\n\t */\n\ttoArray(): T[];\n\n\t/**\n\t * returns number of ops processed and time it took to process these ops.\n\t * Zeros if queue did not process anything (had no messages, was paused or had hit an error before)\n\t */\n\twaitTillProcessingDone(): Promise<{ count: number; duration: number }>;\n}\n\n/**\n * @legacy @beta\n */\nexport type ReadOnlyInfo =\n\t| {\n\t\t\treadonly readonly: false | undefined;\n\t }\n\t| {\n\t\t\treadonly readonly: true;\n\n\t\t\t/**\n\t\t\t * Read-only because `forceReadOnly()` was called.\n\t\t\t */\n\t\t\treadonly forced: boolean;\n\n\t\t\t/**\n\t\t\t * Read-only because client does not have write permissions for document.\n\t\t\t */\n\t\t\treadonly permissions: boolean | undefined;\n\n\t\t\t/**\n\t\t\t * Read-only with no delta stream connection.\n\t\t\t */\n\t\t\treadonly storageOnly: boolean;\n\n\t\t\t/**\n\t\t\t * Extra info on why connection to delta stream is not possible.\n\t\t\t *\n\t\t\t * @remarks This info might be provided if {@link ReadOnlyInfo.storageOnly} is set to `true`.\n\t\t\t */\n\t\t\treadonly storageOnlyReason?: string;\n\t };\n"]}
package/lib/error.d.ts CHANGED
@@ -5,8 +5,7 @@
5
5
  import type { IErrorBase } from "@fluidframework/core-interfaces";
6
6
  /**
7
7
  * Different error types the ClientSession may report out to the Host.
8
- * @legacy
9
- * @alpha
8
+ * @legacy @beta
10
9
  */
11
10
  export declare const ContainerErrorTypes: {
12
11
  /**
@@ -22,14 +21,12 @@ export declare const ContainerErrorTypes: {
22
21
  };
23
22
  /**
24
23
  * {@inheritDoc (ContainerErrorTypes:variable)}
25
- * @legacy
26
- * @alpha
24
+ * @legacy @beta
27
25
  */
28
26
  export type ContainerErrorTypes = (typeof ContainerErrorTypes)[keyof typeof ContainerErrorTypes];
29
27
  /**
30
28
  * Represents warnings raised on container.
31
- * @legacy
32
- * @alpha
29
+ * @legacy @beta
33
30
  */
34
31
  export interface ContainerWarning extends IErrorBase {
35
32
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../src/error.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAGlE;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;IAE/B;;;OAGG;;;;;;;CAEM,CAAC;AAEX;;;;GAIG;AACH,MAAM,MAAM,mBAAmB,GAC9B,CAAC,OAAO,mBAAmB,CAAC,CAAC,MAAM,OAAO,mBAAmB,CAAC,CAAC;AAEhE;;;;GAIG;AACH,MAAM,WAAW,gBAAiB,SAAQ,UAAU;IACnD;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,uBAAuB,GAAG,UAAU,CAAC"}
1
+ {"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../src/error.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAGlE;;;GAGG;AACH,eAAO,MAAM,mBAAmB;IAE/B;;;OAGG;;;;;;;CAEM,CAAC;AAEX;;;GAGG;AACH,MAAM,MAAM,mBAAmB,GAC9B,CAAC,OAAO,mBAAmB,CAAC,CAAC,MAAM,OAAO,mBAAmB,CAAC,CAAC;AAEhE;;;GAGG;AACH,MAAM,WAAW,gBAAiB,SAAQ,UAAU;IACnD;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,uBAAuB,GAAG,UAAU,CAAC"}
package/lib/error.js CHANGED
@@ -5,8 +5,7 @@
5
5
  import { FluidErrorTypes } from "@fluidframework/core-interfaces/internal";
6
6
  /**
7
7
  * Different error types the ClientSession may report out to the Host.
8
- * @legacy
9
- * @alpha
8
+ * @legacy @beta
10
9
  */
11
10
  export const ContainerErrorTypes = {
12
11
  ...FluidErrorTypes,
package/lib/error.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"error.js","sourceRoot":"","sources":["../src/error.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EAAE,eAAe,EAAE,MAAM,0CAA0C,CAAC;AAE3E;;;;GAIG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG;IAClC,GAAG,eAAe;IAClB;;;OAGG;IACH,yBAAyB,EAAE,2BAA2B;CAC7C,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IErrorBase } from \"@fluidframework/core-interfaces\";\nimport { FluidErrorTypes } from \"@fluidframework/core-interfaces/internal\";\n\n/**\n * Different error types the ClientSession may report out to the Host.\n * @legacy\n * @alpha\n */\nexport const ContainerErrorTypes = {\n\t...FluidErrorTypes,\n\t/**\n\t * Error indicating an client session has expired. Currently this only happens when GC is allowed on a document and\n\t * aids in safely deleting unused objects.\n\t */\n\tclientSessionExpiredError: \"clientSessionExpiredError\",\n} as const;\n\n/**\n * {@inheritDoc (ContainerErrorTypes:variable)}\n * @legacy\n * @alpha\n */\nexport type ContainerErrorTypes =\n\t(typeof ContainerErrorTypes)[keyof typeof ContainerErrorTypes];\n\n/**\n * Represents warnings raised on container.\n * @legacy\n * @alpha\n */\nexport interface ContainerWarning extends IErrorBase {\n\t/**\n\t * Whether this error has already been logged. Used to avoid logging errors twice.\n\t *\n\t * @defaultValue `false`\n\t */\n\tlogged?: boolean;\n}\n\n/**\n * Represents errors raised on container.\n *\n * @remarks\n *\n * The following are commonly thrown error types, but `errorType` could be any string.\n *\n * - {@link @fluidframework/core-interfaces#FluidErrorTypes}\n *\n * - {@link @fluidframework/driver-definitions#(DriverErrorTypes:variable)}\n *\n * @public\n */\nexport type ICriticalContainerError = IErrorBase;\n"]}
1
+ {"version":3,"file":"error.js","sourceRoot":"","sources":["../src/error.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EAAE,eAAe,EAAE,MAAM,0CAA0C,CAAC;AAE3E;;;GAGG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG;IAClC,GAAG,eAAe;IAClB;;;OAGG;IACH,yBAAyB,EAAE,2BAA2B;CAC7C,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IErrorBase } from \"@fluidframework/core-interfaces\";\nimport { FluidErrorTypes } from \"@fluidframework/core-interfaces/internal\";\n\n/**\n * Different error types the ClientSession may report out to the Host.\n * @legacy @beta\n */\nexport const ContainerErrorTypes = {\n\t...FluidErrorTypes,\n\t/**\n\t * Error indicating an client session has expired. Currently this only happens when GC is allowed on a document and\n\t * aids in safely deleting unused objects.\n\t */\n\tclientSessionExpiredError: \"clientSessionExpiredError\",\n} as const;\n\n/**\n * {@inheritDoc (ContainerErrorTypes:variable)}\n * @legacy @beta\n */\nexport type ContainerErrorTypes =\n\t(typeof ContainerErrorTypes)[keyof typeof ContainerErrorTypes];\n\n/**\n * Represents warnings raised on container.\n * @legacy @beta\n */\nexport interface ContainerWarning extends IErrorBase {\n\t/**\n\t * Whether this error has already been logged. Used to avoid logging errors twice.\n\t *\n\t * @defaultValue `false`\n\t */\n\tlogged?: boolean;\n}\n\n/**\n * Represents errors raised on container.\n *\n * @remarks\n *\n * The following are commonly thrown error types, but `errorType` could be any string.\n *\n * - {@link @fluidframework/core-interfaces#FluidErrorTypes}\n *\n * - {@link @fluidframework/driver-definitions#(DriverErrorTypes:variable)}\n *\n * @public\n */\nexport type ICriticalContainerError = IErrorBase;\n"]}
@@ -6,8 +6,7 @@ import type { FluidObject } from "@fluidframework/core-interfaces";
6
6
  import type { IProvideFluidCodeDetailsComparer } from "./fluidPackage.js";
7
7
  import type { IRuntimeFactory } from "./runtime.js";
8
8
  /**
9
- * @legacy
10
- * @alpha
9
+ * @legacy @beta
11
10
  */
12
11
  export interface IFluidModule {
13
12
  fluidExport: FluidObject<IRuntimeFactory & IProvideFluidCodeDetailsComparer>;
@@ -1 +1 @@
1
- {"version":3,"file":"fluidModule.d.ts","sourceRoot":"","sources":["../src/fluidModule.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAEnE,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,mBAAmB,CAAC;AAC1E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC5B,WAAW,EAAE,WAAW,CAAC,eAAe,GAAG,gCAAgC,CAAC,CAAC;CAC7E"}
1
+ {"version":3,"file":"fluidModule.d.ts","sourceRoot":"","sources":["../src/fluidModule.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAEnE,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,mBAAmB,CAAC;AAC1E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD;;GAEG;AACH,MAAM,WAAW,YAAY;IAC5B,WAAW,EAAE,WAAW,CAAC,eAAe,GAAG,gCAAgC,CAAC,CAAC;CAC7E"}
@@ -1 +1 @@
1
- {"version":3,"file":"fluidModule.js","sourceRoot":"","sources":["../src/fluidModule.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { FluidObject } from \"@fluidframework/core-interfaces\";\n\nimport type { IProvideFluidCodeDetailsComparer } from \"./fluidPackage.js\";\nimport type { IRuntimeFactory } from \"./runtime.js\";\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IFluidModule {\n\tfluidExport: FluidObject<IRuntimeFactory & IProvideFluidCodeDetailsComparer>;\n}\n"]}
1
+ {"version":3,"file":"fluidModule.js","sourceRoot":"","sources":["../src/fluidModule.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { FluidObject } from \"@fluidframework/core-interfaces\";\n\nimport type { IProvideFluidCodeDetailsComparer } from \"./fluidPackage.js\";\nimport type { IRuntimeFactory } from \"./runtime.js\";\n\n/**\n * @legacy @beta\n */\nexport interface IFluidModule {\n\tfluidExport: FluidObject<IRuntimeFactory & IProvideFluidCodeDetailsComparer>;\n}\n"]}
@@ -4,8 +4,7 @@
4
4
  */
5
5
  /**
6
6
  * Specifies an environment on Fluid property of a IFluidPackage.
7
- * @legacy
8
- * @alpha
7
+ * @legacy @beta
9
8
  */
10
9
  export interface IFluidPackageEnvironment {
11
10
  /**
@@ -32,8 +31,7 @@ export interface IFluidPackageEnvironment {
32
31
  * While compatible with the npm package format it is not necessary that that package is an
33
32
  * npm package:
34
33
  * {@link https://stackoverflow.com/questions/10065564/add-custom-metadata-or-config-to-package-json-is-it-valid}
35
- * @legacy
36
- * @alpha
34
+ * @legacy @beta
37
35
  */
38
36
  export interface IFluidPackage {
39
37
  /**
@@ -60,22 +58,19 @@ export interface IFluidPackage {
60
58
  /**
61
59
  * Check if the package.json defines a Fluid package
62
60
  * @param pkg - the package json data to check if it is a Fluid package.
63
- * @legacy
64
- * @alpha
61
+ * @legacy @beta
65
62
  */
66
63
  export declare const isFluidPackage: (pkg: unknown) => pkg is Readonly<IFluidPackage>;
67
64
  /**
68
65
  * Package manager configuration. Provides a key value mapping of config values
69
- * @legacy
70
- * @alpha
66
+ * @legacy @beta
71
67
  */
72
68
  export interface IFluidCodeDetailsConfig {
73
69
  readonly [key: string]: string;
74
70
  }
75
71
  /**
76
72
  * Data structure used to describe the code to load on the Fluid document
77
- * @legacy
78
- * @alpha
73
+ * @legacy @beta
79
74
  */
80
75
  export interface IFluidCodeDetails {
81
76
  /**
@@ -97,21 +92,18 @@ export interface IFluidCodeDetails {
97
92
  */
98
93
  export declare const isFluidCodeDetails: (details: unknown) => details is Readonly<IFluidCodeDetails>;
99
94
  /**
100
- * @legacy
101
- * @alpha
95
+ * @legacy @beta
102
96
  */
103
97
  export declare const IFluidCodeDetailsComparer: keyof IProvideFluidCodeDetailsComparer;
104
98
  /**
105
- * @legacy
106
- * @alpha
99
+ * @legacy @beta
107
100
  */
108
101
  export interface IProvideFluidCodeDetailsComparer {
109
102
  readonly IFluidCodeDetailsComparer: IFluidCodeDetailsComparer;
110
103
  }
111
104
  /**
112
105
  * Provides capability to compare Fluid code details.
113
- * @legacy
114
- * @alpha
106
+ * @legacy @beta
115
107
  */
116
108
  export interface IFluidCodeDetailsComparer extends IProvideFluidCodeDetailsComparer {
117
109
  /**
@@ -1 +1 @@
1
- {"version":3,"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G;AACH,eAAO,MAAM,kBAAkB,YACrB,OAAO,2CAShB,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,yBAAyB,EAAE,MAAM,gCAClB,CAAC;AAE7B;;GAEG;AACH,MAAM,WAAW,gCAAgC;IAChD,QAAQ,CAAC,yBAAyB,EAAE,yBAAyB,CAAC;CAC9D;AAED;;;GAGG;AACH,MAAM,WAAW,yBAA0B,SAAQ,gCAAgC;IAClF;;;;;OAKG;IACH,SAAS,CAAC,SAAS,EAAE,iBAAiB,EAAE,UAAU,EAAE,iBAAiB,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAEzF;;;;;;;;;;;;;OAaG;IACH,OAAO,CAAC,CAAC,EAAE,iBAAiB,EAAE,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;CACjF"}
@@ -5,8 +5,7 @@
5
5
  /**
6
6
  * Check if the package.json defines a Fluid package
7
7
  * @param pkg - the package json data to check if it is a Fluid package.
8
- * @legacy
9
- * @alpha
8
+ * @legacy @beta
10
9
  */
11
10
  export const isFluidPackage = (pkg) => typeof pkg === "object" &&
12
11
  typeof pkg?.name === "string" &&
@@ -23,8 +22,7 @@ export const isFluidCodeDetails = (details) => {
23
22
  (maybeCodeDetails?.config === undefined || typeof maybeCodeDetails?.config === "object"));
24
23
  };
25
24
  /**
26
- * @legacy
27
- * @alpha
25
+ * @legacy @beta
28
26
  */
29
27
  export const IFluidCodeDetailsComparer = "IFluidCodeDetailsComparer";
30
28
  //# sourceMappingURL=fluidPackage.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"fluidPackage.js","sourceRoot":"","sources":["../src/fluidPackage.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA8DH;;;;;GAKG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,GAAY,EAAkC,EAAE,CAC9E,OAAO,GAAG,KAAK,QAAQ;IACvB,OAAQ,GAA8B,EAAE,IAAI,KAAK,QAAQ;IACzD,OAAQ,GAA8B,EAAE,KAAK,KAAK,QAAQ,CAAC;AAgC5D;;;GAGG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CACjC,OAAgB,EACyB,EAAE;IAC3C,MAAM,gBAAgB,GAAG,OAAiD,CAAC;IAC3E,OAAO,CACN,OAAO,gBAAgB,KAAK,QAAQ;QACpC,CAAC,OAAO,gBAAgB,EAAE,OAAO,KAAK,QAAQ;YAC7C,cAAc,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;QAC3C,CAAC,gBAAgB,EAAE,MAAM,KAAK,SAAS,IAAI,OAAO,gBAAgB,EAAE,MAAM,KAAK,QAAQ,CAAC,CACxF,CAAC;AACH,CAAC,CAAC;AAEF;;;GAGG;AACH,MAAM,CAAC,MAAM,yBAAyB,GACrC,2BAA2B,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Specifies an environment on Fluid property of a IFluidPackage.\n * @legacy\n * @alpha\n */\nexport interface IFluidPackageEnvironment {\n\t/**\n\t * The name of the target. For a browser environment, this could be umd for scripts\n\t * or css for styles.\n\t */\n\t[target: string]:\n\t\t| undefined\n\t\t| {\n\t\t\t\t/**\n\t\t\t\t * List of files for the target. These can be relative or absolute.\n\t\t\t\t * The code loader should resolve relative paths, and validate all\n\t\t\t\t * full urls.\n\t\t\t\t */\n\t\t\t\tfiles: string[];\n\n\t\t\t\t/**\n\t\t\t\t * General access for extended fields as specific usages will\n\t\t\t\t * likely have additional infornamation like a definition\n\t\t\t\t * of Library, the entrypoint for umd packages.\n\t\t\t\t */\n\t\t\t\t[key: string]: unknown;\n\t\t };\n}\n\n/**\n * Fluid-specific properties expected on a package to be loaded by the code loader.\n * While compatible with the npm package format it is not necessary that that package is an\n * npm package:\n * {@link https://stackoverflow.com/questions/10065564/add-custom-metadata-or-config-to-package-json-is-it-valid}\n * @legacy\n * @alpha\n */\nexport interface IFluidPackage {\n\t/**\n\t * The name of the package that this code represnets\n\t */\n\tname: string;\n\t/**\n\t * This object represents the Fluid specific properties of the package\n\t */\n\tfluid: {\n\t\t/**\n\t\t * The name of the of the environment. This should be something like browser, or node\n\t\t * and contain the necessary targets for loading this code in that environment.\n\t\t */\n\t\t[environment: string]: undefined | IFluidPackageEnvironment;\n\t};\n\t/**\n\t * General access for extended fields as specific usages will\n\t * likely have additional infornamation like a definition of\n\t * compatible versions, or deployment information like rings or rollouts.\n\t */\n\t[key: string]: unknown;\n}\n\n/**\n * Check if the package.json defines a Fluid package\n * @param pkg - the package json data to check if it is a Fluid package.\n * @legacy\n * @alpha\n */\nexport const isFluidPackage = (pkg: unknown): pkg is Readonly<IFluidPackage> =>\n\ttypeof pkg === \"object\" &&\n\ttypeof (pkg as Partial<IFluidPackage>)?.name === \"string\" &&\n\ttypeof (pkg as Partial<IFluidPackage>)?.fluid === \"object\";\n\n/**\n * Package manager configuration. Provides a key value mapping of config values\n * @legacy\n * @alpha\n */\nexport interface IFluidCodeDetailsConfig {\n\treadonly [key: string]: string;\n}\n\n/**\n * Data structure used to describe the code to load on the Fluid document\n * @legacy\n * @alpha\n */\nexport interface IFluidCodeDetails {\n\t/**\n\t * The code package to be used on the Fluid document. This is either the package name which will be loaded\n\t * from a package manager. Or the expanded Fluid package.\n\t */\n\treadonly package: string | Readonly<IFluidPackage>;\n\n\t/**\n\t * Configuration details. This includes links to the package manager and base CDNs.\n\t *\n\t * @remarks This is strictly consumer-defined data.\n\t * Its contents and semantics (including whether or not this data is present) are completely up to the consumer.\n\t */\n\treadonly config?: IFluidCodeDetailsConfig;\n}\n\n/**\n * Determines if any object is an IFluidCodeDetails\n * @internal\n */\nexport const isFluidCodeDetails = (\n\tdetails: unknown,\n): details is Readonly<IFluidCodeDetails> => {\n\tconst maybeCodeDetails = details as Partial<IFluidCodeDetails> | undefined;\n\treturn (\n\t\ttypeof maybeCodeDetails === \"object\" &&\n\t\t(typeof maybeCodeDetails?.package === \"string\" ||\n\t\t\tisFluidPackage(maybeCodeDetails?.package)) &&\n\t\t(maybeCodeDetails?.config === undefined || typeof maybeCodeDetails?.config === \"object\")\n\t);\n};\n\n/**\n * @legacy\n * @alpha\n */\nexport const IFluidCodeDetailsComparer: keyof IProvideFluidCodeDetailsComparer =\n\t\"IFluidCodeDetailsComparer\";\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IProvideFluidCodeDetailsComparer {\n\treadonly IFluidCodeDetailsComparer: IFluidCodeDetailsComparer;\n}\n\n/**\n * Provides capability to compare Fluid code details.\n * @legacy\n * @alpha\n */\nexport interface IFluidCodeDetailsComparer extends IProvideFluidCodeDetailsComparer {\n\t/**\n\t * Determines if the `candidate` code details satisfy the constraints specified in `constraint` code details.\n\t *\n\t * Similar semantics to:\n\t * {@link https://github.com/npm/node-semver#usage}\n\t */\n\tsatisfies(candidate: IFluidCodeDetails, constraint: IFluidCodeDetails): Promise<boolean>;\n\n\t/**\n\t * Return a number representing the ascending sort order of the `a` and `b` code details:\n\t *\n\t * - `< 0` if `a < b`.\n\t *\n\t * - `= 0` if `a === b`.\n\t *\n\t * - `> 0` if `a > b`.\n\t *\n\t * - `undefined` if `a` is not comparable to `b`.\n\t *\n\t * Similar semantics to:\n\t * {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#description | Array.sort}\n\t */\n\tcompare(a: IFluidCodeDetails, b: IFluidCodeDetails): Promise<number | undefined>;\n}\n"]}
1
+ {"version":3,"file":"fluidPackage.js","sourceRoot":"","sources":["../src/fluidPackage.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA4DH;;;;GAIG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,GAAY,EAAkC,EAAE,CAC9E,OAAO,GAAG,KAAK,QAAQ;IACvB,OAAQ,GAA8B,EAAE,IAAI,KAAK,QAAQ;IACzD,OAAQ,GAA8B,EAAE,KAAK,KAAK,QAAQ,CAAC;AA8B5D;;;GAGG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CACjC,OAAgB,EACyB,EAAE;IAC3C,MAAM,gBAAgB,GAAG,OAAiD,CAAC;IAC3E,OAAO,CACN,OAAO,gBAAgB,KAAK,QAAQ;QACpC,CAAC,OAAO,gBAAgB,EAAE,OAAO,KAAK,QAAQ;YAC7C,cAAc,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;QAC3C,CAAC,gBAAgB,EAAE,MAAM,KAAK,SAAS,IAAI,OAAO,gBAAgB,EAAE,MAAM,KAAK,QAAQ,CAAC,CACxF,CAAC;AACH,CAAC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,yBAAyB,GACrC,2BAA2B,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Specifies an environment on Fluid property of a IFluidPackage.\n * @legacy @beta\n */\nexport interface IFluidPackageEnvironment {\n\t/**\n\t * The name of the target. For a browser environment, this could be umd for scripts\n\t * or css for styles.\n\t */\n\t[target: string]:\n\t\t| undefined\n\t\t| {\n\t\t\t\t/**\n\t\t\t\t * List of files for the target. These can be relative or absolute.\n\t\t\t\t * The code loader should resolve relative paths, and validate all\n\t\t\t\t * full urls.\n\t\t\t\t */\n\t\t\t\tfiles: string[];\n\n\t\t\t\t/**\n\t\t\t\t * General access for extended fields as specific usages will\n\t\t\t\t * likely have additional infornamation like a definition\n\t\t\t\t * of Library, the entrypoint for umd packages.\n\t\t\t\t */\n\t\t\t\t[key: string]: unknown;\n\t\t };\n}\n\n/**\n * Fluid-specific properties expected on a package to be loaded by the code loader.\n * While compatible with the npm package format it is not necessary that that package is an\n * npm package:\n * {@link https://stackoverflow.com/questions/10065564/add-custom-metadata-or-config-to-package-json-is-it-valid}\n * @legacy @beta\n */\nexport interface IFluidPackage {\n\t/**\n\t * The name of the package that this code represnets\n\t */\n\tname: string;\n\t/**\n\t * This object represents the Fluid specific properties of the package\n\t */\n\tfluid: {\n\t\t/**\n\t\t * The name of the of the environment. This should be something like browser, or node\n\t\t * and contain the necessary targets for loading this code in that environment.\n\t\t */\n\t\t[environment: string]: undefined | IFluidPackageEnvironment;\n\t};\n\t/**\n\t * General access for extended fields as specific usages will\n\t * likely have additional infornamation like a definition of\n\t * compatible versions, or deployment information like rings or rollouts.\n\t */\n\t[key: string]: unknown;\n}\n\n/**\n * Check if the package.json defines a Fluid package\n * @param pkg - the package json data to check if it is a Fluid package.\n * @legacy @beta\n */\nexport const isFluidPackage = (pkg: unknown): pkg is Readonly<IFluidPackage> =>\n\ttypeof pkg === \"object\" &&\n\ttypeof (pkg as Partial<IFluidPackage>)?.name === \"string\" &&\n\ttypeof (pkg as Partial<IFluidPackage>)?.fluid === \"object\";\n\n/**\n * Package manager configuration. Provides a key value mapping of config values\n * @legacy @beta\n */\nexport interface IFluidCodeDetailsConfig {\n\treadonly [key: string]: string;\n}\n\n/**\n * Data structure used to describe the code to load on the Fluid document\n * @legacy @beta\n */\nexport interface IFluidCodeDetails {\n\t/**\n\t * The code package to be used on the Fluid document. This is either the package name which will be loaded\n\t * from a package manager. Or the expanded Fluid package.\n\t */\n\treadonly package: string | Readonly<IFluidPackage>;\n\n\t/**\n\t * Configuration details. This includes links to the package manager and base CDNs.\n\t *\n\t * @remarks This is strictly consumer-defined data.\n\t * Its contents and semantics (including whether or not this data is present) are completely up to the consumer.\n\t */\n\treadonly config?: IFluidCodeDetailsConfig;\n}\n\n/**\n * Determines if any object is an IFluidCodeDetails\n * @internal\n */\nexport const isFluidCodeDetails = (\n\tdetails: unknown,\n): details is Readonly<IFluidCodeDetails> => {\n\tconst maybeCodeDetails = details as Partial<IFluidCodeDetails> | undefined;\n\treturn (\n\t\ttypeof maybeCodeDetails === \"object\" &&\n\t\t(typeof maybeCodeDetails?.package === \"string\" ||\n\t\t\tisFluidPackage(maybeCodeDetails?.package)) &&\n\t\t(maybeCodeDetails?.config === undefined || typeof maybeCodeDetails?.config === \"object\")\n\t);\n};\n\n/**\n * @legacy @beta\n */\nexport const IFluidCodeDetailsComparer: keyof IProvideFluidCodeDetailsComparer =\n\t\"IFluidCodeDetailsComparer\";\n\n/**\n * @legacy @beta\n */\nexport interface IProvideFluidCodeDetailsComparer {\n\treadonly IFluidCodeDetailsComparer: IFluidCodeDetailsComparer;\n}\n\n/**\n * Provides capability to compare Fluid code details.\n * @legacy @beta\n */\nexport interface IFluidCodeDetailsComparer extends IProvideFluidCodeDetailsComparer {\n\t/**\n\t * Determines if the `candidate` code details satisfy the constraints specified in `constraint` code details.\n\t *\n\t * Similar semantics to:\n\t * {@link https://github.com/npm/node-semver#usage}\n\t */\n\tsatisfies(candidate: IFluidCodeDetails, constraint: IFluidCodeDetails): Promise<boolean>;\n\n\t/**\n\t * Return a number representing the ascending sort order of the `a` and `b` code details:\n\t *\n\t * - `< 0` if `a < b`.\n\t *\n\t * - `= 0` if `a === b`.\n\t *\n\t * - `> 0` if `a > b`.\n\t *\n\t * - `undefined` if `a` is not comparable to `b`.\n\t *\n\t * Similar semantics to:\n\t * {@link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#description | Array.sort}\n\t */\n\tcompare(a: IFluidCodeDetails, b: IFluidCodeDetails): Promise<number | undefined>;\n}\n"]}