\hypertarget{classCRL_1_1SearchPath}{}\section{C\+RL\+:\+:Search\+Path Class Reference}
\label{classCRL_1_1SearchPath}\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}


An ordered list of search pathes.  


\subsection*{Classes}
\begin{DoxyCompactItemize}
\item 
class \mbox{\hyperlink{classCRL_1_1SearchPath_1_1Element}{Element}}
\begin{DoxyCompactList}\small\item\em An element of the search path (mapping a directory). \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
void \mbox{\hyperlink{classCRL_1_1SearchPath_a7081332b63c642917b4ca15f665662f4}{reset}} ()
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_af358bdb1e940f08137f887f70eb641e3}{append}} (const std\+::string \&path, const std\+::string \&name=\char`\"{}\char`\"{})
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_af39d78a63d880e90ae6f947abf1fe322}{prepend}} (const std\+::string \&path, const std\+::string \&name=\char`\"{}\char`\"{})
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_a6cd1524e1048f246682cd5ef40145d67}{replace}} (const std\+::string \&path, const std\+::string \&, size\+\_\+t index)
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_af8e579af7e78dddb7a014d4bbbf9a36f}{locate}} (const std\+::string \&file, std\+::ios\+::openmode mode=std\+::ios\+::in, int first=0, int last=64)
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_a861b3045d7ee4671c93ba0396e3639f9}{get\+Size}} () const
\item 
const std\+::string \& \mbox{\hyperlink{classCRL_1_1SearchPath_a1571b1b80eca0da7333a014044158b6f}{get\+Selected}} () const
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_aa1023cd4721778d12756850a57f6a530}{get\+Index}} () const
\item 
bool \mbox{\hyperlink{classCRL_1_1SearchPath_ac6a365281c272da46a02e68de2a401d1}{has\+Selected}} () const
\item 
size\+\_\+t \mbox{\hyperlink{classCRL_1_1SearchPath_a0e255b4339b5ec59bc8425bad057dc4f}{has\+Path}} (const std\+::string \&path) const
\item 
const \mbox{\hyperlink{classCRL_1_1SearchPath_1_1Element}{Element}} \& \mbox{\hyperlink{classCRL_1_1SearchPath_a2ba563c50865bc8417d65cf4a6b342d1}{operator\mbox{[}$\,$\mbox{]}}} (size\+\_\+t index) const
\end{DoxyCompactItemize}
\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
static std\+::string \mbox{\hyperlink{classCRL_1_1SearchPath_aef473ae1037c8cb792a3af02baea6fdc}{extract\+Lib\+Name}} (const std\+::string \&)
\end{DoxyCompactItemize}


\subsection{Detailed Description}
An ordered list of search pathes. 

The \mbox{\hyperlink{classCRL_1_1SearchPath}{Search\+Path}} is an \mbox{\hyperlink{classCRL_1_1AllianceFramework}{Alliance\+Framework}} owned object, and as such it\textquotesingle{}s constructors \& destructors are made inaccessible by the outside world. 

\subsection{Member Function Documentation}
\mbox{\Hypertarget{classCRL_1_1SearchPath_aef473ae1037c8cb792a3af02baea6fdc}\label{classCRL_1_1SearchPath_aef473ae1037c8cb792a3af02baea6fdc}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!extract\+Lib\+Name@{extract\+Lib\+Name}}
\index{extract\+Lib\+Name@{extract\+Lib\+Name}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{extract\+Lib\+Name()}{extractLibName()}}
{\footnotesize\ttfamily std\+::string C\+R\+L\+::\+Search\+Path\+::extract\+Lib\+Name (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [static]}}

\begin{DoxyReturn}{Returns}
the library name guessed from a directory path. This is the last component of the, stripped of any extention. 
\end{DoxyReturn}


Referenced by append().

