Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QFileInfoPrivate Class Reference

#include <qfileinfo_p.h>

+ Inheritance diagram for QFileInfoPrivate:
+ Collaboration diagram for QFileInfoPrivate:

Public Types

enum  {
  CachedFileFlags = 0x01 , CachedLinkTypeFlag = 0x02 , CachedBundleTypeFlag = 0x04 , CachedSize = 0x08 ,
  CachedATime = 0x10 , CachedBTime = 0x20 , CachedMCTime = 0x40 , CachedMTime = 0x80 ,
  CachedPerms = 0x100
}
 

Public Member Functions

 QFileInfoPrivate ()
 
 QFileInfoPrivate (const QFileInfoPrivate &copy)
 
 QFileInfoPrivate (const QString &file)
 
 QFileInfoPrivate (const QFileSystemEntry &file, const QFileSystemMetaData &data)
 
 QFileInfoPrivate (const QFileSystemEntry &file, const QFileSystemMetaData &data, std::unique_ptr< QAbstractFileEngine > engine)
 
void clearFlags () const
 
void clear ()
 
uint getFileFlags (QAbstractFileEngine::FileFlags) const
 
QDateTimegetFileTime (QFile::FileTime) const
 
QString getFileName (QAbstractFileEngine::FileName) const
 
QString getFileOwner (QAbstractFileEngine::FileOwner own) const
 
bool getCachedFlag (uint c) const
 
void setCachedFlag (uint c) const
 
template<typename Ret , typename FSLambda , typename EngineLambda >
Ret checkAttribute (Ret defaultValue, QFileSystemMetaData::MetaDataFlags fsFlags, FSLambda fsLambda, EngineLambda engineLambda) const
 
template<typename Ret , typename FSLambda , typename EngineLambda >
Ret checkAttribute (QFileSystemMetaData::MetaDataFlags fsFlags, FSLambda fsLambda, EngineLambda engineLambda) const
 
- Public Member Functions inherited from QSharedData
 QSharedData () noexcept
 Constructs a QSharedData object with a reference count of 0.
 
 QSharedData (const QSharedData &) noexcept
 Constructs a QSharedData object with reference count 0.
 
QSharedDataoperator= (const QSharedData &)=delete
 
 ~QSharedData ()=default
 

Public Attributes

QFileSystemEntry fileEntry
 
QFileSystemMetaData metaData
 
std::unique_ptr< QAbstractFileEngine > const fileEngine
 
QString fileNames [QAbstractFileEngine::NFileNames]
 
QString fileOwners [2]
 
QDateTime fileTimes [4]
 
uint cachedFlags: 30
 
bool const isDefaultConstructed: 1
 
bool cache_enabled: 1
 
uint fileFlags
 
qint64 fileSize
 
- Public Attributes inherited from QSharedData
QAtomicInt ref
 

Detailed Description

Definition at line 32 of file qfileinfo_p.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
CachedFileFlags 
CachedLinkTypeFlag 
CachedBundleTypeFlag 
CachedSize 
CachedATime 
CachedBTime 
CachedMCTime 
CachedMTime 
CachedPerms 

Definition at line 35 of file qfileinfo_p.h.

Constructor & Destructor Documentation

◆ QFileInfoPrivate() [1/5]

QFileInfoPrivate::QFileInfoPrivate ( )
inline

Definition at line 48 of file qfileinfo_p.h.

◆ QFileInfoPrivate() [2/5]

QFileInfoPrivate::QFileInfoPrivate ( const QFileInfoPrivate & copy)
inline

Definition at line 54 of file qfileinfo_p.h.

◆ QFileInfoPrivate() [3/5]

QFileInfoPrivate::QFileInfoPrivate ( const QString & file)
inline

Definition at line 67 of file qfileinfo_p.h.

◆ QFileInfoPrivate() [4/5]

QFileInfoPrivate::QFileInfoPrivate ( const QFileSystemEntry & file,
const QFileSystemMetaData & data )
inline

Definition at line 80 of file qfileinfo_p.h.

References fileEngine, and metaData.

◆ QFileInfoPrivate() [5/5]

QFileInfoPrivate::QFileInfoPrivate ( const QFileSystemEntry & file,
const QFileSystemMetaData & data,
std::unique_ptr< QAbstractFileEngine > engine )
inline

Definition at line 95 of file qfileinfo_p.h.

Member Function Documentation

◆ checkAttribute() [1/2]

template<typename Ret , typename FSLambda , typename EngineLambda >
Ret QFileInfoPrivate::checkAttribute ( QFileSystemMetaData::MetaDataFlags fsFlags,
FSLambda fsLambda,
EngineLambda engineLambda ) const
inline

Definition at line 164 of file qfileinfo_p.h.

References checkAttribute().

+ Here is the call graph for this function:

◆ checkAttribute() [2/2]

