namespace com.azkoss.excellite { using System; /// ///Hold information about function( name, code, expected arguments count. ) /// internal class FormulaFunctionInfo { // Methods /// ///Initializes a new instance of the class. /// ///The function code. ///The function name. public FormulaFunctionInfo(ushort code, string name) : this(code, name, 0xff) { } /// ///Initializes a new instance of the class. /// ///The function code. ///The function name. ///The function's arguments count. public FormulaFunctionInfo(ushort code, string name, byte argumentsCount) { this.argumentsCount = 0xff; this.code = code; this.name = name; this.argumentsCount = argumentsCount; } // Properties /// ///Arguments count value, by default it is initilized with not fixed( variable ) argument count mark. /// public byte ArgumentsCount { get { return this.argumentsCount; } } /// ///Gets function code. /// ///The function code. public ushort Code { get { return this.code; } } /// ///Gets a value indicating whether function has fixed argument count. /// /// ///true if this function has fixed argument count; otherwise, false. /// public bool IsFixedArgumentCount { get { return (this.ArgumentsCount != 0xff); } } /// ///Gets function name. /// ///Function name. public string Name { get { return this.name; } } // Fields /// ///Arguments count value, by default it is initilized with not fixed( variable ) argument count mark. /// private byte argumentsCount; private ushort code; private string name; /// ///Is used to the specify for appropriate functins the variable count of arguments /// public const byte VariableArgumentAmountMark = 0xff; } }