Java Doc for PoolTcpEndpoint.java in  » Sevlet-Container » apache-tomcat-6.0.14 » org » apache » tomcat » util » net » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Sevlet Container » apache tomcat 6.0.14 » org.apache.tomcat.util.net 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.tomcat.util.net.PoolTcpEndpoint

PoolTcpEndpoint
public class PoolTcpEndpoint implements Runnable(Code)
Handle incoming TCP connections. This class implement a simple server model: one listener thread accepts on a socket and creates a new worker thread for each incoming connection. More advanced Endpoints will reuse the threads, use queues, etc.
author:
   James Duncan Davidson [duncan@eng.sun.com]
author:
   Jason Hunter [jch@eng.sun.com]
author:
   James Todd [gonzo@eng.sun.com]
author:
   Costin@eng.sun.com
author:
   Gal Shachor [shachor@il.ibm.com]
author:
   Yoav Shapira


Field Summary
final static  intdebug
    
 TcpConnectionHandlerhandler
    
protected  intlinger
    
 ThreadPoolRunnablelistener
    
static  Loglog
    
protected  intsocketTimeout
    
protected  booleantcpNoDelay
    
 ThreadPooltp
    

Constructor Summary
public  PoolTcpEndpoint()
    
public  PoolTcpEndpoint(ThreadPool tp)
    

Method Summary
 SocketacceptSocket()
    
protected  voidcloseServerSocket()
    
public  InetAddressgetAddress()
    
public  intgetBacklog()
    
public  TcpConnectionHandlergetConnectionHandler()
    
public  intgetCurrentThreadCount()
    
public  intgetCurrentThreadsBusy()
    
public  intgetMaxSpareThreads()
    
public  intgetMaxThreads()
    
public  intgetMinSpareThreads()
    
public  intgetPort()
    
public  intgetServerSoTimeout()
    
 ServerSocketFactorygetServerSocketFactory()
    
public  intgetSoLinger()
    
public  intgetSoTimeout()
    
public  StringgetStrategy()
    
public  booleangetTcpNoDelay()
    
public  intgetThreadPriority()
    
public  voidinitEndpoint()
    
public  booleanisPaused()
    
public  booleanisRunning()
    
public  voidpauseEndpoint()
    
 voidprocessSocket(Socket s, TcpConnection con, Object[] threadData)
    
 voidrecycleWorkerThread(MasterSlaveWorkerThread workerThread)
     Recycle the specified Processor so that it can be used again.
public  voidresumeEndpoint()
    
public  voidrun()
     The background thread that listens for incoming TCP/IP connections and hands them off to an appropriate processor.
public  voidsetAddress(InetAddress inet)
    
public  voidsetBacklog(int backlog)
     Allows the server developer to specify the backlog that should be used for server sockets.
public  voidsetConnectionHandler(TcpConnectionHandler handler)
    
public  voidsetMaxSpareThreads(int maxThreads)
    
public  voidsetMaxThreads(int maxThreads)
    
public  voidsetMinSpareThreads(int minThreads)
    
public  voidsetPort(int port)
    
public  voidsetServerSoTimeout(int i)
    
public  voidsetServerSocket(ServerSocket ss)
    
public  voidsetServerSocketFactory(ServerSocketFactory factory)
    
public  voidsetServerTimeout(int timeout)
     Sets the timeout in ms of the server sockets created by this server.
public  voidsetSoLinger(int i)
    
public  voidsetSoTimeout(int i)
    
 voidsetSocketOptions(Socket socket)
    
public  voidsetStrategy(String strategy)
    
public  voidsetTcpNoDelay(boolean b)
    
public  voidsetThreadPriority(int threadPriority)
    
public  voidstartEndpoint()
    
public  voidstopEndpoint()
    
protected  voidunlockAccept()
    

Field Detail
debug
final static int debug(Code)



handler
TcpConnectionHandler handler(Code)



linger
protected int linger(Code)



listener
ThreadPoolRunnable listener(Code)



