LibrePCB Developers Documentation
FileSystem Class Referenceabstract

Base class / interface for all file system implementations. More...

#include <filesystem.h>

+ Inheritance diagram for FileSystem:
+ Collaboration diagram for FileSystem:

Public Member Functions

 FileSystem (QObject *parent=nullptr) noexcept
 
virtual ~FileSystem () noexcept
 
virtual FilePath getAbsPath (const QString &path="") const noexcept=0
 
virtual QStringList getDirs (const QString &path="") const noexcept=0
 
virtual QStringList getFiles (const QString &path="") const noexcept=0
 
virtual bool fileExists (const QString &path) const noexcept=0
 
virtual QByteArray read (const QString &path) const =0
 
virtual void write (const QString &path, const QByteArray &content)=0
 
virtual void removeFile (const QString &path)=0
 
virtual void removeDirRecursively (const QString &path="")=0
 

Detailed Description

Base class / interface for all file system implementations.

Constructor & Destructor Documentation

◆ FileSystem()

FileSystem ( QObject *  parent = nullptr)
inlinenoexcept

◆ ~FileSystem()

virtual ~FileSystem ( )
inlinevirtualnoexcept
+ Here is the call graph for this function:

Member Function Documentation

◆ getAbsPath()

virtual FilePath getAbsPath ( const QString &  path = "") const
pure virtualnoexcept

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ getDirs()

virtual QStringList getDirs ( const QString &  path = "") const
pure virtualnoexcept

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ getFiles()

virtual QStringList getFiles ( const QString &  path = "") const
pure virtualnoexcept

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ fileExists()

virtual bool fileExists ( const QString &  path) const
pure virtualnoexcept

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ read()

virtual QByteArray read ( const QString &  path) const
pure virtual

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ write()

virtual void write ( const QString &  path,
const QByteArray &  content 
)
pure virtual

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ removeFile()

virtual void removeFile ( const QString &  path)
pure virtual

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

◆ removeDirRecursively()

virtual void removeDirRecursively ( const QString &  path = "")
pure virtual

Implemented in TransactionalFileSystem, and TransactionalDirectory.

+ Here is the caller graph for this function:

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