MCPcopy Create free account
hub / github.com/Zetaphor/whatcable-linux / cableSpeedLabel

Function cableSpeedLabel

src/core/PDDecoder.cpp:21–31  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19}
20
21QString cableSpeedLabel(CableSpeed speed)
22{
23 switch (speed) {
24 case CableSpeed::USB20: return QStringLiteral("USB 2.0");
25 case CableSpeed::USB32Gen1: return QStringLiteral("USB 3.2 Gen 1 (5 Gbps)");
26 case CableSpeed::USB32Gen2: return QStringLiteral("USB 3.2 Gen 2 (10 Gbps)");
27 case CableSpeed::USB4Gen3: return QStringLiteral("USB4 Gen 3 (20/40 Gbps)");
28 case CableSpeed::USB4Gen4: return QStringLiteral("USB4 Gen 4 (40/80 Gbps)");
29 default: return QStringLiteral("Unknown");
30 }
31}
32
33int cableSpeedMaxGbps(CableSpeed speed)
34{

Callers 3

dataMethod · 0.85
fromTypeCPortMethod · 0.85
deviceToJsonFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected