1 package org.sapia.ubik.net.nio.acceptor; 2 3 import java.io.IOException ; 4 5 import org.sapia.ubik.net.nio.Cycle; 6 import org.sapia.ubik.net.nio.util.WriteHelper; 7 8 23 public class WriteStateHandler extends AbstractStateHandler { 24 25 private WriteHelper _helper = new WriteHelper(); 26 27 public WriteStateHandler(AcceptorConfig config) { 28 super(config); 29 } 30 31 34 public void handle(Cycle cycle) throws HandlerException { 35 if(_config.debug.on()) 36 _config.debug.out(getClass(), "WRITE..."); 37 try { 38 _config.dispatcher.dispatch(cycle); 39 } catch(IOException e) { 40 cycle.error(e); 41 cycle.next(); 42 } 43 } 44 } 45 | Popular Tags |