Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@gauravpaliwal
Created July 28, 2013 14:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gauravpaliwal/6098794 to your computer and use it in GitHub Desktop.
Save gauravpaliwal/6098794 to your computer and use it in GitHub Desktop.
package org.openmrs.module.patientmatching.web;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.openmrs.module.patientmatching.db.DecisionTreeXMLMetadataDao;
import org.openmrs.module.patientmatching.db.hibernate.HibernateDecisionTreeXMLMetadataDAO;
import org.openmrs.module.patientmatching.DecisionTreeXML;
public class CRUDServlet extends HttpServlet {
private Log log = LogFactory.getLog(getClass());
public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
{
// Set response content type
response.setContentType("text/html");
// Actual logic goes here.
PrintWriter out = response.getWriter();
out.println("<h1>" + message + "</h1>");
}
@Override
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
{
doGet(request, response);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment