\section{lccd\-:\-:D\-B\-Interface Class Reference}
\label{classlccd_1_1DBInterface}\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}}


Provides a simple interface to the conditions data base for lccd.  




{\ttfamily \#include $<$D\-B\-Interface.\-hh$>$}

\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
{\bf D\-B\-Interface} (const std\-::string \&folder, bool update=false)
\begin{DoxyCompactList}\small\item\em Default c'tor, uses \doxyref{lccd\-::get\-D\-B\-Init\-String()}{p.}{namespacelccd_ae03027e1443dc12963247da4d0c7477f} to determine the db initialization, i.\-e. \end{DoxyCompactList}\item 
{\bf D\-B\-Interface} (const std\-::string \&db\-Init, const std\-::string \&folder, bool update=false)
\begin{DoxyCompactList}\small\item\em Open the database specified in db\-Init. \end{DoxyCompactList}\item 
virtual {\bf $\sim$\-D\-B\-Interface} ()\label{classlccd_1_1DBInterface_a6d317dcfee5d92c2862ef2935a094f15}

\begin{DoxyCompactList}\small\item\em D'tor. \end{DoxyCompactList}\item 
I\-Cond\-D\-B\-Mgr $\ast$ {\bf cond\-D\-B\-Mgr} ()\label{classlccd_1_1DBInterface_ac764dcc61196ab8bb54ce263ef7ab9ce}

\begin{DoxyCompactList}\small\item\em The db manager object -\/ use for direct access to the conditions database. \end{DoxyCompactList}\item 
I\-Cond\-D\-B\-Data\-Access $\ast$ {\bf cond\-Data\-Access} ()
\begin{DoxyCompactList}\small\item\em The db access object -\/ use for direct access to the conditions database. \end{DoxyCompactList}\item 
I\-Cond\-D\-B\-Folder\-Mgr $\ast$ {\bf cond\-Folder\-Mgr} ()
\begin{DoxyCompactList}\small\item\em The folder manager -\/ use for direct access to the conditions database. \end{DoxyCompactList}\item 
I\-Cond\-D\-B\-Tag\-Mgr $\ast$ {\bf cond\-Tag\-Mgr} ()\label{classlccd_1_1DBInterface_abeab05f3a2de2f10396079b72790fd16}

\begin{DoxyCompactList}\small\item\em The tag manager -\/ use for direct access to the conditions database. \end{DoxyCompactList}\item 
const std\-::string \& {\bf folder\-Name} ()\label{classlccd_1_1DBInterface_a9f08ec75c7ca94314579dee801f9af05}

\begin{DoxyCompactList}\small\item\em The folder used for this D\-B access. \end{DoxyCompactList}\item 
const std\-::string \& {\bf db\-Name} ()\label{classlccd_1_1DBInterface_a2c72e4a851bfb8a9cc4aaa60e9f7ba93}

\begin{DoxyCompactList}\small\item\em The db name used for this D\-B access. \end{DoxyCompactList}\item 
void {\bf store\-Collection} ({\bf L\-C\-C\-D\-Time\-Stamp} since, {\bf L\-C\-C\-D\-Time\-Stamp} till, lcio\-::\-L\-C\-Collection $\ast$col, const std\-::string \&description)\label{classlccd_1_1DBInterface_a9528dae79f81740b686f4886d006573e}

\begin{DoxyCompactList}\small\item\em Stores the given collection in the database. \end{DoxyCompactList}\item 
lcio\-::\-L\-C\-Collection $\ast$ {\bf find\-Collection} ({\bf L\-C\-C\-D\-Time\-Stamp} time\-Stamp, {\bf L\-C\-C\-D\-Time\-Stamp} \&since, {\bf L\-C\-C\-D\-Time\-Stamp} \&till, const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Retrieves the collection for the given point in time -\/ returns N\-U\-L\-L if no data is found. \end{DoxyCompactList}\item 
lcio\-::\-L\-C\-Collection $\ast$ {\bf find\-Next\-Valid\-Collection} ({\bf L\-C\-C\-D\-Time\-Stamp} time\-Stamp, {\bf L\-C\-C\-D\-Time\-Stamp} \&since, {\bf L\-C\-C\-D\-Time\-Stamp} \&till, const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Retrieves the next valid collection from the given point in time, searching forward in time -\/ returns N\-U\-L\-L if no data is found. \end{DoxyCompactList}\item 
lcio\-::\-L\-C\-Collection $\ast$ {\bf find\-Last\-Valid\-Collection} ({\bf L\-C\-C\-D\-Time\-Stamp} time\-Stamp, {\bf L\-C\-C\-D\-Time\-Stamp} \&since, {\bf L\-C\-C\-D\-Time\-Stamp} \&till, const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Retrieves the last valid collection before the given point in time, searching backwards in time -\/ returns N\-U\-L\-L if no data is found. \end{DoxyCompactList}\item 
lcio\-::\-L\-C\-Collection $\ast$ {\bf find\-Collection} ({\bf L\-C\-C\-D\-Time\-Stamp} time\-Stamp, const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Retrieves the collection for the given point in time -\/ returns N\-U\-L\-L if it no data is found. \end{DoxyCompactList}\item 
void {\bf find\-Collections} ({\bf Col\-Vec} \&col\-Vec, const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Creates collections for all conditions data for the given tag and adds them to the colvec. \end{DoxyCompactList}\item 
void {\bf find\-Collections} ({\bf Col\-Vec} \&col\-Vec, {\bf L\-C\-C\-D\-Time\-Stamp} since, {\bf L\-C\-C\-D\-Time\-Stamp} till, const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Creates collections for all conditions data for the given time range and tag. \end{DoxyCompactList}\item 
void {\bf find\-Collections} ({\bf Col\-Vec} \&col\-Vec, {\bf L\-C\-C\-D\-Time\-Stamp} time\-Stamp)
\begin{DoxyCompactList}\small\item\em Creates collections for all conditions data for the given timestamp. \end{DoxyCompactList}\item 
void {\bf find\-All\-Collections} ({\bf Col\-Vec} \&col\-Vec)
\begin{DoxyCompactList}\small\item\em Debug Method\-: Creates collections for all conditions data in current folder. \end{DoxyCompactList}\item 
void {\bf tag\-Folder} (const std\-::string \&tag\-Name, const std\-::string \&description=\char`\"{}\char`\"{}, std\-::string using\-Tag\-Name=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Tag the current H\-E\-A\-D of the database folder as tag\-Name. \end{DoxyCompactList}\item 
bool {\bf folder\-Branch\-Contains\-Tag} (const std\-::string \&tag\-Name)
\begin{DoxyCompactList}\small\item\em Checks if the folder given in the constructor or one of its sub folders is already tagged with the tag given in tag\-Name. \end{DoxyCompactList}\item 
void {\bf create\-D\-B\-File} (const std\-::string \&tag=\char`\"{}\char`\"{})
\begin{DoxyCompactList}\small\item\em Creates an L\-C\-I\-O file with the all conditions data in the folder for the given tag. \end{DoxyCompactList}\item 
void {\bf create\-Simple\-File} ({\bf L\-C\-C\-D\-Time\-Stamp} time\-Stamp, const std\-::string \&tag, bool all\-Layers=false)
\begin{DoxyCompactList}\small\item\em Creates an L\-C\-I\-O file with one event that has a collection with the conditions data for the given time stamp and tag (use \char`\"{}\char`\"{} for the current H\-E\-A\-D). \end{DoxyCompactList}\item 
void {\bf dump2\-File} ()
\begin{DoxyCompactList}\small\item\em Debug Method\-: Creates an L\-C\-I\-O file with the all conditions data in the folder. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Protected Member Functions}
\begin{DoxyCompactItemize}
\item 
void {\bf init} ()\label{classlccd_1_1DBInterface_a722f508dfd3202c9fd74070866ceba05}

\begin{DoxyCompactList}\small\item\em Initializes the database access. \end{DoxyCompactList}\item 
lcio\-::\-L\-C\-Collection $\ast$ {\bf collection\-From\-Cond\-D\-B\-Object} (I\-Cond\-D\-B\-Object $\ast$object, const std\-::string \&tag)
\begin{DoxyCompactList}\small\item\em Creates an L\-C\-Colleciton from the data in the I\-Cond\-D\-B\-Object. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Protected Attributes}
\begin{DoxyCompactItemize}
\item 
I\-Cond\-D\-B\-Mgr $\ast$ {\bfseries \-\_\-cond\-D\-Bmgr}\label{classlccd_1_1DBInterface_a253d9f02076e4600fb022f39eef10156}

\item 
I\-Cond\-D\-B\-Data\-Access $\ast$ {\bfseries \-\_\-cond\-Data\-Access}\label{classlccd_1_1DBInterface_abac2f4d8edf355a78ee655e6d49a08a6}

\item 
I\-Cond\-D\-B\-Folder\-Mgr $\ast$ {\bfseries \-\_\-cond\-Folder\-Mgr}\label{classlccd_1_1DBInterface_a584df3619a5bde7b6676d3efc9092bcc}

\item 
I\-Cond\-D\-B\-Tag\-Mgr $\ast$ {\bfseries \-\_\-cond\-Tag\-Mgr}\label{classlccd_1_1DBInterface_af555dfa2a291387600dc8843217a632f}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
Provides a simple interface to the conditions data base for lccd. 

The functionality corresponds to a subset of the Conditions\-D\-B A\-P\-I for user's ( and lccd developer's) convenience. Most of the usual tasks can be handled through this interface.\par
 If needed access to the relevant manager objects of Conditions\-D\-B is provided.\par
 Every \doxyref{D\-B\-Interface}{p.}{classlccd_1_1DBInterface} object is attached to one particular folder in a particular database.\par
 The methods \doxyref{create\-D\-B\-File()}{p.}{classlccd_1_1DBInterface_aa8b3009b022dc72b1d42d828e5f5fed3} and \doxyref{create\-Simple\-File()}{p.}{classlccd_1_1DBInterface_abe706052e791afdad3b60ae5b8219b16} can be used to produce L\-C\-I\-O files with conditions data as input for the corresponding conditions handlers in a reconstrcution program.\par
 They also provide an easy way to browse the database horizontally (by tag) or vertically (by time stamp).

20090109, B.\-Lutz D\-E\-S\-Y\-: added functions\-: void find\-Collections(Col\-Vec \&col\-Vec, L\-C\-C\-D\-Time\-Stamp since, L\-C\-C\-D\-Time\-Stamp till, const std\-::string \&tag=\char`\"{}\char`\"{}) ; void \doxyref{dump2\-File( )}{p.}{classlccd_1_1DBInterface_a20132ad6879bf9685d3fd5caf46a676e} ; void \doxyref{find\-All\-Collections( Col\-Vec\& col\-Vec )}{p.}{classlccd_1_1DBInterface_a06519396ce89798a960e807e4fbef4d6} ;

\begin{DoxyAuthor}{Author}
F.\-Gaede, D\-E\-S\-Y 
\end{DoxyAuthor}
\begin{DoxyVersion}{Version}

\end{DoxyVersion}
\begin{DoxyParagraph}{Id\-:}
\doxyref{D\-B\-Interface.\-hh}{p.}{DBInterface_8hh_source},v 1.\-11 2009-\/01-\/09 10\-:20\-:58 gaede Exp 
\end{DoxyParagraph}


\subsection{Constructor \& Destructor Documentation}
\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!D\-B\-Interface@{D\-B\-Interface}}
\index{D\-B\-Interface@{D\-B\-Interface}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{D\-B\-Interface}]{\setlength{\rightskip}{0pt plus 5cm}lccd\-::\-D\-B\-Interface\-::\-D\-B\-Interface (
\begin{DoxyParamCaption}
\item[{const std\-::string \&}]{folder, }
\item[{bool}]{update = {\ttfamily false}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a4143cec30bcc4d7887cc06a2796a1b67}


Default c'tor, uses \doxyref{lccd\-::get\-D\-B\-Init\-String()}{p.}{namespacelccd_ae03027e1443dc12963247da4d0c7477f} to determine the db initialization, i.\-e. 

as defined by the environment variable \$\-L\-C\-C\-D\-\_\-\-D\-B\-\_\-\-I\-N\-I\-T. In update mode the folder is created if it doesn't exist -\/ provided the database user has the proper privileges.


\begin{DoxyParams}{Parameters}
{\em folder} & the folder used for this db access \\
\hline
{\em update} & open db in update mode, default\-: false \\
\hline
\end{DoxyParams}


References init().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!D\-B\-Interface@{D\-B\-Interface}}
\index{D\-B\-Interface@{D\-B\-Interface}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{D\-B\-Interface}]{\setlength{\rightskip}{0pt plus 5cm}lccd\-::\-D\-B\-Interface\-::\-D\-B\-Interface (
\begin{DoxyParamCaption}
\item[{const std\-::string \&}]{db\-Init, }
\item[{const std\-::string \&}]{folder, }
\item[{bool}]{update = {\ttfamily false}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a7dc45784358978edce829e469befa80a}


Open the database specified in db\-Init. 

In update mode the folder is created if it doesn't exist -\/ provided the database user has the proper privileges.


\begin{DoxyParams}{Parameters}
{\em folder} & the folder used for this db access \\
\hline
{\em update} & open db in update mode, default\-: false \\
\hline
\end{DoxyParams}


References init().



\subsection{Member Function Documentation}
\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!collection\-From\-Cond\-D\-B\-Object@{collection\-From\-Cond\-D\-B\-Object}}
\index{collection\-From\-Cond\-D\-B\-Object@{collection\-From\-Cond\-D\-B\-Object}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{collection\-From\-Cond\-D\-B\-Object}]{\setlength{\rightskip}{0pt plus 5cm}lcio\-::\-L\-C\-Collection $\ast$ lccd\-::\-D\-B\-Interface\-::collection\-From\-Cond\-D\-B\-Object (
\begin{DoxyParamCaption}
\item[{I\-Cond\-D\-B\-Object $\ast$}]{object, }
\item[{const std\-::string \&}]{tag}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily [protected]}}\label{classlccd_1_1DBInterface_abfaadf78a9db1a148ba384f93bdeb4d2}


Creates an L\-C\-Colleciton from the data in the I\-Cond\-D\-B\-Object. 

Adds the db parameters as described in \doxyref{find\-Collection()}{p.}{classlccd_1_1DBInterface_acea1bd25d01945e0961a28b504763281} to the collection. 

References lccd\-::\-D\-B\-F\-O\-L\-D\-E\-R, lccd\-::\-D\-B\-I\-N\-S\-E\-R\-T\-I\-O\-N\-T\-I\-M\-E, lccd\-::\-D\-B\-L\-A\-Y\-E\-R, lccd\-::\-D\-B\-N\-A\-M\-E, lccd\-::\-D\-B\-Q\-U\-E\-R\-Y\-T\-I\-M\-E, lccd\-::\-D\-B\-S\-I\-N\-C\-E, lccd\-::\-D\-B\-T\-A\-G, lccd\-::\-D\-B\-T\-I\-L\-L, lccd\-::from\-Simple\-Time(), lccd\-::\-Streamer\-Mgr\-::get\-Streamer(), and lccd\-::\-Streamer\-Mgr\-::instance().



Referenced by find\-All\-Collections(), find\-Collection(), find\-Collections(), find\-Last\-Valid\-Collection(), and find\-Next\-Valid\-Collection().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!cond\-Data\-Access@{cond\-Data\-Access}}
\index{cond\-Data\-Access@{cond\-Data\-Access}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{cond\-Data\-Access}]{\setlength{\rightskip}{0pt plus 5cm}I\-Cond\-D\-B\-Data\-Access$\ast$ lccd\-::\-D\-B\-Interface\-::cond\-Data\-Access (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily [inline]}}\label{classlccd_1_1DBInterface_ad45e12ffab52c8de8d78c7cc58889ffe}


The db access object -\/ use for direct access to the conditions database. 



Referenced by find\-All\-Collections(), find\-Collection(), find\-Collections(), find\-Last\-Valid\-Collection(), find\-Next\-Valid\-Collection(), and store\-Collection().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!cond\-Folder\-Mgr@{cond\-Folder\-Mgr}}
\index{cond\-Folder\-Mgr@{cond\-Folder\-Mgr}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{cond\-Folder\-Mgr}]{\setlength{\rightskip}{0pt plus 5cm}I\-Cond\-D\-B\-Folder\-Mgr$\ast$ lccd\-::\-D\-B\-Interface\-::cond\-Folder\-Mgr (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily [inline]}}\label{classlccd_1_1DBInterface_a3b50bfbb4a42a0008b40daaffbf9dbe3}


The folder manager -\/ use for direct access to the conditions database. 

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!create\-D\-B\-File@{create\-D\-B\-File}}
\index{create\-D\-B\-File@{create\-D\-B\-File}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{create\-D\-B\-File}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::create\-D\-B\-File (
\begin{DoxyParamCaption}
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_aa8b3009b022dc72b1d42d828e5f5fed3}


Creates an L\-C\-I\-O file with the all conditions data in the folder for the given tag. 

The collections are sorted w.\-r.\-t. their validity time intervall and attached to consecutive events. The run header holds a map of validity time intervalls to events. in the parameters D\-B\-Since and D\-B\-Till.\par
 The name of the file will be of the form \char`\"{}conddb\-\_\-\-C\-O\-L\-N\-A\-M\-E\-\_\-\-T\-A\-G\-\_\-\-Y\-Y\-Y\-Y\-M\-M\-D\-D\-\_\-\-H\-H\-M\-M\-S\-S.\-slcio\char`\"{} where the specified time is the creation time. This file can be used by the \doxyref{D\-B\-File\-Handler}{p.}{classlccd_1_1DBFileHandler}.\par
 

References lccd\-::\-D\-B\-F\-O\-L\-D\-E\-R, lccd\-::\-D\-B\-N\-A\-M\-E, lccd\-::\-D\-B\-S\-I\-N\-C\-E, lccd\-::\-D\-B\-T\-A\-G, lccd\-::\-D\-B\-T\-I\-L\-L, and find\-Collections().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!create\-Simple\-File@{create\-Simple\-File}}
\index{create\-Simple\-File@{create\-Simple\-File}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{create\-Simple\-File}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::create\-Simple\-File (
\begin{DoxyParamCaption}
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{time\-Stamp, }
\item[{const std\-::string \&}]{tag, }
\item[{bool}]{all\-Layers = {\ttfamily false}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_abe706052e791afdad3b60ae5b8219b16}


Creates an L\-C\-I\-O file with one event that has a collection with the conditions data for the given time stamp and tag (use \char`\"{}\char`\"{} for the current H\-E\-A\-D). 

\par
 If all\-Layers==true then in addition to the specified collection, all collections in the database for this timestamp are added to the event with name C\-O\-L\-N\-A\-M\-E\-\_\-layer\-\_\-\-L\-A\-Y\-E\-R\-N\-U\-M. The name of the file will be of the form \char`\"{}conddb\-\_\-\-C\-O\-L\-N\-A\-M\-E\-\_\-\-T\-A\-G\-\_\-\-T\-I\-M\-E\-S\-T\-A\-M\-P.\-slcio\char`\"{} This file can be used by the \doxyref{Simple\-File\-Handler}{p.}{classlccd_1_1SimpleFileHandler}.\par
 

References lccd\-::\-D\-B\-F\-O\-L\-D\-E\-R, lccd\-::\-D\-B\-L\-A\-Y\-E\-R, lccd\-::\-D\-B\-N\-A\-M\-E, lccd\-::\-D\-B\-T\-A\-G, lccd\-::\-D\-B\-T\-I\-M\-E\-S\-T\-A\-M\-P, find\-Collection(), and find\-Collections().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!dump2\-File@{dump2\-File}}
\index{dump2\-File@{dump2\-File}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{dump2\-File}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::dump2\-File (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a20132ad6879bf9685d3fd5caf46a676e}


Debug Method\-: Creates an L\-C\-I\-O file with the all conditions data in the folder. 

\par
 {\bfseries  This file does not respect tags. It is not meant to be used with the \doxyref{D\-B\-File\-Handler}{p.}{classlccd_1_1DBFileHandler}. }

The collections are sorted w.\-r.\-t. their validity time intervall and attached to consecutive events. The run header holds a map of validity time intervalls to events. in the parameters D\-B\-Since and D\-B\-Till.\par
 The name of the file will be of the form \char`\"{}conddb\-\_\-\-C\-O\-L\-N\-A\-M\-E\-\_\-\-Y\-Y\-Y\-Y\-M\-M\-D\-D\-\_\-\-H\-H\-M\-M\-S\-S.\-slcio\char`\"{} where the specified time is the creation time. \begin{DoxyWarning}{Warning}
This file does not respect tags. It is not meant ot be used with the \doxyref{D\-B\-File\-Handler}{p.}{classlccd_1_1DBFileHandler}. 
\end{DoxyWarning}


References lccd\-::\-D\-B\-F\-O\-L\-D\-E\-R, lccd\-::\-D\-B\-N\-A\-M\-E, lccd\-::\-D\-B\-S\-I\-N\-C\-E, lccd\-::\-D\-B\-T\-I\-L\-L, and find\-All\-Collections().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-All\-Collections@{find\-All\-Collections}}
\index{find\-All\-Collections@{find\-All\-Collections}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-All\-Collections}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::find\-All\-Collections (
\begin{DoxyParamCaption}
\item[{{\bf Col\-Vec} \&}]{col\-Vec}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a06519396ce89798a960e807e4fbef4d6}


Debug Method\-: Creates collections for all conditions data in current folder. 

\par
 {\bfseries  This does not respect tags. }

Description parameters are added to the collections as in \doxyref{find\-Collection()}{p.}{classlccd_1_1DBInterface_acea1bd25d01945e0961a28b504763281} plus D\-B\-Layer. \begin{DoxyWarning}{Warning}
This does not respect tags. 
\end{DoxyWarning}


References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().



Referenced by dump2\-File().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Collection@{find\-Collection}}
\index{find\-Collection@{find\-Collection}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Collection}]{\setlength{\rightskip}{0pt plus 5cm}lcio\-::\-L\-C\-Collection $\ast$ lccd\-::\-D\-B\-Interface\-::find\-Collection (
\begin{DoxyParamCaption}
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{time\-Stamp, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp} \&}]{since, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp} \&}]{till, }
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_acea1bd25d01945e0961a28b504763281}


Retrieves the collection for the given point in time -\/ returns N\-U\-L\-L if no data is found. 

\par
 This expects the L\-C\-I\-O collection type to be decoded in the object description\-:\par
 \char`\"{}\-L\-C\-I\-O\-\_\-\-C\-O\-L\-\_\-\-T\-Y\-P\-E\-: some description\char`\"{} -\/ \doxyref{store\-Collection()}{p.}{classlccd_1_1DBInterface_a9528dae79f81740b686f4886d006573e} does this automatically.\par
 Some parameters are added to the collection\-:\par
 
\begin{DoxyItemize}
\item D\-B\-Name\-: name of the (My\-S\-Q\-L) database 
\item D\-B\-Folder\-: data base folder  
\item D\-B\-Tag\-: the tag used for the query -\/ possibly H\-E\-A\-D at that time.  
\item D\-B\-Query\-Time\-: the time the conditions data was extracted from the data base.  
\item D\-B\-Insertion\-Time\-: the time the conditions data was inserted into the data base.  
\item D\-B\-Since\-: the start of the vaidity intervall 
\item D\-B\-Till\-: the end of the validity intervall 
\item D\-B\-Layer\-: the layer number of this data set 
\end{DoxyItemize}D\-B\-Query\-Time, D\-B\-Insertion\-Time, D\-B\-Since and D\-B\-Till are string vectors with two elements\-: the 64bit time stamp and the date in human readable format.


\begin{DoxyParams}{Parameters}
{\em time\-Stamp} & the point in time for which the conditions data is valid \\
\hline
{\em since} & return the begin of the validity interval \\
\hline
{\em end} & return the end of the validity interval \\
\hline
{\em tag} & the tag to be used for the query, if omitted H\-E\-A\-D is used \\
\hline
\end{DoxyParams}


References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().



Referenced by create\-Simple\-File(), find\-Collection(), and lccd\-::\-D\-B\-Cond\-Handler\-::update().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Collection@{find\-Collection}}
\index{find\-Collection@{find\-Collection}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Collection}]{\setlength{\rightskip}{0pt plus 5cm}lcio\-::\-L\-C\-Collection $\ast$ lccd\-::\-D\-B\-Interface\-::find\-Collection (
\begin{DoxyParamCaption}
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{time\-Stamp, }
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a486d9a032a77c2a45ffc7a1eb181cac1}


Retrieves the collection for the given point in time -\/ returns N\-U\-L\-L if it no data is found. 

\par
 Same as above, except that no information on the validity interval is returned. 

References find\-Collection().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Collections@{find\-Collections}}
\index{find\-Collections@{find\-Collections}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Collections}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::find\-Collections (
\begin{DoxyParamCaption}
\item[{{\bf Col\-Vec} \&}]{col\-Vec, }
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a3c89da23045f80974269650b26e3000b}


Creates collections for all conditions data for the given tag and adds them to the colvec. 

The collections are ordered w.\-r.\-t. to their validity time.\par
 Description parameters are added to the collections as in \doxyref{find\-Collection()}{p.}{classlccd_1_1DBInterface_acea1bd25d01945e0961a28b504763281}. 

References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().



Referenced by create\-D\-B\-File(), and create\-Simple\-File().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Collections@{find\-Collections}}
\index{find\-Collections@{find\-Collections}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Collections}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::find\-Collections (
\begin{DoxyParamCaption}
\item[{{\bf Col\-Vec} \&}]{col\-Vec, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{since, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{till, }
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a26aba740ea925e8245864d69c801ed9b}


Creates collections for all conditions data for the given time range and tag. 

The result is added to the colvec. The collections are ordered w.\-r.\-t. to their validity time.\par
 Description parameters are added to the collections as in \doxyref{find\-Collection()}{p.}{classlccd_1_1DBInterface_acea1bd25d01945e0961a28b504763281}. 

References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Collections@{find\-Collections}}
\index{find\-Collections@{find\-Collections}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Collections}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::find\-Collections (
\begin{DoxyParamCaption}
\item[{{\bf Col\-Vec} \&}]{col\-Vec, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{time\-Stamp}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_aa7c72a78ba36b2102ce1f9d1eaff2c04}


Creates collections for all conditions data for the given timestamp. 

The collections are ordered w.\-r.\-t. to the layer number in the database.\par
 Description parameters are added to the collections as in \doxyref{find\-Collection()}{p.}{classlccd_1_1DBInterface_acea1bd25d01945e0961a28b504763281} plus D\-B\-Layer. 

References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Last\-Valid\-Collection@{find\-Last\-Valid\-Collection}}
\index{find\-Last\-Valid\-Collection@{find\-Last\-Valid\-Collection}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Last\-Valid\-Collection}]{\setlength{\rightskip}{0pt plus 5cm}lcio\-::\-L\-C\-Collection $\ast$ lccd\-::\-D\-B\-Interface\-::find\-Last\-Valid\-Collection (
\begin{DoxyParamCaption}
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{time\-Stamp, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp} \&}]{since, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp} \&}]{till, }
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a6babe02706a38643f1855f25596b2c4b}


