@univerjs/rpc
Advanced tools
Comparing version 0.1.4 to 0.1.5
@@ -1,20 +0,6 @@ | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import { IRPChannelService } from '../../services/rpc/channel.service'; | ||
import { IRemoteSyncService } from '../../services/remote-instance/remote-instance.service'; | ||
import { Injector } from '@wendellhu/redi'; | ||
import { ICommandService, IUniverInstanceService, RxDisposable } from '@univerjs/core'; | ||
import { Injector } from '@wendellhu/redi'; | ||
import { IRemoteSyncService } from '../../services/remote-instance/remote-instance.service'; | ||
import { IRPChannelService } from '../../services/rpc/channel.service'; | ||
/** | ||
@@ -21,0 +7,0 @@ * This controller is responsible for syncing data from the primary thread to |
@@ -1,20 +0,6 @@ | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import { IRPChannelService } from '../../services/rpc/channel.service'; | ||
import { IRemoteInstanceService } from '../../services/remote-instance/remote-instance.service'; | ||
import { Injector } from '@wendellhu/redi'; | ||
import { Disposable, ICommandService } from '@univerjs/core'; | ||
import { Injector } from '@wendellhu/redi'; | ||
import { IRemoteInstanceService } from '../../services/remote-instance/remote-instance.service'; | ||
import { IRPChannelService } from '../../services/rpc/channel.service'; | ||
/** | ||
@@ -21,0 +7,0 @@ * This controller is responsible for syncing data from the worker thread to |
@@ -1,18 +0,4 @@ | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import { Injector } from '@wendellhu/redi'; | ||
import { Plugin, PluginType } from '@univerjs/core'; | ||
import { Injector } from '@wendellhu/redi'; | ||
export interface IUniverRPCMainThreadConfig { | ||
@@ -19,0 +5,0 @@ workerURL: string | URL | Worker; |
@@ -1,18 +0,3 @@ | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import type { IExecutionOptions, IMutationInfo, IWorkbookData } from '@univerjs/core'; | ||
import { ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core'; | ||
import { IExecutionOptions, IMutationInfo, IWorkbookData, ICommandService, IUniverInstanceService, UniverInstanceType } from '@univerjs/core'; | ||
export interface IRemoteSyncMutationOptions extends IExecutionOptions { | ||
@@ -28,3 +13,3 @@ /** If this mutation is executed after it was sent from the peer univer instance (e.g. in a web worker). */ | ||
*/ | ||
export declare const IRemoteSyncService: import("@wendellhu/redi").IdentifierDecorator<IRemoteSyncService>; | ||
export declare const IRemoteSyncService: import('@wendellhu/redi').IdentifierDecorator<IRemoteSyncService>; | ||
export interface IRemoteSyncService { | ||
@@ -49,3 +34,3 @@ syncMutation(params: { | ||
*/ | ||
export declare const IRemoteInstanceService: import("@wendellhu/redi").IdentifierDecorator<IRemoteInstanceService>; | ||
export declare const IRemoteInstanceService: import('@wendellhu/redi').IdentifierDecorator<IRemoteInstanceService>; | ||
export interface IRemoteInstanceService { | ||
@@ -52,0 +37,0 @@ /** Tell other modules if the `IRemoteInstanceService` is ready to load files. */ |
@@ -1,17 +0,3 @@ | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import type { IChannel, IMessageProtocol } from './rpc.service'; | ||
import { IChannel, IMessageProtocol } from './rpc.service'; | ||
export interface IRPChannelService { | ||
@@ -21,3 +7,3 @@ requestChannel(name: string): IChannel; | ||
} | ||
export declare const IRPChannelService: import("@wendellhu/redi").IdentifierDecorator<IRPChannelService>; | ||
export declare const IRPChannelService: import('@wendellhu/redi').IdentifierDecorator<IRPChannelService>; | ||
/** | ||
@@ -24,0 +10,0 @@ * This service is responsible for managing the RPC channels. |
@@ -0,18 +1,4 @@ | ||
import { IMessageProtocol } from '../rpc.service'; | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import type { IMessageProtocol } from '../rpc.service'; | ||
/** | ||
* Generate an `IMessageProtocol` on the web worker. | ||
@@ -19,0 +5,0 @@ */ |
@@ -1,18 +0,4 @@ | ||
/** | ||
* Copyright 2023-present DreamNum Inc. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
import { Observable } from 'rxjs'; | ||
import { RxDisposable } from '@univerjs/core'; | ||
import { Observable } from 'rxjs'; | ||
/** This protocol is for transferring data from the two peer univer instance running in different locations. */ | ||
@@ -19,0 +5,0 @@ export interface IMessageProtocol { |
{ | ||
"name": "@univerjs/rpc", | ||
"version": "0.1.4", | ||
"version": "0.1.5", | ||
"private": false, | ||
@@ -54,3 +54,3 @@ "author": "DreamNum <developer@univer.ai>", | ||
"rxjs": ">=7.0.0", | ||
"@univerjs/core": "0.1.4" | ||
"@univerjs/core": "0.1.5" | ||
}, | ||
@@ -61,7 +61,7 @@ "dependencies": {}, | ||
"rxjs": "^7.8.1", | ||
"typescript": "^5.4.2", | ||
"vite": "^5.1.6", | ||
"typescript": "^5.4.3", | ||
"vite": "^5.2.6", | ||
"vitest": "^1.4.0", | ||
"@univerjs/core": "0.1.4", | ||
"@univerjs/shared": "0.1.4" | ||
"@univerjs/core": "0.1.5", | ||
"@univerjs/shared": "0.1.5" | ||
}, | ||
@@ -68,0 +68,0 @@ "scripts": { |
@@ -10,3 +10,3 @@ # @univerjs/rpc | ||
For more information, see the [Architecture of Web Worker](https://univer.ai/en-us/guides/architecture/web-worker/). | ||
For more information, see the [Architecture of Web Worker](https://univer.ai/guides/concepts-and-architecture/web-worker/). | ||
@@ -13,0 +13,0 @@ ## Usage |
57281
809