当前位置: 首页>>代码示例>>C#>>正文


C# List.TrimExcess方法代码示例

本文整理汇总了C#中ReportingCloud.Engine.List.TrimExcess方法的典型用法代码示例。如果您正苦于以下问题:C# List.TrimExcess方法的具体用法?C# List.TrimExcess怎么用?C# List.TrimExcess使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ReportingCloud.Engine.List的用法示例。


在下文中一共展示了List.TrimExcess方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: TableGroups

        List<TableGroup> _Items; // list of TableGroup entries

        #endregion Fields

        #region Constructors

        internal TableGroups(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            TableGroup tg;
            _Items = new List<TableGroup>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "TableGroup":
                        tg = new TableGroup(r, this, xNodeLoop);
                        break;
                    default:
                        tg=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown TableGroups element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (tg != null)
                    _Items.Add(tg);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For TableGroups at least one TableGroup is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:TableGroups.cs

示例2: TableCells

        List<TableCell> _Items; // list of TableCell

        #endregion Fields

        #region Constructors

        internal TableCells(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            TableCell tc;
            _Items = new List<TableCell>();
            // Loop thru all the child nodes
            int colIndex=0;			// keep track of the column numbers
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "TableCell":
                        tc = new TableCell(r, this, xNodeLoop, colIndex);
                        colIndex += tc.ColSpan;
                        break;
                    default:
                        tc=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown TableCells element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (tc != null)
                    _Items.Add(tc);
            }
            if (_Items.Count > 0)
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:TableCells.cs

示例3: GroupExpressions

        List<GroupExpression> _Items; // list of GroupExpression

        #endregion Fields

        #region Constructors

        internal GroupExpressions(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            GroupExpression g;
            _Items = new List<GroupExpression>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "GroupExpression":
                        g = new GroupExpression(r, this, xNodeLoop);
                        break;
                    default:
                        g=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown GroupExpressions element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (g != null)
                    _Items.Add(g);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "GroupExpressions require at least one GroupExpression be defined.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:GroupExpressions.cs

示例4: SubReportParameters

        List<SubreportParameter> _Items; // list of SubreportParameter

        #endregion Fields

        #region Constructors

        internal SubReportParameters(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            SubreportParameter rp;
            _Items = new List<SubreportParameter>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Parameter":
                        rp = new SubreportParameter(r, this, xNodeLoop);
                        break;
                    default:
                        rp=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown SubreportParameters element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (rp != null)
                    _Items.Add(rp);
            }
            if (_Items.Count > 0)
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:33,代码来源:SubreportParameters.cs

示例5: StaticCategories

        List<StaticMember> _Items; // list of StaticMember

        #endregion Fields

        #region Constructors

        internal StaticCategories(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            StaticMember sm;
            _Items = new List<StaticMember>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "StaticMember":
                        sm = new StaticMember(r, this, xNodeLoop);
                        break;
                    default:
                        sm=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown StaticCategories element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (sm != null)
                    _Items.Add(sm);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For StaticCategories at least one StaticMember is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:StaticCategories.cs

示例6: MatrixRows

        List<MatrixRow> _Items; // list of MatrixRow

        #endregion Fields

        #region Constructors

        internal MatrixRows(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            MatrixRow m;
            _Items = new List<MatrixRow>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "MatrixRow":
                        m = new MatrixRow(r, this, xNodeLoop);
                        break;
                    default:
                        m=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown MatrixRows element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (m != null)
                    _Items.Add(m);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For MatrixRows at least one MatrixRow is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:MatrixRows.cs

示例7: DataValues

        List<DataValue> _Items; // list of DataValue

        #endregion Fields

        #region Constructors

        internal DataValues(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            DataValue dv;
            _Items = new List<DataValue>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "DataValue":
                        dv = new DataValue(r, this, xNodeLoop);
                        break;
                    default:
                        dv=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown DataValues element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (dv != null)
                    _Items.Add(dv);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For DataValues at least one DataValue is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:DataValues.cs

示例8: Sorting

        List<SortBy> _Items; // list of SortBy

        #endregion Fields

        #region Constructors

        internal Sorting(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            SortBy s;
            _Items = new List<SortBy>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "SortBy":
                        s = new SortBy(r, this, xNodeLoop);
                        break;
                    default:
                        s=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Sorting element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (s != null)
                    _Items.Add(s);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "Sorting requires at least one SortBy be defined.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:Sorting.cs

示例9: RowGroupings

 internal RowGroupings(ReportDefn r, ReportLink p, XmlNode xNode)
     : base(r, p)
 {
     RowGrouping g;
     _Items = new List<RowGrouping>();
     // Loop thru all the child nodes
     foreach(XmlNode xNodeLoop in xNode.ChildNodes)
     {
         if (xNodeLoop.NodeType != XmlNodeType.Element)
             continue;
         switch (xNodeLoop.Name)
         {
             case "RowGrouping":
                 g = new RowGrouping(r, this, xNodeLoop);
                 break;
             default:
                 g=null;		// don't know what this is
                 // don't know this element - log it
                 OwnerReport.rl.LogError(4, "Unknown RowGroupings element '" + xNodeLoop.Name + "' ignored.");
                 break;
         }
         if (g != null)
             _Items.Add(g);
     }
     if (_Items.Count == 0)
         OwnerReport.rl.LogError(8, "For RowGroupings at least one RowGrouping is required.");
     else
     {
         _Items.TrimExcess();
         _StaticCount = GetStaticCount();
     }
 }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:32,代码来源:RowGroupings.cs

示例10: QueryParameters

        List<QueryParameter> _Items; // list of QueryParameter

        #endregion Fields

        #region Constructors

        internal QueryParameters(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _ContainsArray = false;
            QueryParameter q;
            _Items = new List<QueryParameter>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "QueryParameter":
                        q = new QueryParameter(r, this, xNodeLoop);
                        break;
                    default:
                        q=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown QueryParameters element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (q != null)
                    _Items.Add(q);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For QueryParameters at least one QueryParameter is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:36,代码来源:QueryParameters.cs

示例11: SeriesGroupings

        List<SeriesGrouping> _Items; // list of SeriesGrouping

        #endregion Fields

        #region Constructors

        internal SeriesGroupings(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            SeriesGrouping sg;
            _Items = new List<SeriesGrouping>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "SeriesGrouping":
                        sg = new SeriesGrouping(r, this, xNodeLoop);
                        break;
                    default:
                        sg=null;		// don't know what this is
                        break;
                }
                if (sg != null)
                    _Items.Add(sg);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For SeriesGroupings at least one SeriesGrouping is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:33,代码来源:SeriesGroupings.cs

示例12: Filters

        List<Filter> _Items; // list of Filter

        #endregion Fields

        #region Constructors

        internal Filters(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            Filter f;
            _Items = new List<Filter>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "Filter":
                        f = new Filter(r, this, xNodeLoop);
                        break;
                    default:
                        f=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown Filters element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (f != null)
                    _Items.Add(f);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "Filters require at least one Filter be defined.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:Filters.cs

示例13: CodeModules

        List<CodeModule> _Items; // list of code module

        #endregion Fields

        #region Constructors

        internal CodeModules(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Items = new List<CodeModule>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                if (xNodeLoop.Name == "CodeModule")
                {
                    CodeModule cm = new CodeModule(r, this, xNodeLoop);
                    _Items.Add(cm);
                }
                else
                {
                    // don't know this element - log it
                    OwnerReport.rl.LogError(4, "Unknown CodeModules element '" + xNodeLoop.Name + "' ignored.");
                }
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For CodeModules at least one CodeModule is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:31,代码来源:CodeModules.cs

示例14: ChartData

        List<ChartSeries> _Items; // list of chart series

        #endregion Fields

        #region Constructors

        internal ChartData(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            ChartSeries cs;
            _Items = new List<ChartSeries>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                switch (xNodeLoop.Name)
                {
                    case "ChartSeries":
                        cs = new ChartSeries(r, this, xNodeLoop);
                        break;
                    default:
                        cs=null;		// don't know what this is
                        // don't know this element - log it
                        OwnerReport.rl.LogError(4, "Unknown ChartData element '" + xNodeLoop.Name + "' ignored.");
                        break;
                }
                if (cs != null)
                    _Items.Add(cs);
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For ChartData at least one ChartSeries is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:35,代码来源:ChartData.cs

示例15: Classes

        List<ReportClass> _Items; // list of report class

        #endregion Fields

        #region Constructors

        internal Classes(ReportDefn r, ReportLink p, XmlNode xNode)
            : base(r, p)
        {
            _Items = new List<ReportClass>();
            // Loop thru all the child nodes
            foreach(XmlNode xNodeLoop in xNode.ChildNodes)
            {
                if (xNodeLoop.NodeType != XmlNodeType.Element)
                    continue;
                if (xNodeLoop.Name == "Class")
                {
                    ReportClass rc = new ReportClass(r, this, xNodeLoop);
                    _Items.Add(rc);
                }
            }
            if (_Items.Count == 0)
                OwnerReport.rl.LogError(8, "For Classes at least one Class is required.");
            else
                _Items.TrimExcess();
        }
开发者ID:bittercoder,项目名称:reportingcloud,代码行数:26,代码来源:Classes.cs


注:本文中的ReportingCloud.Engine.List.TrimExcess方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。