Solid

ifaces/opticaldisc.h
1/*
2 SPDX-FileCopyrightText: 2006 Kevin Ottens <ervin@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 SOLID_IFACES_OPTICALDISC_H
8#define SOLID_IFACES_OPTICALDISC_H
9
10#include <solid/devices/ifaces/storagevolume.h>
11#include <solid/opticaldisc.h>
12
13namespace Solid
14{
15namespace Ifaces
16{
17/**
18 * This device interface is available on optical discs.
19 *
20 * An optical disc is a volume that can be inserted in a cdrom drive.
21 */
22class OpticalDisc : virtual public StorageVolume
23{
24public:
25 /**
26 * Destroys an OpticalDisc object.
27 */
28 ~OpticalDisc() override;
29
30 /**
31 * Retrieves the content types this disc contains (audio, video,
32 * data...).
33 *
34 * @return the flag set indicating the available contents
35 */
37
38 /**
39 * Retrieves the disc type (cdr, cdrw...).
40 *
41 * @return the disc type
42 */
44
45 /**
46 * Indicates if it's possible to write additional data to the disc.
47 *
48 * @return true if the disc is appendable, false otherwise
49 */
50 virtual bool isAppendable() const = 0;
51
52 /**
53 * Indicates if the disc is blank.
54 *
55 * @return true if the disc is blank, false otherwise
56 */
57 virtual bool isBlank() const = 0;
58
59 /**
60 * Indicates if the disc is rewritable.
61 *
62 * A disc is rewritable if you can write on it several times.
63 *
64 * @return true if the disc is rewritable, false otherwise
65 */
66 virtual bool isRewritable() const = 0;
67
68 /**
69 * Retrieves the disc capacity (that is the maximum size of a
70 * volume could have on this disc).
71 *
72 * @return the capacity of the disc in bytes
73 */
74 virtual qulonglong capacity() const = 0;
75};
76}
77}
78
79Q_DECLARE_INTERFACE(Solid::Ifaces::OpticalDisc, "org.kde.Solid.Ifaces.OpticalDisc/0.1")
80
81#endif
This device interface is available on optical discs.
virtual bool isBlank() const =0
Indicates if the disc is blank.
virtual bool isRewritable() const =0
Indicates if the disc is rewritable.
virtual Solid::OpticalDisc::ContentTypes availableContent() const =0
Retrieves the content types this disc contains (audio, video, data...).
virtual Solid::OpticalDisc::DiscType discType() const =0
Retrieves the disc type (cdr, cdrw...).
virtual qulonglong capacity() const =0
Retrieves the disc capacity (that is the maximum size of a volume could have on this disc).
virtual bool isAppendable() const =0
Indicates if it's possible to write additional data to the disc.
~OpticalDisc() override
Destroys an OpticalDisc object.
This device interface is available on volume devices.
DiscType
This enum type defines the type of optical disc it can be.
The single responsibility of this class is to create arguments valid for logind Inhibit call.
Definition fakebattery.h:16
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:17:12 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.