QAbstractFileEngine Class Reference

#include <qabstractfileengine.h>

Class Description

Definition at line 63 of file qabstractfileengine.h.

+ Inheritance diagram for QAbstractFileEngine:

Classes

class  ExtensionOption
 
class  ExtensionReturn
 
class  MapExtensionOption
 
class  MapExtensionReturn
 
class  UnMapExtensionOption
 

Public Types

enum  FileFlag {
  ReadOwnerPerm = 0x4000, WriteOwnerPerm = 0x2000, ExeOwnerPerm = 0x1000, ReadUserPerm = 0x0400,
  WriteUserPerm = 0x0200, ExeUserPerm = 0x0100, ReadGroupPerm = 0x0040, WriteGroupPerm = 0x0020,
  ExeGroupPerm = 0x0010, ReadOtherPerm = 0x0004, WriteOtherPerm = 0x0002, ExeOtherPerm = 0x0001,
  LinkType = 0x10000, FileType = 0x20000, DirectoryType = 0x40000, BundleType = 0x80000,
  HiddenFlag = 0x0100000, LocalDiskFlag = 0x0200000, ExistsFlag = 0x0400000, RootFlag = 0x0800000,
  Refresh = 0x1000000, PermsMask = 0x0000FFFF, TypesMask = 0x000F0000, FlagsMask = 0x0FF00000,
  FileInfoAll = FlagsMask | PermsMask | TypesMask
}
 
enum  FileName {
  DefaultName, BaseName, PathName, AbsoluteName,
  AbsolutePathName, LinkName, CanonicalName, CanonicalPathName,
  BundleName, NFileNames = 9
}
 
enum  FileOwner { OwnerUser, OwnerGroup }
 
enum  FileTime { CreationTime, ModificationTime, AccessTime }
 
enum  Extension { AtEndExtension, FastReadLineExtension, MapExtension, UnMapExtension }
 
typedef QAbstractFileEngineIterator Iterator
 

Public Member Functions

virtual ~QAbstractFileEngine ()
 
virtual bool open (QIODevice::OpenMode openMode)
 
virtual bool close ()
 
virtual bool flush ()
 
virtual qint64 size () const
 
virtual qint64 pos () const
 
virtual bool seek (qint64 pos)
 
virtual bool isSequential () const
 
virtual bool remove ()
 
virtual bool copy (const QString &newName)
 
virtual bool rename (const QString &newName)
 
virtual bool link (const QString &newName)
 
virtual bool mkdir (const QString &dirName, bool createParentDirectories) const
 
virtual bool rmdir (const QString &dirName, bool recurseParentDirectories) const
 
virtual bool setSize (qint64 size)
 
virtual bool caseSensitive () const
 
virtual bool isRelativePath () const
 
virtual QStringList entryList (QDir::Filters filters, const QStringList &filterNames) const
 
virtual FileFlags fileFlags (FileFlags type=FileInfoAll) const
 
virtual bool setPermissions (uint perms)
 
virtual QString fileName (FileName file=DefaultName) const
 
virtual uint ownerId (FileOwner) const
 
virtual QString owner (FileOwner) const
 
virtual QDateTime fileTime (FileTime time) const
 
virtual void setFileName (const QString &file)
 
virtual int handle () const
 
bool atEnd () const
 
uchar * map (qint64 offset, qint64 size, QFile::MemoryMapFlags flags)
 
bool unmap (uchar *ptr)
 
virtual IteratorbeginEntryList (QDir::Filters filters, const QStringList &filterNames)
 
virtual IteratorendEntryList ()
 
virtual qint64 read (char *data, qint64 maxlen)
 
virtual qint64 readLine (char *data, qint64 maxlen)
 
virtual qint64 write (const char *data, qint64 len)
 
QFile::FileError error () const
 
QString errorString () const
 
virtual bool extension (Extension extension, const ExtensionOption *option=0, ExtensionReturn *output=0)
 
virtual bool supportsExtension (Extension extension) const
 

Static Public Member Functions

static QAbstractFileEnginecreate (const QString &fileName)
 

Protected Member Functions

void setError (QFile::FileError error, const QString &str)
 
 QAbstractFileEngine ()
 
 QAbstractFileEngine (QAbstractFileEnginePrivate &)
 

Protected Attributes

QScopedPointer< QAbstractFileEnginePrivate > d_ptr
 

Member Typedef Documentation

Definition at line 147 of file qabstractfileengine.h.

Member Enumeration Documentation

enum FileFlag
Enumerator
ReadOwnerPerm 
WriteOwnerPerm 
ExeOwnerPerm 
ReadUserPerm 
WriteUserPerm 
ExeUserPerm 
ReadGroupPerm 
WriteGroupPerm 
ExeGroupPerm 
ReadOtherPerm 
WriteOtherPerm 
ExeOtherPerm 
LinkType 
FileType 
DirectoryType 
BundleType 
HiddenFlag 
LocalDiskFlag 
ExistsFlag 
RootFlag 
Refresh 
PermsMask 
TypesMask 
FlagsMask 
FileInfoAll 

Definition at line 66 of file qabstractfileengine.h.

