Package: com.multiversesocial.hyperview
Class: com.multiversesocial.hyperview.HyperConnectionNode
Source: src/com/multiversesocial/hyperview/HyperConnectionNode.java

HyperConnectionNode

HyperView V3.2 — class
version V3.2 class

Summary

Lists for IO Vector pool List for external connections ---------------

Source file: HyperConnectionNode.java

Hierarchy

Extends: Linkable

Implements: BufferConstants, HyperNodeConstants

Referenced HyperView classes

Media files used

Declaration & members

public class HyperConnectionNode extends Linkable implements BufferConstants, HyperNodeConstants

Declared in src/com/multiversesocial/hyperview/HyperConnectionNode.java, lines 8–881. 36 field(s), 4 constructor(s), 29 method(s). Every member has an anchor you can link to (e.g. HyperConnectionNode.html#<id>).

Fields (36)

DeclarationValue / initializerDescriptionSource
byte[] bufferNo comment in source; assigned in HyperConnectionNode(), initialize(), cleanUp(); used in toString().line 10
static final int BUFFER_SIZE= 512 (constant)TCP/IP minimum receive unitline 13
HyperChannel channelNo comment in source; assigned in HyperConnectionNode(), initialize().line 28
DisconnectVector disconnectVectorList for external connectionsline 42
ExternalConnectionNode externalConnectionNodeNo comment in source; name appears in 2 other source file(s): HyperExternalConnectionHandler, MakeConnection.line 32
int inactivityTimerNo comment in source; assigned in HyperConnectionNode(), cleanUp(); used in saveNode().line 16
int ioReturnVectorTimeoutNo comment in source; assigned in HyperConnectionNode().line 35
volatile int nodeFlagsNo comment in source; assigned in HyperConnectionNode(), cleanUp(); used in saveNode(), getExceptionBits(), getNodeBits().line 12
int numberNo comment in source; assigned in HyperConnectionNode(); used in saveNode(), toString().line 17
OutputStream outputStreamNo comment in source; assigned in HyperConnectionNode(), initialize(); used in toString().line 36
HyperConnectionHandler parentConnectionHandlerNo comment in source; assigned in HyperConnectionNode(), initialize(); used in saveNode(), cleanUp().line 29
HyperNBInputHandler parentInputHandlerNo comment in source; assigned in HyperConnectionNode(), initialize(), cleanUp(); used in saveNode(), getIO().line 31
HyperNBOutputHandler parentOutputHandlerNo comment in source; assigned in HyperConnectionNode(), initialize(), cleanUp(); used in saveNode(), sendIO().line 30
int pingNumberNo comment in source; assigned in HyperConnectionNode(), initialize(); used in saveNode().line 21
PortNode portNodeNo comment in source; name appears in 5 other source file(s): HyperConnectionHandler, PortControlPane, STDInputHandler, ServerChannelPane ….line 55
int readBlockSizeNo comment in source; assigned in HyperConnectionNode(), cleanUp(); used in saveNode().line 19
int readBytesNo comment in source; assigned in HyperConnectionNode(), cleanUp(); used in saveNode().line 18
volatile HyperLinkedList readVectorReturnListLists for IO Vector poolline 39
SocketAddress remoteAddressNo comment in source; assigned in HyperConnectionNode(), initialize(); used in saveNode(), toString().line 25
InetSocketAddress remoteInetAddressNo comment in source; assigned in initialize(); used in toString().line 26
int securityLevelNo comment in source; assigned in HyperConnectionNode(), cleanUp(); used in saveNode().line 20
volatile Object serverIOReadChangeClassNo comment in source; not referenced by name in this type’s methods.line 51
volatile IOReply serverIOReadClassNo comment in source; name appears in 3 other source file(s): HyperConnectionHandler, HyperDefs, PreferencesPane.line 54
volatile Object serverIOWriteChangeClassClasses to allow the implementor to overide The default Server IORequests defined in Preferences Using "change" copies of the default class references allows Thread safe swapping on the fly without forcing synchronization when accessing the currently set IORequestline 50
volatile IOReply serverIOWriteClassNo comment in source; name appears in 2 other source file(s): HyperDefs, PreferencesPane.line 53
Socket socketNo comment in source; assigned in HyperConnectionNode(), initialize(), cleanUp(); used in saveNode(), setSocketDefaults().line 24
SocketChannel socketChannelNo comment in source; assigned in HyperConnectionNode(), initialize(), cleanUp(); used in saveNode(), getWriteVector(), getReadVector().line 27
Object socketChannelLockNo comment in source; assigned in initialize(), cleanUp(); used in saveNode().line 37
StateMachine stateMachineNo comment in source; assigned in HyperConnectionNode(), initialize(); used in toString().line 11
int timeoutNo comment in source; assigned in HyperConnectionNode(), cleanUp(); used in saveNode().line 14
int timeTillTimeoutNo comment in source; assigned in HyperConnectionNode(); used in saveNode().line 15
volatile long totalReadBytesNo comment in source; assigned in HyperConnectionNode(); used in saveNode().line 22
volatile int totalReadVectorsNo comment in source; assigned in HyperConnectionNode(), getReadVector(); used in saveNode().line 33
volatile int totalWriteVectorsNo comment in source; assigned in HyperConnectionNode(), getWriteVector(); used in saveNode().line 34
volatile long totalWrittenBytesNo comment in source; assigned in HyperConnectionNode(); used in saveNode().line 23
volatile HyperLinkedList writeVectorReturnListNo comment in source; assigned in HyperConnectionNode(), initialize(); used in saveNode(), returnMsg(), getWriteVector().line 40

Constructors (4)

SignatureDescriptionSource
HyperConnectionNode()17 statement(s); calls super().line 57
HyperConnectionNode(int tNodeNumber, HyperChannel tChannel)24 statement(s); calls super(); creates HyperLinkedList, ServerStateMachine.line 77
HyperConnectionNode(HyperConnectionHandler tHandler, int tNodeNumber, ServerSocketChannel tServerSocketChannel)25 statement(s); calls super(), tServerSocketChannel.accept().socket(), tServerSocketChannel.accept(), socket.setSoLinger(), sex.printStackTrace() …; creates HyperLinkedList, StateMachine.line 105
HyperConnectionNode(PortNode tPortNode)22 statement(s); calls super(); creates HyperLinkedList, StateMachine.line 175

Methods (29)

SignatureDescriptionSource
public boolean cleanUp()15 statement(s); calls socket.close().line 707
public byte getByte()Returns 1.line 203
public byte[] getData()Returns new byte[1].line 227
public byte[] getData(int tLength)Returns new byte[tLength].line 223
String getExceptionBits()Returns "Node " + (((this.nodeFlags & HyperNodeConstants.NODE_EXCEPTION_MASK) == HyperNodeConstants.NODE_EXC.line 802
public int getInt()Returns 1.line 213
public HyperNodeReadVector getIO()4 statement(s); calls getReadVector(), parentInputHandler.readAddList.dlStore(), parentInputHandler.readAddList.notifyAll().line 526
public void getIO(HyperLinkedList tList)For lists of HyperNodeReadVectors() ie: queue multiple readsline 507
public void getIO(HyperNodeReadVector tempReadVector)1 statement(s); calls parentInputHandler.readAddList.dlStore(), parentInputHandler.readAddList.notifyAll().line 517
public long getLong()Returns 1L.line 218
public String getNodeBits()9 statement(s); calls sb.append(), sb.toString(); creates StringBuilder.line 812
HyperNodeReadVector getReadVector()2 statement(s); calls readVectorReturnList.dlDelete(), tHyperNodeReadVector.initialize(), readVectorReturnList.clear(), readVectorReturnList.notifyAll(); creates HyperNodeReadVector.line 681
HyperNodeReadVector getReadVector(HyperChannel tChannel, IOReply tReply)2 statement(s); calls readVectorReturnList.dlDelete(), tHyperNodeReadVector.initialize(), readVectorReturnList.clear(), readVectorReturnList.notifyAll(); creates HyperNodeReadVector.line 597
public short getShort()Returns 1.line 208
HyperNodeWriteVector getWriteVector()2 statement(s); calls writeVectorReturnList.dlDelete(), tHyperNodeWriteVector.initialize(), writeVectorReturnList.notifyAll(); creates HyperNodeWriteVector.line 655
HyperNodeWriteVector getWriteVector(HyperChannel tChannel)3 statement(s); calls System.exit(), writeVectorReturnList.dlDelete(), tHyperNodeWriteVector.initialize(), writeVectorReturnList.notifyAll(); creates HyperNodeWriteVector.line 622
public void initialize(int tNodeNumber, HyperChannel tChannel)6 statement(s).line 404
public void initialize(HyperConnectionHandler tHandler, int tNodeNumber, ServerSocketChannel tServerSocketChannel)1 method for local servers and the other for external connections.line 275
public void initialize(HyperConnectionHandler tHandler, int tNodeNumber, SocketChannel tSocketChannel)For external connections.line 351
void returnMsg(HyperNodeWriteVector tVector)1 statement(s); calls writeVectorReturnList.dlStore(), writeVectorReturnList.notifyAll().line 574
void returnMsg(HyperNodeReadVector tVector)3 statement(s); calls readVectorReturnList.dlStore(), readVectorReturnList.notifyAll().line 585
public void saveNode()1 statement(s); calls saveNode().line 232
public void saveNode(int tInt)23 statement(s); calls HyperConnectionHandler.out(), socket.toString(), remoteAddress.toString(), socketChannel.toString(), parentConnectionHandler.toString() ….line 237
public int sendIO(HyperLinkedList tVectorList)Asynchronous Send HyperNodeWriteVector listline 473
public int sendIO(byte data)7 statement(s); calls getWriteVector(), tByteBuffer.clear(), tByteBuffer.put(), tByteBuffer.flip(), parentOutputHandler.writeAddList.dlStore() ….line 541
public int sendIO(byte[] data, int tLen)7 statement(s); calls getWriteVector(), tWriteVector.writeBuffer.clear(), tWriteVector.writeBuffer.put(), tWriteVector.writeBuffer.limit(), tWriteVector.writeBuffer.position() ….line 416
void setSocketDefaults()1 statement(s); calls socket.setSoTimeout(), socket.setTcpNoDelay(), socket.setSoLinger(), socket.setReuseAddress(), socket.setKeepAlive() ….line 784
public void showBufferInfo(ByteBuffer tBuffer)6 statement(s); calls tBuffer.capacity(), tBuffer.limit(), tBuffer.position(), tBuffer.remaining().line 774
public String toString()11 statement(s); calls sb.append(), stateMachine.toString(), getNodeBits(), remoteAddress.toString(), remoteInetAddress.toString() …; creates StringBuilder.
Overrides Object.toString()
line 829

Inherited members

Non-private members inherited from HyperView superclasses and not overridden or hidden here.

From Linkable (7 fields, 2 methods)

Fields: attachment, index, linkFlags, name, next, parentList, prev

Methods: inList(), setName(String)

Examples

Real usage taken from elsewhere in the HyperView 3.2 source (file and line shown; source path src/com/multiversesocial/hyperview/).

instantiation — HyperConnectionHandler.java, line 996

  996  tempNode = new HyperConnectionNode(this,masterNodeList.items,
  997   (ServerSocketChannel)tNextReady);

declaration — DisconnectTimer.java, line 85

   85  HyperConnectionNode tHyperConnectionNode = null;

declaration — HyperChannel.java, line 24

   24  static HyperConnectionNode channelNode;
Hits--