#ifndef IMEDIALIBRARY_H #define IMEDIALIBRARY_H #include #include #include class IAlbum; class IAlbumTrack; class IFile; class ILabel; class IMetadataService; class IShow; class IShowEpisode; typedef std::shared_ptr FilePtr; typedef std::shared_ptr LabelPtr; typedef std::shared_ptr AlbumPtr; typedef std::shared_ptr AlbumTrackPtr; typedef std::shared_ptr ShowPtr; typedef std::shared_ptr ShowEpisodePtr; class IMediaLibrary { public: virtual ~IMediaLibrary() {} virtual bool initialize( const std::string& dbPath ) = 0; virtual FilePtr addFile( const std::string& path ) = 0; virtual FilePtr file( const std::string& path ) = 0; virtual bool deleteFile( const std::string& mrl ) = 0; virtual bool deleteFile( FilePtr file ) = 0; virtual LabelPtr createLabel( const std::string& label ) = 0; virtual bool deleteLabel( const std::string& label ) = 0; virtual bool deleteLabel( LabelPtr label ) = 0; virtual bool files( std::vector& res ) = 0; virtual AlbumPtr album( const std::string& id3Tag ) = 0; virtual AlbumPtr createAlbum( const std::string& id3Tag ) = 0; virtual ShowPtr show( const std::string& name ) = 0; virtual ShowPtr createShow( const std::string& name ) = 0; virtual void addMetadataService( IMetadataService* service ) = 0; }; class MediaLibraryFactory { public: static IMediaLibrary* create(); }; #endif // IMEDIALIBRARY_H