API Reference
@univerjs
@univerjs/sheets-data-validation
classes
Datavalidationcustomformulaservice

@univerjs/sheets-data-validation v0.4.2Docs


Class: DataValidationCustomFormulaService

Extends

Constructors

new DataValidationCustomFormulaService()

new DataValidationCustomFormulaService(
   _instanceSrv, 
   _registerOtherFormulaService, 
   _lexerTreeBuilder, 
   _dataValidationModel, 
   _dataValidationCacheService, 
   _injector): DataValidationCustomFormulaService

Parameters

ParameterType
_instanceSrvIUniverInstanceService
_registerOtherFormulaServiceRegisterOtherFormulaService
_lexerTreeBuilderLexerTreeBuilder
_dataValidationModelDataValidationModel
_dataValidationCacheServiceDataValidationCacheService
_injectorInjector

Returns

DataValidationCustomFormulaService

Overrides

Disposable.constructor

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:65 (opens in a new tab)

Properties

PropertyModifierTypeDefault valueInherited fromDefined in
_disposedprotectedbooleanfalseDisposable._disposedcore/src/shared/lifecycle.ts:93 (opens in a new tab)

Methods

addRule()

addRule(
   unitId, 
   subUnitId, 
   rule): void

Parameters

ParameterType
unitIdstring
subUnitIdstring
ruleISheetDataValidationRule

Returns

void

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:214 (opens in a new tab)


deleteByRuleId()

deleteByRuleId(
   unitId, 
   subUnitId, 
   ruleId): void

Parameters

ParameterType
unitIdstring
subUnitIdstring
ruleIdstring

Returns

void

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:146 (opens in a new tab)


dispose()

dispose(): void

Returns

void

Inherited from

Disposable.dispose

Defined in

core/src/shared/lifecycle.ts:106 (opens in a new tab)


disposeWithMe()

disposeWithMe(disposable): IDisposable

Parameters

ParameterType
disposableDisposableLike

Returns

IDisposable

Inherited from

Disposable.disposeWithMe

Defined in

core/src/shared/lifecycle.ts:96 (opens in a new tab)


ensureNotDisposed()

protected ensureNotDisposed(): void

Returns

void

Inherited from

Disposable.ensureNotDisposed

Defined in

core/src/shared/lifecycle.ts:100 (opens in a new tab)


getCellFormulaValue()

getCellFormulaValue(
   unitId, 
   subUnitId, 
   row, 
col): Promise<Nullable<IOtherFormulaResult>>

Parameters

ParameterType
unitIdstring
subUnitIdstring
rownumber
colnumber

Returns

Promise<Nullable<IOtherFormulaResult>>

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:297 (opens in a new tab)


getRuleFormulaInfo()

getRuleFormulaInfo(
   unitId, 
   subUnitId, 
   ruleId): undefined | IFormulaData

Parameters

ParameterType
unitIdstring
subUnitIdstring
ruleIdstring

Returns

undefined | IFormulaData

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:307 (opens in a new tab)


updateRuleFormula()

updateRuleFormula(
   unitId, 
   subUnitId, 
   ruleId, 
   ranges, 
   formula): void

Parameters

ParameterType
unitIdstring
subUnitIdstring
ruleIdstring
rangesIRange[]
formulastring

Returns

void

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:289 (opens in a new tab)


updateRuleRanges()

updateRuleRanges(
   unitId, 
   subUnitId, 
   ruleId, 
   oldRanges, 
   newRanges): void

Parameters

ParameterType
unitIdstring
subUnitIdstring
ruleIdstring
oldRangesIRange[]
newRangesIRange[]

Returns

void

Defined in

sheets-data-validation/src/services/dv-custom-formula.service.ts:222 (opens in a new tab)


Copyright © 2021-2024 DreamNum Co,Ltd. All Rights Reserved.