1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | cfMesh: A library for mesh generation
5 \\ / A nd | Author: Franjo Juretic (franjo.juretic@c-fields.com)
6 \\/ M anipulation | Copyright (C) Creative Fields, Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of cfMesh.
11 cfMesh is free software; you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by the
13 Free Software Foundation; either version 3 of the License, or (at your
14 option) any later version.
16 cfMesh is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 You should have received a copy of the GNU General Public License
22 along with cfMesh. If not, see <http://www.gnu.org/licenses/>.
25 An IODynList of a given type is a List of that type which supports automated
28 \*---------------------------------------------------------------------------*/
30 #include "IODynList.H"
32 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
37 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
39 template<class T, class IndexType>
40 IODynList<T, IndexType>::IODynList(const IOobject& io)
43 DynList<T, IndexType>()
47 io.readOpt() == IOobject::MUST_READ
48 || (io.readOpt() == IOobject::READ_IF_PRESENT && headerOk())
51 readStream(typeName) >> *this;
57 template<class T, class IndexType>
58 IODynList<T, IndexType>::IODynList
65 DynList<T, IndexType>(size)
69 template<class T, class IndexType>
70 IODynList<T, IndexType>::IODynList
73 const DynList<T, IndexType>& list
77 DynList<T, IndexType>()
79 if (io.readOpt() == IOobject::READ_IF_PRESENT && headerOk())
81 readStream(typeName) >> *this;
85 DynList<T, IndexType>::operator=(list);
89 template<class T, class IndexType>
90 void IODynList<T, IndexType>::operator=
92 const IODynList<T, IndexType>& rhs
95 DynList<T, IndexType>::operator=(rhs);
99 template<class T, class IndexType>
100 void IODynList<T, IndexType>::operator=
102 const DynList<T, IndexType>& rhs
105 DynList<T, IndexType>::operator=(rhs);
109 template<class T, class IndexType>
110 bool IODynList<T, IndexType>::writeData(Ostream& os) const
112 return (os << *this).good();
116 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
118 } // End namespace Foam
120 // ************************************************************************* //