Retrieves the last valid collection before the given point in time, searching backwards in time -\/ returns N\-U\-L\-L if no data is found. 

\par
 This expects the L\-C\-I\-O collection type to be decoded in the object description\-:\par
 \char`\"{}\-L\-C\-I\-O\-\_\-\-C\-O\-L\-\_\-\-T\-Y\-P\-E\-: some description\char`\"{} -\/ \doxyref{store\-Collection()}{p.}{classlccd_1_1DBInterface_a9528dae79f81740b686f4886d006573e} does this automatically.\par
 Some parameters are added to the collection\-:\par
 
\begin{DoxyItemize}
\item D\-B\-Name\-: name of the (My\-S\-Q\-L) database 
\item D\-B\-Folder\-: data base folder  
\item D\-B\-Tag\-: the tag used for the query -\/ possibly H\-E\-A\-D at that time.  
\item D\-B\-Query\-Time\-: the time the conditions data was extracted from the data base.  
\item D\-B\-Insertion\-Time\-: the time the conditions data was inserted into the data base.  
\item D\-B\-Since\-: the start of the vaidity intervall 
\item D\-B\-Till\-: the end of the validity intervall 
\item D\-B\-Layer\-: the layer number of this data set 
\end{DoxyItemize}D\-B\-Query\-Time, D\-B\-Insertion\-Time, D\-B\-Since and D\-B\-Till are string vectors with two elements\-: the 64bit time stamp and the date in human readable format.


