internal void DoneReadingRows(ref Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult[] runningValueValues, ref Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult[] runningValueOfAggregateValues, ref Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult[] cellRunningValueValues) { AggregatesImpl aggregatesImpl = m_odpContext.ReportObjectModel.AggregatesImpl; RuntimeRICollection.StoreRunningValues(aggregatesImpl, m_hierarchyDef.RunningValues, ref runningValueValues); if (m_hierarchyDef.DataScopeInfo != null) { RuntimeRICollection.StoreRunningValues(aggregatesImpl, m_hierarchyDef.DataScopeInfo.RunningValuesOfAggregates, ref runningValueOfAggregateValues); } int num = (m_staticCellPreviousValues != null) ? m_staticCellPreviousValues.Count : 0; int num2 = (m_staticCellRVs != null) ? m_staticCellRVs.Count : 0; if (num2 > 0) { cellRunningValueValues = new Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult[num2 + num]; for (int i = 0; i < num2; i++) { Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObj aggregateObj = aggregatesImpl.GetAggregateObj(m_staticCellRVs[i]); cellRunningValueValues[i] = aggregateObj.AggregateResult(); } } if (num > 0) { if (cellRunningValueValues == null) { cellRunningValueValues = new Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult[num]; } for (int j = 0; j < num; j++) { Microsoft.ReportingServices.ReportIntermediateFormat.DataAggregateObj aggregateObj2 = aggregatesImpl.GetAggregateObj(m_staticCellPreviousValues[j]); cellRunningValueValues[num2 + j] = aggregateObj2.AggregateResult(); } } }
protected override void ConstructRuntimeStructure(ref DataActions innerDataAction, bool onePassProcess) { m_dataRegionScopedItems = null; base.ConstructRuntimeStructure(ref innerDataAction, onePassProcess); List <Microsoft.ReportingServices.ReportIntermediateFormat.ReportItem> dataRegionScopedItems = GetDataRegionScopedItems(); if (dataRegionScopedItems != null) { m_dataRegionScopedItems = new RuntimeRICollection(m_selfReference, dataRegionScopedItems, ref innerDataAction, m_odpContext); } }
protected override void InitializeGroupScopedItems(Microsoft.ReportingServices.ReportIntermediateFormat.ReportHierarchyNode member, ref DataActions innerDataAction) { List <Microsoft.ReportingServices.ReportIntermediateFormat.ReportItem> groupScopedContents = GetGroupScopedContents(member); if (groupScopedContents != null) { if (m_groupScopedItems == null) { m_groupScopedItems = new RuntimeRICollection(groupScopedContents.Count); } m_groupScopedItems.AddItems(m_selfReference, groupScopedContents, ref innerDataAction, m_odpContext); } }
protected override void ConstructCellContents(Cell cell, ref DataActions dataAction) { List <Microsoft.ReportingServices.ReportIntermediateFormat.ReportItem> cellContents = GetCellContents(cell); if (cellContents != null) { m_owner.Value().OdpContext.TablixProcessingScalabilityCache.AllocateAndPin((RuntimeCell)this, m_outerGroupDynamicIndex); if (m_cellContents == null) { m_cellContents = new RuntimeRICollection(cellContents.Count); } m_cellContents.AddItems(m_selfReference, cellContents, ref dataAction, m_owner.Value().OdpContext); } }
protected override void ConstructOutermostCellContents(Cell cell) { List <Microsoft.ReportingServices.ReportIntermediateFormat.ReportItem> cellContents = GetCellContents(cell); if (cellContents != null) { DataActions dataAction = DataActions.None; if (m_groupScopedItems == null) { m_groupScopedItems = new RuntimeRICollection(cellContents.Count); } m_groupScopedItems.AddItems(m_selfReference, cellContents, ref dataAction, m_odpContext); } }
public override void Deserialize(IntermediateFormatReader reader) { base.Deserialize(reader); reader.RegisterDeclaration(m_declaration); while (reader.NextMember()) { MemberName memberName = reader.CurrentMember.MemberName; if (memberName == MemberName.CellContents) { m_cellContents = (RuntimeRICollection)reader.ReadRIFObject(); } else { Global.Tracer.Assert(condition: false, string.Concat("Unsupported member name: ", reader.CurrentMember.MemberName, ".")); } } }
internal override void CalculateRunningValues(Dictionary <string, IReference <RuntimeGroupRootObj> > groupCol, IReference <RuntimeGroupRootObj> lastGroup, AggregateUpdateContext aggContext) { if (m_dataRegionDef.RunningValues != null && m_runningValues == null && m_previousValues == null) { AddRunningValues(m_odpContext, m_dataRegionDef.RunningValues, ref m_runningValues, ref m_previousValues, groupCol, lastGroup); } if (m_dataRegionDef.DataScopeInfo != null) { List <string> runningValuesInGroup = null; List <string> previousValuesInGroup = null; AddRunningValues(m_odpContext, m_dataRegionDef.DataScopeInfo.RunningValuesOfAggregates, ref runningValuesInGroup, ref previousValuesInGroup, groupCol, lastGroup); } bool flag = m_dataRows != null && FlagUtils.HasFlag(m_dataAction, DataActions.PostSortAggregates); AggregateUpdateQueue workQueue = RuntimeDataRegionObj.AggregateOfAggregatesStart(aggContext, this, m_dataRegionDef.DataScopeInfo, m_postSortAggregatesOfAggregates, flag ? AggregateUpdateFlags.ScopedAggregates : AggregateUpdateFlags.Both, needsSetupEnvironment: true); if (flag) { DataActions dataActions = DataActions.PostSortAggregates; if (aggContext.LastScopeNeedsRowAggregateProcessing()) { dataActions |= DataActions.PostSortAggregatesOfAggregates; } ReadRows(dataActions, aggContext); m_dataRows = null; } int num = (m_outerGroupings != null) ? m_outerGroupings.Length : 0; if (num == 0) { if (m_innerGroupings != null) { for (int i = 0; i < m_innerGroupings.Length; i++) { IReference <RuntimeMemberObj> reference = m_innerGroupings[i]; using (reference.PinValue()) { reference.Value().CalculateRunningValues(groupCol, lastGroup, aggContext); } } } } else { for (int j = 0; j < num; j++) { IReference <RuntimeMemberObj> reference2 = m_outerGroupings[j]; bool flag2; using (reference2.PinValue()) { RuntimeMemberObj runtimeMemberObj = reference2.Value(); runtimeMemberObj.CalculateRunningValues(groupCol, lastGroup, aggContext); flag2 = (runtimeMemberObj.GroupRoot == null); } if (!flag2 || m_innerGroupings == null) { continue; } for (int k = 0; k < m_innerGroupings.Length; k++) { IReference <RuntimeMemberObj> reference3 = m_innerGroupings[k]; using (reference3.PinValue()) { RuntimeMemberObj runtimeMemberObj2 = reference3.Value(); runtimeMemberObj2.PrepareCalculateRunningValues(); runtimeMemberObj2.CalculateRunningValues(groupCol, lastGroup, aggContext); } } } } CalculateRunningValuesForTopLevelStaticContents(groupCol, lastGroup, aggContext); RuntimeDataRegionObj.AggregatesOfAggregatesEnd(this, aggContext, workQueue, m_dataRegionDef.DataScopeInfo, m_postSortAggregatesOfAggregates, updateAggsIfNeeded: true); CalculateDRPreviousAggregates(); RuntimeRICollection.StoreRunningValues(m_odpContext.ReportObjectModel.AggregatesImpl, m_dataRegionDef.RunningValues, ref m_runningValueValues); if (m_dataRegionDef.DataScopeInfo != null) { RuntimeRICollection.StoreRunningValues(m_odpContext.ReportObjectModel.AggregatesImpl, m_dataRegionDef.DataScopeInfo.RunningValuesOfAggregates, ref m_runningValueOfAggregateValues); } }
private void CreateRuntimeStructure() { m_runtimeDataRegions = new RuntimeRICollection(m_selfReference, m_dataSet.DataRegions, m_odpContext, m_odpContext.ReportDefinition.MergeOnePass); }