Qyoto  4.0.5
Qyoto is a C# language binding for Qt
 All Classes Namespaces Functions Variables Typedefs Enumerations Properties
QtCore.QFSFileEngine Class Reference

The QFSFileEngine class implements Qt's default file engine. More...

Inheritance diagram for QtCore.QFSFileEngine:
Collaboration diagram for QtCore.QFSFileEngine:

Public Member Functions

 QFSFileEngine ()
 
 
 QFSFileEngine (string file)
 
 
override void CreateProxy ()
 
override
QAbstractFileEngineIterator 
BeginEntryList (QDir.Filter filters, System.Collections.Generic.List< string > filterNames)
 
 
override bool CaseSensitive ()
 
 
override bool Close ()
 
 
override bool Copy (string newName)
 
 
override
QAbstractFileEngineIterator 
EndEntryList ()
 
override
System.Collections.Generic.List
< string > 
EntryList (QDir.Filter filters, System.Collections.Generic.List< string > filterNames)
 
 
new bool extension (QAbstractFileEngine.Extension extension)
 
 
new bool extension (QAbstractFileEngine.Extension extension, QAbstractFileEngine.ExtensionOption option=null)
 
 
override bool extension (QAbstractFileEngine.Extension extension, QAbstractFileEngine.ExtensionOption option=null, QAbstractFileEngine.ExtensionReturn output=null)
 
 
override
QAbstractFileEngine.FileFlag 
FileFlags (QAbstractFileEngine.FileFlag type)
 
 
override string fileName (QAbstractFileEngine.FileName file)
 
 
override QDateTime fileTime (QAbstractFileEngine.FileTime time)
 
 
override bool Flush ()
 
 
override int Handle ()
 
 
override bool IsRelativePath ()
 
 
override bool IsSequential ()
 
 
override bool Link (string newName)
 
 
override bool Mkdir (string dirName, bool createParentDirectories)
 
 
override bool Open (QIODevice.OpenModeFlag openMode)
 
 
new bool Open (QIODevice.OpenModeFlag flags, int fd)
 
 
new bool Open (QIODevice.OpenModeFlag flags, int fd, QFile.FileHandleFlag handleFlags)
 
 
override string Owner (QAbstractFileEngine.FileOwner arg1)
 
 
override uint OwnerId (QAbstractFileEngine.FileOwner arg1)
 
 
override long Pos ()
 
 
override long Read (Pointer< sbyte > data, long maxlen)
 
 
override long ReadLine (Pointer< sbyte > data, long maxlen)
 
 
override bool Remove ()
 
 
override bool Rename (string newName)
 
 
override bool Rmdir (string dirName, bool recurseParentDirectories)
 
 
override bool Seek (long arg1)
 
 
override void SetFileName (string file)
 
 
override bool SetPermissions (uint perms)
 
 
override bool SetSize (long size)
 
 
override long Size ()
 
 
override bool SupportsExtension (QAbstractFileEngine.Extension extension)
 
 
override long Write (string data, long len)
 
 
new void Dispose ()
 
- Public Member Functions inherited from QtCore.QAbstractFileEngine
new bool AtEnd ()
 
 
new QFile.FileError Error ()
 
 
new string ErrorString ()
 
 
new bool extension (QAbstractFileEngine.Extension extension)
 
 
new bool extension (QAbstractFileEngine.Extension extension, QAbstractFileEngine.ExtensionOption option=null)
 
 
new string fileName ()
 
 
new Pointer< byte > Map (long offset, long size, QFile.MemoryMapFlags flags)
 
 
new bool Unmap (Pointer< byte > ptr)
 
 
new void Dispose ()
 

Static Public Member Functions

static string CurrentPath (string path="")
 
 
static
System.Collections.Generic.List
< QFileInfo
Drives ()
 
 
static string HomePath ()
 
 
static string RootPath ()
 
 
static bool SetCurrentPath (string path)
 
 
static string TempPath ()
 
 
- Static Public Member Functions inherited from QtCore.QAbstractFileEngine
static QAbstractFileEngine Create (string fileName)
 
 

