// -*- Mode: C++; indent-tabs-mode: nil; tab-width: 2 -*-
/*
* Copyright (C) 2012 Canonical Ltd
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 3 as
* published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*
* Authored by: Andrea Azzarone
*/
#ifndef UNITYSHELL_VOLUME_H
#define UNITYSHELL_VOLUME_H
#include
#include
#include
#include
namespace unity
{
namespace launcher
{
class Volume : public sigc::trackable
{
public:
typedef std::shared_ptr Ptr;
Volume() = default;
virtual ~Volume() = default;
virtual bool CanBeEjected() const = 0;
virtual bool CanBeFormatted() const = 0;
virtual bool CanBeRemoved() const = 0;
virtual bool CanBeStopped() const = 0;
virtual std::string GetName() const = 0;
virtual std::string GetIconName() const = 0;
virtual std::string GetIdentifier() const = 0;
virtual std::string GetUnixDevicePath() const = 0;
virtual std::string GetUri() const = 0;
virtual bool HasSiblings() const = 0;
virtual bool IsMounted() const = 0;
virtual void Eject() = 0;
virtual void Mount() = 0;
virtual void StopDrive() = 0;
virtual void Unmount() = 0;
sigc::signal changed;
sigc::signal removed;
sigc::signal mounted;
sigc::signal unmounted;
sigc::signal ejected;
sigc::signal stopped;
private:
Volume(Volume const&) = delete;
Volume& operator=(Volume const&) = delete;
};
}
}
#endif