\hypertarget{class_s_c_i_run_1_1_mutex}{\section{Mutex Class Reference}
\label{class_s_c_i_run_1_1_mutex}\index{Mutex@{Mutex}}
}


{\ttfamily \#include $<$Mutex.\-h$>$}

\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{class_s_c_i_run_1_1_mutex_a5d95a69128fddd7a01fbd1f9567f3582}{Mutex} (const char $\ast$\hyperlink{_boost_graph_example_tests_8cc_a8ad72759d07f18eaf8f6690e5dfb747c}{name})
\item 
\hyperlink{class_s_c_i_run_1_1_mutex_a205e2c334b25cb96e4f1303a4fde6b0c}{$\sim$\-Mutex} ()
\item 
void \hyperlink{class_s_c_i_run_1_1_mutex_aa81aed607133209dade63a226818224d}{lock} ()
\item 
bool \hyperlink{class_s_c_i_run_1_1_mutex_ac1aa74f9e66d65b9dccf7a2e92921192}{try\-Lock} ()
\item 
void \hyperlink{class_s_c_i_run_1_1_mutex_a9278be8203e1c42e2619179882ae4403}{unlock} ()
\end{DoxyCompactItemize}
\subsection*{Friends}
\begin{DoxyCompactItemize}
\item 
class \hyperlink{class_s_c_i_run_1_1_mutex_ab270e49e575fdf0fe1a4f2ee911df116}{Condition\-Variable}
\end{DoxyCompactItemize}


\subsection{Constructor \& Destructor Documentation}
\hypertarget{class_s_c_i_run_1_1_mutex_a5d95a69128fddd7a01fbd1f9567f3582}{\index{S\-C\-I\-Run\-::\-Mutex@{S\-C\-I\-Run\-::\-Mutex}!Mutex@{Mutex}}
\index{Mutex@{Mutex}!SCIRun::Mutex@{S\-C\-I\-Run\-::\-Mutex}}
\subsubsection[{Mutex}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Mutex} (
\begin{DoxyParamCaption}
\item[{const char $\ast$}]{name}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily [explicit]}}}\label{class_s_c_i_run_1_1_mutex_a5d95a69128fddd7a01fbd1f9567f3582}
Create the mutex. The mutex is allocated in the unlocked state. {\itshape name} should be a static string which describes the primitive for debugging purposes. \hypertarget{class_s_c_i_run_1_1_mutex_a205e2c334b25cb96e4f1303a4fde6b0c}{\index{S\-C\-I\-Run\-::\-Mutex@{S\-C\-I\-Run\-::\-Mutex}!$\sim$\-Mutex@{$\sim$\-Mutex}}
\index{$\sim$\-Mutex@{$\sim$\-Mutex}!SCIRun::Mutex@{S\-C\-I\-Run\-::\-Mutex}}
\subsubsection[{$\sim$\-Mutex}]{\setlength{\rightskip}{0pt plus 5cm}$\sim${\bf Mutex} (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}\label{class_s_c_i_run_1_1_mutex_a205e2c334b25cb96e4f1303a4fde6b0c}
Destroy the mutex. Destroying the mutex in the locked state has undefined results. 

\subsection{Member Function Documentation}
\hypertarget{class_s_c_i_run_1_1_mutex_aa81aed607133209dade63a226818224d}{\index{S\-C\-I\-Run\-::\-Mutex@{S\-C\-I\-Run\-::\-Mutex}!lock@{lock}}
\index{lock@{lock}!SCIRun::Mutex@{S\-C\-I\-Run\-::\-Mutex}}
\subsubsection[{lock}]{\setlength{\rightskip}{0pt plus 5cm}void lock (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}\label{class_s_c_i_run_1_1_mutex_aa81aed607133209dade63a226818224d}
Acquire the \hyperlink{class_s_c_i_run_1_1_mutex}{Mutex}. This method will block until the mutex is acquired. \hypertarget{class_s_c_i_run_1_1_mutex_ac1aa74f9e66d65b9dccf7a2e92921192}{\index{S\-C\-I\-Run\-::\-Mutex@{S\-C\-I\-Run\-::\-Mutex}!try\-Lock@{try\-Lock}}
\index{try\-Lock@{try\-Lock}!SCIRun::Mutex@{S\-C\-I\-Run\-::\-Mutex}}
\subsubsection[{try\-Lock}]{\setlength{\rightskip}{0pt plus 5cm}bool try\-Lock (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}\label{class_s_c_i_run_1_1_mutex_ac1aa74f9e66d65b9dccf7a2e92921192}
Attempt to acquire the \hyperlink{class_s_c_i_run_1_1_mutex}{Mutex} without blocking. Returns true if the mutex was available and actually acquired. \hypertarget{class_s_c_i_run_1_1_mutex_a9278be8203e1c42e2619179882ae4403}{\index{S\-C\-I\-Run\-::\-Mutex@{S\-C\-I\-Run\-::\-Mutex}!unlock@{unlock}}
\index{unlock@{unlock}!SCIRun::Mutex@{S\-C\-I\-Run\-::\-Mutex}}
\subsubsection[{unlock}]{\setlength{\rightskip}{0pt plus 5cm}void unlock (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}\label{class_s_c_i_run_1_1_mutex_a9278be8203e1c42e2619179882ae4403}
Release the \hyperlink{class_s_c_i_run_1_1_mutex}{Mutex}, unblocking any other threads that are blocked waiting for the \hyperlink{class_s_c_i_run_1_1_mutex}{Mutex}. 

\subsection{Friends And Related Function Documentation}
\hypertarget{class_s_c_i_run_1_1_mutex_ab270e49e575fdf0fe1a4f2ee911df116}{\index{S\-C\-I\-Run\-::\-Mutex@{S\-C\-I\-Run\-::\-Mutex}!Condition\-Variable@{Condition\-Variable}}
\index{Condition\-Variable@{Condition\-Variable}!SCIRun::Mutex@{S\-C\-I\-Run\-::\-Mutex}}
\subsubsection[{Condition\-Variable}]{\setlength{\rightskip}{0pt plus 5cm}friend class {\bf Condition\-Variable}\hspace{0.3cm}{\ttfamily [friend]}}}\label{class_s_c_i_run_1_1_mutex_ab270e49e575fdf0fe1a4f2ee911df116}


The documentation for this class was generated from the following files\-:\begin{DoxyCompactItemize}
\item 
Core/\-Thread/\-Legacy/\hyperlink{_legacy_2_mutex_8h}{Mutex.\-h}\item 
Core/\-Thread/\-Legacy/\hyperlink{_thread__none_8cc}{Thread\-\_\-none.\-cc}\item 
Core/\-Thread/\-Legacy/\hyperlink{_thread__pthreads_8cc}{Thread\-\_\-pthreads.\-cc}\end{DoxyCompactItemize}
