Class FunctionVarPtg
This class represents function with variable arguments number in a formula.
Implements
Inherited Members
Namespace: Syncfusion.XlsIO.Parser.Biff_Records.Formula
Assembly: Syncfusion.XlsIO.Base.dll
Syntax
[CLSCompliant(false)]
[Token(FormulaToken.tFunctionVar1)]
[Token(FormulaToken.tFunctionVar2)]
[Token(FormulaToken.tFunctionVar3)]
public class FunctionVarPtg : FunctionPtg, ICloneable
Constructors
FunctionVarPtg()
Default constructor
Declaration
public FunctionVarPtg()
FunctionVarPtg(ExcelFunction)
Constructs token by built-in function index.
Declaration
public FunctionVarPtg(ExcelFunction funcIndex)
Parameters
Type | Name | Description |
---|---|---|
ExcelFunction | funcIndex | Built-in function index. |
FunctionVarPtg(DataProvider, Int32, ExcelVersion)
Constructs token using data from byte array.
Declaration
public FunctionVarPtg(DataProvider provider, int offset, ExcelVersion version)
Parameters
Type | Name | Description |
---|---|---|
DataProvider | provider | Object that provides access to the data. |
System.Int32 | offset | Offset to the token data. |
ExcelVersion | version | Excel version that was used to infill data provider. |
FunctionVarPtg(String)
Constructs function token by function name.
Declaration
public FunctionVarPtg(string strFunctionName)
Parameters
Type | Name | Description |
---|---|---|
System.String | strFunctionName | Valid function name. |
Methods
GetOperands(String, ref Int32, FormulaUtil)
Gets operands from string and returns array of string representation of the operands.
Declaration
public override string[] GetOperands(string strFormula, ref int index, FormulaUtil formulaParser)
Parameters
Type | Name | Description |
---|---|---|
System.String | strFormula | Formula string. |
System.Int32 | index | Index of function in the string. |
FormulaUtil | formulaParser | Formula parser. |
Returns
Type | Description |
---|---|
System.String[] | Array of strings containing function parameters. |
Overrides
GetSize(ExcelVersion)
Read-only. Size of the token.
Declaration
public override int GetSize(ExcelVersion version)
Parameters
Type | Name | Description |
---|---|---|
ExcelVersion | version |
Returns
Type |
---|
System.Int32 |
Overrides
IndexToCode(Int32)
Declaration
public static FormulaToken IndexToCode(int index)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index |
Returns
Type |
---|
FormulaToken |
InfillPTG(DataProvider, ref Int32, ExcelVersion)
Infill PTG structure.
Declaration
public override void InfillPTG(DataProvider provider, ref int offset, ExcelVersion version)
Parameters
Type | Name | Description |
---|---|---|
DataProvider | provider | Represents storage. |
System.Int32 | offset | Offset in storage. |
ExcelVersion | version | Excel version that was used to infill data provider. |
Overrides
PushResultToStack(FormulaUtil, Stack<Object>, Boolean)
Takes all needed operands from the stack and pushes the result of the function.
Declaration
public override void PushResultToStack(FormulaUtil formulaUtil, Stack<object> operands, bool isForSerialization)
Parameters
Type | Name | Description |
---|---|---|
FormulaUtil | formulaUtil | Object used for formula parsing. |
System.Collections.Generic.Stack<System.Object> | operands | Stack that contains all operands and will receive result of the operation. |
System.Boolean | isForSerialization |
Overrides
ToByteArray(ExcelVersion)
Converts token to byte array.
Declaration
public override byte[] ToByteArray(ExcelVersion version)
Parameters
Type | Name | Description |
---|---|---|
ExcelVersion | version |
Returns
Type | Description |
---|---|
System.Byte[] | Array of bytes representing this token. |