66  {
67  //perms (overlaps the QFile::Permission)
68  ReadOwnerPerm = 0x4000, WriteOwnerPerm = 0x2000, ExeOwnerPerm = 0x1000,
69  ReadUserPerm = 0x0400, WriteUserPerm = 0x0200, ExeUserPerm = 0x0100,
70  ReadGroupPerm = 0x0040, WriteGroupPerm = 0x0020, ExeGroupPerm = 0x0010,
71  ReadOtherPerm = 0x0004, WriteOtherPerm = 0x0002, ExeOtherPerm = 0x0001,
72 
73  //types
74  LinkType = 0x10000,
75  FileType = 0x20000,
76  DirectoryType = 0x40000,
77  BundleType = 0x80000,
78 
79  //flags
80  HiddenFlag = 0x0100000,
81  LocalDiskFlag = 0x0200000,
82  ExistsFlag = 0x0400000,
83  RootFlag = 0x0800000,
84  Refresh = 0x1000000,
85 
86  //masks
87  PermsMask = 0x0000FFFF,
88  TypesMask = 0x000F0000,
89  FlagsMask = 0x0FF00000,
91  };
enum FileOwner
Enumerator
OwnerUser 
OwnerGroup 

Definition at line 106 of file qabstractfileengine.h.

enum FileTime
Enumerator
CreationTime 
ModificationTime 
AccessTime 

Definition at line 110 of file qabstractfileengine.h.

Constructor & Destructor Documentation

virtual ~QAbstractFileEngine ( )
virtual
QAbstractFileEngine ( )
protected
QAbstractFileEngine ( QAbstractFileEnginePrivate &  )
protected

Member Function Documentation

virtual bool open ( QIODevice::OpenMode  openMode)
virtual

Reimplemented in QFSFileEngine.

virtual bool close ( )
virtual

Reimplemented in QFSFileEngine.

virtual bool flush ( )
virtual

Reimplemented in QFSFileEngine.

virtual qint64 size ( ) const
virtual

Reimplemented in QFSFileEngine.

virtual qint64 pos ( ) const
virtual

Reimplemented in QFSFileEngine.

virtual bool seek ( qint64  pos)
virtual

Reimplemented in QFSFileEngine.

virtual bool isSequential ( ) const
virtual

Reimplemented in QFSFileEngine.

virtual bool remove ( )
virtual

Reimplemented in QFSFileEngine.

virtual bool copy ( const QString newName)
virtual

Reimplemented in QFSFileEngine.

virtual bool rename ( const QString newName)
virtual

Reimplemented in QFSFileEngine.

virtual bool link ( const QString newName)
virtual

Reimplemented in QFSFileEngine.

virtual bool mkdir ( const QString dirName,
bool  createParentDirectories 
) const
virtual

Reimplemented in QFSFileEngine.

virtual bool rmdir ( const QString dirName,
bool  recurseParentDirectories 
) const
virtual

Reimplemented in QFSFileEngine.

virtual bool setSize ( qint64  size)
virtual

Reimplemented in QFSFileEngine.

virtual bool caseSensitive ( ) const
virtual

Reimplemented in QFSFileEngine.

virtual bool isRelativePath ( ) const
virtual

Reimplemented in QFSFileEngine.

virtual QStringList entryList ( QDir::Filters  filters,
const QStringList filterNames 
) const
virtual

Reimplemented in QFSFileEngine.

virtual FileFlags fileFlags ( FileFlags  type = FileInfoAll) const
virtual

Reimplemented in QFSFileEngine.

virtual bool setPermissions ( uint  perms)
virtual

Reimplemented in QFSFileEngine.

virtual QString fileName ( FileName  file = DefaultName) const
virtual

Reimplemented in QFSFileEngine.

virtual uint ownerId ( FileOwner  ) const
virtual

Reimplemented in QFSFileEngine.

virtual QString owner ( FileOwner  ) const
virtual

Reimplemented in QFSFileEngine.

virtual QDateTime fileTime ( FileTime  time) const
virtual

Reimplemented in QFSFileEngine.

virtual void setFileName ( const QString file)
virtual

Reimplemented in QFSFileEngine.

virtual int handle ( ) const
virtual

Reimplemented in QFSFileEngine.

bool atEnd ( ) const
uchar* map ( qint64  offset,
qint64  size,
QFile::MemoryMapFlags  flags 
)
bool unmap ( uchar *  ptr)
virtual Iterator* beginEntryList ( QDir::Filters  filters,
const QStringList filterNames 
)
virtual

Reimplemented in QFSFileEngine.

virtual Iterator* endEntryList ( )
virtual

Reimplemented in QFSFileEngine.

virtual qint64 read ( char *  data,
qint64  maxlen 
)
virtual

Reimplemented in QFSFileEngine.

virtual qint64 readLine ( char *  data,
qint64  maxlen 
)
virtual

Reimplemented in QFSFileEngine.

virtual qint64 write ( const char *  data,
qint64  len 
)
virtual

Reimplemented in QFSFileEngine.

QFile::FileError error ( ) const
QString errorString ( ) const
virtual bool extension ( Extension  extension,
const ExtensionOption option = 0,
ExtensionReturn output = 0 
)
virtual

Reimplemented in QFSFileEngine.

virtual bool supportsExtension ( Extension  extension) const
virtual

Reimplemented in QFSFileEngine.

static QAbstractFileEngine* create ( const QString fileName)
static
void setError ( QFile::FileError  error,
const QString str 
)
protected

Member Data Documentation

QScopedPointer<QAbstractFileEnginePrivate> d_ptr
protected

Definition at line 197 of file qabstractfileengine.h.


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