<class name="QFSFileEngine" doc="/** <p>The <a href="QFSFileEngine.html#QFSFileEngine(java.lang.String)"><tt>QFSFileEngine</tt></a> class implements Qt's default file engine.</p> <p>This class is part of the file engine framework in Qt. If you only want to access files or directories, use <a href="QFile.html"><tt>QFile</tt></a>, <a href="QFileInfo.html"><tt>QFileInfo</tt></a> or <a href="QDir.html"><tt>QDir</tt></a> instead.</p> <p><a href="QFSFileEngine.html#QFSFileEngine(java.lang.String)"><tt>QFSFileEngine</tt></a> 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 <a href="QAbstractFileEngine.html#QAbstractFileEngine()"><tt>QAbstractFileEngine</tt></a> subclass. To install your custom file engine, you must also subclass <a href="QAbstractFileEngineHandler.html"><tt>QAbstractFileEngineHandler</tt></a> and create an instance of your handler.</p> <p>It can also be useful to create a <a href="QFSFileEngine.html#QFSFileEngine(java.lang.String)"><tt>QFSFileEngine</tt></a> 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()).</p> */"> <method name="public QFSFileEngine()" doc="/** <p>Constructs a <a href="QFSFileEngine.html#QFSFileEngine(java.lang.String)"><tt>QFSFileEngine</tt></a>.</p> */"/> <method name="public QFSFileEngine(java.lang.String file)" doc="/** <p>Constructs a <a href="QFSFileEngine.html#QFSFileEngine(java.lang.String)"><tt>QFSFileEngine</tt></a> for the file name <tt>file</tt>.</p> */"/> <method name="public final com.trolltech.qt.core.QAbstractFileEngineIterator beginEntryList(com.trolltech.qt.core.QDir.Filters filters, java.util.List<java.lang.String> filterNames)" doc="/** <p>Returns an instance of a <a href="QAbstractFileEngineIterator.html"><tt>QAbstractFileEngineIterator</tt></a> using <tt>filters</tt> for entry filtering and <tt>filterNames</tt> for name filtering. This function is called by <a href="QDirIterator.html"><tt>QDirIterator</tt></a> to initiate directory iteration.</p> <p><a href="QDirIterator.html"><tt>QDirIterator</tt></a> takes ownership of the returned instance, and deletes it when it's done.</p> @see <a href="QDirIterator.html"><tt>QDirIterator</tt></a> */"/> <method name="public final com.trolltech.qt.core.QAbstractFileEngineIterator endEntryList()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public final boolean open(com.trolltech.qt.core.QIODevice.OpenMode flags, int fd)" doc="/** <p>Opens the file descriptor <tt>fd</tt> in <tt>flags</tt> mode. Returns true on success; otherwise returns false.</p> */"/> <method name="public boolean caseSensitive()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean close()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean copy(java.lang.String newName)" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public java.util.List<java.lang.String> entryList(com.trolltech.qt.core.QDir.Filters filters, java.util.List<java.lang.String> filterNames)" doc="/** <p>Requests that a list of all the files matching the <tt>filters</tt> list based on the <tt>filterNames</tt> in the file engine's directory are returned.</p> <p>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.</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> */"/> <method name="public com.trolltech.qt.core.QAbstractFileEngine.FileFlags fileFlags(com.trolltech.qt.core.QAbstractFileEngine.FileFlags type)" doc="/** <p>This function should return the set of OR'd flags that are true for the file engine's file, and that are in the <tt>type</tt>'s OR'd members.</p> <p>In your reimplementation you can use the <tt>type</tt> argument as an optimization hint and only return the OR'd set of members that are true and that match those in <tt>type</tt>; in other words you can ignore any members not mentioned in <tt>type</tt>, thus avoiding some potentially expensive lookups or system calls.</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> */"/> <method name="public java.lang.String fileName(com.trolltech.qt.core.QAbstractFileEngine.FileName file)" doc="/** <p>Return the file engine's current file name in the format specified by <tt>file</tt>.</p> <p>If you don't handle some <tt>FileName</tt> possibilities, return the file name set in <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> when an unhandled format is requested.</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> @see <a href="QAbstractFileEngine.html#FileName-enum"><tt>FileName</tt></a> */"/> <method name="public com.trolltech.qt.core.QDateTime fileTime(com.trolltech.qt.core.QAbstractFileEngine.FileTime time)" doc="/** <p>If <tt>time</tt> is <tt>CreationTime</tt>, return when the file was created. If <tt>time</tt> is <tt>ModificationTime</tt>, return when the file was most recently modified. If <tt>time</tt> is <tt>AccessTime</tt>, return when the file was most recently accessed (e.g&#x2e; read or written). If the time cannot be determined return QDateTime() (an invalid date time).</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> @see <a href="QDateTime.html"><tt>QDateTime</tt></a> @see <tt>QDateTime::isValid</tt> @see <a href="QAbstractFileEngine.html#FileTime-enum"><tt>FileTime</tt></a> */"/> <method name="public boolean flush()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public int handle()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean isRelativePath()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean isSequential()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean link(java.lang.String newName)" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean mkdir(java.lang.String dirName, boolean createParentDirectories)" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean open(com.trolltech.qt.core.QIODevice.OpenMode openMode)" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public java.lang.String owner(com.trolltech.qt.core.QAbstractFileEngine.FileOwner arg__1)" doc="/** <p>If <tt>arg__1</tt> is <tt>OwnerUser</tt> return the name of the user who owns the file. If <tt>arg__1</tt> is <tt>OwnerGroup</tt> return the name of the group that own the file. If you can't determine the owner return <a href="%2E%2E/porting4.html#qstring"><tt>QString</tt></a>.</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#ownerId(com.trolltech.qt.core.QAbstractFileEngine.FileOwner)"><tt>ownerId</tt></a> @see <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> @see <a href="QAbstractFileEngine.html#FileOwner-enum"><tt>FileOwner</tt></a> */"/> <method name="public int ownerId(com.trolltech.qt.core.QAbstractFileEngine.FileOwner arg__1)" doc="/** <p>If <tt>arg__1</tt> is <tt>OwnerUser</tt> return the ID of the user who owns the file. If <tt>arg__1</tt> is <tt>OwnerGroup</tt> return the ID of the group that own the file. If you can't determine the owner return -2.</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#owner(com.trolltech.qt.core.QAbstractFileEngine.FileOwner)"><tt>owner</tt></a> @see <a href="QFSFileEngine.html#setFileName(java.lang.String)"><tt>setFileName</tt></a> @see <a href="QAbstractFileEngine.html#FileOwner-enum"><tt>FileOwner</tt></a> */"/> <method name="public long pos()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public long read(com.trolltech.qt.QNativePointer data, long maxlen)" doc="/** <p>Reads a number of characters from the file into <tt>data</tt>. At most <tt>maxlen</tt> characters will be read.</p> <p>Returns -1 if a fatal error occurs, or 0 if there are no bytes to read.</p> */"/> <method name="public long readLine(com.trolltech.qt.QNativePointer data, long maxlen)" doc="/** <p>This function reads one line, terminated by a '\n' character, from the file info <tt>data</tt>. At most <tt>maxlen</tt> characters will be read. The end-of-line character is included.</p> */"/> <method name="public boolean remove()" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean rename(java.lang.String newName)" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean rmdir(java.lang.String dirName, boolean recurseParentDirectories)" doc="/** <p>This function is reimplemented for internal reasons.</p> */"/> <method name="public boolean seek(long arg__1)" doc="/** <p>Sets the file position to the given <tt>arg__1</tt>. Returns true if the position was successfully set; otherwise returns false.</p> <p>The offset is from the beginning of the file, unless the file is sequential.</p> @see <a href="QFSFileEngine.html#isSequential()"><tt>isSequential</tt></a> */"/> <method name="public void setFileName(java.lang.String file)" doc="/** <p>This function is reimplemented for internal reasons.</p> @see <a href="QFSFileEngine.html#fileName(com.trolltech.qt.core.QAbstractFileEngine.FileName)"><tt>fileName</tt></a> */"/> <method name="public boolean setPermissions(int perms)" doc="/** <p>Requests that the file's permissions be set to <tt>perms</tt>. The argument perms will be set to the OR-ed together combination of QAbstractFileEngine::FileInfo, with only the QAbstractFileEngine::PermsMask being honored. If the operations succceeds return true; otherwise return false;</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#size()"><tt>size</tt></a> */"/> <method name="public boolean setSize(long size)" doc="/** <p>Requests that the file be set to size <tt>size</tt>. If <tt>size</tt> is larger than the current file then it is filled with 0's, if smaller it is simply truncated. If the operations succceeds return true; otherwise return false;</p> <p>This virtual function must be reimplemented by all subclasses.</p> @see <a href="QFSFileEngine.html#size()"><tt>size</tt></a> */"/> <method name="public long size()" doc="/** <p>This function is reimplemented for internal reasons.</p> @see <a href="QFSFileEngine.html#setSize(long)"><tt>setSize</tt></a> */"/> <method name="public boolean supportsExtension(com.trolltech.qt.core.QAbstractFileEngine.Extension extension)" doc="/** <p>This virtual function returns true if the file engine supports <tt>extension</tt>; otherwise, false is returned. By default, no extensions are supported.</p> @see <tt>extension</tt> */"/> <method name="public long write(com.trolltech.qt.QNativePointer data, long len)" doc="/** <p>Writes <tt>len</tt> bytes from <tt>data</tt> to the file. Returns the number of characters written on success; otherwise returns -1.</p> */"/> <method name="public native static java.lang.String currentPath(java.lang.String path)" doc="/** <p>Returns the canonicalized form of the current path used by the file engine for the drive specified by <tt>path</tt>.</p> <p>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&#x2e; A: or C:).</p> @see <a href="QFSFileEngine.html#setCurrentPath(java.lang.String)"><tt>setCurrentPath</tt></a> */"/> <method name="public static java.lang.String currentPath()" doc="/** <p>Equivalent to <a href="QFSFileEngine.html#currentPath(java.lang.String)"><tt>currentPath</tt></a>(QString()). */"/> <method name="public native static java.util.List<com.trolltech.qt.core.QFileInfo> drives()" doc="/** <p>Returns the list of drives in the file system as a list of <a href="QFileInfo.html"><tt>QFileInfo</tt></a> objects. On unix and Mac OS X, only the root path is returned. On Windows, this function returns all drives (A:, C:, D:, etc.)&#x2e;</p> */"/> <method name="public native static java.lang.String homePath()" doc="/** <p>Returns the home path of the current user.</p> @see <a href="QFSFileEngine.html#rootPath()"><tt>rootPath</tt></a> */"/> <method name="public native static java.lang.String rootPath()" doc="/** <p>Returns the root path.</p> @see <a href="QFSFileEngine.html#homePath()"><tt>homePath</tt></a> */"/> <method name="public native static boolean setCurrentPath(java.lang.String path)" doc="/** <p>Sets the current path (e.g&#x2e;, for <a href="QDir.html"><tt>QDir</tt></a>), to <tt>path</tt>. Returns true if the new path exists; otherwise this function does nothing, and returns false.</p> @see <a href="QFSFileEngine.html#currentPath(java.lang.String)"><tt>currentPath</tt></a> */"/> <method name="public native static java.lang.String tempPath()" doc="/** <p>Returns the temporary path (i.e&#x2e;, a path in which it is safe to store temporary files).</p> */"/> </class>