Class: FindReplaceModel
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:196
This class stores find replace results and provides methods to perform replace or something.
It only live through a find-replace session and would be disposed when the user close the find replace dialog (considered as session being terminated).
Extends
Constructors
new FindReplaceModel()
new FindReplaceModel(
_state,
_providers,
_univerInstanceService): FindReplaceModel
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:212
Parameters
Parameter | Type |
---|---|
_state | FindReplaceState |
_providers | Set <IFindReplaceProvider > |
_univerInstanceService | IUniverInstanceService |
Returns
Overrides
Properties
Property | Modifier | Type | Default value | Inherited from | Defined in |
---|---|---|---|---|---|
_disposed | protected | boolean | false | Disposable ._disposed | submodules/univer/packages/core/src/shared/lifecycle.ts:96 |
currentMatch$ | readonly | BehaviorSubject <Nullable <IFindMatch >> | undefined | - | submodules/univer/packages/find-replace/src/services/find-replace.service.ts:197 |
replaceables$ | readonly | BehaviorSubject <IReplaceableMatch []> | undefined | - | submodules/univer/packages/find-replace/src/services/find-replace.service.ts:198 |
Accessors
searched
Get Signature
get searched(): boolean
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:210
Returns
boolean
Methods
dispose()
dispose(): void
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:235
Returns
void
Overrides
disposeWithMe()
disposeWithMe(disposable): IDisposable
Defined in: submodules/univer/packages/core/src/shared/lifecycle.ts:99
Parameters
Parameter | Type |
---|---|
disposable | DisposableLike |
Returns
Inherited from
ensureNotDisposed()
protected ensureNotDisposed(): void
Defined in: submodules/univer/packages/core/src/shared/lifecycle.ts:103
Returns
void
Inherited from
getCurrentMatch()
getCurrentMatch(): Nullable<IFindMatch>
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:360
Returns
moveToNextMatch()
moveToNextMatch(): undefined | null | IFindMatch
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:370
Returns
undefined
| null
| IFindMatch
moveToPreviousMatch()
moveToPreviousMatch(): undefined | null | IFindMatch
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:407
Returns
undefined
| null
| IFindMatch
replace()
replace(): Promise<boolean>
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:337
Returns
Promise
<boolean
>
replaceAll()
replaceAll(): Promise<IReplaceAllResult>
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:345
Returns
Promise
<IReplaceAllResult
>
start()
start(): Promise<IFindComplete>
Defined in: submodules/univer/packages/find-replace/src/services/find-replace.service.ts:247
Returns
Promise
<IFindComplete
>