\begin{DoxyParams}{Parameters}
{\em time\-Stamp} & the point in time from which to search backwards for conditions data \\
\hline
{\em since} & return the begin of the validity interval of the conditions data returned \\
\hline
{\em end} & return the end of the validity interval of the conditions data returned \\
\hline
{\em tag} & the tag to be used for the query, if omitted H\-E\-A\-D is used \\
\hline
\end{DoxyParams}


References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().



Referenced by lccd\-::\-D\-B\-Cond\-Handler\-::update().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!find\-Next\-Valid\-Collection@{find\-Next\-Valid\-Collection}}
\index{find\-Next\-Valid\-Collection@{find\-Next\-Valid\-Collection}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{find\-Next\-Valid\-Collection}]{\setlength{\rightskip}{0pt plus 5cm}lcio\-::\-L\-C\-Collection $\ast$ lccd\-::\-D\-B\-Interface\-::find\-Next\-Valid\-Collection (
\begin{DoxyParamCaption}
\item[{{\bf L\-C\-C\-D\-Time\-Stamp}}]{time\-Stamp, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp} \&}]{since, }
\item[{{\bf L\-C\-C\-D\-Time\-Stamp} \&}]{till, }
\item[{const std\-::string \&}]{tag = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_ae3009b0b1437535490ad14eab40a7f0d}


