logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ihabu...@apache.org
Subject svn commit: r1180134 [24/43] - in /logging/site/trunk/docs/log4php: ./ apidocs/ apidocs/log4php/ apidocs/log4php/appenders/ apidocs/log4php/configurators/ apidocs/log4php/filters/ apidocs/log4php/helpers/ apidocs/log4php/layouts/ apidocs/log4php/render...
Date Fri, 07 Oct 2011 18:26:14 GMT
Modified: logging/site/trunk/docs/log4php/coverage-report/appenders_LoggerAppenderPDO.php.html
URL: http://svn.apache.org/viewvc/logging/site/trunk/docs/log4php/coverage-report/appenders_LoggerAppenderPDO.php.html?rev=1180134&r1=1180133&r2=1180134&view=diff
==============================================================================
--- logging/site/trunk/docs/log4php/coverage-report/appenders_LoggerAppenderPDO.php.html (original)
+++ logging/site/trunk/docs/log4php/coverage-report/appenders_LoggerAppenderPDO.php.html Fri Oct  7 18:26:07 2011
@@ -67,22 +67,22 @@
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="71" height="10" alt="71.43%"><img src="snow.png" width="29" height="10" alt="71.43%"></td>
+                <td class="coverBarOutline"><img src="butter.png" width="66" height="10" alt="66.67%"><img src="snow.png" width="34" height="10" alt="66.67%"></td>
               </tr>
             </table>
           </td>
-          <td class="coverPerHi">71.43%</td>
-          <td class="coverNumHi">10 / 14</td>
+          <td class="coverPerMed">66.67%</td>
+          <td class="coverNumMed">8 / 12</td>
           <td class="crap"><acronym title="Change Risk Anti-Patterns (CRAP) Index">CRAP</acronym></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="87" height="10" alt="87.67%"><img src="snow.png" width="13" height="10" alt="87.67%"></td>
+                <td class="coverBarOutline"><img src="chameleon.png" width="86" height="10" alt="86.96%"><img src="snow.png" width="14" height="10" alt="86.96%"></td>
               </tr>
             </table>
           </td>
-          <td class="coverPerHi">87.67%</td>
-          <td class="coverNumHi">64 / 73</td>
+          <td class="coverPerHi">86.96%</td>
+          <td class="coverNumHi">60 / 69</td>
         </tr>
 
         <tr>
@@ -102,72 +102,26 @@
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
-                <td class="coverBarOutline"><img src="butter.png" width="66" height="10" alt="66.67%"><img src="snow.png" width="34" height="10" alt="66.67%"></td>
+                <td class="coverBarOutline"><img src="scarlet_red.png" width="0" height="10" alt="0.00%"><img src="snow.png" width="100" height="10" alt="0.00%"></td>
               </tr>
             </table>
           </td>
-          <td class="coverPerMed">66.67%</td>
-          <td class="coverNumMed">2 / 3</td>
+          <td class="coverPerLo">0.00%</td>
+          <td class="coverNumLo">0 / 1</td>
           <td class="crap"></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="89" height="10" alt="89.74%"><img src="snow.png" width="11" height="10" alt="89.74%"></td>
-              </tr>
-            </table>
-          </td>
-          <td class="coverPerHi">89.74%</td>
-          <td class="coverNumHi">35 / 39</td>
-        </tr>
-
-        <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#126">__construct($name = '')</a></td>
-          <td class="coverBar" align="center" width="100">
-            <table border="0" cellspacing="0" cellpadding="1">
-              <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="100" height="10" alt="100.00%"><img src="snow.png" width="0" height="10" alt="100.00%"></td>
-              </tr>
-            </table>
-          </td>
-          <td class="coverPerHi">100.00%</td>
-          <td class="coverNumHi">1 / 1</td>
-          <td class="crap">1</td>
-          <td class="coverBar" align="center" width="100">
-            <table border="0" cellspacing="0" cellpadding="1">
-              <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="100" height="10" alt="100.00%"><img src="snow.png" width="0" height="10" alt="100.00%"></td>
+                <td class="coverBarOutline"><img src="chameleon.png" width="88" height="10" alt="88.57%"><img src="snow.png" width="12" height="10" alt="88.57%"></td>
               </tr>
             </table>
           </td>
-          <td class="coverPerHi">100.00%</td>
-          <td class="coverNumHi">2 / 2</td>
+          <td class="coverPerHi">88.57%</td>
+          <td class="coverNumHi">31 / 35</td>
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#130">__destruct()</a></td>
-          <td class="coverBar" align="center" width="100">
-            <table border="0" cellspacing="0" cellpadding="1">
-              <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="100" height="10" alt="100.00%"><img src="snow.png" width="0" height="10" alt="100.00%"></td>
-              </tr>
-            </table>
-          </td>
-          <td class="coverPerHi">100.00%</td>
-          <td class="coverNumHi">1 / 1</td>
-          <td class="crap">1</td>
-          <td class="coverBar" align="center" width="100">
-            <table border="0" cellspacing="0" cellpadding="1">
-              <tr>
-                <td class="coverBarOutline"><img src="chameleon.png" width="100" height="10" alt="100.00%"><img src="snow.png" width="0" height="10" alt="100.00%"></td>
-              </tr>
-            </table>
-          </td>
-          <td class="coverPerHi">100.00%</td>
-          <td class="coverNumHi">2 / 2</td>
-        </tr>
-
-        <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#141">activateOptions()</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#128">activateOptions()</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -222,7 +176,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#204">append(LoggerLoggingEvent $event)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#191">append(LoggerLoggingEvent $event)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -245,7 +199,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#226">close()</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#213">close()</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -268,7 +222,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#239">setUser($user)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#226">setUser($user)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -291,7 +245,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#247">setPassword($password)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#234">setPassword($password)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -314,7 +268,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#255">setCreateTable($flag)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#242">setCreateTable($flag)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -337,7 +291,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#272">setSql($sql)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#259">setSql($sql)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -360,7 +314,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#281">setInsertSql($sql)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#268">setInsertSql($sql)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -383,7 +337,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#292">setInsertPattern($pattern)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#279">setInsertPattern($pattern)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -406,7 +360,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#300">setTable($table)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#287">setTable($table)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -429,7 +383,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#308">setDSN($dsn)</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#295">setDSN($dsn)</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -452,7 +406,7 @@
         </tr>
 
         <tr>
-          <td class="coverFile" colspan="4">&nbsp;<a href="#319">getDatabaseHandle()</a></td>
+          <td class="coverFile" colspan="4">&nbsp;<a href="#306">getDatabaseHandle()</a></td>
           <td class="coverBar" align="center" width="100">
             <table border="0" cellspacing="0" cellpadding="1">
               <tr>
