Solid
opticaldisc.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef SOLID_OPTICALDISC_H
00021 #define SOLID_OPTICALDISC_H
00022
00023 #include <solid/solid_export.h>
00024
00025 #include <solid/storagevolume.h>
00026
00027 namespace Solid
00028 {
00029 class OpticalDiscPrivate;
00030 class Device;
00031
00037 class SOLID_EXPORT OpticalDisc : public StorageVolume
00038 {
00039 Q_OBJECT
00040 Q_ENUMS(ContentType DiscType)
00041 Q_FLAGS(ContentTypes)
00042 Q_PROPERTY(ContentTypes availableContent READ availableContent)
00043 Q_PROPERTY(DiscType discType READ discType)
00044 Q_PROPERTY(bool appendable READ isAppendable)
00045 Q_PROPERTY(bool blank READ isBlank)
00046 Q_PROPERTY(bool rewritable READ isRewritable)
00047 Q_PROPERTY(qulonglong capacity READ capacity)
00048 Q_DECLARE_PRIVATE(OpticalDisc)
00049 friend class Device;
00050
00051 public:
00061 enum ContentType { Audio = 0x01, Data = 0x02, VideoCd = 0x04, SuperVideoCd = 0x08, VideoDvd = 0x10 };
00062
00066 Q_DECLARE_FLAGS(ContentTypes, ContentType)
00067
00068
00090 enum DiscType { UnknownDiscType = -1,
00091 CdRom, CdRecordable, CdRewritable, DvdRom, DvdRam,
00092 DvdRecordable, DvdRewritable,
00093 DvdPlusRecordable, DvdPlusRewritable,
00094 DvdPlusRecordableDuallayer, DvdPlusRewritableDuallayer,
00095 BluRayRom, BluRayRecordable, BluRayRewritable,
00096 HdDvdRom, HdDvdRecordable, HdDvdRewritable };
00097
00098
00099 private:
00108 explicit OpticalDisc(QObject *backendObject);
00109
00110 public:
00114 virtual ~OpticalDisc();
00115
00116
00123 static Type deviceInterfaceType() { return DeviceInterface::OpticalDisc; }
00124
00125
00132 ContentTypes availableContent() const;
00133
00139 DiscType discType() const;
00140
00146 bool isAppendable() const;
00147
00153 bool isBlank() const;
00154
00162 bool isRewritable() const;
00163
00170 qulonglong capacity() const;
00171 };
00172 }
00173
00174 Q_DECLARE_OPERATORS_FOR_FLAGS(Solid::OpticalDisc::ContentTypes)
00175
00176 #endif