Class

colossus.core

ServerConnection

Related Doc: package core

Permalink

abstract class ServerConnection extends Connection

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. ServerConnection
  2. Connection
  3. WriteEndpoint
  4. ConnectionHandle
  5. ConnectionInfo
  6. WriteBuffer
  7. KeyInterestManager
  8. ChannelActions
  9. AnyRef
  10. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ServerConnection(id: Long, handler: ServerConnectionHandler, server: ServerRef, worker: WorkerRef)

    Permalink

Abstract Value Members

  1. abstract def channelClose(): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    ChannelActions
  2. abstract def channelHost(): InetAddress

    Permalink
    Attributes
    protected
    Definition Classes
    ChannelActions
  3. abstract def channelWrite(data: DataBuffer): Int

    Permalink

    Hook to perform that actual operation of writing to a channel

    Hook to perform that actual operation of writing to a channel

    Attributes
    protected
    Definition Classes
    ChannelActions
  4. abstract def finishConnect(): Unit

    Permalink
    Definition Classes
    ChannelActions
  5. abstract def keyInterestOps(ops: Int): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    ChannelActions
  6. abstract def status: ConnectionStatus

    Permalink

    Get the current connection status.

    Get the current connection status.

    Definition Classes
    ConnectionInfo

Concrete Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def bytesReceived: Long

    Permalink

    how many bytes have been received on the connection in total

    how many bytes have been received on the connection in total

    Definition Classes
    ConnectionConnectionInfo
  6. def bytesSent: Long

    Permalink
    Definition Classes
    WriteBuffer
  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def close(cause: DisconnectCause): Unit

    Permalink

    close is called with notify: false when reacting to the handler's termination NOTE - This is only called by the worker, because otherwise the worker does not know about the connection being closed

    close is called with notify: false when reacting to the handler's termination NOTE - This is only called by the worker, because otherwise the worker does not know about the connection being closed

    Definition Classes
    ServerConnectionConnection
  9. def completeDisconnect(): Unit

    Permalink

    The WriteBuffer calls this if it has been signaled to disconnect and finishes writing any existing partial buffer

    The WriteBuffer calls this if it has been signaled to disconnect and finishes writing any existing partial buffer

    Definition Classes
    Connection → WriteBuffer
  10. def disableReads(): Unit

    Permalink
    Definition Classes
    KeyInterestManager
  11. def disableWriteReady(): Unit

    Permalink
    Definition Classes
    KeyInterestManager
  12. def disconnect(): Unit

    Permalink

    Terminate the connection

    Terminate the connection

    Definition Classes
    ConnectionConnectionHandle
  13. def domain: String

    Permalink

    ABSTRACT MEMBERS *

    ABSTRACT MEMBERS *

    Definition Classes
    ServerConnectionConnection
  14. def enableReads(): Unit

    Permalink
    Definition Classes
    KeyInterestManager
  15. def enableWriteReady(): Unit

    Permalink
    Definition Classes
    KeyInterestManager
  16. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  17. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  18. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  19. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  20. def gracefulDisconnect(): Unit

    Permalink

    This should be called when it's time to disconnect the connection, but we wish to finish writing any existing partial buffer.

    This should be called when it's time to disconnect the connection, but we wish to finish writing any existing partial buffer. We do this because any levels higher up already consider any data in a partial buffer to be sent, so we don't want to disconnect until we fullfil that promise.

    Definition Classes
    WriteBuffer
  21. def handleRead(data: DataBuffer)(implicit time: Long): Unit

    Permalink
    Definition Classes
    Connection
  22. def handleWrite(data: DynamicOutBuffer): Boolean

    Permalink

    The main entry point for allowing a connection handler to write data to the connection.

    The main entry point for allowing a connection handler to write data to the connection. Handlers cannot write data whenever they please, instead they must initiate a write request. The worker then calls this method to fullfill the request and provide the handler with a DataOutBuffer to which it can write data.

    Definition Classes
    Connection
  23. def handler: ConnectionHandler

    Permalink
    Definition Classes
    Connection
  24. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  25. val id: Long

    Permalink

    The id of the underlying connection.

    The id of the underlying connection. This is different from a WorkerItem's id.

    Definition Classes
    ConnectionConnectionInfo
  26. def info(now: Long): ConnectionSnapshot

    Permalink
    Definition Classes
    Connection
  27. def isDataBuffered: Boolean

    Permalink
    Definition Classes
    WriteBuffer
  28. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  29. def isTimedOut(time: Long): Boolean

    Permalink
    Definition Classes
    ServerConnectionConnection
  30. def isTimedOut(maxIdleTime: Duration, currentTime: Long): Boolean

    Permalink
    Attributes
    protected
    Definition Classes
    Connection
  31. def isWritable: Boolean

    Permalink

    Returns true if data can be written to the connection.

    Returns true if data can be written to the connection. This will generally only return false if the write buffer is full or the connection has been terminated.

    Definition Classes
    ConnectionWriteEndpoint
  32. def lastTimeDataReceived: Long

    Permalink

    Returns a timestamp, in milliseconds of when the last time data was read on the connection

    Returns a timestamp, in milliseconds of when the last time data was read on the connection

    Definition Classes
    ConnectionConnectionInfo
  33. def lastTimeDataWritten: Long

    Permalink
    Definition Classes
    WriteBuffer
  34. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  35. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  36. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  37. val outgoing: Boolean

    Permalink
    Definition Classes
    ServerConnectionConnection
  38. def readsEnabled: Boolean

    Permalink
    Definition Classes
    KeyInterestManager
  39. def remoteAddress: Option[InetSocketAddress]

    Permalink

    The address of the remote host for this connection, if connected

    The address of the remote host for this connection, if connected

    Definition Classes
    ConnectionConnectionInfo
  40. def requestWrite(): Unit

    Permalink
    Definition Classes
    WriteBuffer
  41. val server: ServerRef

    Permalink
  42. def serverHandler: ServerConnectionHandler

    Permalink
  43. def setHandler(newHandler: ConnectionHandler): Unit

    Permalink

    replace the existing handler with a new one.

    replace the existing handler with a new one. The old handler is terminated with the Disconnect cause and connected is called on the new handler if the connection is connected. No action is taken if the connection is closed

    Definition Classes
    Connection
  44. def setKeyInterest(): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    KeyInterestManager
  45. val startTime: Long

    Permalink
    Definition Classes
    Connection
  46. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  47. def timeIdle(currentTime: Long): Long

    Permalink
    Definition Classes
    Connection
  48. def timeOpen: Long

    Permalink

    How long, in milliseconds, since the connection was opened

    How long, in milliseconds, since the connection was opened

    Definition Classes
    ConnectionConnectionInfo
  49. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  50. def unbindHandlerOnClose: Boolean

    Permalink
    Definition Classes
    ServerConnectionConnection
  51. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  52. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  53. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  54. val worker: WorkerRef

    Permalink

    Gets the worker this connection is bound to.

    Gets the worker this connection is bound to.

    Definition Classes
    ConnectionConnectionHandle
  55. def write(raw: DataBuffer): WriteStatus

    Permalink
    Attributes
    protected
    Definition Classes
    WriteBuffer
  56. def writeReadyEnabled: Boolean

    Permalink
    Definition Classes
    KeyInterestManager

Inherited from Connection

Inherited from WriteEndpoint

Inherited from ConnectionHandle

Inherited from ConnectionInfo

Inherited from WriteBuffer

Inherited from KeyInterestManager

Inherited from ChannelActions

Inherited from AnyRef

Inherited from Any

Ungrouped