class KFileViewItem

Provides information about a file that has been examined with KDir. More...

Definition#include <kfileviewitem.h>
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods

Public Static Methods

Protected Methods


Detailed Description

Provides information about a file that has been examined with KDir.

KFileViewItem (const KUDSEntry &)

Construct a KFileViewItem object from a KDirEntry.

KFileViewItem (const KFileViewItem &)

Copy a KFileViewItem.

KFileViewItem (const QString& dir, const QString& name, bool delaystat = false)

Constructs a "little" KFileViewItem (just for local files)

~KFileViewItem ()

Destroy the KFileViewItem object.

KFileViewItem & operator= (const KFileViewItem &)

Copy a KFileViewItem.

bool isDir ()
[const]

Returns true if this file is a directory.

QString name ()
[const]

Returns the name of the file

Note: If this object does not refer to a real file (broken symlink), it will return QString::null

QPixmap pixmap ( KIconLoader::Size size )
[const]

Returns an icon for this file. It will return the icon according to the mimetype of this file, when you have called @see mimeType() once. Otherwise, it will return a default icon.

Parameters:
sizespecifies the size of the icon. The default icon is only available in small size, so far.

QPixmap pixmap ()
[const]

Returns a pixmap for this file. The only semantic difference to the other pixmap() method is that the last used Pixmap-size will be used. E.g. if you call pixmap( KIconLoader::Large ) once, you can refer to this pixmap thru this method without specifying the size. The default size is KIconLoader::Small

QString date ()
[const]

Returns a string of the date of the file.

time_t mTime ()
[const]

Returns the modification time of the file.

QString access ()
[const]

Returns the access permissions for the file as a string.

QString owner ()
[const]

Returns the owner of the file.

QString group ()
[const]

Returns the group of the file.

uint size ()
[const]

Returns the size of the file.

bool permission (uint permissionSpec)

Returns true if the specified permission flag is set.

bool isReadable ()
[const]

Return true if the file is readable

QString mimeType ()

Returns the mimetype, e.g. "image/png" When this method is called the first time, it will also search for the correct icon according to this mimetype. The next call to

See also: pixmap(), will, return, this, correct, pixmap.

void cleanup ()
[static]

frees the static allocated ressources (user information from /etc/passwd and /etc/group)