allow functions to call other functions #53

This commit is contained in:
undergroundwires
2021-01-16 13:26:41 +01:00
parent f1abd7682f
commit 7661575573
38 changed files with 1507 additions and 645 deletions

View File

@@ -0,0 +1,27 @@
import { ISharedFunction } from '@/application/Parser/Script/Compiler/Function/ISharedFunction';
export class SharedFunctionStub implements ISharedFunction {
public name = 'shared-function-stub-name';
public parameters?: readonly string[] = [
'shared-function-stub-parameter',
];
public code = 'shared-function-stub-code';
public revertCode = 'shared-function-stub-revert-code';
public withName(name: string) {
this.name = name;
return this;
}
public withCode(code: string) {
this.code = code;
return this;
}
public withRevertCode(revertCode: string) {
this.revertCode = revertCode;
return this;
}
public withParameters(...params: string[]) {
this.parameters = params;
return this;
}
}