Makefile: included all the new sources

blockingClientTCPTransport.cpp: implementation

blockingTCP.h:
* class BlockingTCPTransport:
  - added Context to ctor
  - added 'virtual' declaration to overrides
  - 'priority' is now 'int16'
* added class 'BlockingClientTCPTransport'

blockingTCPConnector.cpp: implementation

blockingTCPTransport.cpp:
* removed 'transportRegistry' added 'context'

blockingUDP.h:
* added missing override 'getIntrospectionRegistry'
* 'BlockingUDPConnector::_priority' is now 'int16' instead of 'short'

blockingUDPConnector.cpp:
* 'connect' parameter priority is now 'int16' instead of 'short'
* fixed and added error logging

remote.h:
* added 'TransportRegistry' forward declaration
* added 'Transport::getIntrospectionRegistry' prototype
* changed 'Connector::connect' prototype parameter 'priority': 'short'->'int16'
* added 'Context' interface
* added 'ReferenceCountingTransport' interface

transportRegistry.h:
* added 'Transport' forward declaration

testRemoteClientImpl.cpp:
* added '#include <transportRegistry.h>' to fix compile error
* lots of auto-format changes

transportRegistryTest.cpp:
*
This commit is contained in:
miha_vitorovic
2011-01-04 11:58:00 +01:00
parent 9b99f6f389
commit bd1a4e2634
11 changed files with 775 additions and 158 deletions
+6 -7
View File
@@ -62,9 +62,9 @@ namespace epics {
GrowingCircularBuffer<TransportSender*>* _monitorSendQueue;
};
BlockingTCPTransport::BlockingTCPTransport(SOCKET channel,
ResponseHandler* responseHandler, int receiveBufferSize,
short priority, TransportRegistry* transportRegistry) :
BlockingTCPTransport::BlockingTCPTransport(Context* context,
SOCKET channel, ResponseHandler* responseHandler,
int receiveBufferSize, int16 priority) :
_closed(false), _channel(channel), _remoteTransportRevision(0),
_remoteTransportReceiveBufferSize(MAX_TCP_RECV),
_remoteTransportSocketReceiveBufferSize(MAX_TCP_RECV),
@@ -86,8 +86,7 @@ namespace epics {
_rcvThreadId(NULL), _sendThreadId(NULL), _monitorSendQueue(
new GrowingCircularBuffer<TransportSender*> (100)),
_monitorSender(new MonitorSender(_monitorMutex,
_monitorSendQueue)), _transportRegistry(
transportRegistry) {
_monitorSendQueue)), _context(context) {
_socketBuffer = new ByteBuffer(max(MAX_TCP_RECV
+MAX_ENSURE_DATA_BUFFER_SIZE, receiveBufferSize));
@@ -124,7 +123,7 @@ namespace epics {
clearAndReleaseBuffer();
// add to registry
_transportRegistry->put(this);
_context->getTransportRegistry()->put(this);
}
BlockingTCPTransport::~BlockingTCPTransport() {
@@ -195,7 +194,7 @@ namespace epics {
_closed = true;
// remove from registry
_transportRegistry->remove(this);
_context->getTransportRegistry()->remove(this);
// clean resources
internalClose(force);