\hypertarget{a08900}{}\section{Open\+Mesh\+:\+:Property\+Manager$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ Class Template Reference}
\label{a08900}\index{Open\+Mesh\+::\+Property\+Manager$<$ P\+R\+O\+P\+T\+Y\+P\+E, Mesh\+T $>$@{Open\+Mesh\+::\+Property\+Manager$<$ P\+R\+O\+P\+T\+Y\+P\+E, Mesh\+T $>$}}


{\ttfamily \#include $<$Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Core/\+Utils/\+Property\+Manager.\+hh$>$}

\subsection*{Classes}
\begin{DoxyCompactItemize}
\item 
class \hyperlink{a08904}{Proxy}
\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{a08900_ab669f9c2efb6f9ad356c7c653a8de40c}{Property\+Manager} (MeshT \&mesh, const char $\ast$propname, bool existing=false)
\item 
\mbox{\Hypertarget{a08900_a1ac1f21a36640158de02c8dffbf81ff0}\label{a08900_a1ac1f21a36640158de02c8dffbf81ff0}} 
void {\bfseries swap} (\hyperlink{a08900}{Property\+Manager} \&rhs)
\item 
\mbox{\Hypertarget{a08900_a9535daa19510a51a0b7071ded8120453}\label{a08900_a9535daa19510a51a0b7071ded8120453}} 
bool {\bfseries is\+Valid} () const
\item 
\mbox{\Hypertarget{a08900_a61deccf62ce3fdb2b4b9c5f242b78d27}\label{a08900_a61deccf62ce3fdb2b4b9c5f242b78d27}} 
{\bfseries operator bool} () const
\item 
\mbox{\Hypertarget{a08900_acfc2d0c6b76e06a1679239587edd2e01}\label{a08900_acfc2d0c6b76e06a1679239587edd2e01}} 
const P\+R\+O\+P\+T\+Y\+PE \& {\bfseries get\+Raw\+Property} () const
\item 
\mbox{\Hypertarget{a08900_a44cde31cc2c53d5b6bf691c956b626a4}\label{a08900_a44cde31cc2c53d5b6bf691c956b626a4}} 
const std\+::string \& {\bfseries get\+Name} () const
\item 
\mbox{\Hypertarget{a08900_a07d67820fdf8b1d1cfc67549eddd0ce4}\label{a08900_a07d67820fdf8b1d1cfc67549eddd0ce4}} 
MeshT \& {\bfseries get\+Mesh} () const
\item 
\mbox{\Hypertarget{a08900_a9915ccbeea2a78ce68f7ee9432fe10b6}\label{a08900_a9915ccbeea2a78ce68f7ee9432fe10b6}} 
{\bfseries operator Proxy} ()
\item 
\mbox{\Hypertarget{a08900_ac6ddf364a994ad862070dfdb8cbdf620}\label{a08900_ac6ddf364a994ad862070dfdb8cbdf620}} 
\hyperlink{a08904}{Proxy} {\bfseries move} ()
\item 
\mbox{\Hypertarget{a08900_aefc965e7287262872137602a092da5de}\label{a08900_aefc965e7287262872137602a092da5de}} 
{\bfseries Property\+Manager} (\hyperlink{a08904}{Proxy} p)
\item 
\mbox{\Hypertarget{a08900_a01ba8c3df63d76589b170e34ae72972b}\label{a08900_a01ba8c3df63d76589b170e34ae72972b}} 
\hyperlink{a08900}{Property\+Manager} \& {\bfseries operator=} (\hyperlink{a08904}{Proxy} p)
\item 
\mbox{\Hypertarget{a08900_a17cb0e6fd5f3a334140fde962ee0ca6a}\label{a08900_a17cb0e6fd5f3a334140fde962ee0ca6a}} 
\hyperlink{a08904}{Proxy} {\bfseries duplicate} (const char $\ast$clone\+\_\+name)
\item 
void \hyperlink{a08900_aa388e739951640a7c432b49e5232cb84}{retain} (bool do\+Retain=true)
\begin{DoxyCompactList}\small\item\em Disable lifecycle management for this property. \end{DoxyCompactList}\item 
P\+R\+O\+P\+T\+Y\+PE \& \hyperlink{a08900_a0175f913ec495b7b9699a4a4d0993814}{operator$\ast$} ()
\item 
const P\+R\+O\+P\+T\+Y\+PE \& \hyperlink{a08900_a1a879138edcfc4cb6506ef7b83ddc322}{operator$\ast$} () const
\item 
{\footnotesize template$<$typename Handle\+Type $>$ }\\P\+R\+O\+P\+T\+Y\+P\+E\+::reference \hyperlink{a08900_a982d39e7eeac8383b3c899b029698496}{operator\mbox{[}$\,$\mbox{]}} (const Handle\+Type \&handle)
\item 
{\footnotesize template$<$typename Handle\+Type $>$ }\\P\+R\+O\+P\+T\+Y\+P\+E\+::const\+\_\+reference \hyperlink{a08900_ac5e33e1887e065283ea41c868ac51965}{operator\mbox{[}$\,$\mbox{]}} (const Handle\+Type \&handle) const
\item 
{\footnotesize template$<$typename Handle\+Type\+Iterator , typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE $>$ }\\void \hyperlink{a08900_a1c7b5c7063fb137ba9552afd4a0ec77f}{set\+\_\+range} (Handle\+Type\+Iterator begin, Handle\+Type\+Iterator end, const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&value)
\item 
{\footnotesize template$<$typename Handle\+Type\+Iterator , typename P\+R\+O\+P\+T\+Y\+P\+E\+\_\+2 , typename Mesh\+T\+\_\+2 , typename Handle\+Type\+Iterator\+\_\+2 $>$ }\\void \hyperlink{a08900_a6397c44399425725499fec75ff110026}{copy\+\_\+to} (Handle\+Type\+Iterator begin, Handle\+Type\+Iterator end, \hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+P\+E\+\_\+2, Mesh\+T\+\_\+2 $>$ \&dst\+\_\+propmanager, Handle\+Type\+Iterator\+\_\+2 dst\+\_\+begin, Handle\+Type\+Iterator\+\_\+2 dst\+\_\+end) const
\item 
\mbox{\Hypertarget{a08900_a74b933ad5110c73ce019ea2b8a7e2a9f}\label{a08900_a74b933ad5110c73ce019ea2b8a7e2a9f}} 
{\footnotesize template$<$typename Range\+Type , typename P\+R\+O\+P\+T\+Y\+P\+E\+\_\+2 , typename Mesh\+T\+\_\+2 , typename Range\+Type\+\_\+2 $>$ }\\void {\bfseries copy\+\_\+to} (const Range\+Type \&range, \hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+P\+E\+\_\+2, Mesh\+T\+\_\+2 $>$ \&dst\+\_\+propmanager, const Range\+Type\+\_\+2 \&dst\+\_\+range) const
\end{DoxyCompactItemize}
\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a08900_aab5979a603a7f4e2603c5342dda2de30}\label{a08900_aab5979a603a7f4e2603c5342dda2de30}} 
static bool {\bfseries property\+Exists} (MeshT \&mesh, const char $\ast$propname)
\item 
static \hyperlink{a08904}{Proxy} \hyperlink{a08900_adcef81e060c6dc8a10a7ed1a7fb01869}{create\+If\+Not\+Exists} (MeshT \&mesh, const char $\ast$propname)
\item 
{\footnotesize template$<$typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE , typename I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE $>$ }\\static \hyperlink{a08904}{Proxy} \hyperlink{a08900_a6be8aa3c45827108cfd0a89d1bfe2c28}{create\+If\+Not\+Exists} (MeshT \&mesh, const char $\ast$propname, const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&begin, const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&end, const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&init\+\_\+value)
\item 
{\footnotesize template$<$typename Range\+Type , typename Mesh\+T\+\_\+2 , typename Range\+Type\+\_\+2 $>$ }\\static void \hyperlink{a08900_aadbc2e85d8471cf8915a720aac6e5a7b}{copy} (const char $\ast$prop\+\_\+name, MeshT \&src\+\_\+mesh, const Range\+Type \&src\+\_\+range, Mesh\+T\+\_\+2 \&dst\+\_\+mesh, const Range\+Type\+\_\+2 \&dst\+\_\+range)
\end{DoxyCompactItemize}
\subsection*{Private Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{a08900_ada0ea7bb5b0b22d529b836dd4198a309}{Property\+Manager} (const \hyperlink{a08900}{Property\+Manager} \&)
\item 
\hyperlink{a08900}{Property\+Manager} \& \hyperlink{a08900_aa1492f8a40f29cfb1892cf4f783aa925}{operator=} (const \hyperlink{a08900}{Property\+Manager} \&)
\item 
\mbox{\Hypertarget{a08900_a60b868c3e7616ac8ffa2719b041c8990}\label{a08900_a60b868c3e7616ac8ffa2719b041c8990}} 
void {\bfseries delete\+Property} ()
\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{a08900_ac91d69a7b5510d1a608e5e6047feb428}\label{a08900_ac91d69a7b5510d1a608e5e6047feb428}} 
MeshT $\ast$ {\bfseries mesh\+\_\+}
\item 
\mbox{\Hypertarget{a08900_a57550261a734656d1598028c4b514d81}\label{a08900_a57550261a734656d1598028c4b514d81}} 
P\+R\+O\+P\+T\+Y\+PE {\bfseries prop\+\_\+}
\item 
\mbox{\Hypertarget{a08900_a19ccf617fbf1f1d102a93baeb1e54732}\label{a08900_a19ccf617fbf1f1d102a93baeb1e54732}} 
bool {\bfseries retain\+\_\+}
\item 
\mbox{\Hypertarget{a08900_aeeea39105b9bc6ee3fa218cd2df00749}\label{a08900_aeeea39105b9bc6ee3fa218cd2df00749}} 
std\+::string {\bfseries name\+\_\+}
\end{DoxyCompactItemize}
\subsection*{Related Functions}
(Note that these are not member functions.) \begin{DoxyCompactItemize}
\item 
{\footnotesize template$<$typename ElementT , typename T , typename MeshT $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ typename \hyperlink{a08832}{Handle\+To\+Prop\+Handle}$<$ ElementT, T $>$\+::type, MeshT $>$ \hyperlink{a08900_a879b7250e5270fbaee884ec1e0af0a4f}{make\+Temporary\+Property} (MeshT \&mesh, const char $\ast$propname=\char`\"{}\char`\"{})
\item 
{\footnotesize template$<$typename ElementT , typename T , typename MeshT $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ typename \hyperlink{a08832}{Handle\+To\+Prop\+Handle}$<$ ElementT, T $>$\+::type, MeshT $>$ \hyperlink{a08900_a28070d2a453498769b94d57953420785}{get\+Property} (MeshT \&mesh, const char $\ast$propname)
\item 
{\footnotesize template$<$typename ElementT , typename T , typename MeshT $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ typename \hyperlink{a08832}{Handle\+To\+Prop\+Handle}$<$ ElementT, T $>$\+::type, MeshT $>$ \hyperlink{a08900_a6532b67cfcf20a1a0754651f26b7179f}{get\+Or\+Make\+Property} (MeshT \&mesh, const char $\ast$propname)
\item 
{\footnotesize template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \hyperlink{a08900_a6a48e0a7e2115953158298617626bd87}{make\+Property\+Manager\+From\+New} (MeshT \&mesh, const char $\ast$propname)
\item 
{\footnotesize template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \hyperlink{a08900_a867447f5f0bef7f7e1566c0f1dfa4e51}{make\+Property\+Manager\+From\+Existing} (MeshT \&mesh, const char $\ast$propname)
\item 
{\footnotesize template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \hyperlink{a08900_ade542fc7505f5988782515b8d9873408}{make\+Property\+Manager\+From\+Existing\+Or\+New} (MeshT \&mesh, const char $\ast$propname)
\item 
{\footnotesize template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT , typename I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE , typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \hyperlink{a08900_ad28dc870789c604c3c49a1d21d6ed86f}{make\+Property\+Manager\+From\+Existing\+Or\+New} (MeshT \&mesh, const char $\ast$propname, const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&begin, const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&end, const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&init\+\_\+value)
\item 
{\footnotesize template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT , typename I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+R\+A\+N\+GE , typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE $>$ }\\\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \hyperlink{a08900_a4726501b7561ddbbb734e1c9dbdb53e3}{make\+Property\+Manager\+From\+Existing\+Or\+New} (MeshT \&mesh, const char $\ast$propname, const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+R\+A\+N\+GE \&range, const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&init\+\_\+value)
\end{DoxyCompactItemize}


\subsection{Detailed Description}
\subsubsection*{template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$\newline
class Open\+Mesh\+::\+Property\+Manager$<$ P\+R\+O\+P\+T\+Y\+P\+E, Mesh\+T $>$}

This class is intended to manage the lifecycle of properties. It also defines convenience operators to access the encapsulated property\textquotesingle{}s value.

It is recommended to use the factory functions \hyperlink{a08900_a879b7250e5270fbaee884ec1e0af0a4f}{make\+Temporary\+Property()}, \hyperlink{a08900_a28070d2a453498769b94d57953420785}{get\+Property()}, and \hyperlink{a08900_a6532b67cfcf20a1a0754651f26b7179f}{get\+Or\+Make\+Property()} to construct a \hyperlink{a08900}{Property\+Manager}, e.\+g.


\begin{DoxyCode}
\{
    TriMesh mesh;
    \textcolor{keyword}{auto} visited = makeTemporaryProperty<VertexHandle, bool>(mesh);

    \textcolor{keywordflow}{for} (\textcolor{keyword}{auto} vh : mesh.vertices()) \{
        \textcolor{keywordflow}{if} (!visited[vh]) \{
            visitComponent(mesh, vh, visited);
        \}
    \}
    \textcolor{comment}{// The property is automatically removed at the end of the scope}
\}
\end{DoxyCode}
 

Definition at line 77 of file Property\+Manager.\+hh.



\subsection{Constructor \& Destructor Documentation}
\mbox{\Hypertarget{a08900_ada0ea7bb5b0b22d529b836dd4198a309}\label{a08900_ada0ea7bb5b0b22d529b836dd4198a309}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!Property\+Manager@{Property\+Manager}}
\index{Property\+Manager@{Property\+Manager}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{Property\+Manager()}{PropertyManager()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
\hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::\hyperlink{a08900}{Property\+Manager} (\begin{DoxyParamCaption}\item[{const \hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \&}]{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}

Noncopyable because there aren\textquotesingle{}t no straightforward copy semantics. \mbox{\Hypertarget{a08900_ab669f9c2efb6f9ad356c7c653a8de40c}\label{a08900_ab669f9c2efb6f9ad356c7c653a8de40c}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!Property\+Manager@{Property\+Manager}}
\index{Property\+Manager@{Property\+Manager}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{Property\+Manager()}{PropertyManager()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
\hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::\hyperlink{a08900}{Property\+Manager} (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname,  }\item[{bool}]{existing = {\ttfamily false} }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Constructor.

Throws an {\ttfamily std\+::runtime\+\_\+error} if {\ttfamily existing} is true and no property named {\ttfamily propname} of the appropriate property type exists.


\begin{DoxyParams}{Parameters}
{\em mesh} & The mesh on which to create the property. \\
\hline
{\em propname} & The name of the property. \\
\hline
{\em existing} & If false, a new property is created and its lifecycle is managed (i.\+e. the property is deleted upon destruction of the \hyperlink{a08900}{Property\+Manager} instance). If true, the instance merely acts as a convenience wrapper around an existing property with no lifecycle management whatsoever.\\
\hline
\end{DoxyParams}
\begin{DoxySeeAlso}{See also}
\hyperlink{a08900_adcef81e060c6dc8a10a7ed1a7fb01869}{Property\+Manager\+::create\+If\+Not\+Exists}, \hyperlink{a08900_a6a48e0a7e2115953158298617626bd87}{make\+Property\+Manager\+From\+New}, \hyperlink{a08900_a867447f5f0bef7f7e1566c0f1dfa4e51}{make\+Property\+Manager\+From\+Existing}, \hyperlink{a08900_ade542fc7505f5988782515b8d9873408}{make\+Property\+Manager\+From\+Existing\+Or\+New} 
\end{DoxySeeAlso}


Definition at line 113 of file Property\+Manager.\+hh.



\subsection{Member Function Documentation}
\mbox{\Hypertarget{a08900_aadbc2e85d8471cf8915a720aac6e5a7b}\label{a08900_aadbc2e85d8471cf8915a720aac6e5a7b}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!copy@{copy}}
\index{copy@{copy}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{copy()}{copy()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
template$<$typename Range\+Type , typename Mesh\+T\+\_\+2 , typename Range\+Type\+\_\+2 $>$ \\
static void \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::copy (\begin{DoxyParamCaption}\item[{const char $\ast$}]{prop\+\_\+name,  }\item[{MeshT \&}]{src\+\_\+mesh,  }\item[{const Range\+Type \&}]{src\+\_\+range,  }\item[{Mesh\+T\+\_\+2 \&}]{dst\+\_\+mesh,  }\item[{const Range\+Type\+\_\+2 \&}]{dst\+\_\+range }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}

Copy the values of a property from a source range to a target range. The source range must not be smaller than the target range.


\begin{DoxyParams}{Parameters}
{\em prop\+\_\+name} & Name of the property to copy. Must exist on the source mesh. Will be created on the target mesh if it doesn\textquotesingle{}t exist.\\
\hline
{\em src\+\_\+mesh} & Source mesh from which to copy. \\
\hline
{\em src\+\_\+range} & Source range which to copy. Must not be smaller than dst\+\_\+range. \\
\hline
{\em dst\+\_\+mesh} & Destination mesh on which to copy. \\
\hline
{\em dst\+\_\+range} & Destination range. \\
\hline
\end{DoxyParams}


Definition at line 453 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a6397c44399425725499fec75ff110026}\label{a08900_a6397c44399425725499fec75ff110026}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!copy\+\_\+to@{copy\+\_\+to}}
\index{copy\+\_\+to@{copy\+\_\+to}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{copy\+\_\+to()}{copy\_to()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
template$<$typename Handle\+Type\+Iterator , typename P\+R\+O\+P\+T\+Y\+P\+E\+\_\+2 , typename Mesh\+T\+\_\+2 , typename Handle\+Type\+Iterator\+\_\+2 $>$ \\
void \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::copy\+\_\+to (\begin{DoxyParamCaption}\item[{Handle\+Type\+Iterator}]{begin,  }\item[{Handle\+Type\+Iterator}]{end,  }\item[{\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+P\+E\+\_\+2, Mesh\+T\+\_\+2 $>$ \&}]{dst\+\_\+propmanager,  }\item[{Handle\+Type\+Iterator\+\_\+2}]{dst\+\_\+begin,  }\item[{Handle\+Type\+Iterator\+\_\+2}]{dst\+\_\+end }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

Conveniently transfer the values managed by one property manager onto the values managed by a different property manager.


\begin{DoxyParams}{Parameters}
{\em begin} & Start iterator. Needs to dereference to Handle\+Type. Will be used with this property manager. \\
\hline
{\em end} & End iterator. (Exclusive.) Will be used with this property manager. \\
\hline
{\em dst\+\_\+propmanager} & The destination property manager. \\
\hline
{\em dst\+\_\+begin} & Start iterator. Needs to dereference to the Handle\+Type of dst\+\_\+propmanager. Will be used with dst\+\_\+propmanager. \\
\hline
{\em dst\+\_\+end} & End iterator. (Exclusive.) Will be used with dst\+\_\+propmanager. Used to double check the bounds. \\
\hline
\end{DoxyParams}


Definition at line 420 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_adcef81e060c6dc8a10a7ed1a7fb01869}\label{a08900_adcef81e060c6dc8a10a7ed1a7fb01869}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!create\+If\+Not\+Exists@{create\+If\+Not\+Exists}}
\index{create\+If\+Not\+Exists@{create\+If\+Not\+Exists}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{create\+If\+Not\+Exists()}{createIfNotExists()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
static \hyperlink{a08904}{Proxy} \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::create\+If\+Not\+Exists (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}

Create a property manager for the supplied property and mesh. If the property doesn\textquotesingle{}t exist, it is created. In any case, lifecycle management is disabled.

\begin{DoxySeeAlso}{See also}
\hyperlink{a08900_ade542fc7505f5988782515b8d9873408}{make\+Property\+Manager\+From\+Existing\+Or\+New} 
\end{DoxySeeAlso}


Definition at line 282 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a6be8aa3c45827108cfd0a89d1bfe2c28}\label{a08900_a6be8aa3c45827108cfd0a89d1bfe2c28}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!create\+If\+Not\+Exists@{create\+If\+Not\+Exists}}
\index{create\+If\+Not\+Exists@{create\+If\+Not\+Exists}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{create\+If\+Not\+Exists()}{createIfNotExists()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
template$<$typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE , typename I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE $>$ \\
static \hyperlink{a08904}{Proxy} \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::create\+If\+Not\+Exists (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname,  }\item[{const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&}]{begin,  }\item[{const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&}]{end,  }\item[{const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&}]{init\+\_\+value }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}

Like \hyperlink{a08900_adcef81e060c6dc8a10a7ed1a7fb01869}{create\+If\+Not\+Exists()} with two parameters except, if the property doesn\textquotesingle{}t exist, it is initialized with the supplied value over the supplied range after creation. If the property already exists, this method has the exact same effect as the two parameter version. Lifecycle management is disabled in any case.

\begin{DoxySeeAlso}{See also}
\hyperlink{a08900_ade542fc7505f5988782515b8d9873408}{make\+Property\+Manager\+From\+Existing\+Or\+New} 
\end{DoxySeeAlso}


Definition at line 299 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a0175f913ec495b7b9699a4a4d0993814}\label{a08900_a0175f913ec495b7b9699a4a4d0993814}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!operator$\ast$@{operator$\ast$}}
\index{operator$\ast$@{operator$\ast$}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{operator$\ast$()}{operator*()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
P\+R\+O\+P\+T\+Y\+PE\& \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::operator$\ast$ (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Access the encapsulated property. 

Definition at line 330 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a1a879138edcfc4cb6506ef7b83ddc322}\label{a08900_a1a879138edcfc4cb6506ef7b83ddc322}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!operator$\ast$@{operator$\ast$}}
\index{operator$\ast$@{operator$\ast$}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{operator$\ast$()}{operator*()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
const P\+R\+O\+P\+T\+Y\+PE\& \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::operator$\ast$ (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

Access the encapsulated property. 

Definition at line 337 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_aa1492f8a40f29cfb1892cf4f783aa925}\label{a08900_aa1492f8a40f29cfb1892cf4f783aa925}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!operator=@{operator=}}
\index{operator=@{operator=}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{operator=()}{operator=()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
\hyperlink{a08900}{Property\+Manager}\& \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::operator= (\begin{DoxyParamCaption}\item[{const \hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ \&}]{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}

Noncopyable because there aren\textquotesingle{}t no straightforward copy semantics. \mbox{\Hypertarget{a08900_a982d39e7eeac8383b3c899b029698496}\label{a08900_a982d39e7eeac8383b3c899b029698496}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!operator\mbox{[}\mbox{]}@{operator[]}}
\index{operator\mbox{[}\mbox{]}@{operator[]}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{operator[]()}{operator[]()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
template$<$typename Handle\+Type $>$ \\
P\+R\+O\+P\+T\+Y\+P\+E\+::reference \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::operator\mbox{[}$\,$\mbox{]} (\begin{DoxyParamCaption}\item[{const Handle\+Type \&}]{handle }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Enables convenient access to the encapsulated property.

For a usage example see this class\textquotesingle{} documentation.


\begin{DoxyParams}{Parameters}
{\em handle} & A handle of the appropriate handle type. (I.\+e. {\ttfamily \hyperlink{a08696}{Vertex\+Handle}} for {\ttfamily \hyperlink{a08876}{V\+Prop\+HandleT}}, etc.) \\
\hline
\end{DoxyParams}


Definition at line 349 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_ac5e33e1887e065283ea41c868ac51965}\label{a08900_ac5e33e1887e065283ea41c868ac51965}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!operator\mbox{[}\mbox{]}@{operator[]}}
\index{operator\mbox{[}\mbox{]}@{operator[]}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{operator[]()}{operator[]()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
template$<$typename Handle\+Type $>$ \\
P\+R\+O\+P\+T\+Y\+P\+E\+::const\+\_\+reference \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::operator\mbox{[}$\,$\mbox{]} (\begin{DoxyParamCaption}\item[{const Handle\+Type \&}]{handle }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

Enables convenient access to the encapsulated property.

For a usage example see this class\textquotesingle{} documentation.


\begin{DoxyParams}{Parameters}
{\em handle} & A handle of the appropriate handle type. (I.\+e. {\ttfamily \hyperlink{a08696}{Vertex\+Handle}} for {\ttfamily \hyperlink{a08876}{V\+Prop\+HandleT}}, etc.) \\
\hline
\end{DoxyParams}


Definition at line 361 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_aa388e739951640a7c432b49e5232cb84}\label{a08900_aa388e739951640a7c432b49e5232cb84}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!retain@{retain}}
\index{retain@{retain}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{retain()}{retain()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
void \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::retain (\begin{DoxyParamCaption}\item[{bool}]{do\+Retain = {\ttfamily true} }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}



Disable lifecycle management for this property. 

If this method is called, the encapsulated property will not be deleted upon destruction of the \hyperlink{a08900}{Property\+Manager} instance. 

Definition at line 323 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a1c7b5c7063fb137ba9552afd4a0ec77f}\label{a08900_a1c7b5c7063fb137ba9552afd4a0ec77f}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!set\+\_\+range@{set\+\_\+range}}
\index{set\+\_\+range@{set\+\_\+range}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{set\+\_\+range()}{set\_range()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE, typename MeshT$>$ \\
template$<$typename Handle\+Type\+Iterator , typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE $>$ \\
void \hyperlink{a08900}{Open\+Mesh\+::\+Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$\+::set\+\_\+range (\begin{DoxyParamCaption}\item[{Handle\+Type\+Iterator}]{begin,  }\item[{Handle\+Type\+Iterator}]{end,  }\item[{const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&}]{value }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Conveniently set the property for an entire range of values.

Examples\+: 
\begin{DoxyCode}
MeshT mesh;
PropertyManager<VPropHandleT<double>, MeshT> distance(
    mesh, \textcolor{stringliteral}{"distance.plugin-example.i8.informatik.rwth-aachen.de"});
distance.set\_range(
    mesh.vertices\_begin(), mesh.vertices\_end(),
    std::numeric\_limits<double>::infinity());
\end{DoxyCode}
 or 
\begin{DoxyCode}
MeshT::VertexHandle vh;
distance.set\_range(
    mesh.vv\_begin(vh), mesh.vv\_end(vh),
    std::numeric\_limits<double>::infinity());
\end{DoxyCode}



\begin{DoxyParams}{Parameters}
{\em begin} & Start iterator. Needs to dereference to Handle\+Type. \\
\hline
{\em end} & End iterator. (Exclusive.) \\
\hline
{\em value} & The value the range will be set to. \\
\hline
\end{DoxyParams}


Definition at line 390 of file Property\+Manager.\+hh.



\subsection{Friends And Related Function Documentation}
\mbox{\Hypertarget{a08900_a6532b67cfcf20a1a0754651f26b7179f}\label{a08900_a6532b67cfcf20a1a0754651f26b7179f}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!get\+Or\+Make\+Property@{get\+Or\+Make\+Property}}
\index{get\+Or\+Make\+Property@{get\+Or\+Make\+Property}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{get\+Or\+Make\+Property()}{getOrMakeProperty()}}
{\footnotesize\ttfamily template$<$typename ElementT , typename T , typename MeshT $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ typename \hyperlink{a08832}{Handle\+To\+Prop\+Handle}$<$ ElementT, T $>$\+::type, MeshT $>$ get\+Or\+Make\+Property (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

Obtains a handle to a named property if it exists or creates a new one otherwise.

Used for creating or accessing permanent properties.

Example\+: 
\begin{DoxyCode}
PolyMesh m;
\{
    \textcolor{keyword}{auto} is\_quad = getOrMakeProperty<FaceHandle, bool>(m, \textcolor{stringliteral}{"is\_quad"});
    \textcolor{keywordflow}{for} (\textcolor{keyword}{auto}& fh : m.faces()) \{
        is\_quad[fh] = (m.valence(fh) == 4);
    \}
    \textcolor{comment}{// The property remains on the mesh after the end of the scope.}
\}
\{
    \textcolor{comment}{// Retrieve the property from the previous scope.}
    \textcolor{keyword}{auto} is\_quad = getOrMakeProperty<FaceHandle, bool>(m, \textcolor{stringliteral}{"is\_quad"});
    \textcolor{comment}{// Use is\_quad here.}
\}
\end{DoxyCode}



\begin{DoxyParams}{Parameters}
{\em mesh} & The mesh on which the property is created \\
\hline
{\em propname} & The name of the created property \\
\hline
\end{DoxyParams}

\begin{DoxyTemplParams}{Template Parameters}
{\em ElementT} & Element type of the created property, e.\+g. \hyperlink{a08696}{Vertex\+Handle}, \hyperlink{a08700}{Halfedge\+Handle}, etc. \\
\hline
{\em T} & Value type of the created property, e.\+g., {\ttfamily double}, {\ttfamily int}, etc. \\
\hline
{\em MeshT} & Type of the mesh. Can often be inferred from {\ttfamily mesh} \\
\hline
\end{DoxyTemplParams}
\begin{DoxyReturn}{Returns}
A \hyperlink{a08900}{Property\+Manager} wrapping the property 
\end{DoxyReturn}


Definition at line 577 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a28070d2a453498769b94d57953420785}\label{a08900_a28070d2a453498769b94d57953420785}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!get\+Property@{get\+Property}}
\index{get\+Property@{get\+Property}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{get\+Property()}{getProperty()}}
{\footnotesize\ttfamily template$<$typename ElementT , typename T , typename MeshT $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ typename \hyperlink{a08832}{Handle\+To\+Prop\+Handle}$<$ ElementT, T $>$\+::type, MeshT $>$ get\+Property (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

Obtains a handle to a named property.

Example\+: 
\begin{DoxyCode}
PolyMesh m;
\{
    \textcolor{keywordflow}{try} \{
        \textcolor{keyword}{auto} is\_quad = getProperty<FaceHandle, bool>(m, \textcolor{stringliteral}{"is\_quad"});
        \textcolor{comment}{// Use is\_quad here.}
    \}
    \textcolor{keywordflow}{catch} (\textcolor{keyword}{const} std::runtime\_error& e) \{
        \textcolor{comment}{// There is no is\_quad face property on the mesh.}
    \}
\}
\end{DoxyCode}


\begin{DoxyPrecond}{Precondition}
Property with the name {\ttfamily propname} of matching type exists. 
\end{DoxyPrecond}

\begin{DoxyExceptions}{Exceptions}
{\em std\+::runtime\+\_\+error} & if no property with the name {\ttfamily propname} of matching type exists. \\
\hline
\end{DoxyExceptions}

\begin{DoxyParams}{Parameters}
{\em mesh} & The mesh on which the property is created \\
\hline
{\em propname} & The name of the created property \\
\hline
\end{DoxyParams}

\begin{DoxyTemplParams}{Template Parameters}
{\em ElementT} & Element type of the created property, e.\+g. \hyperlink{a08696}{Vertex\+Handle}, \hyperlink{a08700}{Halfedge\+Handle}, etc. \\
\hline
{\em T} & Value type of the created property, e.\+g., {\ttfamily double}, {\ttfamily int}, etc. \\
\hline
{\em MeshT} & Type of the mesh. Can often be inferred from {\ttfamily mesh} \\
\hline
\end{DoxyTemplParams}
\begin{DoxyReturn}{Returns}
A \hyperlink{a08900}{Property\+Manager} wrapping the property 
\end{DoxyReturn}


Definition at line 541 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a867447f5f0bef7f7e1566c0f1dfa4e51}\label{a08900_a867447f5f0bef7f7e1566c0f1dfa4e51}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!make\+Property\+Manager\+From\+Existing@{make\+Property\+Manager\+From\+Existing}}
\index{make\+Property\+Manager\+From\+Existing@{make\+Property\+Manager\+From\+Existing}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{make\+Property\+Manager\+From\+Existing()}{makePropertyManagerFromExisting()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ make\+Property\+Manager\+From\+Existing (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

\begin{DoxyRefDesc}{Deprecated}
\item[\hyperlink{a06165__deprecated000010}{Deprecated}]Use \hyperlink{a08900_a28070d2a453498769b94d57953420785}{get\+Property()} instead.\end{DoxyRefDesc}


Creates a non-\/owning wrapper for an existing mesh property (no lifecycle management).

Intended for convenient access.

\begin{DoxyPrecond}{Precondition}
Property with the name {\ttfamily propname} of matching type exists. 
\end{DoxyPrecond}

\begin{DoxyExceptions}{Exceptions}
{\em std\+::runtime\+\_\+error} & if no property with the name {\ttfamily propname} of matching type exists. \\
\hline
\end{DoxyExceptions}


Definition at line 611 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_ade542fc7505f5988782515b8d9873408}\label{a08900_ade542fc7505f5988782515b8d9873408}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!make\+Property\+Manager\+From\+Existing\+Or\+New@{make\+Property\+Manager\+From\+Existing\+Or\+New}}
\index{make\+Property\+Manager\+From\+Existing\+Or\+New@{make\+Property\+Manager\+From\+Existing\+Or\+New}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{make\+Property\+Manager\+From\+Existing\+Or\+New()}{makePropertyManagerFromExistingOrNew()}\hspace{0.1cm}{\footnotesize\ttfamily [1/3]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ make\+Property\+Manager\+From\+Existing\+Or\+New (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

\begin{DoxyRefDesc}{Deprecated}
\item[\hyperlink{a06165__deprecated000011}{Deprecated}]Use \hyperlink{a08900_a6532b67cfcf20a1a0754651f26b7179f}{get\+Or\+Make\+Property()} instead.\end{DoxyRefDesc}


Creates a non-\/owning wrapper for a mesh property (no lifecycle management). If the given property does not exist, it is created.

Intended for creating or accessing persistent properties. 

Definition at line 626 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_ad28dc870789c604c3c49a1d21d6ed86f}\label{a08900_ad28dc870789c604c3c49a1d21d6ed86f}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!make\+Property\+Manager\+From\+Existing\+Or\+New@{make\+Property\+Manager\+From\+Existing\+Or\+New}}
\index{make\+Property\+Manager\+From\+Existing\+Or\+New@{make\+Property\+Manager\+From\+Existing\+Or\+New}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{make\+Property\+Manager\+From\+Existing\+Or\+New()}{makePropertyManagerFromExistingOrNew()}\hspace{0.1cm}{\footnotesize\ttfamily [2/3]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT , typename I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE , typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ make\+Property\+Manager\+From\+Existing\+Or\+New (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname,  }\item[{const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&}]{begin,  }\item[{const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+T\+Y\+PE \&}]{end,  }\item[{const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&}]{init\+\_\+value }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

Like the two parameter version of \hyperlink{a08900_ade542fc7505f5988782515b8d9873408}{make\+Property\+Manager\+From\+Existing\+Or\+New()} except it initializes the property with the specified value over the specified range if it needs to be created. If the property already exists, this function has the exact same effect as the two parameter version.

Creates a non-\/owning wrapper for a mesh property (no lifecycle management). If the given property does not exist, it is created.

Intended for creating or accessing persistent properties. 

Definition at line 644 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a4726501b7561ddbbb734e1c9dbdb53e3}\label{a08900_a4726501b7561ddbbb734e1c9dbdb53e3}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!make\+Property\+Manager\+From\+Existing\+Or\+New@{make\+Property\+Manager\+From\+Existing\+Or\+New}}
\index{make\+Property\+Manager\+From\+Existing\+Or\+New@{make\+Property\+Manager\+From\+Existing\+Or\+New}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{make\+Property\+Manager\+From\+Existing\+Or\+New()}{makePropertyManagerFromExistingOrNew()}\hspace{0.1cm}{\footnotesize\ttfamily [3/3]}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT , typename I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+R\+A\+N\+GE , typename P\+R\+O\+P\+\_\+\+V\+A\+L\+UE $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ make\+Property\+Manager\+From\+Existing\+Or\+New (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname,  }\item[{const I\+T\+E\+R\+A\+T\+O\+R\+\_\+\+R\+A\+N\+GE \&}]{range,  }\item[{const P\+R\+O\+P\+\_\+\+V\+A\+L\+UE \&}]{init\+\_\+value }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

Like the two parameter version of \hyperlink{a08900_ade542fc7505f5988782515b8d9873408}{make\+Property\+Manager\+From\+Existing\+Or\+New()} except it initializes the property with the specified value over the specified range if it needs to be created. If the property already exists, this function has the exact same effect as the two parameter version.

Creates a non-\/owning wrapper for a mesh property (no lifecycle management). If the given property does not exist, it is created.

Intended for creating or accessing persistent properties. 

Definition at line 665 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a6a48e0a7e2115953158298617626bd87}\label{a08900_a6a48e0a7e2115953158298617626bd87}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!make\+Property\+Manager\+From\+New@{make\+Property\+Manager\+From\+New}}
\index{make\+Property\+Manager\+From\+New@{make\+Property\+Manager\+From\+New}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{make\+Property\+Manager\+From\+New()}{makePropertyManagerFromNew()}}
{\footnotesize\ttfamily template$<$typename P\+R\+O\+P\+T\+Y\+PE , typename MeshT $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ P\+R\+O\+P\+T\+Y\+PE, MeshT $>$ make\+Property\+Manager\+From\+New (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

\begin{DoxyRefDesc}{Deprecated}
\item[\hyperlink{a06165__deprecated000009}{Deprecated}]Use \hyperlink{a08900_a879b7250e5270fbaee884ec1e0af0a4f}{make\+Temporary\+Property()} instead.\end{DoxyRefDesc}


Creates a new property whose lifecycle is managed by the returned \hyperlink{a08900}{Property\+Manager}.

Intended for temporary properties. Shadows any existing properties of matching name and type. 

Definition at line 592 of file Property\+Manager.\+hh.

\mbox{\Hypertarget{a08900_a879b7250e5270fbaee884ec1e0af0a4f}\label{a08900_a879b7250e5270fbaee884ec1e0af0a4f}} 
\index{Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}!make\+Temporary\+Property@{make\+Temporary\+Property}}
\index{make\+Temporary\+Property@{make\+Temporary\+Property}!Open\+Mesh\+::\+Property\+Manager@{Open\+Mesh\+::\+Property\+Manager}}
\subsubsection{\texorpdfstring{make\+Temporary\+Property()}{makeTemporaryProperty()}}
{\footnotesize\ttfamily template$<$typename ElementT , typename T , typename MeshT $>$ \\
\hyperlink{a08900}{Property\+Manager}$<$ typename \hyperlink{a08832}{Handle\+To\+Prop\+Handle}$<$ ElementT, T $>$\+::type, MeshT $>$ make\+Temporary\+Property (\begin{DoxyParamCaption}\item[{MeshT \&}]{mesh,  }\item[{const char $\ast$}]{propname = {\ttfamily \char`\"{}\char`\"{}} }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [related]}}

Creates a new property whose lifetime is limited to the current scope.

Used for temporary properties. Shadows any existing properties of matching name and type.

Example\+: 
\begin{DoxyCode}
PolyMesh m;
\{
    \textcolor{keyword}{auto} is\_quad = makeTemporaryProperty<FaceHandle, bool>(m);
    \textcolor{keywordflow}{for} (\textcolor{keyword}{auto}& fh : m.faces()) \{
        is\_quad[fh] = (m.valence(fh) == 4);
    \}
    \textcolor{comment}{// The property is automatically removed from the mesh at the end of the scope.}
\}
\end{DoxyCode}



\begin{DoxyParams}{Parameters}
{\em mesh} & The mesh on which the property is created \\
\hline
{\em propname} & (optional) The name of the created property \\
\hline
\end{DoxyParams}

\begin{DoxyTemplParams}{Template Parameters}
{\em ElementT} & Element type of the created property, e.\+g. \hyperlink{a08696}{Vertex\+Handle}, \hyperlink{a08700}{Halfedge\+Handle}, etc. \\
\hline
{\em T} & Value type of the created property, e.\+g., {\ttfamily double}, {\ttfamily int}, etc. \\
\hline
{\em MeshT} & Type of the mesh. Can often be inferred from {\ttfamily mesh} \\
\hline
\end{DoxyTemplParams}
\begin{DoxyReturn}{Returns}
A \hyperlink{a08900}{Property\+Manager} handling the lifecycle of the property 
\end{DoxyReturn}


Definition at line 507 of file Property\+Manager.\+hh.



The documentation for this class was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
Open\+Flipper/libs\+\_\+required/\+Open\+Mesh/src/\+Open\+Mesh/\+Core/\+Utils/Property\+Manager.\+hh\end{DoxyCompactItemize}