template<typename Ret , typename FSLambda , typename EngineLambda >
Ret QFileInfoPrivate::checkAttribute ( Ret defaultValue,
QFileSystemMetaData::MetaDataFlags fsFlags,
FSLambda fsLambda,
EngineLambda engineLambda ) const
inline

Definition at line 149 of file qfileinfo_p.h.

References cache_enabled, fileEngine, fileEntry, QFileSystemEngine::fillMetaData(), QFileSystemMetaData::hasFlags(), isDefaultConstructed, and metaData.

Referenced by checkAttribute().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ clear()

void QFileInfoPrivate::clear ( )
inline

Definition at line 115 of file qfileinfo_p.h.

References clear(), QFileSystemMetaData::clear(), QString::clear(), clearFlags(), fileNames, fileOwners, i, metaData, and QAbstractFileEngine::NFileNames.

Referenced by clear().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ clearFlags()

void QFileInfoPrivate::clearFlags ( ) const
inline

Definition at line 109 of file qfileinfo_p.h.

References cachedFlags, fileEngine, fileFlags, QAbstractFileEngine::Refresh, and void.

Referenced by clear(), and getFileTime().

+ Here is the caller graph for this function:

◆ getCachedFlag()

bool QFileInfoPrivate::getCachedFlag ( uint c) const
inline

Definition at line 143 of file qfileinfo_p.h.

References cache_enabled, and cachedFlags.

Referenced by getFileFlags(), and getFileTime().

+ Here is the caller graph for this function:

◆ getFileFlags()

uint QFileInfoPrivate::getFileFlags ( QAbstractFileEngine::FileFlags request) const

◆ getFileName()

◆ getFileOwner()

QString QFileInfoPrivate::getFileOwner ( QAbstractFileEngine::FileOwner own) const

Definition at line 75 of file qfileinfo.cpp.

References cache_enabled, fileEngine, fileEntry, fileOwners, metaData, QAbstractFileEngine::OwnerGroup, QAbstractFileEngine::OwnerUser, QFileSystemEngine::resolveGroupName(), QFileSystemEngine::resolveUserName(), and ret.

+ Here is the call graph for this function:

◆ getFileTime()

QDateTime & QFileInfoPrivate::getFileTime ( QFile::FileTime request) const

Definition at line 160 of file qfileinfo.cpp.

References cache_enabled, CachedATime, CachedBTime, CachedMCTime, CachedMTime, clearFlags(), QFileDevice::FileAccessTime, QFileDevice::FileBirthTime, fileEngine, QFileDevice::FileMetadataChangeTime, QFileDevice::FileModificationTime, fileTimes, getCachedFlag(), Q_ASSERT, request, and setCachedFlag().

+ Here is the call graph for this function:

◆ setCachedFlag()

void QFileInfoPrivate::setCachedFlag ( uint c) const
inline

Definition at line 145 of file qfileinfo_p.h.

References cache_enabled, and cachedFlags.

Referenced by getFileFlags(), and getFileTime().

+ Here is the caller graph for this function:

Member Data Documentation

◆ cache_enabled

bool QFileInfoPrivate::cache_enabled

◆ cachedFlags

uint QFileInfoPrivate::cachedFlags
mutable

Definition at line 138 of file qfileinfo_p.h.

Referenced by clearFlags(), getCachedFlag(), getFileFlags(), and setCachedFlag().

◆ fileEngine

std::unique_ptr<QAbstractFileEngine> const QFileInfoPrivate::fileEngine

◆ fileEntry

QFileSystemEntry QFileInfoPrivate::fileEntry

Definition at line 129 of file qfileinfo_p.h.

Referenced by checkAttribute(), getFileOwner(), and QFileInfo::makeAbsolute().

◆ fileFlags

uint QFileInfoPrivate::fileFlags
mutable

Definition at line 141 of file qfileinfo_p.h.

Referenced by clearFlags(), and getFileFlags().

◆ fileNames

QString QFileInfoPrivate::fileNames[QAbstractFileEngine::NFileNames]
mutable

Definition at line 134 of file qfileinfo_p.h.

Referenced by clear().

◆ fileOwners

QString QFileInfoPrivate::fileOwners[2]
mutable

Definition at line 135 of file qfileinfo_p.h.

Referenced by clear(), and getFileOwner().

◆ fileSize

qint64 QFileInfoPrivate::fileSize
mutable

Definition at line 142 of file qfileinfo_p.h.

◆ fileTimes

QDateTime QFileInfoPrivate::fileTimes[4]
mutable

Definition at line 136 of file qfileinfo_p.h.

Referenced by getFileTime().

◆ isDefaultConstructed

bool const QFileInfoPrivate::isDefaultConstructed

Definition at line 139 of file qfileinfo_p.h.

Referenced by checkAttribute(), and QFileInfo::makeAbsolute().

◆ metaData

QFileSystemMetaData QFileInfoPrivate::metaData
mutable

Definition at line 130 of file qfileinfo_p.h.

Referenced by QFileInfoPrivate(), checkAttribute(), clear(), and getFileOwner().


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