5 #ifndef SPECIESHANDLER_H
6 #define SPECIESHANDLER_H
48 unsigned int getMixedId(
unsigned int id1,
unsigned int id2)
const;
54 return static_cast<typename U::MixedSpeciesType*
>(
getMixedObject(
S->getIndex(),
T->getIndex()));
67 virtual void write(std::ostream& os)
const;
Container to store the pointers to all objects that one creates in a simulation.
Definition: BaseHandler.h:30
virtual void clear()
Empties the whole BaseHandler by removing all Objects and setting all other variables to 0.
Definition: BaseHandler.h:536
BaseSpecies is the class from which all other species are derived.
Definition: BaseSpecies.h:29
Definition: ParticleSpecies.h:16
Container to store all ParticleSpecies.
Definition: SpeciesHandler.h:15
void updateMixedObjects()
Updates the mixed species.
Definition: SpeciesHandler.cc:986
bool useAngularDOFs()
Check if angular DOF have to be used.
Definition: SpeciesHandler.cc:1073
std::string getName() const override
Returns the name of the handler, namely the string "SpeciesHandler".
Definition: SpeciesHandler.cc:1065
void removeObject(unsigned int index) override
Remove the ParticleSpecies with given id.
Definition: SpeciesHandler.cc:1033
void clear() override
Empties the whole BaseHandler by removing all Objects and setting all other variables to 0.
Definition: SpeciesHandler.h:32
SpeciesHandler & operator=(const SpeciesHandler &rhs)
Assignment operator that copies all species and the pointer to the DPMBase from the given SpeciesHand...
Definition: SpeciesHandler.cc:107
std::vector< BaseSpecies * > mixedObjects_
The list of pointers to the mixed species.
Definition: SpeciesHandler.h:77
unsigned int getMixedId(unsigned int id1, unsigned int id2) const
Gets the Id of the behaviour between two given species.
Definition: SpeciesHandler.cc:932
void addObject(ParticleSpecies *S) override
Adds a new ParticleSpecies to the SpeciesHandler.
Definition: SpeciesHandler.cc:1008
void readAndAddObject(std::istream &is) override
Reads Species data into the SpeciesHandler from restart file.
Definition: SpeciesHandler.cc:153
const std::vector< BaseSpecies * > & getMixedObjects() const
Returns a pointer to the vector of all mixed objects.
Definition: SpeciesHandler.cc:941
ParticleSpecies * readOldObject(std::istream &is)
Reads ParticleSpecies into the SpeciesHandler from old-style restart data.
Definition: SpeciesHandler.cc:854
~SpeciesHandler() override
Destructor, it destructs the SpeciesHandler and all ParticleSpecies it contains.
Definition: SpeciesHandler.cc:133
SpeciesHandler()
Default constructor, it creates an empty SpeciesHandler.
Definition: SpeciesHandler.cc:76
std::enable_if<!std::is_pointer< typename U::MixedSpeciesType >::value, typename U::MixedSpeciesType * >::type getMixedObject(const U *S, const U *T)
Definition: SpeciesHandler.h:52
virtual void write(std::ostream &os) const
Write all the species and mixed species to an output stream.
Definition: SpeciesHandler.cc:1047
squared absolute value
Definition: GlobalFunctions.h:87
double U
Swimming speed.
Definition: two_d_variable_diff_adapt.cc:53
type
Definition: compute_granudrum_aor.py:141
std::string string(const unsigned &i)
Definition: oomph_definitions.cc:286
@ S
Definition: quadtree.h:62