/*---------------------------------------------------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | \\ / A nd | Copyright (C) 2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License This file is part of OpenFOAM. OpenFOAM is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. OpenFOAM is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenFOAM. If not, see . Class Foam::Particle Description SourceFiles ParticleI.H Particle.C ParticleIO.C \*---------------------------------------------------------------------------*/ #ifndef Particle_H #define Particle_H #include "word.H" #include "scalar.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // namespace Foam { // Forward declaration of classes class Istream; class Ostream; class dictionary; // Forward declaration of friend functions and operators class Particle; Istream& operator>>(Istream&, Particle&); Ostream& operator<<(Ostream&, const Particle&); /*---------------------------------------------------------------------------*\ Class Particle Declaration \*---------------------------------------------------------------------------*/ class Particle { public: //- Enumeration defining the particle geometry enum Geometry { ATOM = 0, LINEAR = 1, NONLINEAR = 2 }; protected: // Private data //- Species name word name_; //- Molecular weight [kg / kmol] scalar W_; //- Number of elementary charges scalar z_; //- Geometry Geometry geometry_; // Private Member Functions //- Disallow default bitwise copy construct Particle(const Particle&); //- Disallow default bitwise assignment void operator=(const Particle&); public: // Static data members // Constructors //- Construct from components Particle(const dictionary& dict); //- Construct from Istream Particle(Istream&); //- Construct as copy // Particle(const Particle&); //- Destructor ~Particle(); // Member Functions // Access inline const word& name() const; inline scalar W() const; inline scalar z() const; inline Geometry geometry() const; // Check // Edit // Write // Member Operators // void operator=(const Particle&); // Friend Functions // Friend Operators // IOstream Operators friend Istream& operator>>(Istream&, Particle&); friend Ostream& operator<<(Ostream&, const Particle&); }; // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // } // End namespace Foam // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // #include "ParticleI.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // #endif // ************************************************************************* //