@univerjs-procollaboration-clientclassesCollaborationsessionservice

@univerjs-pro/collaboration-client v0.5.0-beta.1Docs


Class: CollaborationSessionService

This service provide collaboration sessions to univer instances. A collaboration session may be used by different controllers of different features.

Extends

Constructors

new CollaborationSessionService()

new CollaborationSessionService(
   _injector, 
   _localeService, 
   _messageService, 
   _logService, 
   _configService, 
   _socketService, 
   _httpService): CollaborationSessionService

Parameters

ParameterType
_injectorInjector
_localeServiceLocaleService
_messageServiceIMessageService
_logServiceILogService
_configServiceIConfigService
_socketServiceICollaborationSocketService
_httpServiceHTTPService

Returns

CollaborationSessionService

Overrides

Disposable.constructor

Defined in

packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:51

Properties

PropertyModifierTypeDefault valueInherited fromDefined in
_disposedprotectedbooleanfalseDisposable._disposedsubmodules/univer/packages/core/src/shared/lifecycle.ts:93
socket$readonlyObservable<Nullable<ICollaborationSocket>>undefined-packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:34
status$publicObservable<SessionStatus>undefined-packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:44

Methods

closeSession()

closeSession(unitID): void

Parameters

ParameterType
unitIDstring

Returns

void

Defined in

packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:96


dispose()

dispose(): void

Returns

void

Overrides

Disposable.dispose

Defined in

packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:70


disposeWithMe()

disposeWithMe(disposable): IDisposable

Parameters

ParameterType
disposableDisposableLike

Returns

IDisposable

Inherited from

Disposable.disposeWithMe

Defined in

submodules/univer/packages/core/src/shared/lifecycle.ts:96


ensureNotDisposed()

protected ensureNotDisposed(): void

Returns

void

Inherited from

Disposable.ensureNotDisposed

Defined in

submodules/univer/packages/core/src/shared/lifecycle.ts:100


reconnect()

reconnect(): void

Returns

void

Defined in

packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:108


requireSession()

requireSession(unitID): Promise<CollaborationSession>

Require a collaboration session.

Parameters

ParameterType
unitIDstring

Returns

Promise<CollaborationSession>

a collaboration session.

Defined in

packages/collaboration-client/src/services/collaboration-session/collaboration-session.service.ts:83