Esempio n. 1
0
 public void PostFilterNextRow()
 {
     if (m_nonCustomAggregates != null)
     {
         for (int i = 0; i < m_nonCustomAggregates.Count; i++)
         {
             m_nonCustomAggregates[i].Update();
         }
     }
     if (m_dataRows != null)
     {
         RuntimeDataTablixObj.SaveData(m_dataRows, m_odpContext);
     }
     if (m_firstNonAggregateRow)
     {
         m_firstNonAggregateRow           = false;
         m_dataSetInstance.FirstRowOffset = m_odpContext.ReportObjectModel.FieldsImpl.StreamOffset;
     }
     if (m_lookupProcessor != null)
     {
         m_lookupProcessor.NextRow();
     }
     else
     {
         PostLookupNextRow();
     }
 }
 protected void CommonNextRow(ScalableList <DataFieldRow> dataRows)
 {
     if (dataRows != null)
     {
         RuntimeDataTablixObj.SaveData(dataRows, m_odpContext);
     }
     SendToInner();
 }
        internal void NextRow()
        {
            long           streamOffset = m_odpContext.ReportObjectModel.FieldsImpl.StreamOffset;
            int            num          = -1;
            CommonRowCache tablixProcessingLookupRowCache = m_odpContext.TablixProcessingLookupRowCache;

            if (m_mustBufferAllRows)
            {
                num = tablixProcessingLookupRowCache.AddRow(RuntimeDataTablixObj.SaveData(m_odpContext));
                if (m_firstRowCacheIndex == -1)
                {
                    m_firstRowCacheIndex = num;
                }
            }
            IScalabilityCache tablixProcessingScalabilityCache = m_odpContext.TablixProcessingScalabilityCache;

            for (int i = 0; i < m_dataSet.LookupDestinationInfos.Count; i++)
            {
                LookupDestinationInfo lookupDestinationInfo = m_dataSet.LookupDestinationInfos[i];
                LookupObjResult       lookupObjResult       = m_dataSetInstance.LookupResults[i];
                if (lookupObjResult.ErrorOccured)
                {
                    continue;
                }
                Microsoft.ReportingServices.RdlExpressions.VariantResult variantResult = lookupDestinationInfo.EvaluateDestExpr(m_odpContext, lookupObjResult);
                if (variantResult.ErrorOccurred)
                {
                    lookupObjResult.DataFieldStatus = variantResult.FieldStatus;
                    continue;
                }
                object      value       = variantResult.Value;
                LookupTable lookupTable = lookupObjResult.GetLookupTable(m_odpContext);
                try
                {
                    if (!lookupTable.TryGetAndPinValue(value, out LookupMatches matches, out IDisposable cleanupRef))
                    {
                        matches    = ((!lookupDestinationInfo.UsedInSameDataSetTablixProcessing) ? new LookupMatches() : new LookupMatchesWithRows());
                        cleanupRef = lookupTable.AddAndPin(value, matches);
                    }
                    if (lookupDestinationInfo.IsMultiValue || !matches.HasRow)
                    {
                        matches.AddRow(streamOffset, num, tablixProcessingScalabilityCache);
                    }
                    cleanupRef.Dispose();
                }
                catch (ReportProcessingException_SpatialTypeComparisonError reportProcessingException_SpatialTypeComparisonError)
                {
                    throw new ReportProcessingException(m_lookupOwner.RegisterSpatialElementComparisonError(reportProcessingException_SpatialTypeComparisonError.Type));
                }
            }
            if (!m_mustBufferAllRows)
            {
                m_lookupOwner.PostLookupNextRow();
            }
        }