File indexing completed on 2024-05-12 04:41:11

0001 /* AtCore KDE Libary for 3D Printers
0002     SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
0003     SPDX-FileCopyrightText: 2016-2018 Chris Rizzitello <rizzitello@kde.org>
0004     SPDX-FileCopyrightText: 2016 Tomaz Canabrava <tcanabrava@kde.org>
0005     SPDX-FileCopyrightText: 2016-2018 Patrick José Pereira <patrickjp@kde.org>
0006 */
0007 
0008 #pragma once
0009 
0010 #include <QObject>
0011 
0012 #include "ifirmware.h"
0013 /**
0014  * @brief The TeacupPlugin class
0015  * Plugin for Teacup
0016  */
0017 class TeacupPlugin : public IFirmware
0018 {
0019     Q_OBJECT
0020     Q_PLUGIN_METADATA(IID "org.kde.atelier.core.firmware")
0021     Q_INTERFACES(IFirmware)
0022 
0023 public:
0024     /**
0025      * @brief Create new TeacupPlugin
0026      */
0027     TeacupPlugin();
0028     ~TeacupPlugin() = default;
0029 
0030     /**
0031      * @brief Check for plugin support of sd cards.
0032      * @return True if firmware plugin supports sd cards.
0033      */
0034     virtual bool isSdSupported() const override;
0035 
0036     /**
0037      * @brief Return Plugin name
0038      * @return Teacup
0039      */
0040     QString name() const override;
0041 
0042     /**
0043      * @brief Translate common commands to firmware specific command.
0044      * @param command: command to translate
0045      * @return firmware specific translated command
0046      */
0047     QByteArray translate(const QString &command) override;
0048 };