@elyx-code/project-logic-tree 0.0.6018 → 0.0.6020
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/dist/definitions/built-in-base-entities/ids.d.ts +36 -0
- package/dist/definitions/mock/default-mock/functions/manual-hello-world-loop/loop/break-statement.d.ts +1 -3
- package/dist/definitions/mock/default-mock/functions/manual-hello-world-loop/loop/continue-statement.d.ts +1 -1
- package/dist/index.js +10547 -10113
- package/dist/index.umd.cjs +251 -251
- package/dist/tree/state/action-descriptor/action-descriptor.d.ts +1 -1
- package/dist/tree/state/argument-declaration/argument-declaration.d.ts +1 -2
- package/dist/tree/state/custom-entity/custom-entity.d.ts +1 -1
- package/dist/tree/state/data-type/data-type.d.ts +2 -1
- package/dist/tree/state/function-declaration/function-declaration.d.ts +2 -2
- package/dist/tree/state/input-map/input-map.d.ts +1 -1
- package/dist/tree/state/loop/loop.d.ts +4 -1
- package/dist/tree/state/loop/loop.test.d.ts +1 -0
- package/dist/tree/state/loop/validation/logic-validation.d.ts +1 -0
- package/dist/tree/state/return-declaration/return-declaration.d.ts +1 -0
- package/dist/tree/state/return-declaration/return-declaration.test.d.ts +1 -0
- package/dist/tree/state/types/index.d.ts +7 -0
- package/dist/tree/state/value-descriptor/value-descriptor.d.ts +1 -1
- package/dist/tree/utils/data-type.d.ts +1 -0
- package/package.json +1 -1
|
@@ -109,7 +109,7 @@ export declare class ActionDescriptorState implements IActionDescriptor, UserMan
|
|
|
109
109
|
};
|
|
110
110
|
getErrors(): EntityError[];
|
|
111
111
|
getShallowErrors(): EntityError[];
|
|
112
|
-
clone(
|
|
112
|
+
clone(parent?: CustomEntityState | PrimitiveEntityState | BuiltInBaseEntityState | DataTypeState | null, newId?: string | null, subscribe?: boolean): ActionDescriptorState;
|
|
113
113
|
setDynamicArgumentsDataType(dataType: DataTypeState): ActionDescriptorState;
|
|
114
114
|
setDynamicReturnsDataType(dataType: DataTypeState): ActionDescriptorState;
|
|
115
115
|
addFixedArgument(argument: ValueDescriptorState): ActionDescriptorState;
|
|
@@ -4,7 +4,6 @@ import { BaseState, ChildEntityState, EntityWithValueClass, UserManagedEntitySta
|
|
|
4
4
|
import { EntityState, EntryPointEntityState, ValueReadingEntityState } from '../types';
|
|
5
5
|
import { DataTypeState } from '../data-type';
|
|
6
6
|
import { ProjectState } from '../project/project';
|
|
7
|
-
import { ActionDescriptorState } from '../action-descriptor';
|
|
8
7
|
import { SearchState } from '../search';
|
|
9
8
|
import { EntityError, EntityGenerationError } from '../../state/error';
|
|
10
9
|
import { PrimitiveValueState } from '../primitive-value';
|
|
@@ -93,7 +92,7 @@ export declare class ArgumentDeclarationState implements IArgumentDeclaration, U
|
|
|
93
92
|
getErrors(): EntityError[];
|
|
94
93
|
getShallowErrors(): EntityError[];
|
|
95
94
|
getDefaultValue(): PrimitiveValueState | null;
|
|
96
|
-
clone(
|
|
95
|
+
clone(parent?: EntryPointEntityState | SearchState | null, newId?: string | null, subscribe?: boolean): ArgumentDeclarationState;
|
|
97
96
|
getDataType(): DataTypeState | null;
|
|
98
97
|
setDataType(dataType: DataTypeState): ArgumentDeclarationState;
|
|
99
98
|
removeDataType(): ArgumentDeclarationState;
|
|
@@ -110,7 +110,7 @@ export declare class CustomEntityState implements BaseState, UserManagedEntitySt
|
|
|
110
110
|
};
|
|
111
111
|
getErrors(): EntityError[];
|
|
112
112
|
getShallowErrors(): EntityError[];
|
|
113
|
-
clone(): CustomEntityState;
|
|
113
|
+
clone(parent?: DataTypeState | null, newId?: string | null, subscribe?: boolean): CustomEntityState;
|
|
114
114
|
getFunctionDeclaration(id: EntityId): FunctionDeclarationState | undefined;
|
|
115
115
|
implement(newEntityName: string, newId?: string): {
|
|
116
116
|
errors: [];
|
|
@@ -102,12 +102,13 @@ export declare class DataTypeState implements IDataType, UserManagedEntityStateF
|
|
|
102
102
|
};
|
|
103
103
|
getErrors(): EntityError[];
|
|
104
104
|
getShallowErrors(): EntityError[];
|
|
105
|
-
clone(parent?: PropertyState | VariableDeclarationState | ArgumentDeclarationState | ReturnDeclarationState | ActionDescriptorState | DataTypeState | null, newId?: string | null, subscribe?: boolean): DataTypeState;
|
|
105
|
+
clone(parent?: PropertyState | VariableDeclarationState | ArgumentDeclarationState | ReturnDeclarationState | ActionDescriptorState | ValueDescriptorState | DataTypeState | null, newId?: string | null, subscribe?: boolean): DataTypeState;
|
|
106
106
|
addToAndGroup(child: DataTypeState): DataTypeState;
|
|
107
107
|
addToOrGroup(child: DataTypeState): DataTypeState;
|
|
108
108
|
getDefaultValue(): PrimitiveValueState | null;
|
|
109
109
|
setDefaultValue(value: PrimitiveValueState): DataTypeState;
|
|
110
110
|
setEntity(entity: CustomEntityState | PrimitiveEntityState | ActionDescriptorState | BuiltInBaseEntityState): DataTypeState;
|
|
111
|
+
isResolved(): boolean;
|
|
111
112
|
inferFromInputs(inputs: VariableInputMapState[]): DataTypeState;
|
|
112
113
|
}
|
|
113
114
|
export type DataTypePayloadUnion = DataTypeState | DataTypeTypesUnion;
|
|
@@ -69,7 +69,7 @@ export declare class FunctionDeclarationState implements IFunctionDeclaration, B
|
|
|
69
69
|
subscribeDetachedChild(child: CanvasEntityState): FunctionDeclarationState;
|
|
70
70
|
addInputDeclaration(input: ArgumentDeclarationState): FunctionDeclarationState;
|
|
71
71
|
removeInputDeclaration(input: ArgumentDeclarationState): FunctionDeclarationState;
|
|
72
|
-
setParent(parent: ProjectState | InstalledProjectState | CustomEntityState | LoopState | BuiltInBaseEntityState): FunctionDeclarationState;
|
|
72
|
+
setParent(parent: ProjectState | InstalledProjectState | CustomEntityState | LoopState | BuiltInBaseEntityState | PrimitiveEntityState): FunctionDeclarationState;
|
|
73
73
|
addCall(entity: CallableEntityState): FunctionDeclarationState;
|
|
74
74
|
removeCall(entity: CallableEntityState): FunctionDeclarationState;
|
|
75
75
|
initChildren(): FunctionDeclarationState;
|
|
@@ -109,7 +109,7 @@ export declare class FunctionDeclarationState implements IFunctionDeclaration, B
|
|
|
109
109
|
};
|
|
110
110
|
getErrors(): EntityError[];
|
|
111
111
|
getShallowErrors(): EntityError[];
|
|
112
|
-
clone(
|
|
112
|
+
clone(parent?: CustomEntityState | null, newId?: string | null, subscribe?: boolean, cloneBody?: boolean): FunctionDeclarationState;
|
|
113
113
|
getVariableInstances(): VariableInstanceState[];
|
|
114
114
|
getArgument(id: EntityId): ArgumentDeclarationState | null;
|
|
115
115
|
createCall(parent?: EntityWithLogicScopeState | ProjectState, overrides?: Partial<IFunctionCallTransfer>): FunctionCallState;
|
|
@@ -63,7 +63,7 @@ export declare class InputMapState implements IInputMap, ValueReadingEntityClass
|
|
|
63
63
|
self: InputMapState;
|
|
64
64
|
};
|
|
65
65
|
setParent(parent: PassThroughCallableEntityState | InputMapState): InputMapState;
|
|
66
|
-
setDeclaration(declaration: ArgumentDeclarationState | PropertyState | null): InputMapState;
|
|
66
|
+
setDeclaration(declaration: ArgumentDeclarationState | PropertyState | ValueDescriptorState | null): InputMapState;
|
|
67
67
|
removeInput(input: InputMapState): InputMapState;
|
|
68
68
|
addInput(input: InputMapState): InputMapState;
|
|
69
69
|
initChildren(): InputMapState;
|
|
@@ -3,7 +3,7 @@ import { ZodError } from 'zod';
|
|
|
3
3
|
import { BaseCanvasDraggableState, BaseState, CallableEntityClass, ChildEntityState, EntityWithLogicScopeClass, PassThroughCallableEntityClass, UserManagedEntityStateFunctionality } from '../base';
|
|
4
4
|
import { ActionInputMapState } from '../input-map';
|
|
5
5
|
import { ActionOutputMapState } from '../output-map';
|
|
6
|
-
import { CallableEntityState, CallerEntityState, CanvasEntityState, EntityState, EntityWithLogicScopeState, EntryPointEntityState, PassThroughCallableEntityState } from '../types';
|
|
6
|
+
import { CallableEntityState, CallerEntityState, CanvasEntityState, EntityState, EntityWithLogicScopeState, EntryPointEntityState, IChangeSet, PassThroughCallableEntityState } from '../types';
|
|
7
7
|
import { ProjectState } from '../project/project';
|
|
8
8
|
import { BreakStatementState } from '../break-statement';
|
|
9
9
|
import { ContinueStatementState } from '../continue-statement';
|
|
@@ -126,5 +126,8 @@ export declare class LoopState implements ILoop, BaseState, UserManagedEntitySta
|
|
|
126
126
|
removeBreakStatement(statement: BreakStatementState): LoopState;
|
|
127
127
|
addContinueStatement(statement: ContinueStatementState): LoopState;
|
|
128
128
|
removeContinueStatement(statement: ContinueStatementState): LoopState;
|
|
129
|
+
syncTerminationStatements(): IChangeSet<LoopState>;
|
|
130
|
+
syncChildren(): IChangeSet<LoopState>;
|
|
131
|
+
inferAndPadAndSyncMissingChildren(): IChangeSet<LoopState>;
|
|
129
132
|
}
|
|
130
133
|
export type LoopPayloadUnion = LoopState | LoopTypesUnion;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -99,6 +99,7 @@ export declare class ReturnDeclarationState implements IReturnDeclaration, UserM
|
|
|
99
99
|
clone(_?: ReturnStatementState | SearchState | BreakStatementState | ContinueStatementState): ReturnDeclarationState;
|
|
100
100
|
setDataType(dataType: DataTypeState): ReturnDeclarationState;
|
|
101
101
|
removeDataType(): ReturnDeclarationState;
|
|
102
|
+
inferDataType(): ReturnDeclarationState;
|
|
102
103
|
getDataType(): DataTypeState | null;
|
|
103
104
|
}
|
|
104
105
|
export type ReturnDeclarationPayloadUnion = ReturnDeclarationState | ReturnDeclarationTypesUnion;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ProjectState } from '../project';
|
|
2
|
+
import { EntityState } from './state';
|
|
2
3
|
|
|
3
4
|
export * from './state';
|
|
4
5
|
export * from './validation';
|
|
@@ -6,3 +7,9 @@ export interface IModuleInjection {
|
|
|
6
7
|
id: string;
|
|
7
8
|
init(project: ProjectState): Promise<void> | void;
|
|
8
9
|
}
|
|
10
|
+
export interface IChangeSet<T = EntityState> {
|
|
11
|
+
added: EntityState[];
|
|
12
|
+
updated: EntityState[];
|
|
13
|
+
removed: EntityState[];
|
|
14
|
+
self: T;
|
|
15
|
+
}
|
|
@@ -88,7 +88,7 @@ export declare class ValueDescriptorState implements IValueDescriptor, UserManag
|
|
|
88
88
|
};
|
|
89
89
|
getErrors(): EntityError[];
|
|
90
90
|
getShallowErrors(): EntityError[];
|
|
91
|
-
clone(): ValueDescriptorState;
|
|
91
|
+
clone(parent?: ActionDescriptorState | null, newId?: string | null, subscribe?: boolean): ValueDescriptorState;
|
|
92
92
|
getDataType(): DataTypeState | null;
|
|
93
93
|
setDataType(dataType: DataTypeState): ValueDescriptorState;
|
|
94
94
|
getDefaultValue(): PrimitiveValueState | null;
|
|
@@ -44,6 +44,7 @@ export declare function checkAreDataTypesCompatible(dataTypeA: DataTypeState | n
|
|
|
44
44
|
export declare function generateExecutionDataType(entity: PropertyState | ArgumentDeclarationState | ReturnDeclarationState | VariableDeclarationState | ActionDescriptorState | ValueDescriptorState | DataTypeState): DataTypeState;
|
|
45
45
|
export declare function inferArgumentDeclarationDataType(entity: ArgumentDeclarationState): DataTypeState | null;
|
|
46
46
|
export declare function inferInputMapDataType(entity: InputMapState): DataTypeState | null;
|
|
47
|
+
export declare function inferReturnDeclarationDataType(entity: ReturnDeclarationState): DataTypeState | null;
|
|
47
48
|
export declare function inferVariableInstanceDataType(entity: VariableInstanceState): DataTypeState | null;
|
|
48
49
|
export declare function inferVariableDeclarationDataType(entity: VariableDeclarationState): DataTypeState | null;
|
|
49
50
|
export declare function inferOutputMapDataType(entity: OutputMapState): DataTypeState | null;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elyx-code/project-logic-tree",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6020",
|
|
4
4
|
"author": "Sergio Herrero",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"description": "An installable module which contains the type definitions and ephemeral state management for a projects' logic tree data structure",
|