Protected Member Functions

 QFSFileEngine (System.Type dummy)
 
- Protected Member Functions inherited from QtCore.QAbstractFileEngine
 QAbstractFileEngine (System.Type dummy)
 
 QAbstractFileEngine ()
 
 
new void SetError (QFile.FileError error, string str)
 
 

Additional Inherited Members

- Public Types inherited from QtCore.QAbstractFileEngine
enum  Extension { AtEndExtension = 0, FastReadLineExtension = 1, MapExtension = 2, UnMapExtension = 3 }
  More...
 
enum  FileFlag {
  BundleType = 524288, DirectoryType = 262144, ExeGroupPerm = 16, ExeOtherPerm = 1,
  ExeOwnerPerm = 4096, ExeUserPerm = 256, ExistsFlag = 4194304, FileInfoAll = 268435455,
  FileType = 131072, FlagsMask = 267386880, HiddenFlag = 1048576, LinkType = 65536,
  LocalDiskFlag = 2097152, PermsMask = 65535, ReadGroupPerm = 64, ReadOtherPerm = 4,
  ReadOwnerPerm = 16384, ReadUserPerm = 1024, Refresh = 16777216, RootFlag = 8388608,
  TypesMask = 983040, WriteGroupPerm = 32, WriteOtherPerm = 2, WriteOwnerPerm = 8192,
  WriteUserPerm = 512
}
  More...
 
enum  FileName {
  AbsoluteName = 3, AbsolutePathName = 4, BaseName = 1, BundleName = 8,
  CanonicalName = 6, CanonicalPathName = 7, DefaultName = 0, LinkName = 5,
  NFileNames = 9, PathName = 2
}
  More...
 
enum  FileOwner { OwnerGroup = 1, OwnerUser = 0 }
  More...
 
enum  FileTime { AccessTime = 2, CreationTime = 0, ModificationTime = 1 }
  More...
 
- Protected Attributes inherited from QtCore.QAbstractFileEngine
SmokeInvocation interceptor
 
- Properties inherited from QtCore.QAbstractFileEngine
virtual System.IntPtr SmokeObject [get, set]
 

Detailed Description

The QFSFileEngine class implements Qt's default file engine.

This class is part of the file engine framework in Qt. If you only want to access files or directories, use QFile, QFileInfo or QDir instead.

QFSFileEngine is the default file engine for accessing regular files. It is provided for convenience; by subclassing this class, you can alter its behavior slightly, without having to write a complete QAbstractFileEngine subclass. To install your custom file engine, you must also subclass QAbstractFileEngineHandler and create an instance of your handler.

It can also be useful to create a QFSFileEngine object directly if you need to use the local file system inside QAbstractFileEngine::create(), in order to avoid recursion (as higher-level classes tend to call QAbstractFileEngine::create()).

Constructor & Destructor Documentation

QtCore.QFSFileEngine.QFSFileEngine ( System.Type  dummy)
protected
QtCore.QFSFileEngine.QFSFileEngine ( )

Constructs a QFSFileEngine.

QtCore.QFSFileEngine.QFSFileEngine ( string  file)

Constructs a QFSFileEngine for the file name file.

Member Function Documentation

override QAbstractFileEngineIterator QtCore.QFSFileEngine.BeginEntryList ( QDir.Filter  filters,
System.Collections.Generic.List< string >  filterNames 
)
virtual

Returns an instance of a QAbstractFileEngineIterator using filters for entry filtering and filterNames for name filtering. This function is called by QDirIterator to initiate directory iteration.

QDirIterator takes ownership of the returned instance, and deletes it when it's done.

See also QDirIterator.

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.CaseSensitive ( )
virtual

Reimplemented from QAbstractFileEngine::caseSensitive().

Returns true for Windows, false for Unix.

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Close ( )
virtual

Reimplemented from QAbstractFileEngine::close().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Copy ( string  newName)
virtual

Reimplemented from QAbstractFileEngine::copy().

For windows, copy the file to file copyName.

Not implemented for Unix.

Reimplemented from QtCore.QAbstractFileEngine.

