Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
XFILE::CVideoDatabaseDirectory Class Reference

#include <VideoDatabaseDirectory.h>

Inheritance diagram for XFILE::CVideoDatabaseDirectory:
XFILE::IDirectory

Public Member Functions

 CVideoDatabaseDirectory (void)
 
 ~CVideoDatabaseDirectory (void) override
 
bool GetDirectory (const CURL &url, CFileItemList &items) override
 Get the items of the directory strPath.
 
bool Exists (const CURL &url) override
 Check for directory existence.
 
bool AllowAll () const override
 Whether to allow all files/folders to be listed.
 
void ClearDirectoryCache (const std::string &strDirectory)
 
bool ContainsMovies (const std::string &path)
 
- Public Member Functions inherited from XFILE::IDirectory
 IDirectory ()
 
virtual ~IDirectory (void)
 
virtual float GetProgress () const
 Retrieve the progress of the current directory fetch (if possible).
 
virtual void CancelDirectory ()
 Cancel the current directory fetch (if possible).
 
virtual bool Create (const CURL &url)
 Create the directory.
 
virtual bool Remove (const CURL &url)
 Removes the directory.
 
virtual bool RemoveRecursive (const CURL &url)
 Recursively removes the directory.
 
virtual bool IsAllowed (const CURL &url) const
 Whether this file should be listed.
 
virtual DIR_CACHE_TYPE GetCacheType (const CURL &url) const
 How this directory should be cached.
 
void SetMask (const std::string &strMask)
 Set a mask of extensions for the files in the directory.
 
void SetFlags (int flags)
 Set the flags for this directory handler.
 
bool ProcessRequirements ()
 Process additional requirements before the directory fetch is performed. Some directory fetches may require authentication, keyboard input etc. The IDirectory subclass should call GetKeyboardInput, SetErrorDialog or RequireAuthentication and then return false from the GetDirectory method. CDirectory will then prompt for input from the user, before re-calling the GetDirectory method.
 
virtual bool Resolve (CFileItem &item) const
 Resolves a given item to a playable item.
 

Static Public Member Functions

static VIDEODATABASEDIRECTORY::NODE_TYPE GetDirectoryChildType (const std::string &strPath)
 
static VIDEODATABASEDIRECTORY::NODE_TYPE GetDirectoryType (const std::string &strPath)
 
static VIDEODATABASEDIRECTORY::NODE_TYPE GetDirectoryParentType (const std::string &strPath)
 
static bool GetQueryParams (const std::string &strPath, VIDEODATABASEDIRECTORY::CQueryParams &params)
 
static bool IsAllItem (const std::string &strDirectory)
 
static bool GetLabel (const std::string &strDirectory, std::string &strLabel)
 
static std::string GetIcon (const std::string &strDirectory)
 
static bool CanCache (const std::string &path)
 
- Static Public Member Functions inherited from XFILE::IDirectory
static void RegisterProfileManager (const CProfileManager &profileManager)
 
static void UnregisterProfileManager ()
 

Additional Inherited Members

- Protected Member Functions inherited from XFILE::IDirectory
bool GetKeyboardInput (const CVariant &heading, std::string &input, bool hiddenInput=false)
 Prompt the user for some keyboard input Call this method from the GetDirectory method to retrieve additional input from the user. If this function returns false then no input has been received, and the GetDirectory call should return false.
 
void SetErrorDialog (const CVariant &heading, const CVariant &line1, const CVariant &line2=0, const CVariant &line3=0)
 Show an error dialog on failure of GetDirectory call Call this method from the GetDirectory method to set an error message to be shown to the user.
 
void RequireAuthentication (const CURL &url)
 Prompt the user for authentication of a URL. Call this method from the GetDirectory method when authentication is required from the user, before returning false from the GetDirectory call. The user will be prompted for authentication, and GetDirectory will be re-called.
 
- Protected Attributes inherited from XFILE::IDirectory
std::string m_strFileMask
 Holds the file mask specified by SetMask()
 
int m_flags
 Directory flags - see DIR_FLAG.
 
CVariant m_requirements
 
- Static Protected Attributes inherited from XFILE::IDirectory
static const CProfileManagerm_profileManager = nullptr
 

Constructor & Destructor Documentation

◆ CVideoDatabaseDirectory()

CVideoDatabaseDirectory::CVideoDatabaseDirectory ( void )
default

◆ ~CVideoDatabaseDirectory()

CVideoDatabaseDirectory::~CVideoDatabaseDirectory ( void )
overridedefault

Member Function Documentation

◆ AllowAll()

bool XFILE::CVideoDatabaseDirectory::AllowAll ( ) const
inlineoverridevirtual

Whether to allow all files/folders to be listed.

Returns
Returns true if all files/folder should be listed.

Reimplemented from XFILE::IDirectory.

◆ CanCache()

bool CVideoDatabaseDirectory::CanCache ( const std::string & path)
static

◆ ClearDirectoryCache()

void CVideoDatabaseDirectory::ClearDirectoryCache ( const std::string & strDirectory)

◆ ContainsMovies()

bool CVideoDatabaseDirectory::ContainsMovies ( const std::string & path)

◆ Exists()

bool CVideoDatabaseDirectory::Exists ( const CURL & url)
overridevirtual

Check for directory existence.

Parameters
urlDirectory to check.
Returns
Returns true, if directory exists
See also
CDirectoryFactory

Reimplemented from XFILE::IDirectory.

◆ GetDirectory()

bool CVideoDatabaseDirectory::GetDirectory ( const CURL & url,
CFileItemList & items )
overridevirtual

Get the items of the directory strPath.

Parameters
urlDirectory to read.
itemsRetrieves the directory entries.
Returns
Returns true, if successful.
See also
CDirectoryFactory

Implements XFILE::IDirectory.

◆ GetDirectoryChildType()

NODE_TYPE CVideoDatabaseDirectory::GetDirectoryChildType ( const std::string & strPath)
static

◆ GetDirectoryParentType()

NODE_TYPE CVideoDatabaseDirectory::GetDirectoryParentType ( const std::string & strPath)
static

◆ GetDirectoryType()

NODE_TYPE CVideoDatabaseDirectory::GetDirectoryType ( const std::string & strPath)
static

◆ GetIcon()

std::string CVideoDatabaseDirectory::GetIcon ( const std::string & strDirectory)
static

◆ GetLabel()

bool CVideoDatabaseDirectory::GetLabel ( const std::string & strDirectory,
std::string & strLabel )
static

◆ GetQueryParams()

bool CVideoDatabaseDirectory::GetQueryParams ( const std::string & strPath,
VIDEODATABASEDIRECTORY::CQueryParams & params )
static

◆ IsAllItem()

bool CVideoDatabaseDirectory::IsAllItem ( const std::string & strDirectory)
static

The documentation for this class was generated from the following files: