public abstract class BaseConnection extends Object implements ClientConnection
| Modifier and Type | Field and Description |
|---|---|
protected org.slf4j.Logger |
logger |
protected long |
messageId |
| Modifier | Constructor and Description |
|---|---|
protected |
BaseConnection()
Default constructor that initializes logging and a single threaded EventManager.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
beforeSendMessage(ClientMessage message)
Called before logging the beginning of message processing.
|
protected abstract Object |
doSendMessage(ClientMessage message)
The worker method invoked to process message.
|
long |
getProcessedMessagesCount()
Returns a count of processed messages since the beginning of life of this
connector.
|
Object |
sendMessage(ClientMessage message)
Invokes 'beforeSendMessage' on self, then invokes 'doSendMessage'.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetServerEventBridgeprotected BaseConnection()
public Object sendMessage(ClientMessage message) throws CayenneRuntimeException
sendMessage in interface ClientConnectionCayenneRuntimeExceptionpublic long getProcessedMessagesCount()
protected abstract void beforeSendMessage(ClientMessage message) throws CayenneRuntimeException
CayenneRuntimeExceptionprotected abstract Object doSendMessage(ClientMessage message) throws CayenneRuntimeException
CayenneRuntimeExceptionCopyright © 2001–2023 Apache Cayenne. All rights reserved.