From: kanschat Date: Fri, 20 May 2011 01:57:29 +0000 (+0000) Subject: add constructor with empty blocks X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8d1d429c9662d1360533dfe47bf7b05aadc1027c;p=dealii-svn.git add constructor with empty blocks git-svn-id: https://svn.dealii.org/trunk@23725 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/include/deal.II/lac/block_list.h b/deal.II/include/deal.II/lac/block_list.h index 47fe1c1c6d..203e5549aa 100644 --- a/deal.II/include/deal.II/lac/block_list.h +++ b/deal.II/include/deal.II/lac/block_list.h @@ -71,6 +71,12 @@ class BlockList : void add(unsigned int block, const std::vector& indices, const std::vector& selected_indices); + + /** + * Just set up the correct size + * and assign indices to blocks later. + */ + void initialize(unsigned int n_blocks); /** * Set up all index sets using an @@ -305,6 +311,14 @@ BlockList::add( } +inline +void +BlockList::initialize(unsigned int n_blocks) +{ + index_sets.resize(n_blocks); +} + + template inline void