Filer
Public Member Functions | List of all members
ExtendedAttributes Class Reference

The ExtendedAttributes class provides functionality to read and write extended attributes of a file. More...

#include <ExtendedAttributes.h>

Public Member Functions

 ExtendedAttributes (const QString &filePath)
 Constructs an ExtendedAttributes object for the specified file. More...
 
bool write (const QString &attributeName, const QByteArray &attributeValue)
 Writes an extended attribute for the file. More...
 
QByteArray read (const QString &attributeName)
 Reads the value of an extended attribute from the file. More...
 
bool clear (const QString &attributeName)
 

Detailed Description

The ExtendedAttributes class provides functionality to read and write extended attributes of a file.

Constructor & Destructor Documentation

◆ ExtendedAttributes()

ExtendedAttributes::ExtendedAttributes ( const QString &  filePath)

Constructs an ExtendedAttributes object for the specified file.

Parameters
filePathThe path of the file to work with.

Member Function Documentation

◆ read()

QByteArray ExtendedAttributes::read ( const QString &  attributeName)

Reads the value of an extended attribute from the file.

Parameters
attributeNameThe name of the attribute to read.
Returns
The value of the attribute, or an empty QByteArray if not found.

◆ write()

bool ExtendedAttributes::write ( const QString &  attributeName,
const QByteArray &  attributeValue 
)

Writes an extended attribute for the file.

Parameters
attributeNameThe name of the attribute.
attributeValueThe value of the attribute to be written.
Returns
True if the attribute was written successfully, false otherwise.

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