1 8 package org.codehaus.spice.netserve.connection.handlers; 9 10 import java.net.Socket ; 11 import org.codehaus.spice.netserve.connection.RequestHandler; 12 13 19 public class DelegatingRequestHandler 20 extends AbstractRequestHandler 21 { 22 25 private final RequestHandler m_handler; 26 27 32 public DelegatingRequestHandler( final RequestHandler handler ) 33 { 34 if( null == handler ) 35 { 36 throw new NullPointerException ( "handler" ); 37 } 38 m_handler = handler; 39 } 40 41 47 protected void doPerformRequest( final Socket socket ) 48 throws Exception 49 { 50 m_handler.handleConnection( socket ); 51 } 52 53 56 public void shutdown( final long timeout ) 57 { 58 m_handler.shutdown( timeout ); 59 super.shutdown( timeout ); 60 } 61 } 62 | Popular Tags |