示例#1
0
        public override AlgebraNode VisitTableAlgebraNode(TableAlgebraNode node)
        {
            List <RuntimeColumnValueOutput> definedValues = new List <RuntimeColumnValueOutput>();

            foreach (ColumnValueDefinition columnValueDefinition in node.DefinedValues)
            {
                RuntimeColumnValueOutput definedValue = new RuntimeColumnValueOutput();
                definedValue.TargetIndex   = definedValues.Count;
                definedValue.ColumnBinding = columnValueDefinition.ColumnRefBinding.ColumnBinding;
                definedValues.Add(definedValue);
            }

            TableIterator tableIterator = new TableIterator();

            tableIterator.RowBuffer     = new object[node.OutputList.Length];
            tableIterator.DefinedValues = definedValues.ToArray();
            tableIterator.Table         = node.TableRefBinding.TableBinding;
            SetLastIterator(node, tableIterator);

            return(node);
        }
示例#2
0
		public override AlgebraNode VisitTableAlgebraNode(TableAlgebraNode node)
		{
			List<RuntimeColumnValueOutput> definedValues = new List<RuntimeColumnValueOutput>();
			foreach (ColumnValueDefinition columnValueDefinition in node.DefinedValues)
			{
				RuntimeColumnValueOutput definedValue = new RuntimeColumnValueOutput();
				definedValue.TargetIndex = definedValues.Count;
				definedValue.ColumnBinding = columnValueDefinition.ColumnRefBinding.ColumnBinding;
				definedValues.Add(definedValue);
			}

			TableIterator tableIterator = new TableIterator();
			tableIterator.RowBuffer = new object[node.OutputList.Length];
			tableIterator.DefinedValues = definedValues.ToArray();
			tableIterator.Table = node.TableRefBinding.TableBinding;
			SetLastIterator(node, tableIterator);

			return node;
		}