Package org.openl.rules.data
Class DataNodeBinder
- java.lang.Object
-
- org.openl.binding.impl.ANodeBinder
-
- org.openl.rules.lang.xls.binding.AXlsTableBinder
-
- org.openl.rules.data.DataNodeBinder
-
- All Implemented Interfaces:
INodeBinder
- Direct Known Subclasses:
ADtColumnsDefinitionTableBinder,PropertyTableBinder,TestMethodNodeBinder
public class DataNodeBinder extends AXlsTableBinder
- Author:
- snshor
-
-
Field Summary
Fields Modifier and Type Field Description static intTYPE_INDEX
-
Constructor Summary
Constructors Constructor Description DataNodeBinder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ILogicalTablegetTableBody(TableSyntaxNode tsn)protected ColumnDescriptor[]makeDescriptors(ITable tableToProcess, IOpenClass tableType, IBindingContext bindingContext, OpenL openl, boolean hasColumnTitleRow, ILogicalTable horizDataTableBody, ILogicalTable descriptorRows, ILogicalTable dataWithTitleRows)protected ATableBoundNodemakeNode(TableSyntaxNode tsn, XlsModuleOpenClass module, RulesModuleBindingContext bindingContext)protected ITablemakeTable(XlsModuleOpenClass xlsOpenClass, TableSyntaxNode tableSyntaxNode, String tableName, IOpenClass tableType, IBindingContext bindingContext, OpenL openl, boolean useRegistered)Default method.IMemberBoundNodepreBind(TableSyntaxNode tableSyntaxNode, OpenL openl, RulesModuleBindingContext bindingContext, XlsModuleOpenClass module)voidprocessTable(XlsModuleOpenClass xlsOpenClass, ITable tableToProcess, ILogicalTable tableBody, String tableName, IOpenClass tableType, IBindingContext bindingContext, OpenL openl, boolean hasColumnTitleRow)Populate theITablewith data fromILogicalTable.static voidputSubTableForBusinessView(TableSyntaxNode tableSyntaxNode, IOpenClass tableType)Adds sub table for displaying on business view.-
Methods inherited from class org.openl.rules.lang.xls.binding.AXlsTableBinder
bind
-
Methods inherited from class org.openl.binding.impl.ANodeBinder
assertCountOfChild, bindChildNode, bindChildren, bindChildren, bindTarget, bindTargetNode, bindType, bindTypeChildren, bindTypeChildren, bindTypeNode, getCast, getCast, getIdentifier, getType, getTypes, hasErrorBoundNode, makeErrorNode, replace
-
-
-
-
Field Detail
-
TYPE_INDEX
public static final int TYPE_INDEX
- See Also:
- Constant Field Values
-
-
Method Detail
-
makeNode
protected ATableBoundNode makeNode(TableSyntaxNode tsn, XlsModuleOpenClass module, RulesModuleBindingContext bindingContext)
-
getTableBody
protected ILogicalTable getTableBody(TableSyntaxNode tsn)
-
preBind
public IMemberBoundNode preBind(TableSyntaxNode tableSyntaxNode, OpenL openl, RulesModuleBindingContext bindingContext, XlsModuleOpenClass module) throws Exception
- Specified by:
preBindin classAXlsTableBinder- Throws:
Exception
-
processTable
public void processTable(XlsModuleOpenClass xlsOpenClass, ITable tableToProcess, ILogicalTable tableBody, String tableName, IOpenClass tableType, IBindingContext bindingContext, OpenL openl, boolean hasColumnTitleRow) throws Exception
Populate theITablewith data fromILogicalTable.- Parameters:
xlsOpenClass- Open class representing OpenL module.tableToProcess- Table to be processed.tableBody- Body of the table (without header and properties sections). Its like a source to processITablewith data.tableName- Name of the outcome table.tableType- Type of the data in table.bindingContext- OpenL context.openl- OpenL instance.hasColumnTitleRow- Flag representing if tableBody has title row for columns.- Throws:
Exception
-
makeDescriptors
protected ColumnDescriptor[] makeDescriptors(ITable tableToProcess, IOpenClass tableType, IBindingContext bindingContext, OpenL openl, boolean hasColumnTitleRow, ILogicalTable horizDataTableBody, ILogicalTable descriptorRows, ILogicalTable dataWithTitleRows) throws Exception
- Throws:
Exception
-
putSubTableForBusinessView
public static void putSubTableForBusinessView(TableSyntaxNode tableSyntaxNode, IOpenClass tableType)
Adds sub table for displaying on business view.- Parameters:
tableSyntaxNode-TableSyntaxNoderepresenting table.tableType- Type of the data in table.
-
makeTable
protected ITable makeTable(XlsModuleOpenClass xlsOpenClass, TableSyntaxNode tableSyntaxNode, String tableName, IOpenClass tableType, IBindingContext bindingContext, OpenL openl, boolean useRegistered) throws Exception
Default method. It is called during processing OpenL module. If you call this method, you want to process table with cell title row set toTRUE. callsprocessTable(XlsModuleOpenClass, ITable, ILogicalTable, String, IOpenClass, IBindingContext, OpenL, boolean)to populateITablewith data. Also adds toTableSyntaxNodesub table for displaying on business view.- Parameters:
xlsOpenClass- Open class representing OpenL module.tableSyntaxNode-TableSyntaxNodeto be processed.tableName- Name of the outcome table.tableType- Type of the data in table.bindingContext- OpenL context.openl- OpenL instance.- Throws:
Exception
-
-