Retrieves the next valid collection from the given point in time, searching forward in time -\/ returns N\-U\-L\-L if no data is found. 

\par
 This expects the L\-C\-I\-O collection type to be decoded in the object description\-:\par
 \char`\"{}\-L\-C\-I\-O\-\_\-\-C\-O\-L\-\_\-\-T\-Y\-P\-E\-: some description\char`\"{} -\/ \doxyref{store\-Collection()}{p.}{classlccd_1_1DBInterface_a9528dae79f81740b686f4886d006573e} does this automatically.\par
 Some parameters are added to the collection\-:\par
 
\begin{DoxyItemize}
\item D\-B\-Name\-: name of the (My\-S\-Q\-L) database 
\item D\-B\-Folder\-: data base folder  
\item D\-B\-Tag\-: the tag used for the query -\/ possibly H\-E\-A\-D at that time.  
\item D\-B\-Query\-Time\-: the time the conditions data was extracted from the data base.  
\item D\-B\-Insertion\-Time\-: the time the conditions data was inserted into the data base.  
\item D\-B\-Since\-: the start of the vaidity intervall 
\item D\-B\-Till\-: the end of the validity intervall 
\item D\-B\-Layer\-: the layer number of this data set 
\end{DoxyItemize}D\-B\-Query\-Time, D\-B\-Insertion\-Time, D\-B\-Since and D\-B\-Till are string vectors with two elements\-: the 64bit time stamp and the date in human readable format.


