1 package org.codehaus.xfire; 2 3 import java.io.InputStream; 4 import java.io.OutputStream; 5 import org.codehaus.xfire.service.ServiceRegistry; 6 import org.codehaus.xfire.transport.TransportManager; 7 8 /*** 9 * <p>Central processing point for XFire. This can be instantiated 10 * programmatically by using one of the implementations (such as 11 * <code>DefaultXFire</code> or can be managed by a container like 12 * Pico or Plexus. 13 * </p> 14 * <p> 15 * Central, however, does not mean that there can be only one. 16 * Implementations can be very lightweight, creating fast generic 17 * SOAP processors. 18 * </p> 19 * @author <a href="mailto:dan@envoisolutions.com">Dan Diephouse</a> 20 * @since Feb 18, 2004 21 */ 22 public interface XFire 23 { 24 final public static String ROLE = XFire.class.getName(); 25 26 /*** 27 * Processes a new SOAP Message request. If a fault 28 * or exception occurs, it is written to the OutputStream 29 * in the <code>MessageContext</code>. However, 30 * <code>XFireRuntimeException</code>s may still be thrown if 31 * something fatal goes wrong in the pipeline. 32 * 33 * @param in An InputStream to the SOAP document. 34 * @param context The MessageContext. 35 */ 36 void invoke( InputStream in, 37 MessageContext context ); 38 39 /*** 40 * Generate WSDL for a service. 41 * 42 * @param service The name of the service. 43 * @param out The OutputStream to write the WSDL to. 44 */ 45 void generateWSDL(String service, OutputStream out); 46 47 /*** 48 * Get the <code>ServiceRegistry</code>. 49 */ 50 ServiceRegistry getServiceRegistry(); 51 52 /*** 53 * Get the <code>TransportManager</code>. 54 */ 55 TransportManager getTransportManager(); 56 }