@univerjs/sheets-conditional-formatting v0.5.4
Class: ConditionalFormattingFormulaService
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:64
Extends
Constructors
new ConditionalFormattingFormulaService()
new ConditionalFormattingFormulaService(
_commandService,
_activeDirtyManagerService,
_conditionalFormattingRuleModel): ConditionalFormattingFormulaService
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:71
Parameters
Parameter | Type |
---|---|
_commandService | ICommandService |
_activeDirtyManagerService | IActiveDirtyManagerService |
_conditionalFormattingRuleModel | ConditionalFormattingRuleModel |
Returns
ConditionalFormattingFormulaService
Overrides
Properties
Property | Modifier | Type | Default value | Inherited from | Defined in |
---|---|---|---|---|---|
_disposed | protected | boolean | false | Disposable ._disposed | core/src/shared/lifecycle.ts:96 |
result$ | public | Observable <IFormulaItem & { isAllFinished : boolean ; }> | undefined | - | sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:69 |
Methods
createCFormulaId()
createCFormulaId(cfId, formulaText): string
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:295
A conditional formatting may have multiple formulas;if the formulas are identical,then the results will be consistent.
Parameters
Parameter | Type |
---|---|
cfId | string |
formulaText | string |
Returns
string
deleteCache()
deleteCache(
unitId,
subUnitId,
cfId,
formulaText?): IFormulaItem[]
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:258
If formulaText
is not provided, then all caches related to cfId
will be deleted.
Parameters
Parameter | Type |
---|---|
unitId | string |
subUnitId | string |
cfId | string |
formulaText ? | string |
Returns
IFormulaItem
[]
dispose()
dispose(): void
Defined in: core/src/shared/lifecycle.ts:109
Returns
void
Inherited from
disposeWithMe()
disposeWithMe(disposable): IDisposable
Defined in: core/src/shared/lifecycle.ts:99
Parameters
Parameter | Type |
---|---|
disposable | DisposableLike |
Returns
Inherited from
ensureNotDisposed()
protected ensureNotDisposed(): void
Defined in: core/src/shared/lifecycle.ts:103
Returns
void
Inherited from
getFormulaMatrix()
getFormulaMatrix(
unitId,
subUnitId,
cfId,
formulaText):
| undefined
| {
result: undefined;
status: FormulaResultStatus;
}
| {
result: ObjectMatrix<undefined | null | string | number | boolean | void>;
status: FormulaResultStatus;
}
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:240
Parameters
Parameter | Type |
---|---|
unitId | string |
subUnitId | string |
cfId | string |
formulaText | string |
Returns
| undefined
| {
result
: undefined
;
status
: FormulaResultStatus
;
}
| {
result
: ObjectMatrix
<undefined
| null
| string
| number
| boolean
| void
>;
status
: FormulaResultStatus
;
}
getFormulaResultWithCoords()
getFormulaResultWithCoords(
unitId,
subUnitId,
cfId,
formulaText,
row,
col):
| {
result: undefined;
status: FormulaResultStatus;
}
| {
result: Nullable<undefined | null | string | number | boolean | void>;
status: FormulaResultStatus;
}
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:219
Parameters
Parameter | Type | Default value |
---|---|---|
unitId | string | undefined |
subUnitId | string | undefined |
cfId | string | undefined |
formulaText | string | undefined |
row | number | 0 |
col | number | 0 |
Returns
| {
result
: undefined
;
status
: FormulaResultStatus
;
}
| {
result
: Nullable
<undefined
| null
| string
| number
| boolean
| void
>;
status
: FormulaResultStatus
;
}
getSubUnitFormulaMap()
getSubUnitFormulaMap(unitId, subUnitId):
| undefined
| RefAlias<IFormulaItem, "id" | "formulaId">
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:174
Parameters
Parameter | Type |
---|---|
unitId | string |
subUnitId | string |
Returns
| undefined
| RefAlias
<IFormulaItem
, "id"
| "formulaId"
>
registerFormulaWithRange()
registerFormulaWithRange(
unitId,
subUnitId,
cfId,
formulaText,
ranges): void
Defined in: sheets-conditional-formatting/src/services/conditional-formatting-formula.service.ts:178
Parameters
Parameter | Type |
---|---|
unitId | string |
subUnitId | string |
cfId | string |
formulaText | string |
ranges | IRange [] |
Returns
void