Coverage report

  %line %branch
net.sf.infrared.web.formbean.SqlStatisticsFormBean
0% 
0% 

 1  
 /*
 2  
  *
 3  
  * Copyright 2005 Tavant Technologies and Contributors
 4  
  * 
 5  
  * Licensed under the Apache License, Version 2.0 (the "License")
 6  
  * you may not use this file except in compliance with the License.
 7  
  * You may obtain a copy of the License at
 8  
  *
 9  
  *     http://www.apache.org/licenses/LICENSE-2.0
 10  
  *
 11  
  * Unless required by applicable law or agreed to in writing, software
 12  
  * distributed under the License is distributed on an "AS IS" BASIS,
 13  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 14  
  * See the License for the specific language governing permissions and
 15  
  * limitations under the License.
 16  
  *
 17  
  *
 18  
  *
 19  
  * Original Author:  prashant.nair (Tavant Technologies)
 20  
  * Contributor(s):   -;
 21  
  *
 22  
  */
 23  
 package net.sf.infrared.web.formbean;
 24  
 
 25  
 import net.sf.infrared.web.util.ViewUtil;
 26  
 
 27  
 import org.apache.struts.action.ActionForm;
 28  
 
 29  0
 public class SqlStatisticsFormBean extends ActionForm {
 30  
     
 31  
     private String sql;
 32  
     private String avgTotalTime;
 33  
     private String avgExecuteTime;
 34  
     private String avgPrepareTime;
 35  
     private String noOfExecutes;
 36  
     private String noOfPrepares;
 37  
     private String maxExecuteTime;
 38  
     private String maxPrepareTime;
 39  
     private String minExecuteTime;
 40  
     private String minPrepareTime;
 41  
     private String lastExecuteTime;
 42  
     private String lastPrepareTime;
 43  
     private String firstExecuteTime;
 44  
     private String firstPrepareTime;
 45  
     private String totalExecuteTime;
 46  
     private String totalPrepareTime;
 47  
     private String tdStyle;
 48  
     
 49  
     public String getAvgExecuteTime() {
 50  0
         return ViewUtil.getFormattedTime(avgExecuteTime, 2);
 51  
     }
 52  
     public void setAvgExecuteTime(String avgExecuteTime) {
 53  0
         this.avgExecuteTime = avgExecuteTime;
 54  0
     }
 55  
     public String getAvgPrepareTime() {
 56  0
         return ViewUtil.getFormattedTime(avgPrepareTime, 2);
 57  
     }
 58  
     public void setAvgPrepareTime(String avgPrepareTime) {
 59  0
         this.avgPrepareTime = avgPrepareTime;
 60  0
     }
 61  
     public String getAvgTotalTime() {
 62  0
         return ViewUtil.getFormattedTime(avgTotalTime, 2);
 63  
     }
 64  
     public void setAvgTotalTime(String avgTotalTime) {
 65  0
         this.avgTotalTime = avgTotalTime;
 66  0
     }
 67  
     public String getFirstExecuteTime() {
 68  0
         return firstExecuteTime;
 69  
     }
 70  
     public void setFirstExecuteTime(String firstExecuteTime) {
 71  0
         this.firstExecuteTime = firstExecuteTime;
 72  0
     }
 73  
     public String getFirstPrepareTime() {
 74  0
         return firstPrepareTime;
 75  
     }
 76  
     public void setFirstPrepareTime(String firstPrepareTime) {
 77  0
         this.firstPrepareTime = firstPrepareTime;
 78  0
     }
 79  
     public String getLastExecuteTime() {
 80  0
         return lastExecuteTime;
 81  
     }
 82  
     public void setLastExecuteTime(String lastExecuteTime) {
 83  0
         this.lastExecuteTime = lastExecuteTime;
 84  0
     }
 85  
     public String getLastPrepareTime() {
 86  0
         return lastPrepareTime;
 87  
     }
 88  
     public void setLastPrepareTime(String lastPrepareTime) {
 89  0
         this.lastPrepareTime = lastPrepareTime;
 90  0
     }
 91  
     public String getMaxExecuteTime() {
 92  0
         return maxExecuteTime;
 93  
     }
 94  
     public void setMaxExecuteTime(String maxExecuteTime) {
 95  0
         this.maxExecuteTime = maxExecuteTime;
 96  0
     }
 97  
     public String getMaxPrepareTime() {
 98  0
         return maxPrepareTime;
 99  
     }
 100  
     public void setMaxPrepareTime(String maxPrepareTime) {
 101  0
         this.maxPrepareTime = maxPrepareTime;
 102  0
     }
 103  
     public String getMinExecuteTime() {
 104  0
         return minExecuteTime;
 105  
     }
 106  
     public void setMinExecuteTime(String minExecuteTime) {
 107  0
         this.minExecuteTime = minExecuteTime;
 108  0
     }
 109  
     public String getMinPrepareTime() {
 110  0
         return minPrepareTime;
 111  
     }
 112  
     public void setMinPrepareTime(String minPrepareTime) {
 113  0
         this.minPrepareTime = minPrepareTime;
 114  0
     }
 115  
     public String getNoOfExecutes() {
 116  0
         return noOfExecutes;
 117  
     }
 118  
     public void setNoOfExecutes(String noOfExecutes) {
 119  0
         this.noOfExecutes = noOfExecutes;
 120  0
     }
 121  
     public String getNoOfPrepares() {
 122  0
         return noOfPrepares;
 123  
     }
 124  
     public void setNoOfPrepares(String noOfPrepares) {
 125  0
         this.noOfPrepares = noOfPrepares;
 126  0
     }
 127  
     public String getSql() {
 128  0
         return sql;
 129  
     }
 130  
     public void setSql(String sql) {
 131  0
         this.sql = sql;
 132  0
     }
 133  
     public String getTotalExecuteTime() {
 134  0
         return totalExecuteTime;
 135  
     }
 136  
     public void setTotalExecuteTime(String totalExecuteTime) {
 137  0
         this.totalExecuteTime = totalExecuteTime;
 138  0
     }
 139  
     public String getTotalPrepareTime() {
 140  0
         return totalPrepareTime;
 141  
     }
 142  
     public void setTotalPrepareTime(String totalPrepareTime) {
 143  0
         this.totalPrepareTime = totalPrepareTime;
 144  0
     }    
 145  
     public String getTdStyle() {
 146  0
 		if (Double.parseDouble(avgExecuteTime) > 100)
 147  0
 			tdStyle = "hotSpot";
 148  
 		else
 149  0
 			tdStyle = "";
 150  
 
 151  0
 		return tdStyle;
 152  
 	}
 153  
 
 154  
 
 155  
 }

This report is generated by jcoverage, Maven and Maven JCoverage Plugin.