1 /* 2 * $Id: TransformContext.java,v 1.2 2003/02/19 22:50:49 lhoriman Exp $ 3 * $Source: /cvsroot/mav/maverick/src/java/org/infohazard/maverick/flow/TransformContext.java,v $ 4 */ 5 6 package org.infohazard.maverick.flow; 7 8 import java.util.Map; 9 import javax.servlet.ServletContext; 10 import javax.servlet.ServletException; 11 import javax.servlet.http.HttpServletRequest; 12 import javax.servlet.http.HttpServletResponse; 13 14 /** 15 * TransformContext defines the methods and data available to a transform 16 * for a single request. 17 */ 18 public interface TransformContext 19 { 20 /** 21 */ 22 public HttpServletRequest getRequest(); 23 24 /** 25 */ 26 public ServletContext getServletContext(); 27 28 /** 29 * Obtain any params that were set. 30 */ 31 public Map getTransformParams(); 32 33 /** 34 * @return the next step in the transformation process 35 * 36 * Call this ONLY ONCE per step! 37 */ 38 public TransformStep getNextStep() throws ServletException; 39 40 /** 41 * @return true if the transformation chain is going to be 42 * halted prematurely due to user request. 43 */ 44 public boolean halting(); 45 46 /** 47 * Returns the *real* response object. Do not use this 48 * unless you know are the tail! 49 */ 50 public HttpServletResponse getRealResponse(); 51 } 52