\hypertarget{a11668}{}\section{Open\+Volume\+Mesh\+:\+:IO\+:\+:File\+Manager Class Reference}
\label{a11668}\index{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}}


Read/\+Write mesh data from/to files.  




{\ttfamily \#include $<$Type-\/\+Open\+Volume\+Mesh/libs/\+Open\+Volume\+Mesh/src/\+Open\+Volume\+Mesh/\+File\+Manager/\+File\+Manager.\+hh$>$}

\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a11668_abe3ebe1b45ed50ef5f6061a990b93754}\label{a11668_abe3ebe1b45ed50ef5f6061a990b93754}} 
\hyperlink{a11668_abe3ebe1b45ed50ef5f6061a990b93754}{File\+Manager} ()
\begin{DoxyCompactList}\small\item\em Default constructor. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{a11668_a9a51ac675dba0724b51cfa217c584c3b}\label{a11668_a9a51ac675dba0724b51cfa217c584c3b}} 
\hyperlink{a11668_a9a51ac675dba0724b51cfa217c584c3b}{$\sim$\+File\+Manager} ()
\begin{DoxyCompactList}\small\item\em Default destructor. \end{DoxyCompactList}\item 
void \hyperlink{a11668_ab3c6bc019c27881444cb19e90ac71b8b}{set\+Verbosity\+Level} (int \+\_\+level)
\begin{DoxyCompactList}\small\item\em set minimum level for errors that are printed to std\+::cerr \end{DoxyCompactList}\item 
{\footnotesize template$<$class MeshT $>$ }\\bool \hyperlink{a11668_a62684f7c4c39e002e1f3fba6734758f4}{read\+Stream} (std\+::istream \&\+\_\+istream, MeshT \&\+\_\+mesh, bool \+\_\+topology\+Check=true, bool \+\_\+compute\+Bottom\+Up\+Incidences=true) const
\begin{DoxyCompactList}\small\item\em Read a mesh from an std\+::istream. \end{DoxyCompactList}\item 
{\footnotesize template$<$class MeshT $>$ }\\bool \hyperlink{a11668_a16af670f7303a8046c70ba3cd7b58be1}{read\+File} (const std\+::string \&\+\_\+filename, MeshT \&\+\_\+mesh, bool \+\_\+topology\+Check=true, bool \+\_\+compute\+Bottom\+Up\+Incidences=true) const
\begin{DoxyCompactList}\small\item\em Read a mesh from a file. \end{DoxyCompactList}\item 
{\footnotesize template$<$class MeshT $>$ }\\void \hyperlink{a11668_a0b9a8b82a20db6c488fe0f38a3fd17cd}{write\+Stream} (std\+::ostream \&\+\_\+ostream, const MeshT \&\+\_\+mesh) const
\begin{DoxyCompactList}\small\item\em Write a mesh to an std\+::ostream. \end{DoxyCompactList}\item 
{\footnotesize template$<$class MeshT $>$ }\\bool \hyperlink{a11668_a377354860dd01186ece6342be795e357}{write\+File} (const std\+::string \&\+\_\+filename, const MeshT \&\+\_\+mesh) const
\begin{DoxyCompactList}\small\item\em Write a mesh to a file. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{a11668_a91b680323b4b4dc1b9ebddb62563b19f}\label{a11668_a91b680323b4b4dc1b9ebddb62563b19f}} 
bool \hyperlink{a11668_a91b680323b4b4dc1b9ebddb62563b19f}{is\+Hexahedral\+Mesh} (const std\+::string \&\+\_\+filename) const
\begin{DoxyCompactList}\small\item\em Test whether given file contains a hexahedral mesh. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{a11668_a7c21f5ed672b107cdf4faa5b30dc38e8}\label{a11668_a7c21f5ed672b107cdf4faa5b30dc38e8}} 
bool \hyperlink{a11668_a7c21f5ed672b107cdf4faa5b30dc38e8}{is\+Tetrahedral\+Mesh} (const std\+::string \&\+\_\+filename) const
\begin{DoxyCompactList}\small\item\em Test whether given file contains a tetrahedral mesh. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a11668_aac7179622fc100adcaf4954ffda796c6}\label{a11668_aac7179622fc100adcaf4954ffda796c6}} 
{\footnotesize template$<$class MeshT $>$ }\\void {\bfseries read\+Property} (std\+::istream \&\+\_\+iff, MeshT \&\+\_\+mesh) const
\item 
\mbox{\Hypertarget{a11668_acca2ab387f304d6f35ba6e61f2a86388}\label{a11668_acca2ab387f304d6f35ba6e61f2a86388}} 
{\footnotesize template$<$class PropT , class MeshT $>$ }\\void {\bfseries generate\+Generic\+Property} (const std\+::string \&\+\_\+entity\+\_\+t, const std\+::string \&\+\_\+name, std\+::istream \&\+\_\+iff, MeshT \&\+\_\+mesh) const
\item 
\mbox{\Hypertarget{a11668_af07e719491caf435bacb884f92d451b1}\label{a11668_af07e719491caf435bacb884f92d451b1}} 
{\footnotesize template$<$class IteratorT $>$ }\\void {\bfseries write\+Props} (std\+::ostream \&\+\_\+ostr, const IteratorT \&\+\_\+begin, const IteratorT \&\+\_\+end) const
\item 
\mbox{\Hypertarget{a11668_a289f16b9f2f37fb454b507b37e3159d9}\label{a11668_a289f16b9f2f37fb454b507b37e3159d9}} 
void {\bfseries trim\+String} (std\+::string \&\+\_\+string) const
\item 
\mbox{\Hypertarget{a11668_a8bb1d3af93ef698fd4c3b48ba0adee23}\label{a11668_a8bb1d3af93ef698fd4c3b48ba0adee23}} 
void {\bfseries extract\+Quoted\+Text} (std\+::string \&\+\_\+string) const
\item 
\mbox{\Hypertarget{a11668_a1866a8fb40913519f4c067fb077cdfaa}\label{a11668_a1866a8fb40913519f4c067fb077cdfaa}} 
bool {\bfseries get\+Clean\+Line} (std\+::istream \&ifs, std\+::string \&\+\_\+string, bool \+\_\+skip\+Empty\+Lines=true) const
\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a11668_a0ef91314a750cabe1358f6ad57ef9f72}\label{a11668_a0ef91314a750cabe1358f6ad57ef9f72}} 
int {\bfseries verbosity\+\_\+level\+\_\+} = 3
\end{DoxyCompactItemize}