\mbox{\Hypertarget{classCRL_1_1SearchPath_a7081332b63c642917b4ca15f665662f4}\label{classCRL_1_1SearchPath_a7081332b63c642917b4ca15f665662f4}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!reset@{reset}}
\index{reset@{reset}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{reset()}{reset()}}
{\footnotesize\ttfamily void C\+R\+L\+::\+Search\+Path\+::reset (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Clear all the search path. Only the first, corresponding to the working library is kept. \mbox{\Hypertarget{classCRL_1_1SearchPath_af358bdb1e940f08137f887f70eb641e3}\label{classCRL_1_1SearchPath_af358bdb1e940f08137f887f70eb641e3}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!append@{append}}
\index{append@{append}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{append()}{append()}}
{\footnotesize\ttfamily void C\+R\+L\+::\+Search\+Path\+::append (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{path,  }\item[{const std\+::string \&}]{name = {\ttfamily \char`\"{}\char`\"{}} }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}

Append a search path. The {\ttfamily name} gives the library name. 

References extract\+Lib\+Name().

\mbox{\Hypertarget{classCRL_1_1SearchPath_af39d78a63d880e90ae6f947abf1fe322}\label{classCRL_1_1SearchPath_af39d78a63d880e90ae6f947abf1fe322}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!prepend@{prepend}}
\index{prepend@{prepend}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{prepend()}{prepend()}}
{\footnotesize\ttfamily void C\+R\+L\+::\+Search\+Path\+::prepend (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{path,  }\item[{const std\+::string \&}]{name = {\ttfamily \char`\"{}\char`\"{}} }\end{DoxyParamCaption})}

Prepend a search path. The {\ttfamily name} gives the library name. \mbox{\Hypertarget{classCRL_1_1SearchPath_a6cd1524e1048f246682cd5ef40145d67}\label{classCRL_1_1SearchPath_a6cd1524e1048f246682cd5ef40145d67}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!replace@{replace}}
\index{replace@{replace}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{replace()}{replace()}}
{\footnotesize\ttfamily void C\+R\+L\+::\+Search\+Path\+::replace (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{path,  }\item[{const std\+::string \&}]{name,  }\item[{size\+\_\+t}]{index }\end{DoxyParamCaption})}

Replace the search path element at index {\ttfamily index}. \mbox{\Hypertarget{classCRL_1_1SearchPath_af8e579af7e78dddb7a014d4bbbf9a36f}\label{classCRL_1_1SearchPath_af8e579af7e78dddb7a014d4bbbf9a36f}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!locate@{locate}}
\index{locate@{locate}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{locate()}{locate()}}
{\footnotesize\ttfamily size\+\_\+t C\+R\+L\+::\+Search\+Path\+::locate (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{file,  }\item[{std\+::ios\+::openmode}]{mode = {\ttfamily std\+:\+:ios\+:\+:in},  }\item[{int}]{first = {\ttfamily 0},  }\item[{int}]{last = {\ttfamily 64} }\end{DoxyParamCaption})}


\begin{DoxyParams}{Parameters}
{\em file} & the requested file. \\
\hline
{\em mode} & the wanted opening mode. \\
\hline
{\em first} & the lower bound in the search path elements. \\
\hline
{\em last} & the upper bound in the search path elements. {\bfseries Returns\+:} the index of the search path element in which the file has been found.\\
\hline
\end{DoxyParams}
Try to locate a file named {\ttfamily file} (without leading path, but with extention) and check if it can be opened in the desired {\ttfamily mode}. The file is not left opened, but the memory of the search is kept for further operations. \mbox{\Hypertarget{classCRL_1_1SearchPath_a861b3045d7ee4671c93ba0396e3639f9}\label{classCRL_1_1SearchPath_a861b3045d7ee4671c93ba0396e3639f9}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!get\+Size@{get\+Size}}
\index{get\+Size@{get\+Size}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{get\+Size()}{getSize()}}
{\footnotesize\ttfamily size\+\_\+t C\+R\+L\+::\+Search\+Path\+::get\+Size (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

\begin{DoxyReturn}{Returns}
the number of search path elements (directories). 
\end{DoxyReturn}
\mbox{\Hypertarget{classCRL_1_1SearchPath_a1571b1b80eca0da7333a014044158b6f}\label{classCRL_1_1SearchPath_a1571b1b80eca0da7333a014044158b6f}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!get\+Selected@{get\+Selected}}
\index{get\+Selected@{get\+Selected}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{get\+Selected()}{getSelected()}}
{\footnotesize\ttfamily const std\+::string \& C\+R\+L\+::\+Search\+Path\+::get\+Selected (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

\begin{DoxyReturn}{Returns}
the search path element selected through the last locate request. 
\end{DoxyReturn}
\mbox{\Hypertarget{classCRL_1_1SearchPath_aa1023cd4721778d12756850a57f6a530}\label{classCRL_1_1SearchPath_aa1023cd4721778d12756850a57f6a530}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!get\+Index@{get\+Index}}
\index{get\+Index@{get\+Index}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{get\+Index()}{getIndex()}}
{\footnotesize\ttfamily size\+\_\+t C\+R\+L\+::\+Search\+Path\+::get\+Index (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

\begin{DoxyReturn}{Returns}
the index of search path element selected through the last locate request. 
\end{DoxyReturn}
\mbox{\Hypertarget{classCRL_1_1SearchPath_ac6a365281c272da46a02e68de2a401d1}\label{classCRL_1_1SearchPath_ac6a365281c272da46a02e68de2a401d1}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!has\+Selected@{has\+Selected}}
\index{has\+Selected@{has\+Selected}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{has\+Selected()}{hasSelected()}}
{\footnotesize\ttfamily bool C\+R\+L\+::\+Search\+Path\+::has\+Selected (\begin{DoxyParamCaption}{ }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}

\begin{DoxyReturn}{Returns}
{\bfseries true} if an element is currently selected (a locate has been performed). 
\end{DoxyReturn}
\mbox{\Hypertarget{classCRL_1_1SearchPath_a0e255b4339b5ec59bc8425bad057dc4f}\label{classCRL_1_1SearchPath_a0e255b4339b5ec59bc8425bad057dc4f}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!has\+Path@{has\+Path}}
\index{has\+Path@{has\+Path}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{has\+Path()}{hasPath()}}
{\footnotesize\ttfamily bool C\+R\+L\+::\+Search\+Path\+::has\+Path (\begin{DoxyParamCaption}\item[{const std\+::string \&}]{path }\end{DoxyParamCaption}) const}

\begin{DoxyReturn}{Returns}
{\bfseries true} if the path is present in the search path (at any position). 
\end{DoxyReturn}
\mbox{\Hypertarget{classCRL_1_1SearchPath_a2ba563c50865bc8417d65cf4a6b342d1}\label{classCRL_1_1SearchPath_a2ba563c50865bc8417d65cf4a6b342d1}} 
\index{C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}!operator\mbox{[}\mbox{]}@{operator[]}}
\index{operator\mbox{[}\mbox{]}@{operator[]}!C\+R\+L\+::\+Search\+Path@{C\+R\+L\+::\+Search\+Path}}
\subsubsection{\texorpdfstring{operator[]()}{operator[]()}}
{\footnotesize\ttfamily const \mbox{\hyperlink{classCRL_1_1SearchPath_1_1Element}{Element}} \& C\+R\+L\+::\+Search\+Path\+::operator\mbox{[}$\,$\mbox{]} (\begin{DoxyParamCaption}\item[{size\+\_\+t}]{index }\end{DoxyParamCaption}) const}

\begin{DoxyReturn}{Returns}
The search path element at position {\ttfamily index}. If {\ttfamily index} is out of bounds, an empty \mbox{\hyperlink{classCRL_1_1SearchPath_1_1Element}{Element}} is returned. 
\end{DoxyReturn}


The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
\item 
Search\+Path.\+h\item 
Search\+Path.\+dox\end{DoxyCompactItemize}