log
static Log log(Code)



socketTimeout
protected int socketTimeout(Code)



tcpNoDelay
protected boolean tcpNoDelay(Code)



tp
ThreadPool tp(Code)




Constructor Detail
PoolTcpEndpoint
public PoolTcpEndpoint()(Code)



PoolTcpEndpoint
public PoolTcpEndpoint(ThreadPool tp)(Code)




Method Detail
acceptSocket
Socket acceptSocket()(Code)



closeServerSocket
protected void closeServerSocket()(Code)



getAddress
public InetAddress getAddress()(Code)



getBacklog
public int getBacklog()(Code)



getConnectionHandler
public TcpConnectionHandler getConnectionHandler()(Code)



getCurrentThreadCount
public int getCurrentThreadCount()(Code)



getCurrentThreadsBusy
public int getCurrentThreadsBusy()(Code)



getMaxSpareThreads
public int getMaxSpareThreads()(Code)



getMaxThreads
public int getMaxThreads()(Code)



getMinSpareThreads
public int getMinSpareThreads()(Code)



getPort
public int getPort()(Code)



getServerSoTimeout
public int getServerSoTimeout()(Code)



getServerSocketFactory
ServerSocketFactory getServerSocketFactory()(Code)



getSoLinger
public int getSoLinger()(Code)



getSoTimeout
public int getSoTimeout()(Code)



getStrategy
public String getStrategy()(Code)



getTcpNoDelay
public boolean getTcpNoDelay()(Code)



getThreadPriority
public int getThreadPriority()(Code)



initEndpoint
public void initEndpoint() throws IOException, InstantiationException(Code)



isPaused
public boolean isPaused()(Code)



isRunning
public boolean isRunning()(Code)



pauseEndpoint
public void pauseEndpoint()(Code)



processSocket
void processSocket(Socket s, TcpConnection con, Object[] threadData)(Code)



recycleWorkerThread
void recycleWorkerThread(MasterSlaveWorkerThread workerThread)(Code)
Recycle the specified Processor so that it can be used again.
Parameters:
  processor - The processor to be recycled



resumeEndpoint
public void resumeEndpoint()(Code)



run
public void run()(Code)
The background thread that listens for incoming TCP/IP connections and hands them off to an appropriate processor.



setAddress
public void setAddress(InetAddress inet)(Code)



setBacklog
public void setBacklog(int backlog)(Code)
Allows the server developer to specify the backlog that should be used for server sockets. By default, this value is 100.



setConnectionHandler
public void setConnectionHandler(TcpConnectionHandler handler)(Code)



setMaxSpareThreads
public void setMaxSpareThreads(int maxThreads)(Code)



setMaxThreads
public void setMaxThreads(int maxThreads)(Code)



setMinSpareThreads
public void setMinSpareThreads(int minThreads)(Code)



setPort
public void setPort(int port)(Code)



setServerSoTimeout
public void setServerSoTimeout(int i)(Code)



setServerSocket
public void setServerSocket(ServerSocket ss)(Code)



setServerSocketFactory
public void setServerSocketFactory(ServerSocketFactory factory)(Code)



setServerTimeout
public void setServerTimeout(int timeout)(Code)
Sets the timeout in ms of the server sockets created by this server. This method allows the developer to make servers more or less responsive to having their server sockets shut down.

By default this value is 1000ms.




setSoLinger
public void setSoLinger(int i)(Code)



setSoTimeout
public void setSoTimeout(int i)(Code)



setSocketOptions
void setSocketOptions(Socket socket) throws SocketException(Code)



setStrategy
public void setStrategy(String strategy)(Code)



setTcpNoDelay
public void setTcpNoDelay(boolean b)(Code)



setThreadPriority
public void setThreadPriority(int threadPriority)(Code)



startEndpoint
public void startEndpoint() throws IOException, InstantiationException(Code)



stopEndpoint
public void stopEndpoint()(Code)



unlockAccept
protected void unlockAccept()(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.