$treeview $search $mathjax
|
Palabos
Version 1.1
$projectbrief
|
$projectbrief
|
$searchbox |
00001 /* This file is part of the Palabos library. 00002 * 00003 * Copyright (C) 2011 FlowKit Sarl 00004 * Avenue de Chailly 23 00005 * 1012 Lausanne, Switzerland 00006 * E-mail contact: contact@flowkit.com 00007 * 00008 * The most recent release of Palabos can be downloaded at 00009 * <http://www.palabos.org/> 00010 * 00011 * The library Palabos is free software: you can redistribute it and/or 00012 * modify it under the terms of the GNU Affero General Public License as 00013 * published by the Free Software Foundation, either version 3 of the 00014 * License, or (at your option) any later version. 00015 * 00016 * The library is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00019 * GNU Affero General Public License for more details. 00020 * 00021 * You should have received a copy of the GNU Affero General Public License 00022 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00023 */ 00024 00030 #ifndef MULTI_CONTAINER_BLOCK_2D_H 00031 #define MULTI_CONTAINER_BLOCK_2D_H 00032 00033 #include "core/globalDefs.h" 00034 #include "atomicBlock/atomicContainerBlock2D.h" 00035 #include "multiBlock/multiBlock2D.h" 00036 00037 namespace plb { 00038 00039 class MultiContainerBlock2D : public MultiBlock2D { 00040 public: 00041 typedef std::map<plint,AtomicContainerBlock2D*> BlockMap; 00042 public: 00043 MultiContainerBlock2D ( 00044 MultiBlockManagement2D const& multiBlockManagement_, 00045 CombinedStatistics* combinedStatistics_ ); 00046 MultiContainerBlock2D(plint nx_, plint ny); 00047 MultiContainerBlock2D(MultiBlock2D const& rhs); 00048 MultiContainerBlock2D(MultiBlock2D const& rhs, Box2D subDomain, bool crop); 00049 ~MultiContainerBlock2D(); 00050 MultiContainerBlock2D& operator=(MultiContainerBlock2D const& rhs); 00051 MultiContainerBlock2D(MultiContainerBlock2D const& rhs); 00052 MultiContainerBlock2D* clone() const; 00053 MultiContainerBlock2D* clone(MultiBlockManagement2D const& multiBlockManagement) const; 00054 void swap(MultiContainerBlock2D& rhs); 00055 std::string getBlockName() const; 00056 std::vector<std::string> getTypeInfo() const; 00057 public: 00058 virtual AtomicContainerBlock2D& getComponent(plint iBlock); 00059 virtual AtomicContainerBlock2D const& getComponent(plint iBlock) const; 00060 virtual plint sizeOfCell() const; 00061 virtual plint getCellDim() const; 00062 virtual int getStaticId() const; 00063 virtual void copyReceive ( 00064 MultiBlock2D const& fromBlock, Box2D const& fromDomain, 00065 Box2D const& toDomain, modif::ModifT whichData=modif::dataStructure ); 00066 private: 00067 void allocateBlocks(); 00068 void deAllocateBlocks(); 00069 private: 00070 BlockMap blocks; 00071 }; 00072 00073 } // namespace plb 00074 00075 #endif // MULTI_CONTAINER_BLOCK_2D_H
1.6.3
1.6.3