\subsection{Detailed Description}
Read/\+Write mesh data from/to files. 

\begin{DoxyRefDesc}{Todo}
\item[\hyperlink{a06164__todo000051}{Todo}]Implement binary file support \end{DoxyRefDesc}


Definition at line 62 of file File\+Manager.\+hh.



\subsection{Member Function Documentation}
\mbox{\Hypertarget{a11668_a16af670f7303a8046c70ba3cd7b58be1}\label{a11668_a16af670f7303a8046c70ba3cd7b58be1}} 
\index{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}!read\+File@{read\+File}}
\index{read\+File@{read\+File}!Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}}
\subsubsection{\texorpdfstring{read\+File()}{readFile()}}
{\footnotesize\ttfamily template$<$class MeshT $>$ \\
bool Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager\+::read\+File (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{\+\_\+filename,  }\item[{MeshT \&}]{\+\_\+mesh,  }\item[{bool}]{\+\_\+topology\+Check = {\ttfamily true},  }\item[{bool}]{\+\_\+compute\+Bottom\+Up\+Incidences = {\ttfamily true} }\end{DoxyParamCaption}) const}



Read a mesh from a file. 

Returns true if the file was successfully read. The mesh is stored in parameter \+\_\+mesh. If something goes wrong, this function returns false.


\begin{DoxyParams}{Parameters}
{\em \+\_\+filename} & The file that is to be read \\
\hline
{\em \+\_\+mesh} & A reference to an Open\+Volume\+Mesh instance \\
\hline
{\em \+\_\+topology\+Check} & Pass true if you want to perform a topology check each time an entity is added (slower performance) \\
\hline
{\em \+\_\+compute\+Bottom\+Up\+Incidences} & Pass true if you want the file manager to directly compute the bottom-\/up incidences for the mesh. (Note\+: These are needed for some iterators to work, see documentation) \\
\hline
\end{DoxyParams}


Definition at line 308 of file File\+Manager\+T\+\_\+impl.\+hh.

\mbox{\Hypertarget{a11668_a62684f7c4c39e002e1f3fba6734758f4}\label{a11668_a62684f7c4c39e002e1f3fba6734758f4}} 
\index{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}!read\+Stream@{read\+Stream}}
\index{read\+Stream@{read\+Stream}!Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}}
\subsubsection{\texorpdfstring{read\+Stream()}{readStream()}}
{\footnotesize\ttfamily template$<$class MeshT $>$ \\
bool Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager\+::read\+Stream (\begin{DoxyParamCaption}\item[{std\+::istream \&}]{\+\_\+istream,  }\item[{MeshT \&}]{\+\_\+mesh,  }\item[{bool}]{\+\_\+topology\+Check = {\ttfamily true},  }\item[{bool}]{\+\_\+compute\+Bottom\+Up\+Incidences = {\ttfamily true} }\end{DoxyParamCaption}) const}



Read a mesh from an std\+::istream. 

