FileDocCategorySizeDatePackage
BurritoInventoryConsumer.javaAPI DocExample909Tue Jan 25 10:45:14 GMT 2000None

BurritoInventoryConsumer

public class BurritoInventoryConsumer extends HttpServlet

Fields Summary
private BurritoInventory
inventory
Constructors Summary
Methods Summary
public voiddoGet(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res)


       
                                  
    res.setContentType("text/html");
    PrintWriter out = res.getWriter();

    out.println("<HTML>");
    out.println("<HEAD><TITLE>Burrito Inventory Consumer</TITLE></HEAD>");

    out.println("<BODY><BIG>");

    if (inventory.makeBurrito()) {
      out.println("Your burrito will be ready in a few minutes.");
    }
    else {
      out.println("We're low on ingredients.<BR>");
      out.println("Looks like you're gonna starve.");
    }

    out.println("</BIG></BODY></HTML>");