Commit d21a8761 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

IMedia: Introduce a dummy isAvailable method

This is meant to be then plugged with removable devices
parent 3d795426
......@@ -66,6 +66,7 @@ class IMedia
// This is likely to be used for album arts as well.
virtual const std::string& snapshot() = 0;
virtual unsigned int insertionDate() const = 0;
virtual bool isAvailable() const = 0;
};
#endif // IFILE_H
......@@ -232,6 +232,11 @@ unsigned int Media::insertionDate() const
return m_insertionDate;
}
bool Media::isAvailable() const
{
return true;
}
void Media::setSnapshot( const std::string& snapshot )
{
if ( m_snapshot == snapshot )
......
......@@ -93,6 +93,7 @@ class Media : public IMedia, public DatabaseHelpers<Media, policy::MediaTable>
virtual std::vector<AudioTrackPtr> audioTracks() override;
virtual const std::string& snapshot() override;
virtual unsigned int insertionDate() const override;
virtual bool isAvailable() const override;
void setSnapshot( const std::string& snapshot );
bool save();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment