1 package example; 2 3 import com.caucho.util.L10N; 4 import java.util.logging.Logger ; 5 import java.util.logging.Level ; 6 7 import com.caucho.server.connection.Connection; 8 import com.caucho.server.port.Protocol; 9 import com.caucho.server.port.ServerRequest; 10 11 14 public class Magic8BallProtocol extends Protocol { 15 static protected final Logger log = 16 Logger.getLogger(Magic8BallProtocol.class.getName()); 17 static final L10N L = new L10N(Magic8BallProtocol.class); 18 19 private String _protocolName = "magic8ball"; 20 21 24 public Magic8BallProtocol() 25 { 26 } 27 28 31 public String getProtocolName() 32 { 33 return _protocolName; 34 } 35 36 39 public void setProtocolName(String name) 40 { 41 _protocolName = name; 42 } 43 44 47 public ServerRequest createRequest(Connection conn) 48 { 49 return new Magic8BallRequest(this, conn); 50 } 51 } 52 53 | Popular Tags |