Solid

winblock.h
1/*
2 SPDX-FileCopyrightText: 2013 Patrick von Reth <vonreth@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5*/
6
7#ifndef WINBLOCK_H
8#define WINBLOCK_H
9
10#include "wininterface.h"
11#include <solid/devices/ifaces/block.h>
12
13namespace Solid
14{
15namespace Backends
16{
17namespace Win
18{
19class WinBlock : public WinInterface, virtual public Solid::Ifaces::Block
20{
23public:
24 WinBlock(WinDevice *device);
25 ~WinBlock();
26
27 virtual int deviceMajor() const;
28
29 virtual int deviceMinor() const;
30
31 virtual QString device() const;
32
33 static QSet<QString> getUdis();
34
35 static QString driveLetterFromUdi(const QString &udi);
36 static QString udiFromDriveLetter(const QString &drive);
37 static QString resolveVirtualDrive(const QString &drive);
38 static QSet<QString> updateUdiFromBitMask(const DWORD unitmask);
39 static QSet<QString> getFromBitMask(const DWORD unitmask);
40
41private:
42 static QMap<QString, QString> m_driveLetters;
43 static QMap<QString, QSet<QString>> m_driveUDIS;
44 static QMap<QString, QString> m_virtualDrives;
45
46 int m_major;
47 int m_minor;
48
49 static QStringList drivesFromMask(const DWORD unitmask);
50};
51
52}
53}
54}
55
56#endif // WINBLOCK_H
This device interface is available on block devices.
Q_INTERFACES(...)
Q_OBJECTQ_OBJECT
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 22 2024 12:01:49 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.