1 package org.tigris.scarab.pipeline; 2 3 48 49 import java.io.IOException ; 50 import org.apache.turbine.RunData; 51 import org.apache.turbine.TurbineException; 52 import org.apache.turbine.pipeline.AbstractValve; 53 import org.apache.turbine.ValveContext; 54 import org.apache.turbine.modules.Module; 55 56 import org.tigris.scarab.tools.ScarabRequestTool; 57 import org.tigris.scarab.util.ScarabConstants; 58 59 70 public class SetInfoMessageValve 71 extends AbstractValve 72 { 73 private static String message = null; 74 75 78 public void invoke(RunData data, ValveContext context) 79 throws IOException , TurbineException 80 { 81 ((ScarabRequestTool)Module.getTemplateContext(data) 82 .get(ScarabConstants.SCARAB_REQUEST_TOOL)).setInfoMessage(message); 83 84 context.invokeNext(data); 86 } 87 88 public static void setMessage(String msg) 89 { 90 message = msg; 91 } 92 } 93 | Popular Tags |