Clover Coverage Report - kew-test 2.0.0-SNAPSHOT
Coverage timestamp: Wed Dec 31 1969 19:00:00 EST
../../../../../img/srcFileCovDistChart0.png 0% of files have more coverage
7   56   2   7
2   23   0.29   1
1     2  
1    
 
  EDocLiteTestServlet       Line # 33 7 0% 2 10 0% 0.0
 
No Tests
 
1    /*
2    * Copyright 2007-2008 The Kuali Foundation
3    *
4    * Licensed under the Educational Community License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    * http://www.opensource.org/licenses/ecl2.php
9    *
10    * Unless required by applicable law or agreed to in writing, software
11    * distributed under the License is distributed on an "AS IS" BASIS,
12    * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13    * See the License for the specific language governing permissions and
14    * limitations under the License.
15    */
16    package org.kuali.rice.edl.impl;
17   
18    import java.io.BufferedReader;
19    import java.io.IOException;
20    import java.io.InputStreamReader;
21   
22    import javax.servlet.GenericServlet;
23    import javax.servlet.ServletException;
24    import javax.servlet.ServletRequest;
25    import javax.servlet.ServletResponse;
26   
27    /**
28    * Servlet designed to help run tests for EDocLite documents
29    *
30    * @author Kuali Rice Team (rice.collab@kuali.org)
31    *
32    */
 
33    public class EDocLiteTestServlet extends GenericServlet {
34   
35    private static final long serialVersionUID = 4682035504803952278L;
36   
37    public static String postData;
38   
39    /**
40    * This overridden method saves data to the public static <code>postData</code> variable
41    *
42    * @see javax.servlet.GenericServlet#service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
43    */
 
44  0 toggle @Override
45    public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException {
46  0 BufferedReader br = new BufferedReader(new InputStreamReader(req.getInputStream()));
47  0 StringBuilder sb = new StringBuilder();
48  0 String result = null;
49  0 while ((result = br.readLine()) != null) {
50  0 sb.append(result + "\n");
51    }
52  0 br.close();
53  0 postData = sb.toString();
54    }
55   
56    }