\begin{DoxyParams}{Parameters}
{\em time\-Stamp} & the point in time from which to search foward for conditions data \\
\hline
{\em since} & return the begin of the validity interval of the conditions data returned \\
\hline
{\em end} & return the end of the validity interval of the conditions data returned \\
\hline
{\em tag} & the tag to be used for the query, if omitted H\-E\-A\-D is used \\
\hline
\end{DoxyParams}


References collection\-From\-Cond\-D\-B\-Object(), and cond\-Data\-Access().



Referenced by lccd\-::\-D\-B\-Cond\-Handler\-::update().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!folder\-Branch\-Contains\-Tag@{folder\-Branch\-Contains\-Tag}}
\index{folder\-Branch\-Contains\-Tag@{folder\-Branch\-Contains\-Tag}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{folder\-Branch\-Contains\-Tag}]{\setlength{\rightskip}{0pt plus 5cm}bool lccd\-::\-D\-B\-Interface\-::folder\-Branch\-Contains\-Tag (
\begin{DoxyParamCaption}
\item[{const std\-::string \&}]{tag\-Name}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_ab4c536c3c68995a3374fbbc277a15317}


Checks if the folder given in the constructor or one of its sub folders is already tagged with the tag given in tag\-Name. 

Result is \char`\"{}true\char`\"{} if the tag was already applied to the folder or a sub folder. 

References cond\-Tag\-Mgr().



Referenced by tag\-Folder().

\index{lccd\-::\-D\-B\-Interface@{lccd\-::\-D\-B\-Interface}!tag\-Folder@{tag\-Folder}}
\index{tag\-Folder@{tag\-Folder}!lccd::DBInterface@{lccd\-::\-D\-B\-Interface}}
\subsubsection[{tag\-Folder}]{\setlength{\rightskip}{0pt plus 5cm}void lccd\-::\-D\-B\-Interface\-::tag\-Folder (
\begin{DoxyParamCaption}
\item[{const std\-::string \&}]{tag\-Name, }
\item[{const std\-::string \&}]{description = {\ttfamily \char`\"{}\char`\"{}}, }
\item[{std\-::string}]{using\-Tag\-Name = {\ttfamily \char`\"{}\char`\"{}}}
\end{DoxyParamCaption}
)}\label{classlccd_1_1DBInterface_a1182949240215199ea2c3d6de2b1baac}


Tag the current H\-E\-A\-D of the database folder as tag\-Name. 

If the argument using\-Tag\-Name is provided and refers to an existing tag this tag will be duplicated as tag\-Name.\par
 This can be used to provide a common tag with the same name for several folders of conditions data that have been tagged before with different names. 

References cond\-Tag\-Mgr(), and folder\-Branch\-Contains\-Tag().



The documentation for this class was generated from the following files\-:\begin{DoxyCompactItemize}
\item 
D\-B\-Interface.\-hh\item 
D\-B\-Interface.\-cc\end{DoxyCompactItemize}
