MCPcopy Create free account
hub / github.com/KDAB/GammaRay / create

Method create

client/clientdevice.cpp:30–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28ClientDevice::~ClientDevice() = default;
29
30ClientDevice *ClientDevice::create(const QUrl &url, QObject *parent)
31{
32 ClientDevice *device = nullptr;
33 if (url.scheme() == QLatin1String("tcp"))
34 device = new TcpClientDevice(parent);
35 else if (url.scheme() == QLatin1String("local"))
36 device = new LocalClientDevice(parent);
37
38 if (!device) {
39 qWarning() << "Unsupported transport protocol:" << url.toString();
40 return nullptr;
41 }
42
43 device->m_serverAddress = url;
44 return device;
45}
46
47void ClientDevice::setTryAgain(int tries)
48{

Callers 7

dataMethod · 0.45
testQtQuickProviderMethod · 0.45
testIntegrationMethod · 0.45
testQmlListPropertyMethod · 0.45
testAttachedPropertyMethod · 0.45
testJSValueMethod · 0.45

Calls

no outgoing calls

Tested by 6

testQtQuickProviderMethod · 0.36
testIntegrationMethod · 0.36
testQmlListPropertyMethod · 0.36
testAttachedPropertyMethod · 0.36
testJSValueMethod · 0.36