summaryrefslogtreecommitdiffstats
path: root/src/remoteobjects/qremoteobjectsourceio.cpp
diff options
context:
space:
mode:
authorSona Kurazyan <sona.kurazyan@qt.io>2021-06-01 15:25:01 +0200
committerSona Kurazyan <sona.kurazyan@qt.io>2021-06-17 16:01:57 +0200
commitdd1a09d3a2406736e76bf3065b1895b24d9b402e (patch)
tree0b2647f7e033838cd914d5e0aeff4f1a23019ee9 /src/remoteobjects/qremoteobjectsourceio.cpp
parentbf1356479b3b2be598b3f46e8be2c05b29af945c (diff)
Rename the classes for adding a custom transport support
Added QtRO prefix to IoDeviceBase, ServerIoDevice and ClientIoDevice classes. These classes are exported and can be used externally for supporting a custom transport by deriving from them and implementing the virtual methods. Added the prefix also to ExternalIoDevice, to keep the naming consistent. Pick-to: 6.2 Change-Id: I64845cff55687a127d2c43de03ecc65ac9bd321b Reviewed-by: Brett Stottlemyer <bstottle@ford.com> Reviewed-by: MΓ₯rten Nordheim <marten.nordheim@qt.io>
Diffstat (limited to 'src/remoteobjects/qremoteobjectsourceio.cpp')
-rw-r--r--src/remoteobjects/qremoteobjectsourceio.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/remoteobjects/qremoteobjectsourceio.cpp b/src/remoteobjects/qremoteobjectsourceio.cpp
index b651de2..b59fa6d 100644
--- a/src/remoteobjects/qremoteobjectsourceio.cpp
+++ b/src/remoteobjects/qremoteobjectsourceio.cpp
@@ -155,7 +155,7 @@ void QRemoteObjectSourceIo::unregisterSource(QRemoteObjectSourceBase *source)
void QRemoteObjectSourceIo::onServerDisconnect(QObject *conn)
{
- IoDeviceBase *connection = qobject_cast<IoDeviceBase*>(conn);
+ QtROIoDeviceBase *connection = qobject_cast<QtROIoDeviceBase*>(conn);
m_connections.remove(connection);
qRODebug(this) << "OnServerDisconnect";
@@ -173,7 +173,7 @@ void QRemoteObjectSourceIo::onServerDisconnect(QObject *conn)
void QRemoteObjectSourceIo::onServerRead(QObject *conn)
{
// Assert the invariant here conn is of type QIODevice
- IoDeviceBase *connection = qobject_cast<IoDeviceBase*>(conn);
+ QtROIoDeviceBase *connection = qobject_cast<QtROIoDeviceBase*>(conn);
QRemoteObjectPacketTypeEnum packetType;
do {
@@ -294,17 +294,17 @@ void QRemoteObjectSourceIo::handleConnection()
{
qRODebug(this) << "handleConnection" << m_connections;
- ServerIoDevice *conn = m_server->nextPendingConnection();
+ QtROServerIoDevice *conn = m_server->nextPendingConnection();
newConnection(conn);
}
-void QRemoteObjectSourceIo::newConnection(IoDeviceBase *conn)
+void QRemoteObjectSourceIo::newConnection(QtROIoDeviceBase *conn)
{
m_connections.insert(conn);
- connect(conn, &IoDeviceBase::readyRead, this, [this, conn]() {
+ connect(conn, &QtROIoDeviceBase::readyRead, this, [this, conn]() {
onServerRead(conn);
});
- connect(conn, &IoDeviceBase::disconnected, this, [this, conn]() {
+ connect(conn, &QtROIoDeviceBase::disconnected, this, [this, conn]() {
onServerDisconnect(conn);
});