Returns true if the file was successfully read. The mesh is stored in parameter \+\_\+mesh. If something goes wrong, this function returns false.


\begin{DoxyParams}{Parameters}
{\em \+\_\+istream} & The stream to read the mesh from \\
\hline
{\em \+\_\+mesh} & A reference to an Open\+Volume\+Mesh instance \\
\hline
{\em \+\_\+topology\+Check} & Pass true if you want to perform a topology check each time an entity is added (slower performance) \\
\hline
{\em \+\_\+compute\+Bottom\+Up\+Incidences} & Pass true if you want the file manager to directly compute the bottom-\/up incidences for the mesh. (Note\+: These are needed for some iterators to work, see documentation) \\
\hline
\end{DoxyParams}


Definition at line 67 of file File\+Manager\+T\+\_\+impl.\+hh.

\mbox{\Hypertarget{a11668_ab3c6bc019c27881444cb19e90ac71b8b}\label{a11668_ab3c6bc019c27881444cb19e90ac71b8b}} 
\index{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}!set\+Verbosity\+Level@{set\+Verbosity\+Level}}
\index{set\+Verbosity\+Level@{set\+Verbosity\+Level}!Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}}
\subsubsection{\texorpdfstring{set\+Verbosity\+Level()}{setVerbosityLevel()}}
{\footnotesize\ttfamily void Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager\+::set\+Verbosity\+Level (\begin{DoxyParamCaption}\item[{int}]{\+\_\+level }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}



set minimum level for errors that are printed to std\+::cerr 


\begin{DoxyParams}{Parameters}
{\em \+\_\+level} & 0\+: no output; 1\+: only errors; 2\+: warnings/info \\
\hline
\end{DoxyParams}


Definition at line 76 of file File\+Manager.\+hh.

\mbox{\Hypertarget{a11668_a377354860dd01186ece6342be795e357}\label{a11668_a377354860dd01186ece6342be795e357}} 
\index{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}!write\+File@{write\+File}}
\index{write\+File@{write\+File}!Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}}
\subsubsection{\texorpdfstring{write\+File()}{writeFile()}}
{\footnotesize\ttfamily template$<$class MeshT $>$ \\
bool Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager\+::write\+File (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{\+\_\+filename,  }\item[{const MeshT \&}]{\+\_\+mesh }\end{DoxyParamCaption}) const}



Write a mesh to a file. 

Returns true if the file was successfully written. The mesh is passed as parameter \+\_\+mesh. If something goes wrong, this function returns false.


\begin{DoxyParams}{Parameters}
{\em \+\_\+filename} & The file that is to be stored \\
\hline
{\em \+\_\+mesh} & A const reference to an Open\+Volume\+Mesh instance \\
\hline
\end{DoxyParams}


Definition at line 517 of file File\+Manager\+T\+\_\+impl.\+hh.

\mbox{\Hypertarget{a11668_a0b9a8b82a20db6c488fe0f38a3fd17cd}\label{a11668_a0b9a8b82a20db6c488fe0f38a3fd17cd}} 
\index{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}!write\+Stream@{write\+Stream}}
\index{write\+Stream@{write\+Stream}!Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager@{Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager}}
\subsubsection{\texorpdfstring{write\+Stream()}{writeStream()}}
{\footnotesize\ttfamily template$<$class MeshT $>$ \\
void Open\+Volume\+Mesh\+::\+I\+O\+::\+File\+Manager\+::write\+Stream (\begin{DoxyParamCaption}\item[{std\+::ostream \&}]{\+\_\+ostream,  }\item[{const MeshT \&}]{\+\_\+mesh }\end{DoxyParamCaption}) const}



Write a mesh to an std\+::ostream. 


\begin{DoxyParams}{Parameters}
{\em \+\_\+ostream} & The stream to write the mesh to \\
\hline
{\em \+\_\+mesh} & A const reference to an Open\+Volume\+Mesh instance \\
\hline
\end{DoxyParams}


Definition at line 425 of file File\+Manager\+T\+\_\+impl.\+hh.



The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
\item 
Type-\/\+Open\+Volume\+Mesh/libs/\+Open\+Volume\+Mesh/src/\+Open\+Volume\+Mesh/\+File\+Manager/File\+Manager.\+hh\item 
Type-\/\+Open\+Volume\+Mesh/libs/\+Open\+Volume\+Mesh/src/\+Open\+Volume\+Mesh/\+File\+Manager/File\+Manager.\+cc\item 
Type-\/\+Open\+Volume\+Mesh/libs/\+Open\+Volume\+Mesh/src/\+Open\+Volume\+Mesh/\+File\+Manager/File\+Manager\+T\+\_\+impl.\+hh\end{DoxyCompactItemize}
