定义函数时候写的。
- function FactorialFunction() {
- this.name = "FACTORIAL";
- this.maxArgs = 1;
- this.minArgs = 1;
- this.typeName = "FactorialFunction";
- }
- FactorialFunction.prototype = new GC.Spread.CalcEngine.Functions.Function("FACTORIAL", 1, 1, {
- description: "计算一个数的阶乘",
- parameters: [{
- name: "value",
- repeatable: false,
- optional: false
- }]
- });
复制代码 |