class KFileReader


Definition#include <kfilereader.h>
InheritsKURL (kdecore), QObject (kdecore)
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods

Signals

Protected Methods

Protected Slots

Protected Members

void  setURL (const KURL&)

[virtual]

Set the current url. An url without a protocol (file:/, ftp://) will be treated as a local directory and file:/ will be prepended.

void  setNameFilter (const QString&)

Set the current name filter.

uint  dirCount ()

[const]

Returns the number of directory entries expected.

uint  count ()

[const]

Returns the number of directory entries read.

void  listContents ()

Initiates reading the current directory or url. Returns the contents as a list of KFileViewItem objects matching the specified filter by emitting the signal contents. If we are working on a local directory this will be a blocking readdir(). If we are working on a remote url, we use KIO to list the contents. The contents() signal may be emitted more than once to supply you with KFileViewItems, up until the signal finished is emitted (and isFinished() returns true). If the contents are already cached, you will get the entire contents with just one contents() signal.

const KFileViewItemList &  currentContents ()

[const]

This gives you access to the current list of items. It is not guaranteed that this list is complete (e.g. during asynchronous reading of remote directories. Use only if really necessary. Normally, you should just use listContents and get the list via the signal contents. Never returns 0L.

bool  match (const QString& name)

[const]

Returns true if the name matches the filter.

bool  isRoot ()

[const]

Indicates if the path is empty

bool  isReadable ()

[const]

Indicates if the path is readable. That means, if there are entries to expect

void  setAutoUpdate ( bool b )

[virtual]

Enables/disables automatic updates, when a directory is changed (works only for local files, using KDirWatch). New files will be emitted via newFilesArrived, deleted files with filesDeleted Default is enabled.

void  urlChanged (const QString&)

[signal]

Emitted when the url is changed. It is NOT emitted, when you manually call setURL().

void  dirEntry (KFileViewItem *)

[signal]

Emitted when a directory entry that matches the filter is received.

void  error (int, const QString&)

[signal]

Emitted if a network transfer goes wrong.

void  contents (const KFileViewItemList &, bool ready)

[signal]

Emitted, if new files are queued

void  slotEntries (KIO::Job*, const KIO::UDSEntryList&)

[protected slot]

Called when a directory entry is received.

void  slotIOFinished ( KIO::Job * )

[protected slot]

Called when Job has finished the current network operation.


Generated by: root@porky.devel.redhat.com on Wed May 10 08:56:57 2000, using kdoc 2.0a35.