kodi
SMBDirectory.h
1 /*
2  * Copyright (C) 2005-2018 Team Kodi
3  * This file is part of Kodi - https://kodi.tv
4  *
5  * SPDX-License-Identifier: GPL-2.0-or-later
6  * See LICENSES/README.md for more information.
7  */
8 
9 #pragma once
10 
11 #include "MediaSource.h"
12 #include "SMBFile.h"
13 #include "filesystem/IDirectory.h"
14 
15 namespace XFILE
16 {
17 class CSMBDirectory : public IDirectory
18 {
19 public:
20  CSMBDirectory(void);
21  ~CSMBDirectory(void) override;
22  bool GetDirectory(const CURL& url, CFileItemList &items) override;
23  DIR_CACHE_TYPE GetCacheType(const CURL& url) const override { return DIR_CACHE_ONCE; }
24  bool Create(const CURL& url) override;
25  bool Exists(const CURL& url) override;
26  bool Remove(const CURL& url) override;
27 
28  int Open(const CURL &url);
29 
30 private:
31  int OpenDir(const CURL &url, std::string& strAuth);
32 };
33 }
bool Remove(const CURL &url) override
Removes the directory.
Definition: SMBDirectory.cpp:337
Interface to the directory on a file system.
Definition: IDirectory.h:51
Definition: Scraper.h:41
Represents a list of files.
Definition: FileItem.h:702
Definition: URL.h:21
bool GetDirectory(const CURL &url, CFileItemList &items) override
Get the items of the directory strPath.
Definition: SMBDirectory.cpp:58
bool Create(const CURL &url) override
Create the directory.
Definition: SMBDirectory.cpp:320
DIR_CACHE_TYPE GetCacheType(const CURL &url) const override
How this directory should be cached.
Definition: SMBDirectory.h:23
bool Exists(const CURL &url) override
Check for directory existence.
Definition: SMBDirectory.cpp:357
Definition: SMBDirectory.h:17