@univerjs/engine-formula
Advanced tools
Comparing version 0.2.4 to 0.2.5
@@ -21,2 +21,4 @@ import { BooleanNumber, ICellData, IColumnData, IObjectArrayPrimitiveType, IObjectMatrixPrimitiveType, IRange, IRowData, IUnitRange, Nullable, ObjectMatrix, Styles } from '@univerjs/core'; | ||
columnData: IObjectArrayPrimitiveType<Partial<IColumnData>>; | ||
defaultColumnWidth?: number; | ||
defaultRowHeight?: number; | ||
} | ||
@@ -23,0 +25,0 @@ export interface ISheetData { |
@@ -13,4 +13,7 @@ import { IMutation } from '@univerjs/core'; | ||
export declare const SetFeatureCalculationMutation: IMutation<ISetFeatureCalculationMutation>; | ||
export declare const RemoveFeatureCalculationMutation: IMutation<{ | ||
featureId: string; | ||
}>; | ||
export interface IRemoveFeatureCalculationMutationParam { | ||
featureIds: string[]; | ||
unitId: string; | ||
subUnitId: string; | ||
} | ||
export declare const RemoveFeatureCalculationMutation: IMutation<IRemoveFeatureCalculationMutationParam>; |
@@ -1,15 +0,9 @@ | ||
import { IExecutionOptions, IMutation, IUnitRange, Nullable } from '@univerjs/core'; | ||
import { IDirtyUnitFeatureMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IDirtyUnitSheetNameMap, IRuntimeOtherUnitDataType, IRuntimeUnitDataPrimitiveType } from '../../basics/common'; | ||
import { IExecutionOptions, IMutation, Nullable } from '@univerjs/core'; | ||
import { IRuntimeOtherUnitDataType, IRuntimeUnitDataPrimitiveType } from '../../basics/common'; | ||
import { FormulaExecutedStateType, IExecutionInProgressParams } from '../../services/runtime.service'; | ||
import { IFormulaDirtyData } from '../../services/current-data.service'; | ||
export interface IFormulaDirtyData { | ||
dirtyRanges: IUnitRange[]; | ||
dirtyNameMap: IDirtyUnitSheetNameMap; | ||
dirtyDefinedNameMap: IDirtyUnitSheetDefinedNameMap; | ||
dirtyUnitFeatureMap: IDirtyUnitFeatureMap; | ||
dirtyUnitOtherFormulaMap: IDirtyUnitOtherFormulaMap; | ||
} | ||
export interface ISetFormulaCalculationStartMutation extends IFormulaDirtyData { | ||
options: Nullable<IExecutionOptions>; | ||
forceCalculation?: boolean; | ||
forceCalculation: boolean; | ||
} | ||
@@ -16,0 +10,0 @@ /** |
@@ -1,3 +0,2 @@ | ||
import { Disposable, ICommandService } from '@univerjs/core'; | ||
import { Ctor } from '@wendellhu/redi'; | ||
import { Disposable, ICommandService, Ctor } from '@univerjs/core'; | ||
import { DataSyncPrimaryController } from '@univerjs/rpc'; | ||
@@ -4,0 +3,0 @@ import { IFunctionNames } from '../basics/function'; |
import { Disposable, ICommandService } from '@univerjs/core'; | ||
import { IFeatureCalculationManagerService } from '../services/feature-calculation-manager.service'; | ||
import { IDependencyManagerService } from '../services/dependency-manager.service'; | ||
@@ -7,5 +8,7 @@ | ||
private readonly _dependencyManagerService; | ||
constructor(_commandService: ICommandService, _dependencyManagerService: IDependencyManagerService); | ||
private readonly _featureCalculationManagerService; | ||
constructor(_commandService: ICommandService, _dependencyManagerService: IDependencyManagerService, _featureCalculationManagerService: IFeatureCalculationManagerService); | ||
private _initialize; | ||
private _featureCalculationManagerServiceListener; | ||
private _commandExecutedListener; | ||
} |
@@ -1,3 +0,2 @@ | ||
import { IWorkbookData, Workbook, Univer } from '@univerjs/core'; | ||
import { Dependency } from '@wendellhu/redi'; | ||
import { Dependency, IWorkbookData, Workbook, Univer } from '@univerjs/core'; | ||
import { ISheetData } from '../../../basics/common'; | ||
@@ -8,8 +7,8 @@ | ||
get: { | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, lookUp?: import('@wendellhu/redi').LookUp): T; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.MANY, lookUp?: import('@wendellhu/redi').LookUp): T[]; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.OPTIONAL, lookUp?: import('@wendellhu/redi').LookUp): T | null; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.REQUIRED, lookUp?: import('@wendellhu/redi').LookUp): T; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity?: import('@wendellhu/redi').Quantity, lookUp?: import('@wendellhu/redi').LookUp): T[] | T | null; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantityOrLookup?: import('@wendellhu/redi').Quantity | import('@wendellhu/redi').LookUp, lookUp?: import('@wendellhu/redi').LookUp): T[] | T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, lookUp?: import('@univerjs/core').LookUp): T; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.MANY, lookUp?: import('@univerjs/core').LookUp): T[]; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.OPTIONAL, lookUp?: import('@univerjs/core').LookUp): T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.REQUIRED, lookUp?: import('@univerjs/core').LookUp): T; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity?: import('@univerjs/core').Quantity, lookUp?: import('@univerjs/core').LookUp): T[] | T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantityOrLookup?: import('@univerjs/core').Quantity | import('@univerjs/core').LookUp, lookUp?: import('@univerjs/core').LookUp): T[] | T | null; | ||
}; | ||
@@ -16,0 +15,0 @@ sheet: Workbook; |
@@ -1,2 +0,2 @@ | ||
import { Injector } from '@wendellhu/redi'; | ||
import { Injector } from '@univerjs/core'; | ||
import { AstNodePromiseType } from '../../basics/common'; | ||
@@ -3,0 +3,0 @@ import { BaseFunction } from '../../functions/base-function'; |
@@ -1,3 +0,2 @@ | ||
import { Nullable } from '@univerjs/core'; | ||
import { IAccessor, Injector } from '@wendellhu/redi'; | ||
import { IAccessor, Nullable, Injector } from '@univerjs/core'; | ||
import { BaseFunction } from '../../functions/base-function'; | ||
@@ -4,0 +3,0 @@ import { IFunctionService } from '../../services/function.service'; |
@@ -1,2 +0,2 @@ | ||
import { IAccessor, Injector } from '@wendellhu/redi'; | ||
import { IAccessor, Injector } from '@univerjs/core'; | ||
import { IFormulaRuntimeService } from '../../services/runtime.service'; | ||
@@ -3,0 +3,0 @@ import { ISuperTableService } from '../../services/super-table.service'; |
@@ -1,2 +0,2 @@ | ||
import { IAccessor, Injector } from '@wendellhu/redi'; | ||
import { IAccessor, Injector } from '@univerjs/core'; | ||
import { BaseFunction } from '../../functions/base-function'; | ||
@@ -3,0 +3,0 @@ import { IFunctionService } from '../../services/function.service'; |
import { IRange, IUnitRange, Nullable, Disposable } from '@univerjs/core'; | ||
import { IDirtyUnitSheetNameMap, IFeatureDirtyRangeType, IRuntimeUnitDataType, IUnitExcludedCell } from '../../basics/common'; | ||
import { BaseAstNode } from '../ast-node/base-ast-node'; | ||
import { IFormulaDirtyData } from '../../services/current-data.service'; | ||
import { IAllRuntimeData } from '../../services/runtime.service'; | ||
@@ -32,3 +34,4 @@ export declare enum FDtreeStateType { | ||
featureId: Nullable<string>; | ||
getDirtyData: Nullable<(tree: FormulaDependencyTree) => { | ||
isPassive: boolean; | ||
getDirtyData: Nullable<(tree: FormulaDependencyTree, dirtyData: IFormulaDirtyData, runtimeData: IAllRuntimeData) => { | ||
runtimeCellData: IRuntimeUnitDataType; | ||
@@ -35,0 +38,0 @@ dirtyRanges: IFeatureDirtyRangeType; |
@@ -35,2 +35,3 @@ import { Disposable } from '@univerjs/core'; | ||
private _registerFeatureFormulas; | ||
private _makePassiveDirtyForFeatureFormulas; | ||
private _registerOtherFormulas; | ||
@@ -37,0 +38,0 @@ private _registerFormulas; |
@@ -1,3 +0,2 @@ | ||
import { Injector } from '@wendellhu/redi'; | ||
import { Nullable } from '@univerjs/core'; | ||
import { Injector, Nullable } from '@univerjs/core'; | ||
import { IFunctionService } from '../../services/function.service'; | ||
@@ -4,0 +3,0 @@ import { PrefixNode } from '../ast-node/prefix-node'; |
@@ -152,2 +152,3 @@ import { Nullable } from '@univerjs/core'; | ||
cos(): BaseValueObject; | ||
cosh(): BaseValueObject; | ||
acos(): BaseValueObject; | ||
@@ -154,0 +155,0 @@ acosh(): BaseValueObject; |
@@ -89,2 +89,3 @@ import { Nullable } from '@univerjs/core'; | ||
cos(): BaseValueObject; | ||
cosh(): BaseValueObject; | ||
acos(): BaseValueObject; | ||
@@ -91,0 +92,0 @@ acosh(): BaseValueObject; |
@@ -27,2 +27,3 @@ import { compareToken } from '../../basics/token'; | ||
cos(): BaseValueObject; | ||
cosh(): BaseValueObject; | ||
acos(): BaseValueObject; | ||
@@ -74,2 +75,3 @@ acosh(): BaseValueObject; | ||
cos(): BaseValueObject; | ||
cosh(): BaseValueObject; | ||
acos(): BaseValueObject; | ||
@@ -128,2 +130,3 @@ acosh(): BaseValueObject; | ||
cos(): BaseValueObject; | ||
cosh(): BaseValueObject; | ||
acos(): BaseValueObject; | ||
@@ -130,0 +133,0 @@ acosh(): BaseValueObject; |
@@ -1,3 +0,2 @@ | ||
import { IWorkbookData, Workbook, Univer } from '@univerjs/core'; | ||
import { Dependency } from '@wendellhu/redi'; | ||
import { Dependency, IWorkbookData, Workbook, Univer } from '@univerjs/core'; | ||
import { ISheetData } from '../../basics/common'; | ||
@@ -9,8 +8,8 @@ import { FunctionVariantType } from '../../engine/reference-object/base-reference-object'; | ||
get: { | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, lookUp?: import('@wendellhu/redi').LookUp): T; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.MANY, lookUp?: import('@wendellhu/redi').LookUp): T[]; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.OPTIONAL, lookUp?: import('@wendellhu/redi').LookUp): T | null; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.REQUIRED, lookUp?: import('@wendellhu/redi').LookUp): T; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity?: import('@wendellhu/redi').Quantity, lookUp?: import('@wendellhu/redi').LookUp): T[] | T | null; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantityOrLookup?: import('@wendellhu/redi').Quantity | import('@wendellhu/redi').LookUp, lookUp?: import('@wendellhu/redi').LookUp): T[] | T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, lookUp?: import('@univerjs/core').LookUp): T; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.MANY, lookUp?: import('@univerjs/core').LookUp): T[]; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.OPTIONAL, lookUp?: import('@univerjs/core').LookUp): T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.REQUIRED, lookUp?: import('@univerjs/core').LookUp): T; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity?: import('@univerjs/core').Quantity, lookUp?: import('@univerjs/core').LookUp): T[] | T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantityOrLookup?: import('@univerjs/core').Quantity | import('@univerjs/core').LookUp, lookUp?: import('@univerjs/core').LookUp): T[] | T | null; | ||
}; | ||
@@ -17,0 +16,0 @@ sheet: Workbook; |
@@ -0,3 +1,3 @@ | ||
import { FUNCTION_NAMES_DATE } from './function-names'; | ||
import { DateFunction } from './date'; | ||
import { FUNCTION_NAMES_DATE } from './function-names'; | ||
import { NetworkdaysIntl } from './networkdays-intl'; | ||
@@ -4,0 +4,0 @@ import { WorkdayIntl } from './workday-intl'; |
import { FUNCTION_NAMES_INFORMATION } from './function-names'; | ||
import { Cell } from './cell'; | ||
import { Isblank } from './isblank'; | ||
export declare const functionInformation: (FUNCTION_NAMES_INFORMATION | typeof Isblank)[][]; | ||
export declare const functionInformation: ((FUNCTION_NAMES_INFORMATION | typeof Cell)[] | (FUNCTION_NAMES_INFORMATION | typeof Isblank)[])[]; |
@@ -7,3 +7,3 @@ import { BaseValueObject } from '../../../engine/value-object/base-value-object'; | ||
maxParams: number; | ||
calculate(variant: BaseValueObject): BaseValueObject; | ||
calculate(number: BaseValueObject): BaseValueObject; | ||
} |
@@ -0,3 +1,4 @@ | ||
import { FUNCTION_NAMES_MATH } from './function-names'; | ||
import { Base } from './base'; | ||
import { FUNCTION_NAMES_MATH } from './function-names'; | ||
import { Randarray } from './randarray'; | ||
import { Subtotal } from './subtotal'; | ||
@@ -7,2 +8,2 @@ import { Sum } from './sum'; | ||
export declare const functionMath: ((FUNCTION_NAMES_MATH | typeof Base)[] | (FUNCTION_NAMES_MATH | typeof Subtotal)[] | (FUNCTION_NAMES_MATH | typeof Sum)[] | (FUNCTION_NAMES_MATH | typeof Sumifs)[])[]; | ||
export declare const functionMath: ((FUNCTION_NAMES_MATH | typeof Base)[] | (FUNCTION_NAMES_MATH | typeof Randarray)[] | (FUNCTION_NAMES_MATH | typeof Subtotal)[] | (FUNCTION_NAMES_MATH | typeof Sum)[] | (FUNCTION_NAMES_MATH | typeof Sumifs)[])[]; |
@@ -16,3 +16,3 @@ /** | ||
*/ | ||
export type { IArrayFormulaRangeType, IArrayFormulaUnitCellType, IDirtyUnitFeatureMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDataItem, IFormulaDatasetConfig, IRuntimeUnitDataType, ISheetData, IUnitData, IUnitSheetNameMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, } from './basics/common'; | ||
export type { IArrayFormulaRangeType, IArrayFormulaUnitCellType, IDirtyUnitFeatureMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDataItem, IFormulaDatasetConfig, IRuntimeUnitDataType, ISheetData, IUnitData, IUnitSheetNameMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IFeatureDirtyRangeType, } from './basics/common'; | ||
export { isInDirtyRange } from './basics/dirty'; | ||
@@ -87,3 +87,3 @@ export { ErrorType, ERROR_TYPE_SET } from './basics/error-type'; | ||
export { IFormulaRuntimeService, FormulaRuntimeService } from './services/runtime.service'; | ||
export { IFormulaCurrentConfigService, FormulaCurrentConfigService } from './services/current-data.service'; | ||
export { IFormulaCurrentConfigService, FormulaCurrentConfigService, type IFormulaDirtyData } from './services/current-data.service'; | ||
export { IActiveDirtyManagerService } from './services/active-dirty-manager.service'; | ||
@@ -99,5 +99,5 @@ export type { IRangeChange } from './models/formula-data.model'; | ||
export { RemoveFeatureCalculationMutation, SetFeatureCalculationMutation } from './commands/mutations/set-feature-calculation.mutation'; | ||
export { SetFormulaCalculationStartMutation, SetFormulaCalculationStopMutation, SetFormulaCalculationNotificationMutation, SetFormulaCalculationResultMutation, type ISetFormulaCalculationStartMutation, type ISetFormulaCalculationNotificationMutation, type ISetFormulaCalculationResultMutation, type IFormulaDirtyData, } from './commands/mutations/set-formula-calculation.mutation'; | ||
export { SetFormulaCalculationStartMutation, SetFormulaCalculationStopMutation, SetFormulaCalculationNotificationMutation, SetFormulaCalculationResultMutation, type ISetFormulaCalculationStartMutation, type ISetFormulaCalculationNotificationMutation, type ISetFormulaCalculationResultMutation, } from './commands/mutations/set-formula-calculation.mutation'; | ||
export { SetFormulaDataMutation, type ISetFormulaDataMutationParams } from './commands/mutations/set-formula-data.mutation'; | ||
export { SetOtherFormulaMutation, RemoveOtherFormulaMutation, type ISetOtherFormulaMutationParams, type IRemoveOtherFormulaMutationParams } from './commands/mutations/set-other-formula.mutation'; | ||
export { SetSuperTableMutation, RemoveSuperTableMutation, SetSuperTableOptionMutation } from './commands/mutations/set-super-table.mutation'; |
@@ -1,3 +0,2 @@ | ||
import { IWorkbookData, Univer } from '@univerjs/core'; | ||
import { Dependency } from '@wendellhu/redi'; | ||
import { Dependency, IWorkbookData, Univer } from '@univerjs/core'; | ||
@@ -7,10 +6,10 @@ export declare function createCommandTestBed(workbookData?: IWorkbookData, dependencies?: Dependency[]): { | ||
get: { | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, lookUp?: import('@wendellhu/redi').LookUp): T; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.MANY, lookUp?: import('@wendellhu/redi').LookUp): T[]; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.OPTIONAL, lookUp?: import('@wendellhu/redi').LookUp): T | null; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity: import("@wendellhu/redi").Quantity.REQUIRED, lookUp?: import('@wendellhu/redi').LookUp): T; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantity?: import('@wendellhu/redi').Quantity, lookUp?: import('@wendellhu/redi').LookUp): T[] | T | null; | ||
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, quantityOrLookup?: import('@wendellhu/redi').Quantity | import('@wendellhu/redi').LookUp, lookUp?: import('@wendellhu/redi').LookUp): T[] | T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, lookUp?: import('@univerjs/core').LookUp): T; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.MANY, lookUp?: import('@univerjs/core').LookUp): T[]; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.OPTIONAL, lookUp?: import('@univerjs/core').LookUp): T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity: import("@univerjs/core").Quantity.REQUIRED, lookUp?: import('@univerjs/core').LookUp): T; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantity?: import('@univerjs/core').Quantity, lookUp?: import('@univerjs/core').LookUp): T[] | T | null; | ||
<T>(id: import('@univerjs/core').DependencyIdentifier<T>, quantityOrLookup?: import('@univerjs/core').Quantity | import('@univerjs/core').LookUp, lookUp?: import('@univerjs/core').LookUp): T[] | T | null; | ||
}; | ||
sheet: import('@univerjs/core').Workbook; | ||
}; |
@@ -1,3 +0,2 @@ | ||
import { Plugin } from '@univerjs/core'; | ||
import { Ctor, Injector } from '@wendellhu/redi'; | ||
import { Injector, Plugin, Ctor } from '@univerjs/core'; | ||
import { IFunctionNames } from './basics/function'; | ||
@@ -4,0 +3,0 @@ import { BaseFunction } from './functions/base-function'; |
@@ -35,2 +35,2 @@ import { ICommandInfo, IUnitRange, Nullable, Disposable } from '@univerjs/core'; | ||
} | ||
export declare const IActiveDirtyManagerService: import('@wendellhu/redi').IdentifierDecorator<ActiveDirtyManagerService>; | ||
export declare const IActiveDirtyManagerService: import('@univerjs/core').IdentifierDecorator<ActiveDirtyManagerService>; |
import { IUnitRange, Nullable, Disposable, IUniverInstanceService } from '@univerjs/core'; | ||
import { IDirtyUnitFeatureMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDatasetConfig, IRuntimeUnitDataType, IUnitData, IUnitExcludedCell, IUnitSheetNameMap, IUnitStylesData } from '../basics/common'; | ||
export interface IFormulaDirtyData { | ||
forceCalculation: boolean; | ||
dirtyRanges: IUnitRange[]; | ||
dirtyNameMap: IDirtyUnitSheetNameMap; | ||
dirtyDefinedNameMap: IDirtyUnitSheetDefinedNameMap; | ||
dirtyUnitFeatureMap: IDirtyUnitFeatureMap; | ||
dirtyUnitOtherFormulaMap: IDirtyUnitOtherFormulaMap; | ||
} | ||
export interface IFormulaCurrentConfigService { | ||
@@ -30,2 +38,3 @@ load(config: IFormulaDatasetConfig): void; | ||
setExecuteSubUnitId(subUnitId: string): void; | ||
getDirtyData(): IFormulaDirtyData; | ||
} | ||
@@ -69,2 +78,3 @@ export declare class FormulaCurrentConfigService extends Disposable implements IFormulaCurrentConfigService { | ||
load(config: IFormulaDatasetConfig): void; | ||
getDirtyData(): IFormulaDirtyData; | ||
loadDirtyRangesAndExcludedCell(dirtyRanges: IUnitRange[], excludedCell?: IUnitExcludedCell): void; | ||
@@ -77,2 +87,2 @@ registerUnitData(unitData: IUnitData): void; | ||
} | ||
export declare const IFormulaCurrentConfigService: import('@wendellhu/redi').IdentifierDecorator<FormulaCurrentConfigService>; | ||
export declare const IFormulaCurrentConfigService: import('@univerjs/core').IdentifierDecorator<FormulaCurrentConfigService>; |
@@ -63,2 +63,2 @@ import { IUnitRange, Nullable, Disposable } from '@univerjs/core'; | ||
} | ||
export declare const IDefinedNamesService: import('@wendellhu/redi').IdentifierDecorator<DefinedNamesService>; | ||
export declare const IDefinedNamesService: import('@univerjs/core').IdentifierDecorator<DefinedNamesService>; |
@@ -11,2 +11,9 @@ import { Nullable, Disposable, ObjectMatrix } from '@univerjs/core'; | ||
} | ||
export interface IFeatureFormulaDependencyParam { | ||
[unitId: string]: Nullable<{ | ||
[sheetId: string]: { | ||
[featureId: string]: Nullable<FormulaDependencyTree>; | ||
}; | ||
}>; | ||
} | ||
export interface IFormulaDependencyParam { | ||
@@ -26,4 +33,5 @@ [unitId: string]: Nullable<{ | ||
hasOtherFormulaDependency(unitId: string, sheetId: string, formulaId: string): boolean; | ||
addFeatureFormulaDependency(featureId: string, dependencyTree: FormulaDependencyTree): void; | ||
removeFeatureFormulaDependency(featureId: string): void; | ||
addFeatureFormulaDependency(unitId: string, sheetId: string, featureId: string, dependencyTree: FormulaDependencyTree): void; | ||
removeFeatureFormulaDependency(unitId: string, sheetId: string, featureIds: string[]): void; | ||
getFeatureFormulaDependency(unitId: string, sheetId: string, featureId: string): Nullable<FormulaDependencyTree>; | ||
hasFeatureFormulaDependency(unitId: string, sheetId: string, featureId: string): boolean; | ||
@@ -73,6 +81,8 @@ addFormulaDependency(unitId: string, sheetId: string, row: number, column: number, dependencyTree: FormulaDependencyTree): void; | ||
removeOtherFormulaDependency(unitId: string, sheetId: string, formulaIds: string[]): void; | ||
getOtherFormulaDependency(unitId: string, sheetId: string, formulaId: string): Nullable<FormulaDependencyTree>; | ||
hasOtherFormulaDependency(unitId: string, sheetId: string, formulaId: string): boolean; | ||
addFeatureFormulaDependency(featureId: string, dependencyTree: FormulaDependencyTree): void; | ||
removeFeatureFormulaDependency(featureId: string): void; | ||
hasFeatureFormulaDependency(featureId: string): boolean; | ||
addFeatureFormulaDependency(unitId: string, sheetId: string, featureId: string, dependencyTree: FormulaDependencyTree): void; | ||
removeFeatureFormulaDependency(unitId: string, sheetId: string, featureIds: string[]): void; | ||
getFeatureFormulaDependency(unitId: string, sheetId: string, featureId: string): Nullable<FormulaDependencyTree>; | ||
hasFeatureFormulaDependency(unitId: string, sheetId: string, featureId: string): boolean; | ||
addFormulaDependency(unitId: string, sheetId: string, row: number, column: number, dependencyTree: FormulaDependencyTree): void; | ||
@@ -83,2 +93,2 @@ removeFormulaDependency(unitId: string, sheetId: string, row: number, column: number): void; | ||
} | ||
export declare const IDependencyManagerService: import('@wendellhu/redi').IdentifierDecorator<DependencyManagerService>; | ||
export declare const IDependencyManagerService: import('@univerjs/core').IdentifierDecorator<DependencyManagerService>; |
import { IUnitRange, Nullable, Disposable } from '@univerjs/core'; | ||
import { Observable } from 'rxjs'; | ||
import { IFeatureDirtyRangeType, IRuntimeUnitDataType } from '../basics/common'; | ||
import { IRemoveFeatureCalculationMutationParam } from '../commands/mutations/set-feature-calculation.mutation'; | ||
import { FormulaDependencyTree } from '../engine/dependency/dependency-tree'; | ||
import { IAllRuntimeData } from './runtime.service'; | ||
import { IFormulaDirtyData } from './current-data.service'; | ||
@@ -9,3 +13,3 @@ export interface IFeatureCalculationManagerParam { | ||
dependencyRanges: IUnitRange[]; | ||
getDirtyData: (currentDependencyTree: FormulaDependencyTree) => { | ||
getDirtyData: (tree: FormulaDependencyTree, dirtyData: IFormulaDirtyData, runtimeData: IAllRuntimeData) => { | ||
runtimeCellData: IRuntimeUnitDataType; | ||
@@ -17,7 +21,8 @@ dirtyRanges: IFeatureDirtyRangeType; | ||
dispose(): void; | ||
remove(featureId: string): void; | ||
get(featureId: string): Nullable<IFeatureCalculationManagerParam>; | ||
has(featureId: string): boolean; | ||
register(featureId: string, referenceExecutor: IFeatureCalculationManagerParam): void; | ||
getReferenceExecutorMap(): Map<string, IFeatureCalculationManagerParam>; | ||
remove(unitId: string, subUnitId: string, featureIds: string[]): void; | ||
get(unitId: string, subUnitId: string, featureId: string): Nullable<IFeatureCalculationManagerParam>; | ||
has(unitId: string, subUnitId: string, featureId: string): boolean; | ||
register(unitId: string, subUnitId: string, featureId: string, referenceExecutor: IFeatureCalculationManagerParam): void; | ||
getReferenceExecutorMap(): Map<string, Map<string, Map<string, IFeatureCalculationManagerParam>>>; | ||
onChanged$: Observable<IRemoveFeatureCalculationMutationParam>; | ||
} | ||
@@ -32,9 +37,11 @@ /** | ||
private _referenceExecutorMap; | ||
private _onChanged$; | ||
readonly onChanged$: Observable<IRemoveFeatureCalculationMutationParam>; | ||
dispose(): void; | ||
remove(featureId: string): void; | ||
get(featureId: string): IFeatureCalculationManagerParam | undefined; | ||
has(featureId: string): boolean; | ||
register(featureId: string, referenceExecutor: IFeatureCalculationManagerParam): void; | ||
getReferenceExecutorMap(): Map<string, IFeatureCalculationManagerParam>; | ||
remove(unitId: string, subUnitId: string, featureIds: string[]): void; | ||
get(unitId: string, subUnitId: string, featureId: string): IFeatureCalculationManagerParam | undefined; | ||
has(unitId: string, subUnitId: string, featureId: string): boolean; | ||
register(unitId: string, subUnitId: string, featureId: string, referenceExecutor: IFeatureCalculationManagerParam): void; | ||
getReferenceExecutorMap(): Map<string, Map<string, Map<string, IFeatureCalculationManagerParam>>>; | ||
} | ||
export declare const IFeatureCalculationManagerService: import('@wendellhu/redi').IdentifierDecorator<FeatureCalculationManagerService>; | ||
export declare const IFeatureCalculationManagerService: import('@univerjs/core').IdentifierDecorator<FeatureCalculationManagerService>; |
@@ -1,3 +0,2 @@ | ||
import { Nullable, Disposable } from '@univerjs/core'; | ||
import { IDisposable } from '@wendellhu/redi'; | ||
import { IDisposable, Nullable, Disposable } from '@univerjs/core'; | ||
import { IFunctionInfo, IFunctionNames } from '../basics/function'; | ||
@@ -46,2 +45,2 @@ import { BaseFunction } from '../functions/base-function'; | ||
} | ||
export declare const IFunctionService: import('@wendellhu/redi').IdentifierDecorator<FunctionService>; | ||
export declare const IFunctionService: import('@univerjs/core').IdentifierDecorator<FunctionService>; |
@@ -39,2 +39,2 @@ import { Nullable, Disposable } from '@univerjs/core'; | ||
} | ||
export declare const IOtherFormulaManagerService: import('@wendellhu/redi').IdentifierDecorator<OtherFormulaManagerService>; | ||
export declare const IOtherFormulaManagerService: import('@univerjs/core').IdentifierDecorator<OtherFormulaManagerService>; |
@@ -182,2 +182,2 @@ import { Nullable, Disposable } from '@univerjs/core'; | ||
} | ||
export declare const IFormulaRuntimeService: import('@wendellhu/redi').IdentifierDecorator<FormulaRuntimeService>; | ||
export declare const IFormulaRuntimeService: import('@univerjs/core').IdentifierDecorator<FormulaRuntimeService>; |
@@ -25,2 +25,2 @@ import { Nullable, Disposable } from '@univerjs/core'; | ||
} | ||
export declare const ISuperTableService: import('@wendellhu/redi').IdentifierDecorator<ISuperTableService>; | ||
export declare const ISuperTableService: import('@univerjs/core').IdentifierDecorator<ISuperTableService>; |
{ | ||
"name": "@univerjs/engine-formula", | ||
"version": "0.2.4", | ||
"version": "0.2.5", | ||
"private": false, | ||
@@ -49,6 +49,5 @@ "description": "UniverSheet normal base-formula-engine", | ||
"peerDependencies": { | ||
"@wendellhu/redi": "0.16.0", | ||
"rxjs": ">=7.0.0", | ||
"@univerjs/core": "0.2.4", | ||
"@univerjs/rpc": "0.2.4" | ||
"@univerjs/core": "0.2.5", | ||
"@univerjs/rpc": "0.2.5" | ||
}, | ||
@@ -61,3 +60,2 @@ "dependencies": { | ||
"@types/big.js": "^6.2.2", | ||
"@wendellhu/redi": "0.16.0", | ||
"rxjs": "^7.8.1", | ||
@@ -67,5 +65,5 @@ "typescript": "^5.5.3", | ||
"vitest": "^2.0.3", | ||
"@univerjs/core": "0.2.4", | ||
"@univerjs/shared": "0.2.4", | ||
"@univerjs/rpc": "0.2.4" | ||
"@univerjs/core": "0.2.5", | ||
"@univerjs/rpc": "0.2.5", | ||
"@univerjs/shared": "0.2.5" | ||
}, | ||
@@ -72,0 +70,0 @@ "univerSpace": { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
1534928
5
8
482
25566