コード例 #1
0
 private void _enforce_type(CellGroupBuilderType t)
 {
     if (this.Type != t)
     {
         throw new Exceptions.InternalAssertionException();
     }
 }
コード例 #2
0
        protected CellGroupBuilder(CellGroupBuilderType type)
        {
            var temp_cells = new TGroup();

            Query.Columns cols;

            this.Type = type;
            if (type == CellGroupBuilderType.SingleRow)
            {
                this.query_cells_singlerow = new Query.CellQuery();
                cols = this.query_cells_singlerow.Columns;
            }
            else if (type == CellGroupBuilderType.MultiRow)
            {
                this.query_sections_multirow = new Query.SectionQuery();
                cols = this.query_sections_multirow.Add(temp_cells.CellMetadata.First().Src);
            }
            else
            {
                throw new Exceptions.InternalAssertionException();
            }

            foreach (var pair in temp_cells.CellMetadata)
            {
                cols.Add(pair.Src, pair.Name);
            }
        }