override void QtCore.QFSFileEngine.CreateProxy ( )
virtual

Reimplemented from QtCore.QAbstractFileEngine.

static string QtCore.QFSFileEngine.CurrentPath ( string  path = "")
static

For Unix, returns the current working directory for the file engine.

For Windows, returns the canonicalized form of the current path used by the file engine for the drive specified by fileName. On Windows, each drive has its own current directory, so a different path is returned for file names that include different drive names (e.g. A: or C:).

See also setCurrentPath().

new void QtCore.QFSFileEngine.Dispose ( )
static System.Collections.Generic.List<QFileInfo> QtCore.QFSFileEngine.Drives ( )
static

For Windows, returns the list of drives in the file system as a list of QFileInfo objects. On unix, Mac OS X and Windows CE, only the root path is returned. On Windows, this function returns all drives (A:, C:, D:, etc.).

For Unix, the list contains just the root path "/".

override QAbstractFileEngineIterator QtCore.QFSFileEngine.EndEntryList ( )
virtual

Reimplemented from QtCore.QAbstractFileEngine.

override System.Collections.Generic.List<string> QtCore.QFSFileEngine.EntryList ( QDir.Filter  filters,
System.Collections.Generic.List< string >  filterNames 
)
virtual

Requests that a list of all the files matching the filters list based on the filterNames in the file engine's directory are returned.

Should return an empty list if the file engine refers to a file rather than a directory, or if the directory is unreadable or does not exist or if nothing matches the specifications.

This virtual function must be reimplemented by all subclasses.

See also setFileName().

Reimplemented from QtCore.QAbstractFileEngine.

new bool QtCore.QFSFileEngine.extension ( QAbstractFileEngine.Extension  extension)

Reimplemented from QAbstractFileEngine::extension().

new bool QtCore.QFSFileEngine.extension ( QAbstractFileEngine.Extension  extension,
QAbstractFileEngine.ExtensionOption  option = null 
)

Reimplemented from QAbstractFileEngine::extension().

override bool QtCore.QFSFileEngine.extension ( QAbstractFileEngine.Extension  extension,
QAbstractFileEngine.ExtensionOption  option = null,
QAbstractFileEngine.ExtensionReturn  output = null 
)
virtual

Reimplemented from QAbstractFileEngine::extension().

Reimplemented from QtCore.QAbstractFileEngine.

override QAbstractFileEngine.FileFlag QtCore.QFSFileEngine.FileFlags ( QAbstractFileEngine.FileFlag  type)
virtual

Reimplemented from QAbstractFileEngine::fileFlags().

Reimplemented from QtCore.QAbstractFileEngine.

override string QtCore.QFSFileEngine.fileName ( QAbstractFileEngine.FileName  file)
virtual

Reimplemented from QAbstractFileEngine::fileName().

See also setFileName().

Reimplemented from QtCore.QAbstractFileEngine.

override QDateTime QtCore.QFSFileEngine.fileTime ( QAbstractFileEngine.FileTime  time)
virtual

Reimplemented from QAbstractFileEngine::fileTime().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Flush ( )
virtual

Reimplemented from QAbstractFileEngine::flush().

Reimplemented from QtCore.QAbstractFileEngine.

override int QtCore.QFSFileEngine.Handle ( )
virtual

Reimplemented from QAbstractFileEngine::handle().

Reimplemented from QtCore.QAbstractFileEngine.

static string QtCore.QFSFileEngine.HomePath ( )
static

Returns the home path of the current user.

See also rootPath().

override bool QtCore.QFSFileEngine.IsRelativePath ( )
virtual

Reimplemented from QAbstractFileEngine::isRelativePath().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.IsSequential ( )
virtual

Reimplemented from QAbstractFileEngine::isSequential().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Link ( string  newName)
virtual

Reimplemented from QAbstractFileEngine::link().

Creates a link from the file currently specified by fileName() to newName. What a link is depends on the underlying filesystem (be it a shortcut on Windows or a symbolic link on Unix). Returns true if successful; otherwise returns false.

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Mkdir ( string  dirName,
bool  createParentDirectories 
)
virtual