@@ -608,208 +562,195 @@
 <span class="lineNum" id="container119"><a name="119"></a><a href="#119" id="line119">     119</a> </span>                :     protected $requiresLayout = false;                                                                                          
 <span class="lineNum" id="container120"><a name="120"></a><a href="#120" id="line120">     120</a> </span>                :                                                                                                                                 
 <span class="lineNum" id="container121"><a name="121"></a><a href="#121" id="line121">     121</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container122"><a name="122"></a><a href="#122" id="line122">     122</a> </span>                :      * Constructor.                                                                                                             
-<span class="lineNum" id="container123"><a name="123"></a><a href="#123" id="line123">     123</a> </span>                :      * This apender doesn't require a layout.                                                                                   
-<span class="lineNum" id="container124"><a name="124"></a><a href="#124" id="line124">     124</a> </span>                :      * @param string $name appender name                                                                                        
-<span class="lineNum" id="container125"><a name="125"></a><a href="#125" id="line125">     125</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container126"><a name="126"></a><a href="#126" id="line126">     126</a> </span>                :     public function __construct($name = '') {                                                                                   
-<span class="lineNum" id="container127"><a name="127"></a><a href="#127" id="line127">     127</a> </span><span class="lineCov">              6 :         parent::__construct($name);                                                                                             </span>
-<span class="lineNum" id="container128"><a name="128"></a><a href="#128" id="line128">     128</a> </span><span class="lineCov">              6 :     }                                                                                                                           </span>
-<span class="lineNum" id="container129"><a name="129"></a><a href="#129" id="line129">     129</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container130"><a name="130"></a><a href="#130" id="line130">     130</a> </span>                :     public function __destruct() {                                                                                              
-<span class="lineNum" id="container131"><a name="131"></a><a href="#131" id="line131">     131</a> </span><span class="lineCov">              6 :        $this-&gt;close();                                                                                                          </span>
-<span class="lineNum" id="container132"><a name="132"></a><a href="#132" id="line132">     132</a> </span><span class="lineCov">              6 :        }                                                                                                                        </span>
-<span class="lineNum" id="container133"><a name="133"></a><a href="#133" id="line133">     133</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container134"><a name="134"></a><a href="#134" id="line134">     134</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container135"><a name="135"></a><a href="#135" id="line135">     135</a> </span>                :      * Setup db connection.                                                                                                     
-<span class="lineNum" id="container136"><a name="136"></a><a href="#136" id="line136">     136</a> </span>                :      * Based on defined options, this method connects to db defined in {@link $dsn}                                             
-<span class="lineNum" id="container137"><a name="137"></a><a href="#137" id="line137">     137</a> </span>                :      * and creates a {@link $table} table if {@link $createTable} is true.                                                      
-<span class="lineNum" id="container138"><a name="138"></a><a href="#138" id="line138">     138</a> </span>                :      * @return boolean true if all ok.                                                                                          
-<span class="lineNum" id="container139"><a name="139"></a><a href="#139" id="line139">     139</a> </span>                :      * @throws a PDOException if the attempt to connect to the requested database fails.                                        
-<span class="lineNum" id="container140"><a name="140"></a><a href="#140" id="line140">     140</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container141"><a name="141"></a><a href="#141" id="line141">     141</a> </span>                :     public function activateOptions() {                                                                                         
-<span class="lineNum" id="container142"><a name="142"></a><a href="#142" id="line142">     142</a> </span>                :         try {                                                                                                                   
-<span class="lineNum" id="container143"><a name="143"></a><a href="#143" id="line143">     143</a> </span><span class="lineCov">              5 :             if($this-&gt;user === null) {                                                                                          </span>
-<span class="lineNum" id="container144"><a name="144"></a><a href="#144" id="line144">     144</a> </span><span class="lineNoCov">              0 :                 $this-&gt;db = new PDO($this-&gt;dsn);                                                                                </span>
-<span class="lineNum" id="container145"><a name="145"></a><a href="#145" id="line145">     145</a> </span><span class="lineCov">              5 :             } else if($this-&gt;password === null) {                                                                               </span>
-<span class="lineNum" id="container146"><a name="146"></a><a href="#146" id="line146">     146</a> </span><span class="lineNoCov">              0 :                 $this-&gt;db = new PDO($this-&gt;dsn, $this-&gt;user);                                                                   </span>
-<span class="lineNum" id="container147"><a name="147"></a><a href="#147" id="line147">     147</a> </span><span class="lineNoCov">              0 :             } else {                                                                                                            </span>
-<span class="lineNum" id="container148"><a name="148"></a><a href="#148" id="line148">     148</a> </span><span class="lineCov">              5 :                 $this-&gt;db = new PDO($this-&gt;dsn,$this-&gt;user,$this-&gt;password);                                                    </span>
-<span class="lineNum" id="container149"><a name="149"></a><a href="#149" id="line149">     149</a> </span>                :             }                                                                                                                   
-<span class="lineNum" id="container150"><a name="150"></a><a href="#150" id="line150">     150</a> </span><span class="lineCov">              4 :             $this-&gt;db-&gt;setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);                                                 </span>
-<span class="lineNum" id="container151"><a name="151"></a><a href="#151" id="line151">     151</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container152"><a name="152"></a><a href="#152" id="line152">     152</a> </span>                :             // test if log table exists                                                                                         
-<span class="lineNum" id="container153"><a name="153"></a><a href="#153" id="line153">     153</a> </span>                :             try {                                                                                                               
-<span class="lineNum" id="container154"><a name="154"></a><a href="#154" id="line154">     154</a> </span><span class="lineCov">              4 :                 $result = $this-&gt;db-&gt;query('SELECT * FROM ' . $this-&gt;table . ' WHERE 1 = 0');                                   </span>
-<span class="lineNum" id="container155"><a name="155"></a><a href="#155" id="line155">     155</a> </span><span class="lineNoCov">              0 :                 $result-&gt;closeCursor();                                                                                         </span>
-<span class="lineNum" id="container156"><a name="156"></a><a href="#156" id="line156">     156</a> </span><span class="lineCov">              4 :             } catch (PDOException $e) {                                                                                         </span>
-<span class="lineNum" id="container157"><a name="157"></a><a href="#157" id="line157">     157</a> </span>                :                 // It could be something else but a &quot;no such table&quot; is the most likely                                          
-<span class="lineNum" id="container158"><a name="158"></a><a href="#158" id="line158">     158</a> </span><span class="lineCov">              4 :                 $result = false;                                                                                                </span>
-<span class="lineNum" id="container159"><a name="159"></a><a href="#159" id="line159">     159</a> </span>                :             }                                                                                                                   
-<span class="lineNum" id="container160"><a name="160"></a><a href="#160" id="line160">     160</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container161"><a name="161"></a><a href="#161" id="line161">     161</a> </span>                :             // create table if necessary                                                                                        
-<span class="lineNum" id="container162"><a name="162"></a><a href="#162" id="line162">     162</a> </span><span class="lineCov">              4 :             if ($result == false and $this-&gt;createTable) {                                                                      </span>
-<span class="lineNum" id="container163"><a name="163"></a><a href="#163" id="line163">     163</a> </span>                :                 // The syntax should at least be compatible with MySQL, PostgreSQL, SQLite and Oracle.                          
-<span class="lineNum" id="container164"><a name="164"></a><a href="#164" id="line164">     164</a> </span><span class="lineCov">              3 :                 $query = &quot;CREATE TABLE {$this-&gt;table} (&quot;.                                                                       </span>
-<span class="lineNum" id="container165"><a name="165"></a><a href="#165" id="line165">     165</a> </span><span class="lineCov">              3 :                             &quot;timestamp varchar(32),&quot; .                                                                          </span>
-<span class="lineNum" id="container166"><a name="166"></a><a href="#166" id="line166">     166</a> </span><span class="lineCov">              3 :                             &quot;logger varchar(64),&quot; .                                                                             </span>
-<span class="lineNum" id="container167"><a name="167"></a><a href="#167" id="line167">     167</a> </span><span class="lineCov">              3 :                             &quot;level varchar(32),&quot; .                                                                              </span>
-<span class="lineNum" id="container168"><a name="168"></a><a href="#168" id="line168">     168</a> </span><span class="lineCov">              3 :                             &quot;message varchar(9999),&quot; .                                                                          </span>
-<span class="lineNum" id="container169"><a name="169"></a><a href="#169" id="line169">     169</a> </span><span class="lineCov">              3 :                             &quot;thread varchar(32),&quot; .                                                                             </span>
-<span class="lineNum" id="container170"><a name="170"></a><a href="#170" id="line170">     170</a> </span><span class="lineCov">              3 :                             &quot;file varchar(255),&quot; .                                                                              </span>
-<span class="lineNum" id="container171"><a name="171"></a><a href="#171" id="line171">     171</a> </span><span class="lineCov">              3 :                             &quot;line varchar(6))&quot;;                                                                                 </span>
-<span class="lineNum" id="container172"><a name="172"></a><a href="#172" id="line172">     172</a> </span><span class="lineCov">              3 :                 $result = $this-&gt;db-&gt;query($query);                                                                             </span>
-<span class="lineNum" id="container173"><a name="173"></a><a href="#173" id="line173">     173</a> </span><span class="lineCov">              3 :             }                                                                                                                   </span>
-<span class="lineNum" id="container174"><a name="174"></a><a href="#174" id="line174">     174</a> </span><span class="lineCov">              5 :         } catch (PDOException $e) {                                                                                             </span>
-<span class="lineNum" id="container175"><a name="175"></a><a href="#175" id="line175">     175</a> </span><span class="lineCov">              1 :             $this-&gt;canAppend = false;                                                                                           </span>
-<span class="lineNum" id="container176"><a name="176"></a><a href="#176" id="line176">     176</a> </span><span class="lineCov">              1 :             throw new LoggerException($e);                                                                                      </span>
-<span class="lineNum" id="container177"><a name="177"></a><a href="#177" id="line177">     177</a> </span>                :         }                                                                                                                       
-<span class="lineNum" id="container178"><a name="178"></a><a href="#178" id="line178">     178</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container179"><a name="179"></a><a href="#179" id="line179">     179</a> </span><span class="lineCov">              4 :         $this-&gt;layout = new LoggerLayoutPattern();                                                                              </span>
-<span class="lineNum" id="container180"><a name="180"></a><a href="#180" id="line180">     180</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container181"><a name="181"></a><a href="#181" id="line181">     181</a> </span>                :         //                                                                                                                      
-<span class="lineNum" id="container182"><a name="182"></a><a href="#182" id="line182">     182</a> </span>                :         // Keep compatibility to legacy option $sql which already included the format patterns!                                 
-<span class="lineNum" id="container183"><a name="183"></a><a href="#183" id="line183">     183</a> </span>                :         //                                                                                                                      
-<span class="lineNum" id="container184"><a name="184"></a><a href="#184" id="line184">     184</a> </span><span class="lineCov">              4 :         if (empty($this-&gt;sql)) {                                                                                                </span>
-<span class="lineNum" id="container185"><a name="185"></a><a href="#185" id="line185">     185</a> </span>                :             // new style with prepared Statment and $insertSql and $insertPattern                                               
-<span class="lineNum" id="container186"><a name="186"></a><a href="#186" id="line186">     186</a> </span>                :             // Maybe the tablename has to be substituted.                                                                       
-<span class="lineNum" id="container187"><a name="187"></a><a href="#187" id="line187">     187</a> </span><span class="lineCov">              3 :             $this-&gt;insertSql = preg_replace('/__TABLE__/', $this-&gt;table, $this-&gt;insertSql);                                     </span>
-<span class="lineNum" id="container188"><a name="188"></a><a href="#188" id="line188">     188</a> </span><span class="lineCov">              3 :             $this-&gt;preparedInsert = $this-&gt;db-&gt;prepare($this-&gt;insertSql);                                                       </span>
-<span class="lineNum" id="container189"><a name="189"></a><a href="#189" id="line189">     189</a> </span><span class="lineCov">              3 :             $this-&gt;layout-&gt;setConversionPattern($this-&gt;insertPattern);                                                          </span>
-<span class="lineNum" id="container190"><a name="190"></a><a href="#190" id="line190">     190</a> </span><span class="lineCov">              3 :         } else {                                                                                                                </span>
-<span class="lineNum" id="container191"><a name="191"></a><a href="#191" id="line191">     191</a> </span>                :             // Old style with format strings in the $sql query should be used.                                                  
-<span class="lineNum" id="container192"><a name="192"></a><a href="#192" id="line192">     192</a> </span><span class="lineCov">              1 :         $this-&gt;layout-&gt;setConversionPattern($this-&gt;sql);                                                                        </span>
-<span class="lineNum" id="container193"><a name="193"></a><a href="#193" id="line193">     193</a> </span>                :         }                                                                                                                       
+<span class="lineNum" id="container122"><a name="122"></a><a href="#122" id="line122">     122</a> </span>                :      * Setup db connection.                                                                                                     
+<span class="lineNum" id="container123"><a name="123"></a><a href="#123" id="line123">     123</a> </span>                :      * Based on defined options, this method connects to db defined in {@link $dsn}                                             
+<span class="lineNum" id="container124"><a name="124"></a><a href="#124" id="line124">     124</a> </span>                :      * and creates a {@link $table} table if {@link $createTable} is true.                                                      
+<span class="lineNum" id="container125"><a name="125"></a><a href="#125" id="line125">     125</a> </span>                :      * @return boolean true if all ok.                                                                                          
+<span class="lineNum" id="container126"><a name="126"></a><a href="#126" id="line126">     126</a> </span>                :      * @throws a PDOException if the attempt to connect to the requested database fails.                                        
+<span class="lineNum" id="container127"><a name="127"></a><a href="#127" id="line127">     127</a> </span>                :      */                                                                                                                         
+<span class="lineNum" id="container128"><a name="128"></a><a href="#128" id="line128">     128</a> </span>                :     public function activateOptions() {                                                                                         
+<span class="lineNum" id="container129"><a name="129"></a><a href="#129" id="line129">     129</a> </span>                :         try {                                                                                                                   
+<span class="lineNum" id="container130"><a name="130"></a><a href="#130" id="line130">     130</a> </span><span class="lineCov">              5 :             if($this-&gt;user === null) {                                                                                          </span>
+<span class="lineNum" id="container131"><a name="131"></a><a href="#131" id="line131">     131</a> </span><span class="lineNoCov">              0 :                 $this-&gt;db = new PDO($this-&gt;dsn);                                                                                </span>
+<span class="lineNum" id="container132"><a name="132"></a><a href="#132" id="line132">     132</a> </span><span class="lineCov">              5 :             } else if($this-&gt;password === null) {                                                                               </span>
+<span class="lineNum" id="container133"><a name="133"></a><a href="#133" id="line133">     133</a> </span><span class="lineNoCov">              0 :                 $this-&gt;db = new PDO($this-&gt;dsn, $this-&gt;user);                                                                   </span>
+<span class="lineNum" id="container134"><a name="134"></a><a href="#134" id="line134">     134</a> </span><span class="lineNoCov">              0 :             } else {                                                                                                            </span>
+<span class="lineNum" id="container135"><a name="135"></a><a href="#135" id="line135">     135</a> </span><span class="lineCov">              5 :                 $this-&gt;db = new PDO($this-&gt;dsn,$this-&gt;user,$this-&gt;password);                                                    </span>
+<span class="lineNum" id="container136"><a name="136"></a><a href="#136" id="line136">     136</a> </span>                :             }                                                                                                                   
+<span class="lineNum" id="container137"><a name="137"></a><a href="#137" id="line137">     137</a> </span><span class="lineCov">              4 :             $this-&gt;db-&gt;setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);                                                 </span>
+<span class="lineNum" id="container138"><a name="138"></a><a href="#138" id="line138">     138</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container139"><a name="139"></a><a href="#139" id="line139">     139</a> </span>                :             // test if log table exists                                                                                         
+<span class="lineNum" id="container140"><a name="140"></a><a href="#140" id="line140">     140</a> </span>                :             try {                                                                                                               
+<span class="lineNum" id="container141"><a name="141"></a><a href="#141" id="line141">     141</a> </span><span class="lineCov">              4 :                 $result = $this-&gt;db-&gt;query('SELECT * FROM ' . $this-&gt;table . ' WHERE 1 = 0');                                   </span>
+<span class="lineNum" id="container142"><a name="142"></a><a href="#142" id="line142">     142</a> </span><span class="lineNoCov">              0 :                 $result-&gt;closeCursor();                                                                                         </span>
+<span class="lineNum" id="container143"><a name="143"></a><a href="#143" id="line143">     143</a> </span><span class="lineCov">              4 :             } catch (PDOException $e) {                                                                                         </span>
+<span class="lineNum" id="container144"><a name="144"></a><a href="#144" id="line144">     144</a> </span>                :                 // It could be something else but a &quot;no such table&quot; is the most likely                                          
+<span class="lineNum" id="container145"><a name="145"></a><a href="#145" id="line145">     145</a> </span><span class="lineCov">              4 :                 $result = false;                                                                                                </span>
+<span class="lineNum" id="container146"><a name="146"></a><a href="#146" id="line146">     146</a> </span>                :             }                                                                                                                   
+<span class="lineNum" id="container147"><a name="147"></a><a href="#147" id="line147">     147</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container148"><a name="148"></a><a href="#148" id="line148">     148</a> </span>                :             // create table if necessary                                                                                        
+<span class="lineNum" id="container149"><a name="149"></a><a href="#149" id="line149">     149</a> </span><span class="lineCov">              4 :             if ($result == false and $this-&gt;createTable) {                                                                      </span>
+<span class="lineNum" id="container150"><a name="150"></a><a href="#150" id="line150">     150</a> </span>                :                 // The syntax should at least be compatible with MySQL, PostgreSQL, SQLite and Oracle.                          
+<span class="lineNum" id="container151"><a name="151"></a><a href="#151" id="line151">     151</a> </span><span class="lineCov">              3 :                 $query = &quot;CREATE TABLE {$this-&gt;table} (&quot;.                                                                       </span>
+<span class="lineNum" id="container152"><a name="152"></a><a href="#152" id="line152">     152</a> </span><span class="lineCov">              3 :                             &quot;timestamp varchar(32),&quot; .                                                                          </span>
+<span class="lineNum" id="container153"><a name="153"></a><a href="#153" id="line153">     153</a> </span><span class="lineCov">              3 :                             &quot;logger varchar(64),&quot; .                                                                             </span>
+<span class="lineNum" id="container154"><a name="154"></a><a href="#154" id="line154">     154</a> </span><span class="lineCov">              3 :                             &quot;level varchar(32),&quot; .                                                                              </span>
+<span class="lineNum" id="container155"><a name="155"></a><a href="#155" id="line155">     155</a> </span><span class="lineCov">              3 :                             &quot;message varchar(9999),&quot; .                                                                          </span>
+<span class="lineNum" id="container156"><a name="156"></a><a href="#156" id="line156">     156</a> </span><span class="lineCov">              3 :                             &quot;thread varchar(32),&quot; .                                                                             </span>
+<span class="lineNum" id="container157"><a name="157"></a><a href="#157" id="line157">     157</a> </span><span class="lineCov">              3 :                             &quot;file varchar(255),&quot; .                                                                              </span>
+<span class="lineNum" id="container158"><a name="158"></a><a href="#158" id="line158">     158</a> </span><span class="lineCov">              3 :                             &quot;line varchar(6))&quot;;                                                                                 </span>
+<span class="lineNum" id="container159"><a name="159"></a><a href="#159" id="line159">     159</a> </span><span class="lineCov">              3 :                 $result = $this-&gt;db-&gt;query($query);                                                                             </span>
+<span class="lineNum" id="container160"><a name="160"></a><a href="#160" id="line160">     160</a> </span><span class="lineCov">              3 :             }                                                                                                                   </span>
+<span class="lineNum" id="container161"><a name="161"></a><a href="#161" id="line161">     161</a> </span><span class="lineCov">              5 :         } catch (PDOException $e) {                                                                                             </span>
+<span class="lineNum" id="container162"><a name="162"></a><a href="#162" id="line162">     162</a> </span><span class="lineCov">              1 :             $this-&gt;canAppend = false;                                                                                           </span>
+<span class="lineNum" id="container163"><a name="163"></a><a href="#163" id="line163">     163</a> </span><span class="lineCov">              1 :             throw new LoggerException($e);                                                                                      </span>
+<span class="lineNum" id="container164"><a name="164"></a><a href="#164" id="line164">     164</a> </span>                :         }                                                                                                                       
+<span class="lineNum" id="container165"><a name="165"></a><a href="#165" id="line165">     165</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container166"><a name="166"></a><a href="#166" id="line166">     166</a> </span><span class="lineCov">              4 :         $this-&gt;layout = new LoggerLayoutPattern();                                                                              </span>
+<span class="lineNum" id="container167"><a name="167"></a><a href="#167" id="line167">     167</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container168"><a name="168"></a><a href="#168" id="line168">     168</a> </span>                :         //                                                                                                                      
+<span class="lineNum" id="container169"><a name="169"></a><a href="#169" id="line169">     169</a> </span>                :         // Keep compatibility to legacy option $sql which already included the format patterns!                                 
+<span class="lineNum" id="container170"><a name="170"></a><a href="#170" id="line170">     170</a> </span>                :         //                                                                                                                      
+<span class="lineNum" id="container171"><a name="171"></a><a href="#171" id="line171">     171</a> </span><span class="lineCov">              4 :         if (empty($this-&gt;sql)) {                                                                                                </span>
+<span class="lineNum" id="container172"><a name="172"></a><a href="#172" id="line172">     172</a> </span>                :             // new style with prepared Statment and $insertSql and $insertPattern                                               
+<span class="lineNum" id="container173"><a name="173"></a><a href="#173" id="line173">     173</a> </span>                :             // Maybe the tablename has to be substituted.                                                                       
+<span class="lineNum" id="container174"><a name="174"></a><a href="#174" id="line174">     174</a> </span><span class="lineCov">              3 :             $this-&gt;insertSql = preg_replace('/__TABLE__/', $this-&gt;table, $this-&gt;insertSql);                                     </span>
+<span class="lineNum" id="container175"><a name="175"></a><a href="#175" id="line175">     175</a> </span><span class="lineCov">              3 :             $this-&gt;preparedInsert = $this-&gt;db-&gt;prepare($this-&gt;insertSql);                                                       </span>
+<span class="lineNum" id="container176"><a name="176"></a><a href="#176" id="line176">     176</a> </span><span class="lineCov">              3 :             $this-&gt;layout-&gt;setConversionPattern($this-&gt;insertPattern);                                                          </span>
+<span class="lineNum" id="container177"><a name="177"></a><a href="#177" id="line177">     177</a> </span><span class="lineCov">              3 :         } else {                                                                                                                </span>
+<span class="lineNum" id="container178"><a name="178"></a><a href="#178" id="line178">     178</a> </span>                :             // Old style with format strings in the $sql query should be used.                                                  
+<span class="lineNum" id="container179"><a name="179"></a><a href="#179" id="line179">     179</a> </span><span class="lineCov">              1 :         $this-&gt;layout-&gt;setConversionPattern($this-&gt;sql);                                                                        </span>
+<span class="lineNum" id="container180"><a name="180"></a><a href="#180" id="line180">     180</a> </span>                :         }                                                                                                                       
+<span class="lineNum" id="container181"><a name="181"></a><a href="#181" id="line181">     181</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container182"><a name="182"></a><a href="#182" id="line182">     182</a> </span><span class="lineCov">              4 :         $this-&gt;canAppend = true;                                                                                                </span>
+<span class="lineNum" id="container183"><a name="183"></a><a href="#183" id="line183">     183</a> </span><span class="lineCov">              4 :         return true;                                                                                                            </span>
+<span class="lineNum" id="container184"><a name="184"></a><a href="#184" id="line184">     184</a> </span><span class="lineDeadCode">                :     }                                                                                                                           </span>
+<span class="lineNum" id="container185"><a name="185"></a><a href="#185" id="line185">     185</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container186"><a name="186"></a><a href="#186" id="line186">     186</a> </span>                :     /**                                                                                                                         
+<span class="lineNum" id="container187"><a name="187"></a><a href="#187" id="line187">     187</a> </span>                :      * Appends a new event to the database.                                                                                     
+<span class="lineNum" id="container188"><a name="188"></a><a href="#188" id="line188">     188</a> </span>                :      *                                                                                                                          
+<span class="lineNum" id="container189"><a name="189"></a><a href="#189" id="line189">     189</a> </span>                :      * @throws LoggerException If the pattern conversion or the INSERT statement fails.                                         
+<span class="lineNum" id="container190"><a name="190"></a><a href="#190" id="line190">     190</a> </span>                :      */                                                                                                                         
+<span class="lineNum" id="container191"><a name="191"></a><a href="#191" id="line191">     191</a> </span>                :     public function append(LoggerLoggingEvent $event) {                                                                         
+<span class="lineNum" id="container192"><a name="192"></a><a href="#192" id="line192">     192</a> </span>                :         // TODO: Can't activateOptions() simply throw an Exception if it encounters problems?                                   
+<span class="lineNum" id="container193"><a name="193"></a><a href="#193" id="line193">     193</a> </span><span class="lineCov">              4 :         if ( ! $this-&gt;canAppend) return;                                                                                        </span>
 <span class="lineNum" id="container194"><a name="194"></a><a href="#194" id="line194">     194</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container195"><a name="195"></a><a href="#195" id="line195">     195</a> </span><span class="lineCov">              4 :         $this-&gt;canAppend = true;                                                                                                </span>
-<span class="lineNum" id="container196"><a name="196"></a><a href="#196" id="line196">     196</a> </span><span class="lineCov">              4 :         return true;                                                                                                            </span>
-<span class="lineNum" id="container197"><a name="197"></a><a href="#197" id="line197">     197</a> </span><span class="lineDeadCode">                :     }                                                                                                                           </span>
-<span class="lineNum" id="container198"><a name="198"></a><a href="#198" id="line198">     198</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container199"><a name="199"></a><a href="#199" id="line199">     199</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container200"><a name="200"></a><a href="#200" id="line200">     200</a> </span>                :      * Appends a new event to the database.                                                                                     
-<span class="lineNum" id="container201"><a name="201"></a><a href="#201" id="line201">     201</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container202"><a name="202"></a><a href="#202" id="line202">     202</a> </span>                :      * @throws LoggerException If the pattern conversion or the INSERT statement fails.                                         
-<span class="lineNum" id="container203"><a name="203"></a><a href="#203" id="line203">     203</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container204"><a name="204"></a><a href="#204" id="line204">     204</a> </span>                :     public function append(LoggerLoggingEvent $event) {                                                                         
-<span class="lineNum" id="container205"><a name="205"></a><a href="#205" id="line205">     205</a> </span>                :         // TODO: Can't activateOptions() simply throw an Exception if it encounters problems?                                   
-<span class="lineNum" id="container206"><a name="206"></a><a href="#206" id="line206">     206</a> </span><span class="lineCov">              4 :         if ( ! $this-&gt;canAppend) return;                                                                                        </span>
-<span class="lineNum" id="container207"><a name="207"></a><a href="#207" id="line207">     207</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container208"><a name="208"></a><a href="#208" id="line208">     208</a> </span>                :             try {                                                                                                               
-<span class="lineNum" id="container209"><a name="209"></a><a href="#209" id="line209">     209</a> </span><span class="lineCov">              4 :             if (empty($this-&gt;sql)) {                                                                                            </span>
-<span class="lineNum" id="container210"><a name="210"></a><a href="#210" id="line210">     210</a> </span>                :                 // new style with prepared statement                                                                            
-<span class="lineNum" id="container211"><a name="211"></a><a href="#211" id="line211">     211</a> </span><span class="lineCov">              3 :                 $params = $this-&gt;layout-&gt;formatToArray($event);                                                                 </span>
-<span class="lineNum" id="container212"><a name="212"></a><a href="#212" id="line212">     212</a> </span><span class="lineCov">              3 :                 $this-&gt;preparedInsert-&gt;execute($params);                                                                        </span>
-<span class="lineNum" id="container213"><a name="213"></a><a href="#213" id="line213">     213</a> </span><span class="lineCov">              3 :             } else {                                                                                                            </span>
-<span class="lineNum" id="container214"><a name="214"></a><a href="#214" id="line214">     214</a> </span>                :                 // old style                                                                                                    
-<span class="lineNum" id="container215"><a name="215"></a><a href="#215" id="line215">     215</a> </span><span class="lineCov">              1 :                 $query = $this-&gt;layout-&gt;format($event);                                                                         </span>
-<span class="lineNum" id="container216"><a name="216"></a><a href="#216" id="line216">     216</a> </span><span class="lineCov">              1 :                 $this-&gt;db-&gt;exec($query);                                                                                        </span>
-<span class="lineNum" id="container217"><a name="217"></a><a href="#217" id="line217">     217</a> </span>                :             }                                                                                                                   
-<span class="lineNum" id="container218"><a name="218"></a><a href="#218" id="line218">     218</a> </span><span class="lineCov">              4 :             } catch (Exception $e) {                                                                                            </span>
-<span class="lineNum" id="container219"><a name="219"></a><a href="#219" id="line219">     219</a> </span><span class="lineNoCov">              0 :                 throw new LoggerException($e);                                                                                  </span>
-<span class="lineNum" id="container220"><a name="220"></a><a href="#220" id="line220">     220</a> </span>                :             }                                                                                                                   
-<span class="lineNum" id="container221"><a name="221"></a><a href="#221" id="line221">     221</a> </span><span class="lineCov">              4 :         }                                                                                                                       </span>
-<span class="lineNum" id="container222"><a name="222"></a><a href="#222" id="line222">     222</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container223"><a name="223"></a><a href="#223" id="line223">     223</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container224"><a name="224"></a><a href="#224" id="line224">     224</a> </span>                :      * Closes the connection to the logging database                                                                            
+<span class="lineNum" id="container195"><a name="195"></a><a href="#195" id="line195">     195</a> </span>                :             try {                                                                                                               
+<span class="lineNum" id="container196"><a name="196"></a><a href="#196" id="line196">     196</a> </span><span class="lineCov">              4 :             if (empty($this-&gt;sql)) {                                                                                            </span>
+<span class="lineNum" id="container197"><a name="197"></a><a href="#197" id="line197">     197</a> </span>                :                 // new style with prepared statement                                                                            
+<span class="lineNum" id="container198"><a name="198"></a><a href="#198" id="line198">     198</a> </span><span class="lineCov">              3 :                 $params = $this-&gt;layout-&gt;formatToArray($event);                                                                 </span>
+<span class="lineNum" id="container199"><a name="199"></a><a href="#199" id="line199">     199</a> </span><span class="lineCov">              3 :                 $this-&gt;preparedInsert-&gt;execute($params);                                                                        </span>
+<span class="lineNum" id="container200"><a name="200"></a><a href="#200" id="line200">     200</a> </span><span class="lineCov">              3 :             } else {                                                                                                            </span>
+<span class="lineNum" id="container201"><a name="201"></a><a href="#201" id="line201">     201</a> </span>                :                 // old style                                                                                                    
+<span class="lineNum" id="container202"><a name="202"></a><a href="#202" id="line202">     202</a> </span><span class="lineCov">              1 :                 $query = $this-&gt;layout-&gt;format($event);                                                                         </span>
+<span class="lineNum" id="container203"><a name="203"></a><a href="#203" id="line203">     203</a> </span><span class="lineCov">              1 :                 $this-&gt;db-&gt;exec($query);                                                                                        </span>
+<span class="lineNum" id="container204"><a name="204"></a><a href="#204" id="line204">     204</a> </span>                :             }                                                                                                                   
+<span class="lineNum" id="container205"><a name="205"></a><a href="#205" id="line205">     205</a> </span><span class="lineCov">              4 :             } catch (Exception $e) {                                                                                            </span>
+<span class="lineNum" id="container206"><a name="206"></a><a href="#206" id="line206">     206</a> </span><span class="lineNoCov">              0 :                 throw new LoggerException($e);                                                                                  </span>
+<span class="lineNum" id="container207"><a name="207"></a><a href="#207" id="line207">     207</a> </span>                :             }                                                                                                                   
+<span class="lineNum" id="container208"><a name="208"></a><a href="#208" id="line208">     208</a> </span><span class="lineCov">              4 :         }                                                                                                                       </span>
+<span class="lineNum" id="container209"><a name="209"></a><a href="#209" id="line209">     209</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container210"><a name="210"></a><a href="#210" id="line210">     210</a> </span>                :     /**                                                                                                                         
+<span class="lineNum" id="container211"><a name="211"></a><a href="#211" id="line211">     211</a> </span>                :      * Closes the connection to the logging database                                                                            
+<span class="lineNum" id="container212"><a name="212"></a><a href="#212" id="line212">     212</a> </span>                :      */                                                                                                                         
+<span class="lineNum" id="container213"><a name="213"></a><a href="#213" id="line213">     213</a> </span>                :     public function close() {                                                                                                   
+<span class="lineNum" id="container214"><a name="214"></a><a href="#214" id="line214">     214</a> </span><span class="lineCov">              6 :         if($this-&gt;closed != true) {                                                                                             </span>
+<span class="lineNum" id="container215"><a name="215"></a><a href="#215" id="line215">     215</a> </span><span class="lineCov">              6 :             if ($this-&gt;db !== null) {                                                                                           </span>
+<span class="lineNum" id="container216"><a name="216"></a><a href="#216" id="line216">     216</a> </span><span class="lineCov">              4 :                 $this-&gt;db = null;                                                                                               </span>
+<span class="lineNum" id="container217"><a name="217"></a><a href="#217" id="line217">     217</a> </span><span class="lineCov">              4 :             }                                                                                                                   </span>
+<span class="lineNum" id="container218"><a name="218"></a><a href="#218" id="line218">     218</a> </span><span class="lineCov">              6 :             $this-&gt;closed = true;                                                                                               </span>
+<span class="lineNum" id="container219"><a name="219"></a><a href="#219" id="line219">     219</a> </span><span class="lineCov">              6 :         }                                                                                                                       </span>
+<span class="lineNum" id="container220"><a name="220"></a><a href="#220" id="line220">     220</a> </span><span class="lineCov">              6 :     }                                                                                                                           </span>
+<span class="lineNum" id="container221"><a name="221"></a><a href="#221" id="line221">     221</a> </span>                :                                                                                                                                 
+<span class="lineNum" id="container222"><a name="222"></a><a href="#222" id="line222">     222</a> </span>                :     /**                                                                                                                         
+<span class="lineNum" id="container223"><a name="223"></a><a href="#223" id="line223">     223</a> </span>                :      * Sets the username for this connection.                                                                                   
+<span class="lineNum" id="container224"><a name="224"></a><a href="#224" id="line224">     224</a> </span>                :      * Defaults to ''                                                                                                           
 <span class="lineNum" id="container225"><a name="225"></a><a href="#225" id="line225">     225</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container226"><a name="226"></a><a href="#226" id="line226">     226</a> </span>                :     public function close() {                                                                                                   
-<span class="lineNum" id="container227"><a name="227"></a><a href="#227" id="line227">     227</a> </span><span class="lineCov">              6 :         if($this-&gt;closed != true) {                                                                                             </span>
-<span class="lineNum" id="container228"><a name="228"></a><a href="#228" id="line228">     228</a> </span><span class="lineCov">              6 :             if ($this-&gt;db !== null) {                                                                                           </span>
-<span class="lineNum" id="container229"><a name="229"></a><a href="#229" id="line229">     229</a> </span><span class="lineCov">              4 :                 $this-&gt;db = null;                                                                                               </span>
-<span class="lineNum" id="container230"><a name="230"></a><a href="#230" id="line230">     230</a> </span><span class="lineCov">              4 :             }                                                                                                                   </span>
-<span class="lineNum" id="container231"><a name="231"></a><a href="#231" id="line231">     231</a> </span><span class="lineCov">              6 :             $this-&gt;closed = true;                                                                                               </span>
-<span class="lineNum" id="container232"><a name="232"></a><a href="#232" id="line232">     232</a> </span><span class="lineCov">              6 :         }                                                                                                                       </span>
-<span class="lineNum" id="container233"><a name="233"></a><a href="#233" id="line233">     233</a> </span><span class="lineCov">              6 :     }                                                                                                                           </span>
-<span class="lineNum" id="container234"><a name="234"></a><a href="#234" id="line234">     234</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container235"><a name="235"></a><a href="#235" id="line235">     235</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container236"><a name="236"></a><a href="#236" id="line236">     236</a> </span>                :      * Sets the username for this connection.                                                                                   
-<span class="lineNum" id="container237"><a name="237"></a><a href="#237" id="line237">     237</a> </span>                :      * Defaults to ''                                                                                                           
-<span class="lineNum" id="container238"><a name="238"></a><a href="#238" id="line238">     238</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container239"><a name="239"></a><a href="#239" id="line239">     239</a> </span>                :     public function setUser($user) {                                                                                            
-<span class="lineNum" id="container240"><a name="240"></a><a href="#240" id="line240">     240</a> </span><span class="lineNoCov">              0 :         $this-&gt;user = $user;                                                                                                    </span>
-<span class="lineNum" id="container241"><a name="241"></a><a href="#241" id="line241">     241</a> </span><span class="lineNoCov">              0 :     }                                                                                                                           </span>
-<span class="lineNum" id="container242"><a name="242"></a><a href="#242" id="line242">     242</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container243"><a name="243"></a><a href="#243" id="line243">     243</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container244"><a name="244"></a><a href="#244" id="line244">     244</a> </span>                :      * Sets the password for this connection.                                                                                   
-<span class="lineNum" id="container245"><a name="245"></a><a href="#245" id="line245">     245</a> </span>                :      * Defaults to ''                                                                                                           
-<span class="lineNum" id="container246"><a name="246"></a><a href="#246" id="line246">     246</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container247"><a name="247"></a><a href="#247" id="line247">     247</a> </span>                :     public function setPassword($password) {                                                                                    
-<span class="lineNum" id="container248"><a name="248"></a><a href="#248" id="line248">     248</a> </span><span class="lineNoCov">              0 :         $this-&gt;password = $password;                                                                                            </span>
-<span class="lineNum" id="container249"><a name="249"></a><a href="#249" id="line249">     249</a> </span><span class="lineNoCov">              0 :     }                                                                                                                           </span>
-<span class="lineNum" id="container250"><a name="250"></a><a href="#250" id="line250">     250</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container251"><a name="251"></a><a href="#251" id="line251">     251</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container252"><a name="252"></a><a href="#252" id="line252">     252</a> </span>                :      * Indicator if the logging table should be created on startup,                                                             
-<span class="lineNum" id="container253"><a name="253"></a><a href="#253" id="line253">     253</a> </span>                :      * if its not existing.                                                                                                     
-<span class="lineNum" id="container254"><a name="254"></a><a href="#254" id="line254">     254</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container255"><a name="255"></a><a href="#255" id="line255">     255</a> </span>                :     public function setCreateTable($flag) {                                                                                     
-<span class="lineNum" id="container256"><a name="256"></a><a href="#256" id="line256">     256</a> </span><span class="lineCov">              2 :         $this-&gt;createTable = LoggerOptionConverter::toBoolean($flag, true);                                                     </span>
-<span class="lineNum" id="container257"><a name="257"></a><a href="#257" id="line257">     257</a> </span><span class="lineCov">              2 :     }                                                                                                                           </span>
-<span class="lineNum" id="container258"><a name="258"></a><a href="#258" id="line258">     258</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container259"><a name="259"></a><a href="#259" id="line259">     259</a> </span>                :        /**                                                                                                                      
-<span class="lineNum" id="container260"><a name="260"></a><a href="#260" id="line260">     260</a> </span>                :      * Sets the SQL string into which the event should be transformed.                                                          
-<span class="lineNum" id="container261"><a name="261"></a><a href="#261" id="line261">     261</a> </span>                :      * Defaults to:                                                                                                             
-<span class="lineNum" id="container262"><a name="262"></a><a href="#262" id="line262">     262</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container263"><a name="263"></a><a href="#263" id="line263">     263</a> </span>                :      * INSERT INTO $this-&gt;table                                                                                                 
-<span class="lineNum" id="container264"><a name="264"></a><a href="#264" id="line264">     264</a> </span>                :      * ( timestamp, logger, level, message, thread, file, line)                                                                 
-<span class="lineNum" id="container265"><a name="265"></a><a href="#265" id="line265">     265</a> </span>                :      * VALUES                                                                                                                   
-<span class="lineNum" id="container266"><a name="266"></a><a href="#266" id="line266">     266</a> </span>                :      * ('%d','%c','%p','%m','%t','%F','%L')                                                                                     
-<span class="lineNum" id="container267"><a name="267"></a><a href="#267" id="line267">     267</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container268"><a name="268"></a><a href="#268" id="line268">     268</a> </span>                :      * It's not necessary to change this except you have customized logging'                                                    
-<span class="lineNum" id="container269"><a name="269"></a><a href="#269" id="line269">     269</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container270"><a name="270"></a><a href="#270" id="line270">     270</a> </span>                :      * @deprecated See {@link setInsertSql} and {@link setInsertPattern}.                                                       
-<span class="lineNum" id="container271"><a name="271"></a><a href="#271" id="line271">     271</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container272"><a name="272"></a><a href="#272" id="line272">     272</a> </span>                :     public function setSql($sql) {                                                                                              
-<span class="lineNum" id="container273"><a name="273"></a><a href="#273" id="line273">     273</a> </span><span class="lineCov">              1 :         $this-&gt;sql = $sql;                                                                                                      </span>
-<span class="lineNum" id="container274"><a name="274"></a><a href="#274" id="line274">     274</a> </span><span class="lineCov">              1 :     }                                                                                                                           </span>
-<span class="lineNum" id="container275"><a name="275"></a><a href="#275" id="line275">     275</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container276"><a name="276"></a><a href="#276" id="line276">     276</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container277"><a name="277"></a><a href="#277" id="line277">     277</a> </span>                :      * Sets the SQL INSERT string to use with {@link $insertPattern}.                                                           
-<span class="lineNum" id="container278"><a name="278"></a><a href="#278" id="line278">     278</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container279"><a name="279"></a><a href="#279" id="line279">     279</a> </span>                :      * @param $sql          A complete INSERT INTO query with &quot;?&quot; that gets replaced.                                           
-<span class="lineNum" id="container280"><a name="280"></a><a href="#280" id="line280">     280</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container281"><a name="281"></a><a href="#281" id="line281">     281</a> </span>                :     public function setInsertSql($sql) {                                                                                        
-<span class="lineNum" id="container282"><a name="282"></a><a href="#282" id="line282">     282</a> </span><span class="lineCov">              1 :         $this-&gt;insertSql = $sql;                                                                                                </span>
-<span class="lineNum" id="container283"><a name="283"></a><a href="#283" id="line283">     283</a> </span><span class="lineCov">              1 :     }                                                                                                                           </span>
-<span class="lineNum" id="container284"><a name="284"></a><a href="#284" id="line284">     284</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container285"><a name="285"></a><a href="#285" id="line285">     285</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container286"><a name="286"></a><a href="#286" id="line286">     286</a> </span>                :      * Sets the {@link LoggerLayoutPattern} format strings for {@link $insertSql}.                                              
-<span class="lineNum" id="container287"><a name="287"></a><a href="#287" id="line287">     287</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container288"><a name="288"></a><a href="#288" id="line288">     288</a> </span>                :      * It's not necessary to change this except you have customized logging.                                                    
-<span class="lineNum" id="container289"><a name="289"></a><a href="#289" id="line289">     289</a> </span>                :      *                                                                                                                          
-<span class="lineNum" id="container290"><a name="290"></a><a href="#290" id="line290">     290</a> </span>                :      * @param $pattern          Comma separated format strings like &quot;%p,%m,%C&quot;                                                  
-<span class="lineNum" id="container291"><a name="291"></a><a href="#291" id="line291">     291</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container292"><a name="292"></a><a href="#292" id="line292">     292</a> </span>                :     public function setInsertPattern($pattern) {                                                                                
-<span class="lineNum" id="container293"><a name="293"></a><a href="#293" id="line293">     293</a> </span><span class="lineCov">              1 :         $this-&gt;insertPattern = $pattern;                                                                                        </span>
-<span class="lineNum" id="container294"><a name="294"></a><a href="#294" id="line294">     294</a> </span><span class="lineCov">              1 :     }                                                                                                                           </span>
-<span class="lineNum" id="container295"><a name="295"></a><a href="#295" id="line295">     295</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container296"><a name="296"></a><a href="#296" id="line296">     296</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container297"><a name="297"></a><a href="#297" id="line297">     297</a> </span>                :      * Sets the tablename to which this appender should log.                                                                    
-<span class="lineNum" id="container298"><a name="298"></a><a href="#298" id="line298">     298</a> </span>                :      * Defaults to log4php_log                                                                                                  
-<span class="lineNum" id="container299"><a name="299"></a><a href="#299" id="line299">     299</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container300"><a name="300"></a><a href="#300" id="line300">     300</a> </span>                :     public function setTable($table) {                                                                                          
-<span class="lineNum" id="container301"><a name="301"></a><a href="#301" id="line301">     301</a> </span><span class="lineCov">              1 :         $this-&gt;table = $table;                                                                                                  </span>
-<span class="lineNum" id="container302"><a name="302"></a><a href="#302" id="line302">     302</a> </span><span class="lineCov">              1 :     }                                                                                                                           </span>
-<span class="lineNum" id="container303"><a name="303"></a><a href="#303" id="line303">     303</a> </span>                :                                                                                                                                 
-<span class="lineNum" id="container304"><a name="304"></a><a href="#304" id="line304">     304</a> </span>                :     /**                                                                                                                         
-<span class="lineNum" id="container305"><a name="305"></a><a href="#305" id="line305">     305</a> </span>                :      * Sets the DSN string for this connection. In case of                                                                      
-<span class="lineNum" id="container306"><a name="306"></a><a href="#306" id="line306">     306</a> </span>                :      * SQLite it could look like this: 'sqlite:appenders/pdotest.sqlite'                                                        
-<span class="lineNum" id="container307"><a name="307"></a><a href="#307" id="line307">     307</a> </span>                :      */                                                                                                                         
-<span class="lineNum" id="container308"><a name="308"></a><a href="#308" id="line308">     308</a> </span>                :     public function setDSN($dsn) {                                                                                              
-<span class="lineNum" id="container309"><a name="309"></a><a href="#309" id="line309">     309</a> </span><span class="lineCov">              5 :         $this-&gt;dsn = $dsn;                                                                                                      </span>
-<span class="lineNum" id="container310"><a name="310"></a><a href="#310" id="line310">     310</a> </span><span class="lineCov">              5 :     }                                                                                                                           </span>

[... 548 lines stripped ...]


Mime
View raw message