# PhasicFlow: src/Particles/Insertion/insertionRegion/insertionRegion.hpp Source File

insertionRegion.hpp
Go to the documentation of this file.
/*------------------------------- phasicFlow ---------------------------------
O C enter of
O O E ngineering and
O O M ultiscale modeling of
OOOOOOO F luid flow
------------------------------------------------------------------------------
Copyright (C): www.cemf.ir
email: hamid.r.norouzi AT gmail.com
------------------------------------------------------------------------------
Licence:
This file is part of phasicFlow code. It is a free software for simulating
granular and multiphase flows. You can redistribute it and/or modify it under
the terms of GNU General Public License v3 or any other later versions.
phasicFlow is distributed to help others in their research in the field of
granular and multiphase flows, but WITHOUT ANY WARRANTY; without even the
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-----------------------------------------------------------------------------*/
#ifndef __insertionRegion_hpp__
#define __insertionRegion_hpp__
#include "timeFlowControl.hpp"
#include "shapeMixture.hpp"
#include "peakableRegions.hpp"
#include "setFieldList.hpp"
namespace pFlow
{
class dictionary;
class insertionRegion
:
public timeFlowControl
{
protected:
// - name of the region
word name_;
// - type of insertion region
word type_;
// peakable region of points
uniquePtr<peakableRegion> pRegion_ = nullptr;
// mixture of shapes
uniquePtr<shapeMixture> mixture_ = nullptr;
// setFields for insertion region
uniquePtr<setFieldList> setFields_ = nullptr;
bool readInsertionRegion(const dictionary& dict);
bool writeInsertionRegion(dictionary& dict) const;
public:
TypeInfoNV("insertionRegion");
insertionRegion(const dictionary& dict);
insertionRegion(const insertionRegion& src);
insertionRegion(insertionRegion&&) = default;
insertionRegion& operator=(const insertionRegion&);
insertionRegion& operator=(insertionRegion&&) = default;
~insertionRegion() = default;
const auto& setFields()const
{
return setFields_();
}
const auto& name()const
{
return name_;
}
bool read(const dictionary& dict)
{
if(!timeFlowControl::read(dict))return false;
return readInsertionRegion(dict);
}
bool write(dictionary& dict)const
{
if(!timeFlowControl::write(dict)) return false;
return writeInsertionRegion(dict);
}
};
} //pFlow
#endif //__insertionRegion_hpp__
pFlow::insertionRegion::setFields
const auto & setFields() const
Definition: insertionRegion.hpp:82
pFlow::insertionRegion::TypeInfoNV
TypeInfoNV("insertionRegion")
setFieldList.hpp
pFlow::insertionRegion::type_
word type_
Definition: insertionRegion.hpp:44
pFlow::insertionRegion::insertionRegion
insertionRegion(const dictionary &dict)
Definition: insertionRegion.cpp:95
pFlow::timeFlowControl::read
bool read(const dictionary &dict)
Definition: timeFlowControl.hpp:84
timeFlowControl.hpp
pFlow::insertionRegion::operator=
insertionRegion & operator=(const insertionRegion &)
Definition: insertionRegion.cpp:122
pFlow::word
std::string word
Definition: builtinTypes.hpp:63
pFlow::insertionRegion::setFields_
uniquePtr< setFieldList > setFields_
Definition: insertionRegion.hpp:53
pFlow::insertionRegion::read
bool read(const dictionary &dict)
Definition: insertionRegion.hpp:95
pFlow::timeFlowControl
Definition: timeFlowControl.hpp:32
pFlow::insertionRegion
Definition: insertionRegion.hpp:34
pFlow::insertionRegion::write
bool write(dictionary &dict) const
Definition: insertionRegion.hpp:102
pFlow::insertionRegion::mixture_
uniquePtr< shapeMixture > mixture_
Definition: insertionRegion.hpp:50
pFlow
Definition: demComponent.hpp:28
shapeMixture.hpp
pFlow::insertionRegion::name
const auto & name() const
Definition: insertionRegion.hpp:87
pFlow::insertionRegion::name_
word name_
Definition: insertionRegion.hpp:41
pFlow::timeFlowControl::write
bool write(dictionary &dict) const
Definition: timeFlowControl.hpp:89
pFlow::insertionRegion::writeInsertionRegion
bool writeInsertionRegion(dictionary &dict) const
Definition: insertionRegion.cpp:65
pFlow::uniquePtr
Definition: uniquePtr.hpp:44
pFlow::insertionRegion::pRegion_
uniquePtr< peakableRegion > pRegion_
Definition: insertionRegion.hpp:47
pFlow::insertionRegion::readInsertionRegion
bool readInsertionRegion(const dictionary &dict)
Definition: insertionRegion.cpp:26
pFlow::dictionary
Definition: dictionary.hpp:38
pFlow::insertionRegion::~insertionRegion
~insertionRegion()=default
peakableRegions.hpp