//import Service;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import javax.servlet.ServletContext;

public class CheckOut implements Service 
{
	public CheckOut() 
	{
	}

	/*
		implemented method from Service interface
	*/

	public void execute(HttpServletRequest request, HttpServletResponse response,ServletContext context) 
		throws Exception 
	{
		// Check the HttpSession for an exist travel plan corner
		HttpSession session = request.getSession();
		TravelCorner myTravelCorner = (TravelCorner)session.getAttribute("myTravelCorner");
		if ( myTravelCorner != null ) 
		{
			// If there was an existing travel plan corner empty it
			myTravelCorner.empty();
		}
	}
}
