Java Doc for ConnectionMultiplexer.java in  » 6.0-JDK-Modules-sun » rmi » sun » rmi » transport » tcp » 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 » 6.0 JDK Modules sun » rmi » sun.rmi.transport.tcp 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   sun.rmi.transport.tcp.ConnectionMultiplexer

ConnectionMultiplexer
final class ConnectionMultiplexer (Code)
ConnectionMultiplexer manages the transparent multiplexing of multiple virtual connections from one endpoint to another through one given real connection to that endpoint. The input and output streams for the the underlying real connection must be supplied. A callback object is also supplied to be informed of new virtual connections opened by the remote endpoint. After creation, the run() method must be called in a thread created for demultiplexing the connections. The openConnection() method is called to initiate a virtual connection from this endpoint.
author:
   Peter Jones


Field Summary
static  intlogLevel
    
final static  LogmultiplexLog
    

Constructor Summary
public  ConnectionMultiplexer(TCPChannel channel, InputStream in, OutputStream out, boolean orig)
     Create a new ConnectionMultiplexer using the given underlying input/output stream pair.

Method Summary
protected  voidfinalize()
     Shut down connection upon finalization.
public synchronized  TCPConnectionopenConnection()
     Initiate a new multiplexed connection through the underlying connection.
public  voidrun()
     Process multiplexing protocol received from underlying connection.
 voidsendClose(MultiplexConnectionInfo info)
     Inform remote endpoint that connection has been closed.
 voidsendCloseAck(MultiplexConnectionInfo info)
     Acknowledge remote endpoint's closing of connection.
 voidsendRequest(MultiplexConnectionInfo info, int len)
     Send request for more data on connection to remote endpoint.
 voidsendTransmit(MultiplexConnectionInfo info, byte buf, int off, int len)
     Send packet of requested data on connection to remote endpoint.
public  voidshutDown()
     Shut down all connections and clean up.

Field Detail
logLevel
static int logLevel(Code)
"multiplex" log level



multiplexLog
final static Log multiplexLog(Code)




Constructor Detail
ConnectionMultiplexer
public ConnectionMultiplexer(TCPChannel channel, InputStream in, OutputStream out, boolean orig)(Code)
Create a new ConnectionMultiplexer using the given underlying input/output stream pair. The run method must be called (possibly on a new thread) to handle the demultiplexing.
Parameters:
  channel - object to notify when new connection is received
Parameters:
  in - input stream of underlying connection
Parameters:
  out - output stream of underlying connection
Parameters:
  orig - true if this endpoint intiated the underlyingconnection (needs to be set differently at both ends)




Method Detail
finalize
protected void finalize() throws Throwable(Code)
Shut down connection upon finalization.



openConnection
public synchronized TCPConnection openConnection() throws IOException(Code)
Initiate a new multiplexed connection through the underlying connection.



run
public void run() throws IOException(Code)
Process multiplexing protocol received from underlying connection.



sendClose
void sendClose(MultiplexConnectionInfo info) throws IOException(Code)
Inform remote endpoint that connection has been closed.
Parameters:
  info - connection information structure



sendCloseAck
void sendCloseAck(MultiplexConnectionInfo info) throws IOException(Code)
Acknowledge remote endpoint's closing of connection.
Parameters:
  info - connection information structure



sendRequest
void sendRequest(MultiplexConnectionInfo info, int len) throws IOException(Code)
Send request for more data on connection to remote endpoint.
Parameters:
  info - connection information structure
Parameters:
  len - number of more bytes that can be received



sendTransmit
void sendTransmit(MultiplexConnectionInfo info, byte buf, int off, int len) throws IOException(Code)
Send packet of requested data on connection to remote endpoint.
Parameters:
  info - connection information structure
Parameters:
  buf - array containg bytes to send
Parameters:
  off - offset of first array index of packet
Parameters:
  len - number of bytes in packet to send



shutDown
public void shutDown()(Code)
Shut down all connections and clean up.



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.