@univerjs/engine-formula 0.1.4 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/index.js +1 -1
- package/lib/es/index.js +3186 -2830
- package/lib/types/basics/calculate.d.ts +1 -15
- package/lib/types/basics/common.d.ts +17 -17
- package/lib/types/basics/dirty.d.ts +2 -16
- package/lib/types/basics/function.d.ts +23 -33
- package/lib/types/basics/match-token.d.ts +1 -15
- package/lib/types/basics/object-class-type.d.ts +2 -15
- package/lib/types/basics/runtime.d.ts +2 -16
- package/lib/types/commands/mutations/register-function.mutation.d.ts +2 -16
- package/lib/types/commands/mutations/set-array-formula-data.mutation.d.ts +4 -18
- package/lib/types/commands/mutations/set-defined-name.mutation.d.ts +14 -18
- package/lib/types/commands/mutations/set-feature-calculation.mutation.d.ts +3 -17
- package/lib/types/commands/mutations/set-formula-calculation.mutation.d.ts +6 -18
- package/lib/types/commands/mutations/set-formula-data.mutation.d.ts +3 -17
- package/lib/types/commands/mutations/set-numfmt-formula-data.mutation.d.ts +3 -17
- package/lib/types/commands/mutations/set-other-formula.mutation.d.ts +15 -19
- package/lib/types/commands/mutations/set-super-table.mutation.d.ts +4 -18
- package/lib/types/commands/mutations/unregister-function.mutation.d.ts +2 -16
- package/lib/types/controller/calculate.controller.d.ts +3 -17
- package/lib/types/controller/formula.controller.d.ts +5 -20
- package/lib/types/controller/register-function.controller.d.ts +3 -17
- package/lib/types/controller/set-defined-name.controller.d.ts +2 -16
- package/lib/types/controller/set-feature-calculation.controller.d.ts +2 -16
- package/lib/types/controller/set-other-formula.controller.d.ts +2 -16
- package/lib/types/controller/set-super-table.controller.d.ts +2 -16
- package/lib/types/engine/analysis/__tests__/create-command-test-bed.d.ts +11 -26
- package/lib/types/engine/analysis/lexer-node.d.ts +7 -17
- package/lib/types/engine/analysis/lexer-tree-builder.d.ts +9 -20
- package/lib/types/engine/analysis/lexer.d.ts +10 -21
- package/lib/types/engine/analysis/parser.d.ts +14 -29
- package/lib/types/engine/ast-node/ast-root-node.d.ts +4 -18
- package/lib/types/engine/ast-node/base-ast-node-factory.d.ts +3 -18
- package/lib/types/engine/ast-node/base-ast-node.d.ts +9 -21
- package/lib/types/engine/ast-node/function-node.d.ts +10 -24
- package/lib/types/engine/ast-node/lambda-node.d.ts +6 -20
- package/lib/types/engine/ast-node/lambda-parameter-node.d.ts +4 -19
- package/lib/types/engine/ast-node/null-node.d.ts +2 -16
- package/lib/types/engine/ast-node/operator-node.d.ts +6 -20
- package/lib/types/engine/ast-node/prefix-node.d.ts +8 -23
- package/lib/types/engine/ast-node/reference-node.d.ts +10 -27
- package/lib/types/engine/ast-node/suffix-node.d.ts +7 -22
- package/lib/types/engine/ast-node/union-node.d.ts +5 -19
- package/lib/types/engine/ast-node/value-node.d.ts +4 -18
- package/lib/types/engine/dependency/dependency-tree.d.ts +4 -19
- package/lib/types/engine/dependency/formula-dependency.d.ts +12 -25
- package/lib/types/engine/interpreter/interpreter.d.ts +6 -20
- package/lib/types/engine/reference-object/base-reference-object.d.ts +20 -32
- package/lib/types/engine/reference-object/cell-reference-object.d.ts +4 -18
- package/lib/types/engine/reference-object/column-reference-object.d.ts +2 -16
- package/lib/types/engine/reference-object/range-reference-object.d.ts +2 -16
- package/lib/types/engine/reference-object/row-reference-object.d.ts +2 -16
- package/lib/types/engine/reference-object/table-reference-object.d.ts +2 -17
- package/lib/types/engine/utils/array-object.d.ts +3 -17
- package/lib/types/engine/utils/ast-node-tool.d.ts +3 -17
- package/lib/types/engine/utils/cell.d.ts +2 -16
- package/lib/types/engine/utils/compare.d.ts +1 -15
- package/lib/types/engine/utils/function-definition.d.ts +1 -15
- package/lib/types/engine/utils/node-type.d.ts +5 -19
- package/lib/types/engine/utils/object-compare.d.ts +2 -16
- package/lib/types/engine/utils/prefixHandler.d.ts +4 -18
- package/lib/types/engine/utils/r1c1-reference.d.ts +2 -16
- package/lib/types/engine/utils/reference.d.ts +2 -17
- package/lib/types/engine/utils/relative-formula.d.ts +4 -0
- package/lib/types/engine/utils/sequence.d.ts +2 -16
- package/lib/types/engine/utils/value-object.d.ts +6 -0
- package/lib/types/engine/value-object/array-value-object.d.ts +5 -20
- package/lib/types/engine/value-object/base-value-object.d.ts +6 -21
- package/lib/types/engine/value-object/cube-value-object.d.ts +3 -17
- package/lib/types/engine/value-object/lambda-value-object.d.ts +4 -18
- package/lib/types/engine/value-object/primitive-object.d.ts +3 -17
- package/lib/types/functions/__tests__/create-function-test-bed.d.ts +13 -26
- package/lib/types/functions/base-function.d.ts +8 -24
- package/lib/types/functions/compatibility/function-map.d.ts +2 -16
- package/lib/types/functions/date/date/index.d.ts +2 -16
- package/lib/types/functions/date/day/index.d.ts +2 -16
- package/lib/types/functions/date/edate/index.d.ts +2 -16
- package/lib/types/functions/date/function-map.d.ts +2 -16
- package/lib/types/functions/date/month/index.d.ts +2 -16
- package/lib/types/functions/date/today/index.d.ts +3 -18
- package/lib/types/functions/date/year/index.d.ts +2 -16
- package/lib/types/functions/information/function-map.d.ts +2 -16
- package/lib/types/functions/information/isblank/index.d.ts +2 -16
- package/lib/types/functions/information/iserr/index.d.ts +2 -16
- package/lib/types/functions/information/iserror/index.d.ts +2 -16
- package/lib/types/functions/information/islogical/index.d.ts +2 -16
- package/lib/types/functions/information/isna/index.d.ts +2 -16
- package/lib/types/functions/information/isnontext/index.d.ts +2 -16
- package/lib/types/functions/information/isnumber/index.d.ts +2 -16
- package/lib/types/functions/information/isref/index.d.ts +3 -17
- package/lib/types/functions/information/istext/index.d.ts +2 -16
- package/lib/types/functions/logical/and/index.d.ts +2 -16
- package/lib/types/functions/logical/function-map.d.ts +4 -18
- package/lib/types/functions/logical/if/index.d.ts +2 -16
- package/lib/types/functions/logical/iferror/index.d.ts +3 -17
- package/lib/types/functions/logical/lambda/index.d.ts +2 -16
- package/lib/types/functions/logical/makearray/index.d.ts +3 -17
- package/lib/types/functions/logical/or/index.d.ts +2 -16
- package/lib/types/functions/lookup/address/index.d.ts +2 -16
- package/lib/types/functions/lookup/column/index.d.ts +3 -17
- package/lib/types/functions/lookup/columns/index.d.ts +2 -16
- package/lib/types/functions/lookup/function-map.d.ts +12 -22
- package/lib/types/functions/lookup/hlookup/index.d.ts +2 -16
- package/lib/types/functions/lookup/index/index.d.ts +3 -19
- package/lib/types/functions/lookup/indirect/index.d.ts +3 -17
- package/lib/types/functions/lookup/lookup/index.d.ts +3 -17
- package/lib/types/functions/lookup/match/index.d.ts +3 -17
- package/lib/types/functions/lookup/offset/index.d.ts +4 -18
- package/lib/types/functions/lookup/row/index.d.ts +3 -17
- package/lib/types/functions/lookup/rows/index.d.ts +2 -16
- package/lib/types/functions/lookup/vlookup/index.d.ts +5 -17
- package/lib/types/functions/lookup/xlookup/index.d.ts +3 -17
- package/lib/types/functions/lookup/xmatch/index.d.ts +3 -17
- package/lib/types/functions/math/abs/index.d.ts +2 -16
- package/lib/types/functions/math/acos/index.d.ts +2 -16
- package/lib/types/functions/math/acosh/index.d.ts +2 -16
- package/lib/types/functions/math/acot/index.d.ts +2 -16
- package/lib/types/functions/math/function-map.d.ts +4 -18
- package/lib/types/functions/math/mod/index.d.ts +2 -16
- package/lib/types/functions/math/power/index.d.ts +2 -16
- package/lib/types/functions/math/product/index.d.ts +2 -16
- package/lib/types/functions/math/subtotal/index.d.ts +3 -17
- package/lib/types/functions/math/sum/index.d.ts +2 -16
- package/lib/types/functions/math/sumif/index.d.ts +2 -16
- package/lib/types/functions/math/sumifs/index.d.ts +3 -18
- package/lib/types/functions/meta/compare/index.d.ts +3 -17
- package/lib/types/functions/meta/cube/index.d.ts +2 -16
- package/lib/types/functions/meta/divided/index.d.ts +2 -16
- package/lib/types/functions/meta/function-map.d.ts +2 -16
- package/lib/types/functions/meta/minus/index.d.ts +2 -16
- package/lib/types/functions/meta/multiply/index.d.ts +2 -16
- package/lib/types/functions/meta/plus/index.d.ts +2 -16
- package/lib/types/functions/statistical/average/index.d.ts +2 -16
- package/lib/types/functions/statistical/count/index.d.ts +2 -16
- package/lib/types/functions/statistical/counta/index.d.ts +2 -16
- package/lib/types/functions/statistical/function-map.d.ts +2 -16
- package/lib/types/functions/statistical/max/index.d.ts +2 -16
- package/lib/types/functions/statistical/min/index.d.ts +2 -16
- package/lib/types/functions/statistical/stdev-p/index.d.ts +3 -17
- package/lib/types/functions/statistical/stdev-s/index.d.ts +3 -17
- package/lib/types/functions/statistical/stdeva/index.d.ts +3 -17
- package/lib/types/functions/statistical/stdevpa/index.d.ts +3 -17
- package/lib/types/functions/statistical/var-p/index.d.ts +3 -17
- package/lib/types/functions/statistical/var-s/index.d.ts +3 -17
- package/lib/types/functions/statistical/vara/index.d.ts +3 -17
- package/lib/types/functions/statistical/varpa/index.d.ts +3 -17
- package/lib/types/functions/text/concatenate/index.d.ts +2 -16
- package/lib/types/functions/text/function-map.d.ts +2 -16
- package/lib/types/functions/text/len/index.d.ts +2 -16
- package/lib/types/functions/text/lenb/index.d.ts +2 -16
- package/lib/types/functions/text/text/index.d.ts +2 -16
- package/lib/types/index.d.ts +8 -5
- package/lib/types/models/__tests__/create-command-test-bed.d.ts +10 -25
- package/lib/types/models/formula-data.model.d.ts +3 -18
- package/lib/types/plugin.d.ts +4 -19
- package/lib/types/services/active-dirty-manager.service.d.ts +35 -0
- package/lib/types/services/calculate-formula.service.d.ts +12 -27
- package/lib/types/services/current-data.service.d.ts +20 -19
- package/lib/types/services/defined-names.service.d.ts +52 -25
- package/lib/types/services/feature-calculation-manager.service.d.ts +5 -20
- package/lib/types/services/function.service.d.ts +5 -20
- package/lib/types/services/other-formula-manager.service.d.ts +8 -19
- package/lib/types/services/runtime.service.d.ts +6 -21
- package/lib/types/services/super-table.service.d.ts +4 -19
- package/lib/umd/index.js +1 -1
- package/package.json +6 -6
- package/lib/types/engine/utils/object-covert.d.ts +0 -18
- /package/lib/types/engine/utils/__tests__/{object-covert.spec.d.ts → value-object.spec.d.ts} +0 -0
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class StdevS extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Stdeva extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Stdevpa extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class VarP extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class VarS extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Vara extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Varpa extends BaseFunction {
|
|
19
|
-
calculate(...variants: BaseValueObject[]): BaseValueObject | import(
|
|
5
|
+
calculate(...variants: BaseValueObject[]): BaseValueObject | import('../../..').ArrayValueObject;
|
|
20
6
|
}
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Concatenate extends BaseFunction {
|
|
19
5
|
calculate(...textValues: BaseValueObject[]): BaseValueObject;
|
|
20
6
|
}
|
|
@@ -1,18 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import { Concatenate } from './concatenate';
|
|
17
1
|
import { FUNCTION_NAMES_TEXT } from './function-names';
|
|
2
|
+
import { Concatenate } from './concatenate';
|
|
3
|
+
|
|
18
4
|
export declare const functionText: (FUNCTION_NAMES_TEXT | typeof Concatenate)[][];
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import { type BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Len extends BaseFunction {
|
|
19
5
|
calculate(text: BaseValueObject): BaseValueObject;
|
|
20
6
|
private _handleSingleText;
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import { type BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Lenb extends BaseFunction {
|
|
19
5
|
calculate(text: BaseValueObject): BaseValueObject;
|
|
20
6
|
private _handleSingleText;
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import { type BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
17
1
|
import { BaseFunction } from '../../base-function';
|
|
2
|
+
import { BaseValueObject } from '../../../engine/value-object/base-value-object';
|
|
3
|
+
|
|
18
4
|
export declare class Text extends BaseFunction {
|
|
19
5
|
calculate(text: BaseValueObject, formatText: BaseValueObject): BaseValueObject;
|
|
20
6
|
}
|
package/lib/types/index.d.ts
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
export type { IArrayFormulaRangeType, IArrayFormulaUnitCellType, IDirtyUnitFeatureMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDataItem, IFormulaDatasetConfig, IRuntimeUnitDataType, ISheetData, IUnitData, IUnitSheetNameMap, INumfmtItemMap, } from './basics/common';
|
|
16
|
+
export type { IArrayFormulaRangeType, IArrayFormulaUnitCellType, IDirtyUnitFeatureMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDataItem, IFormulaDatasetConfig, IRuntimeUnitDataType, ISheetData, IUnitData, IUnitSheetNameMap, INumfmtItemMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, } from './basics/common';
|
|
17
17
|
export { isInDirtyRange } from './basics/dirty';
|
|
18
18
|
export { ErrorType } from './basics/error-type';
|
|
19
19
|
export { FunctionType, type IFunctionInfo, type IFunctionParam } from './basics/function';
|
|
@@ -23,11 +23,11 @@ export { convertUnitDataToRuntime } from './basics/runtime';
|
|
|
23
23
|
export { matchToken, compareToken, operatorToken } from './basics/token';
|
|
24
24
|
export { RegisterFunctionMutation } from './commands/mutations/register-function.mutation';
|
|
25
25
|
export { type ISetArrayFormulaDataMutationParams, SetArrayFormulaDataMutation, SetArrayFormulaDataUndoMutationFactory, } from './commands/mutations/set-array-formula-data.mutation';
|
|
26
|
-
export { RemoveDefinedNameMutation, SetDefinedNameMutation } from './commands/mutations/set-defined-name.mutation';
|
|
26
|
+
export { RemoveDefinedNameMutation, SetDefinedNameMutation, SetDefinedNameCurrentMutation, type ISetDefinedNameMutationSearchParam, type ISetDefinedNameMutationParam } from './commands/mutations/set-defined-name.mutation';
|
|
27
27
|
export { RemoveFeatureCalculationMutation, SetFeatureCalculationMutation, } from './commands/mutations/set-feature-calculation.mutation';
|
|
28
28
|
export { type ISetFormulaCalculationNotificationMutation, type ISetFormulaCalculationResultMutation, type ISetFormulaCalculationStartMutation, SetFormulaCalculationNotificationMutation, SetFormulaCalculationResultMutation, SetFormulaCalculationStartMutation, SetFormulaCalculationStopMutation, } from './commands/mutations/set-formula-calculation.mutation';
|
|
29
29
|
export { type ISetFormulaDataMutationParams, SetFormulaDataMutation, } from './commands/mutations/set-formula-data.mutation';
|
|
30
|
-
export { RemoveOtherFormulaMutation, SetOtherFormulaMutation } from './commands/mutations/set-other-formula.mutation';
|
|
30
|
+
export { RemoveOtherFormulaMutation, SetOtherFormulaMutation, type ISetOtherFormulaMutationParams, type IRemoveOtherFormulaMutationParams } from './commands/mutations/set-other-formula.mutation';
|
|
31
31
|
export { RemoveSuperTableMutation, SetSuperTableMutation, SetSuperTableOptionMutation, } from './commands/mutations/set-super-table.mutation';
|
|
32
32
|
export { UnregisterFunctionMutation } from './commands/mutations/unregister-function.mutation';
|
|
33
33
|
export { LexerNode } from './engine/analysis/lexer-node';
|
|
@@ -39,6 +39,7 @@ export { deserializeRangeWithSheet, getAbsoluteRefTypeWithSingleString, getAbsol
|
|
|
39
39
|
export { generateStringWithSequence, type ISequenceNode, sequenceNodeType } from './engine/utils/sequence';
|
|
40
40
|
export { ArrayValueObject, ValueObjectFactory } from './engine/value-object/array-value-object';
|
|
41
41
|
export { BaseValueObject, ErrorValueObject } from './engine/value-object/base-value-object';
|
|
42
|
+
export { BooleanValue } from './basics/common';
|
|
42
43
|
export type { PrimitiveValueType } from './engine/value-object/primitive-object';
|
|
43
44
|
export { NumberValueObject } from './engine/value-object/primitive-object';
|
|
44
45
|
export { BooleanValueObject } from './engine/value-object/primitive-object';
|
|
@@ -82,13 +83,15 @@ export { CalculateFormulaService } from './services/calculate-formula.service';
|
|
|
82
83
|
export { FeatureCalculationManagerService, IFeatureCalculationManagerService, } from './services/feature-calculation-manager.service';
|
|
83
84
|
export { FunctionService } from './services/function.service';
|
|
84
85
|
export { IFunctionService } from './services/function.service';
|
|
85
|
-
export {
|
|
86
|
+
export { IOtherFormulaManagerService, OtherFormulaManagerService } from './services/other-formula-manager.service';
|
|
86
87
|
export { FormulaExecuteStageType, type IExecutionInProgressParams } from './services/runtime.service';
|
|
87
88
|
export { FormulaExecutedStateType, type IAllRuntimeData } from './services/runtime.service';
|
|
88
89
|
export { SetNumfmtFormulaDataMutation } from './commands/mutations/set-numfmt-formula-data.mutation';
|
|
89
90
|
export type { ISetNumfmtFormulaDataMutationParams } from './commands/mutations/set-numfmt-formula-data.mutation';
|
|
90
91
|
export { isReferenceString } from './basics/regex';
|
|
91
92
|
export { matchRefDrawToken } from './basics/match-token';
|
|
92
|
-
export { IDefinedNamesService, DefinedNamesService } from './services/defined-names.service';
|
|
93
|
+
export { IDefinedNamesService, DefinedNamesService, type IDefinedNamesServiceParam, type IDefinedNameMapItem } from './services/defined-names.service';
|
|
94
|
+
export { isFormulaTransformable, transformFormula } from './engine/utils/relative-formula';
|
|
93
95
|
export { IFormulaRuntimeService, FormulaRuntimeService } from './services/runtime.service';
|
|
94
96
|
export { IFormulaCurrentConfigService, FormulaCurrentConfigService } from './services/current-data.service';
|
|
97
|
+
export { IActiveDirtyManagerService } from './services/active-dirty-manager.service';
|
|
@@ -1,30 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { IWorkbookData } from '@univerjs/core';
|
|
17
|
-
import { Univer } from '@univerjs/core';
|
|
18
|
-
import type { Dependency } from '@wendellhu/redi';
|
|
1
|
+
import { Dependency } from '@wendellhu/redi';
|
|
2
|
+
import { IWorkbookData, Univer } from '@univerjs/core';
|
|
3
|
+
|
|
19
4
|
export declare function createCommandTestBed(workbookConfig?: IWorkbookData, dependencies?: Dependency[]): {
|
|
20
5
|
univer: Univer;
|
|
21
6
|
get: {
|
|
22
|
-
<T>(id: import(
|
|
23
|
-
<T_1>(id: import(
|
|
24
|
-
<T_2>(id: import(
|
|
25
|
-
<T_3>(id: import(
|
|
26
|
-
<T_4>(id: import(
|
|
27
|
-
<T_5>(id: import(
|
|
7
|
+
<T>(id: import('@wendellhu/redi').DependencyIdentifier<T>, lookUp?: import('@wendellhu/redi').LookUp | undefined): T;
|
|
8
|
+
<T_1>(id: import('@wendellhu/redi').DependencyIdentifier<T_1>, quantity: import("@wendellhu/redi").Quantity.MANY, lookUp?: import('@wendellhu/redi').LookUp | undefined): T_1[];
|
|
9
|
+
<T_2>(id: import('@wendellhu/redi').DependencyIdentifier<T_2>, quantity: import("@wendellhu/redi").Quantity.OPTIONAL, lookUp?: import('@wendellhu/redi').LookUp | undefined): T_2 | null;
|
|
10
|
+
<T_3>(id: import('@wendellhu/redi').DependencyIdentifier<T_3>, quantity: import("@wendellhu/redi").Quantity.REQUIRED, lookUp?: import('@wendellhu/redi').LookUp | undefined): T_3;
|
|
11
|
+
<T_4>(id: import('@wendellhu/redi').DependencyIdentifier<T_4>, quantity?: import('@wendellhu/redi').Quantity | undefined, lookUp?: import('@wendellhu/redi').LookUp | undefined): T_4 | T_4[] | null;
|
|
12
|
+
<T_5>(id: import('@wendellhu/redi').DependencyIdentifier<T_5>, quantityOrLookup?: import('@wendellhu/redi').Quantity | import('@wendellhu/redi').LookUp | undefined, lookUp?: import('@wendellhu/redi').LookUp | undefined): T_5 | T_5[] | null;
|
|
28
13
|
};
|
|
29
|
-
sheet: import(
|
|
14
|
+
sheet: import('@univerjs/core').Workbook;
|
|
30
15
|
};
|
|
@@ -1,22 +1,7 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { ICellData, IObjectMatrixPrimitiveType, Nullable } from '@univerjs/core';
|
|
17
|
-
import { Disposable, IUniverInstanceService, ObjectMatrix } from '@univerjs/core';
|
|
18
|
-
import type { IArrayFormulaRangeType, IArrayFormulaUnitCellType, IFormulaData, IFormulaDataItem, INumfmtItemMap, IRuntimeUnitDataType, IUnitData, IUnitSheetNameMap } from '../basics/common';
|
|
19
1
|
import { LexerTreeBuilder } from '../engine/analysis/lexer-tree-builder';
|
|
2
|
+
import { IArrayFormulaRangeType, IArrayFormulaUnitCellType, IFormulaData, IFormulaDataItem, INumfmtItemMap, IRuntimeUnitDataType, IUnitData, IUnitSheetNameMap } from '../basics/common';
|
|
3
|
+
import { ICellData, IObjectMatrixPrimitiveType, Nullable, Disposable, IUniverInstanceService, ObjectMatrix } from '@univerjs/core';
|
|
4
|
+
|
|
20
5
|
export interface IFormulaIdMap {
|
|
21
6
|
f: string;
|
|
22
7
|
r: number;
|
package/lib/types/plugin.d.ts
CHANGED
|
@@ -1,23 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
1
|
+
import { BaseFunction } from './functions/base-function';
|
|
2
|
+
import { IFunctionNames } from './basics/function';
|
|
3
|
+
import { Ctor, Injector } from '@wendellhu/redi';
|
|
16
4
|
import { Plugin } from '@univerjs/core';
|
|
17
|
-
|
|
18
|
-
import { Injector } from '@wendellhu/redi';
|
|
19
|
-
import type { IFunctionNames } from './basics/function';
|
|
20
|
-
import type { BaseFunction } from './functions/base-function';
|
|
5
|
+
|
|
21
6
|
interface IUniverFormulaEngine {
|
|
22
7
|
notExecuteFormula?: boolean;
|
|
23
8
|
function?: Array<[Ctor<BaseFunction>, IFunctionNames]>;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { IDirtyUnitFeatureMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IDirtyUnitSheetNameMap } from '../basics/common';
|
|
2
|
+
import { ICommandInfo, IUnitRange, Nullable, Disposable } from '@univerjs/core';
|
|
3
|
+
|
|
4
|
+
export interface IDirtyConversionManagerParams {
|
|
5
|
+
commandId: string;
|
|
6
|
+
getDirtyData: (command: ICommandInfo) => {
|
|
7
|
+
dirtyRanges?: IUnitRange[];
|
|
8
|
+
dirtyNameMap?: IDirtyUnitSheetNameMap;
|
|
9
|
+
dirtyDefinedNameMap?: IDirtyUnitSheetDefinedNameMap;
|
|
10
|
+
dirtyUnitFeatureMap?: IDirtyUnitFeatureMap;
|
|
11
|
+
dirtyUnitOtherFormulaMap?: IDirtyUnitOtherFormulaMap;
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
export interface IActiveDirtyManagerService {
|
|
15
|
+
dispose(): void;
|
|
16
|
+
remove(commandId: string): void;
|
|
17
|
+
get(commandId: string): Nullable<IDirtyConversionManagerParams>;
|
|
18
|
+
has(featureId: string): boolean;
|
|
19
|
+
register(featureId: string, dirtyConversion: IDirtyConversionManagerParams): void;
|
|
20
|
+
getDirtyConversionMap(): Map<string, IDirtyConversionManagerParams>;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Actively mark as dirty, calculate the dirty area based on the command,
|
|
24
|
+
* and plugins can register the ref range they affect into the formula engine.
|
|
25
|
+
*/
|
|
26
|
+
export declare class ActiveDirtyManagerService extends Disposable implements IActiveDirtyManagerService {
|
|
27
|
+
private _dirtyConversionMap;
|
|
28
|
+
dispose(): void;
|
|
29
|
+
remove(commandId: string): void;
|
|
30
|
+
get(commandId: string): IDirtyConversionManagerParams | undefined;
|
|
31
|
+
has(commandId: string): boolean;
|
|
32
|
+
register(commandId: string, dirtyConversion: IDirtyConversionManagerParams): void;
|
|
33
|
+
getDirtyConversionMap(): Map<string, IDirtyConversionManagerParams>;
|
|
34
|
+
}
|
|
35
|
+
export declare const IActiveDirtyManagerService: import('@wendellhu/redi').IdentifierDecorator<ActiveDirtyManagerService>;
|
|
@@ -1,28 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
3
|
-
*
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import { Disposable, IConfigService } from '@univerjs/core';
|
|
17
|
-
import type { IFeatureDirtyRangeType, IFormulaDatasetConfig, IRuntimeUnitDataType } from '../basics/common';
|
|
18
|
-
import { Lexer } from '../engine/analysis/lexer';
|
|
19
|
-
import { AstTreeBuilder } from '../engine/analysis/parser';
|
|
20
|
-
import { ErrorNode } from '../engine/ast-node/base-ast-node';
|
|
21
|
-
import { FormulaDependencyGenerator } from '../engine/dependency/formula-dependency';
|
|
22
|
-
import { Interpreter } from '../engine/interpreter/interpreter';
|
|
1
|
+
import { IAllRuntimeData, IExecutionInProgressParams, IFormulaRuntimeService } from './runtime.service';
|
|
23
2
|
import { IFormulaCurrentConfigService } from './current-data.service';
|
|
24
|
-
import
|
|
25
|
-
import {
|
|
3
|
+
import { Interpreter } from '../engine/interpreter/interpreter';
|
|
4
|
+
import { FormulaDependencyGenerator } from '../engine/dependency/formula-dependency';
|
|
5
|
+
import { ErrorNode } from '../engine/ast-node/base-ast-node';
|
|
6
|
+
import { AstTreeBuilder } from '../engine/analysis/parser';
|
|
7
|
+
import { Lexer } from '../engine/analysis/lexer';
|
|
8
|
+
import { IFeatureDirtyRangeType, IFormulaDatasetConfig, IRuntimeUnitDataType } from '../basics/common';
|
|
9
|
+
import { Disposable, IConfigService } from '@univerjs/core';
|
|
10
|
+
|
|
26
11
|
export declare const DEFAULT_CYCLE_REFERENCE_COUNT = 1;
|
|
27
12
|
export declare const CYCLE_REFERENCE_COUNT = "cycleReferenceCount";
|
|
28
13
|
export declare const EVERY_N_FUNCTION_EXECUTION_PAUSE = 100;
|
|
@@ -35,11 +20,11 @@ export declare class CalculateFormulaService extends Disposable {
|
|
|
35
20
|
private readonly _interpreter;
|
|
36
21
|
private readonly _astTreeBuilder;
|
|
37
22
|
private readonly _executionStartListener$;
|
|
38
|
-
readonly executionStartListener$: import(
|
|
23
|
+
readonly executionStartListener$: import('rxjs').Observable<boolean>;
|
|
39
24
|
private readonly _executionCompleteListener$;
|
|
40
|
-
readonly executionCompleteListener$: import(
|
|
25
|
+
readonly executionCompleteListener$: import('rxjs').Observable<IAllRuntimeData>;
|
|
41
26
|
private readonly _executionInProgressListener$;
|
|
42
|
-
readonly executionInProgressListener$: import(
|
|
27
|
+
readonly executionInProgressListener$: import('rxjs').Observable<IExecutionInProgressParams>;
|
|
43
28
|
constructor(_configService: IConfigService, _lexer: Lexer, _currentConfigService: IFormulaCurrentConfigService, _runtimeService: IFormulaRuntimeService, _formulaDependencyGenerator: FormulaDependencyGenerator, _interpreter: Interpreter, _astTreeBuilder: AstTreeBuilder);
|
|
44
29
|
dispose(): void;
|
|
45
30
|
/**
|
|
@@ -1,21 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
|
-
import type { IUnitRange, Nullable } from '@univerjs/core';
|
|
17
|
-
import { Disposable, IUniverInstanceService } from '@univerjs/core';
|
|
18
|
-
import type { IDirtyUnitFeatureMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDatasetConfig, INumfmtItemMap, IRuntimeUnitDataType, IUnitData, IUnitExcludedCell, IUnitSheetNameMap } from '../basics/common';
|
|
1
|
+
import { IDirtyUnitFeatureMap, IDirtyUnitOtherFormulaMap, IDirtyUnitSheetDefinedNameMap, IDirtyUnitSheetNameMap, IFormulaData, IFormulaDatasetConfig, INumfmtItemMap, IRuntimeUnitDataType, IUnitData, IUnitExcludedCell, IUnitSheetNameMap } from '../basics/common';
|
|
2
|
+
import { IUnitRange, Nullable, Disposable, IUniverInstanceService } from '@univerjs/core';
|
|
3
|
+
|
|
19
4
|
export declare const DEFAULT_DOCUMENT_SUB_COMPONENT_ID = "__default_document_sub_component_id20231101__";
|
|
20
5
|
export interface IFormulaCurrentConfigService {
|
|
21
6
|
load(config: IFormulaDatasetConfig): void;
|
|
@@ -25,6 +10,7 @@ export interface IFormulaCurrentConfigService {
|
|
|
25
10
|
isForceCalculate(): boolean;
|
|
26
11
|
getDirtyRanges(): IUnitRange[];
|
|
27
12
|
getDirtyNameMap(): IDirtyUnitSheetNameMap;
|
|
13
|
+
getDirtyDefinedNameMap(): IDirtyUnitSheetDefinedNameMap;
|
|
28
14
|
getDirtyUnitFeatureMap(): IDirtyUnitFeatureMap;
|
|
29
15
|
registerUnitData(unitData: IUnitData): void;
|
|
30
16
|
registerFormulaData(formulaData: IFormulaData): void;
|
|
@@ -33,6 +19,11 @@ export interface IFormulaCurrentConfigService {
|
|
|
33
19
|
loadDirtyRangesAndExcludedCell(dirtyRanges: IUnitRange[], excludedCell?: IUnitExcludedCell): void;
|
|
34
20
|
getArrayFormulaCellData(): IRuntimeUnitDataType;
|
|
35
21
|
getSheetName(unitId: string, sheetId: string): string;
|
|
22
|
+
getDirtyUnitOtherFormulaMap(): IDirtyUnitOtherFormulaMap;
|
|
23
|
+
getExecuteUnitId(): Nullable<string>;
|
|
24
|
+
getExecuteSubUnitId(): Nullable<string>;
|
|
25
|
+
setExecuteUnitId(unitId: string): void;
|
|
26
|
+
setExecuteSubUnitId(subUnitId: string): void;
|
|
36
27
|
}
|
|
37
28
|
export declare class FormulaCurrentConfigService extends Disposable implements IFormulaCurrentConfigService {
|
|
38
29
|
private readonly _currentUniverService;
|
|
@@ -43,12 +34,20 @@ export declare class FormulaCurrentConfigService extends Disposable implements I
|
|
|
43
34
|
private _forceCalculate;
|
|
44
35
|
private _dirtyRanges;
|
|
45
36
|
private _dirtyNameMap;
|
|
37
|
+
private _dirtyDefinedNameMap;
|
|
46
38
|
private _numfmtItemMap;
|
|
47
39
|
private _dirtyUnitFeatureMap;
|
|
40
|
+
private _dirtyUnitOtherFormulaMap;
|
|
48
41
|
private _excludedCell;
|
|
49
42
|
private _sheetIdToNameMap;
|
|
43
|
+
private _executeUnitId;
|
|
44
|
+
private _executeSubUnitId;
|
|
50
45
|
constructor(_currentUniverService: IUniverInstanceService);
|
|
51
46
|
dispose(): void;
|
|
47
|
+
getExecuteUnitId(): Nullable<string>;
|
|
48
|
+
getExecuteSubUnitId(): Nullable<string>;
|
|
49
|
+
setExecuteUnitId(unitId: string): void;
|
|
50
|
+
setExecuteSubUnitId(subUnitId: string): void;
|
|
52
51
|
getExcludedRange(): Nullable<IUnitExcludedCell>;
|
|
53
52
|
getUnitData(): IUnitData;
|
|
54
53
|
getFormulaData(): IFormulaData;
|
|
@@ -57,8 +56,10 @@ export declare class FormulaCurrentConfigService extends Disposable implements I
|
|
|
57
56
|
isForceCalculate(): boolean;
|
|
58
57
|
getDirtyRanges(): IUnitRange[];
|
|
59
58
|
getDirtyNameMap(): IDirtyUnitSheetNameMap;
|
|
59
|
+
getDirtyDefinedNameMap(): IDirtyUnitSheetDefinedNameMap;
|
|
60
60
|
getNumfmtItemMap(): INumfmtItemMap;
|
|
61
61
|
getDirtyUnitFeatureMap(): IDirtyUnitFeatureMap;
|
|
62
|
+
getDirtyUnitOtherFormulaMap(): IDirtyUnitOtherFormulaMap;
|
|
62
63
|
getSheetName(unitId: string, sheetId: string): string;
|
|
63
64
|
load(config: IFormulaDatasetConfig): void;
|
|
64
65
|
loadDirtyRangesAndExcludedCell(dirtyRanges: IUnitRange[], excludedCell?: IUnitExcludedCell): void;
|
|
@@ -68,4 +69,4 @@ export declare class FormulaCurrentConfigService extends Disposable implements I
|
|
|
68
69
|
private _mergeNameMap;
|
|
69
70
|
private _loadSheetData;
|
|
70
71
|
}
|
|
71
|
-
export declare const IFormulaCurrentConfigService: import(
|
|
72
|
+
export declare const IFormulaCurrentConfigService: import('@wendellhu/redi').IdentifierDecorator<FormulaCurrentConfigService>;
|