Reimplemented from QAbstractFileEngine::mkdir().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Open ( QIODevice.OpenModeFlag  openMode)
virtual

Reimplemented from QAbstractFileEngine::open().

Reimplemented from QtCore.QAbstractFileEngine.

new bool QtCore.QFSFileEngine.Open ( QIODevice.OpenModeFlag  flags,
int  fd 
)

Reimplemented from QAbstractFileEngine::open().

new bool QtCore.QFSFileEngine.Open ( QIODevice.OpenModeFlag  flags,
int  fd,
QFile.FileHandleFlag  handleFlags 
)

Reimplemented from QAbstractFileEngine::open().

override string QtCore.QFSFileEngine.Owner ( QAbstractFileEngine.FileOwner  arg1)
virtual

Reimplemented from QAbstractFileEngine::owner().

Reimplemented from QtCore.QAbstractFileEngine.

override uint QtCore.QFSFileEngine.OwnerId ( QAbstractFileEngine.FileOwner  arg1)
virtual

Reimplemented from QAbstractFileEngine::ownerId().

In Unix, if stat() is successful, the uid is returned if own is the owner. Otherwise the gid is returned. If stat() is unsuccessful, -2 is reuturned.

For Windows, -2 is always returned.

Reimplemented from QtCore.QAbstractFileEngine.

override long QtCore.QFSFileEngine.Pos ( )
virtual

Reimplemented from QAbstractFileEngine::pos().

Reimplemented from QtCore.QAbstractFileEngine.

override long QtCore.QFSFileEngine.Read ( Pointer< sbyte >  data,
long  maxlen 
)
virtual

Reimplemented from QAbstractFileEngine::read().

Reimplemented from QtCore.QAbstractFileEngine.

override long QtCore.QFSFileEngine.ReadLine ( Pointer< sbyte >  data,
long  maxlen 
)
virtual

Reimplemented from QAbstractFileEngine::readLine().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Remove ( )
virtual

Reimplemented from QAbstractFileEngine::remove().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Rename ( string  newName)
virtual

Reimplemented from QAbstractFileEngine::rename().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.Rmdir ( string  dirName,
bool  recurseParentDirectories 
)
virtual

Reimplemented from QAbstractFileEngine::rmdir().

Reimplemented from QtCore.QAbstractFileEngine.

static string QtCore.QFSFileEngine.RootPath ( )
static

Returns the root path.

See also homePath().

override bool QtCore.QFSFileEngine.Seek ( long  arg1)
virtual

Reimplemented from QAbstractFileEngine::seek().

Reimplemented from QtCore.QAbstractFileEngine.

static bool QtCore.QFSFileEngine.SetCurrentPath ( string  path)
static

Sets the current path (e.g., for QDir), to path. Returns true if the new path exists; otherwise this function does nothing, and returns false.

See also currentPath().

override void QtCore.QFSFileEngine.SetFileName ( string  file)
virtual

Reimplemented from QAbstractFileEngine::setFileName().

See also fileName().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.SetPermissions ( uint  perms)
virtual

Reimplemented from QAbstractFileEngine::setPermissions().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.SetSize ( long  size)
virtual

Reimplemented from QAbstractFileEngine::setSize().

See also size().

Reimplemented from QtCore.QAbstractFileEngine.

override long QtCore.QFSFileEngine.Size ( )
virtual

Reimplemented from QAbstractFileEngine::size().

See also setSize().

Reimplemented from QtCore.QAbstractFileEngine.

override bool QtCore.QFSFileEngine.SupportsExtension ( QAbstractFileEngine.Extension  extension)
virtual

Reimplemented from QAbstractFileEngine::supportsExtension().

Reimplemented from QtCore.QAbstractFileEngine.

static string QtCore.QFSFileEngine.TempPath ( )
static

Returns the temporary path (i.e., a path in which it is safe to store temporary files).

override long QtCore.QFSFileEngine.Write ( string  data,
long  len 
)
virtual

Reimplemented from QAbstractFileEngine::write().

Reimplemented from QtCore.QAbstractFileEngine.