Ejemplo n.º 1
0
        public bool IsSortFilterTarget(bool[] isSortFilterTarget, IReference <IScope> outerScope, IReference <IHierarchyObj> target, ref RuntimeUserSortTargetInfo userSortTargetInfo)
        {
            bool result = false;

            if (this.m_runtimeSortFilterInfo != null && isSortFilterTarget != null && (outerScope == null || !outerScope.Value().TargetForNonDetailSort))
            {
                for (int i = 0; i < this.m_runtimeSortFilterInfo.Count; i++)
                {
                    IReference <RuntimeSortFilterEventInfo> reference = this.m_runtimeSortFilterInfo[i];
                    using (reference.PinValue())
                    {
                        RuntimeSortFilterEventInfo runtimeSortFilterEventInfo = reference.Value();
                        if (isSortFilterTarget[i] && (outerScope == null || outerScope.Value().TargetScopeMatched(i, false)))
                        {
                            runtimeSortFilterEventInfo.EventTarget = target;
                            runtimeSortFilterEventInfo.Processed   = false;
                            if (userSortTargetInfo == null)
                            {
                                userSortTargetInfo = new RuntimeUserSortTargetInfo(target, i, reference);
                            }
                            else
                            {
                                userSortTargetInfo.AddSortInfo(target, i, reference);
                            }
                            result = true;
                        }
                    }
                }
            }
            return(result);
        }
 protected void ScopeFinishSorting(ref DataFieldRow firstRow, RuntimeUserSortTargetInfo sortTargetInfo)
 {
     Global.Tracer.Assert(null != sortTargetInfo, "(null != sortTargetInfo)");
     firstRow = null;
     sortTargetInfo.SortTree.Traverse(ProcessingStages.UserSortFilter, true, null);
     sortTargetInfo.SortTree.Dispose();
     sortTargetInfo.SortTree = null;
     if (sortTargetInfo.AggregateRows != null)
     {
         for (int i = 0; i < sortTargetInfo.AggregateRows.Count; i++)
         {
             sortTargetInfo.AggregateRows[i].SetFields(this.m_odpContext.ReportObjectModel.FieldsImpl);
             this.SendToInner();
         }
         sortTargetInfo.AggregateRows = null;
     }
 }
 protected void ScopeNextAggregateRow(RuntimeUserSortTargetInfo sortTargetInfo)
 {
     if (sortTargetInfo != null)
     {
         if (sortTargetInfo.AggregateRows == null)
         {
             sortTargetInfo.AggregateRows = new List <AggregateRow>();
         }
         AggregateRow item = new AggregateRow(this.m_odpContext.ReportObjectModel.FieldsImpl, true);
         sortTargetInfo.AggregateRows.Add(item);
         if (!sortTargetInfo.TargetForNonDetailSort)
         {
             return;
         }
     }
     this.SendToInner();
 }
Ejemplo n.º 4
0
        public override void Deserialize(IntermediateFormatReader reader)
        {
            base.Deserialize(reader);
            reader.RegisterDeclaration(RuntimeRDLDataRegionObj.m_declaration);
            IScalabilityCache scalabilityCache = reader.PersistenceHelper as IScalabilityCache;

            while (reader.NextMember())
            {
                switch (reader.CurrentMember.MemberName)
                {
                case MemberName.DataRegionDef:
                {
                    int id2 = reader.ReadInt32();
                    this.m_dataRegionDef = (AspNetCore.ReportingServices.ReportIntermediateFormat.DataRegion)scalabilityCache.FetchStaticReference(id2);
                    break;
                }

                case MemberName.OuterScope:
                    this.m_outerScope = (IReference <IScope>)reader.ReadRIFObject();
                    break;

                case MemberName.FirstRow:
                    this.m_firstRow = (DataFieldRow)reader.ReadRIFObject();
                    break;

                case MemberName.FirstRowIsAggregate:
                    this.m_firstRowIsAggregate = reader.ReadBoolean();
                    break;

                case MemberName.Filters:
                {
                    int id = reader.ReadInt32();
                    this.m_filters = (Filters)scalabilityCache.FetchStaticReference(id);
                    break;
                }

                case MemberName.NonCustomAggregates:
                    this.m_nonCustomAggregates = reader.ReadListOfRIFObjects <List <AspNetCore.ReportingServices.ReportIntermediateFormat.DataAggregateObj> >();
                    break;

                case MemberName.CustomAggregates:
                    this.m_customAggregates = reader.ReadListOfRIFObjects <List <AspNetCore.ReportingServices.ReportIntermediateFormat.DataAggregateObj> >();
                    break;

                case MemberName.DataAction:
                    this.m_dataAction = (DataActions)reader.ReadEnum();
                    break;

                case MemberName.OuterDataAction:
                    this.m_outerDataAction = (DataActions)reader.ReadEnum();
                    break;

                case MemberName.RunningValues:
                    this.m_runningValues = reader.ReadListOfPrimitives <string>();
                    break;

                case MemberName.PreviousValues:
                    this.m_previousValues = reader.ReadListOfPrimitives <string>();
                    break;

                case MemberName.RunningValueValues:
                    this.m_runningValueValues = reader.ReadArrayOfRIFObjects <AspNetCore.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult>();
                    break;

                case MemberName.RunningValueOfAggregateValues:
                    this.m_runningValueOfAggregateValues = reader.ReadArrayOfRIFObjects <AspNetCore.ReportingServices.ReportIntermediateFormat.DataAggregateObjResult>();
                    break;

                case MemberName.PostSortAggregates:
                    this.m_postSortAggregates = reader.ReadListOfRIFObjects <List <AspNetCore.ReportingServices.ReportIntermediateFormat.DataAggregateObj> >();
                    break;

                case MemberName.DataRows:
                    this.m_dataRows = reader.ReadRIFObject <ScalableList <DataFieldRow> >();
                    break;

                case MemberName.InnerDataAction:
                    this.m_innerDataAction = (DataActions)reader.ReadEnum();
                    break;

                case MemberName.UserSortTargetInfo:
                    this.m_userSortTargetInfo = (RuntimeUserSortTargetInfo)reader.ReadRIFObject();
                    break;

                case MemberName.SortFilterExpressionScopeInfoIndices:
                    this.m_sortFilterExpressionScopeInfoIndices = reader.ReadInt32Array();
                    break;

                case MemberName.InDataRowSortPhase:
                    this.m_inDataRowSortPhase = reader.ReadBoolean();
                    break;

                case MemberName.SortedDataRowTree:
                    this.m_sortedDataRowTree = (BTree)reader.ReadRIFObject();
                    break;

                case MemberName.DataRowSortExpression:
                    this.m_dataRowSortExpression = (RuntimeExpressionInfo)reader.ReadRIFObject();
                    break;

                case MemberName.AggregatesOfAggregates:
                    this.m_aggregatesOfAggregates = (BucketedDataAggregateObjs)reader.ReadRIFObject();
                    break;

                case MemberName.PostSortAggregatesOfAggregates:
                    this.m_postSortAggregatesOfAggregates = (BucketedDataAggregateObjs)reader.ReadRIFObject();
                    break;

                case MemberName.HasProcessedAggregateRow:
                    this.m_hasProcessedAggregateRow = reader.ReadBoolean();
                    break;

                default:
                    Global.Tracer.Assert(false);
                    break;
                }
            }
        }