| Classes - Annotated - Tree - Functions - Home - Structure

# QUrlInfo Class Reference

`#include <qurlinfo.h>`

List of all member functions.

## Public Members

- QUrlInfo ()
- QUrlInfo ( const QUrlOperator & path, const QString & file )
- QUrlInfo ( const QUrlInfo & ui )
- QUrlInfo ( const QString & name, int permissions, const QString & owner, const QString & group, uint size, const QDateTime & lastModified, const QDateTime & lastRead, bool isDir, bool isFile, bool isSymLink, bool isWritable, bool isReadable, bool isExecutable )
- QUrlInfo ( const QUrl & url, int permissions, const QString & owner, const QString & group, uint size, const QDateTime & lastModified, const QDateTime & lastRead, bool isDir, bool isFile, bool isSymLink, bool isWritable, bool isReadable, bool isExecutable )
- QUrlInfo& operator= ( const QUrlInfo & ui )
- virtual ~QUrlInfo ()
- virtual void setName ( const QString & name )
- virtual void setDir ( bool b )
- virtual void setFile ( bool b )
- virtual void setSymLink ( bool b )
- virtual void setOwner ( const QString & s )
- virtual void setGroup ( const QString & s )
- virtual void setSize ( uint s )
- virtual void setWritable ( bool b )
- virtual void setReadable ( bool b )
- virtual void setPermissions ( int p )
- virtual void setLastModified ( const QDateTime & dt )
- QString name () const
- int permissions () const
- QString owner () const
- QString group () const
- uint size () const
- QDateTime lastModified () const
- QDateTime lastRead () const
- bool isDir () const
- bool isFile () const
- bool isSymLink () const
- bool isWritable () const
- bool isReadable () const
- bool isExecutable () const
- bool operator== ( const QUrlInfo & i ) const

## Static Public Members

- bool greaterThan ( const QUrlInfo & i1, const QUrlInfo & i2, int sortBy )
- bool lessThan ( const QUrlInfo & i1, const QUrlInfo & i2, int sortBy )
- bool equal ( const QUrlInfo & i1, const QUrlInfo & i2, int sortBy )

## Detailed Description

This class is just a container for storing information about a URLs. That's why all informations have to be passed in the constructor.

## Member Function Documentation

### QUrlInfo::QUrlInfo ()

Constructs an empty QUrlInfo object with default values.

### QUrlInfo::QUrlInfo ( const QString & name, int permissions, const QString & owner, const QString & group, uint size, const QDateTime & lastModified, const QDateTime & lastRead, bool isDir, bool isFile, bool isSymLink, bool isWritable, bool isReadable, bool isExecutable )

Constructs a QUrlInfo object by specifying all information of the URL.

### QUrlInfo::QUrlInfo ( const QUrl & url, int permissions, const QString & owner, const QString & group, uint size, const QDateTime & lastModified, const QDateTime & lastRead, bool isDir, bool isFile, bool isSymLink, bool isWritable, bool isReadable, bool isExecutable )

Constructs a QUrlInfo object by specifying all information of the URL.

### QUrlInfo::QUrlInfo ( const QUrlOperator & path, const QString & file )

Constructs a QUrlInfo object with information about the file file in the path. This constructor tries to find the infos about file, which should be stored in the QUrlOperator path. If this is not the case, an empty QUrlInfo object is created.

### QUrlInfo::QUrlInfo ( const QUrlInfo & ui )

Copy constructor.

### QUrlInfo::~QUrlInfo () `[virtual]`

Destructor.

### bool QUrlInfo::equal ( const QUrlInfo & i1, const QUrlInfo & i2, int sortBy ) `[static]`

Returns TRUE if u1 is equal u2, else FALSE. The objects are compared by the value, which is specified by sortBy. This has to be one of QDir::Name, QDir::Time and QDir::Size.

### bool QUrlInfo::greaterThan ( const QUrlInfo & i1, const QUrlInfo & i2, int sortBy ) `[static]`

Returns TRUE if u1 is greater than u2, else FALSE. The objects are compared by the value, which is specified by sortBy. This has to be one of QDir::Name, QDir::Time and QDir::Size.

### QString QUrlInfo::group () const

Returns the group of the URL.

### bool QUrlInfo::isDir () const

Returns TRUE, if the URL is a directory, else FALSE.

### bool QUrlInfo::isExecutable () const

Returns TRUE, if the URL is executable, else FALSE.

### bool QUrlInfo::isFile () const

Returns TRUE, if the URL is a file, else FALSE.

### bool QUrlInfo::isReadable () const

Returns TRUE, if the URL is readable , else FALSE.

### bool QUrlInfo::isSymLink () const

Returns TRUE, if the URL is a symbolic link, else FALSE.

### bool QUrlInfo::isWritable () const

Returns TRUE, if the URL is writable, else FALSE.

### QDateTime QUrlInfo::lastModified () const

Returns the last modification date of the URL.

### QDateTime QUrlInfo::lastRead () const

Returns the date at which the URL was read the last time.

### bool QUrlInfo::lessThan ( const QUrlInfo & i1, const QUrlInfo & i2, int sortBy ) `[static]`

Returns TRUE if u1 is less than u2, else FALSE. The objects are compared by the value, which is specified by sortBy. This has to be one of QDir::Name, QDir::Time and QDir::Size.

### QString QUrlInfo::name () const

Returns the filename of the URL.

### QUrlInfo & QUrlInfo::operator= ( const QUrlInfo & ui )

Assings the values of ui to this QUrlInfo object.

### bool QUrlInfo::operator== ( const QUrlInfo & i ) const

Compares this QUrlInfo with i and returns TRUE if they are equal, else FALSE.

### QString QUrlInfo::owner () const

Returns the owner of the URL.

### int QUrlInfo::permissions () const

Returns the permissions of the URL.

### void QUrlInfo::setDir ( bool b ) `[virtual]`

Specifies if the URL is a directory.

### void QUrlInfo::setFile ( bool b ) `[virtual]`

Specifies if the URL is a file.

### void QUrlInfo::setGroup ( const QString & s ) `[virtual]`

Sets the group if the URL to s.

### void QUrlInfo::setLastModified ( const QDateTime & dt ) `[virtual]`

Sets the last modification date of the URL to dt.

### void QUrlInfo::setName ( const QString & name ) `[virtual]`

Sets the filename or the URL.

### void QUrlInfo::setOwner ( const QString & s ) `[virtual]`

Sets the owner of the URL to s.

### void QUrlInfo::setPermissions ( int p ) `[virtual]`

Sets the permissions of the URL to p.

### void QUrlInfo::setReadable ( bool b ) `[virtual]`

Specifies if the URL is readable.

### void QUrlInfo::setSize ( uint s ) `[virtual]`

Sets the size of the URL to s.

### void QUrlInfo::setSymLink ( bool b ) `[virtual]`

Specifies if the URL is a symbolic link.

### void QUrlInfo::setWritable ( bool b ) `[virtual]`

Specifies if the URL is writable.

### uint QUrlInfo::size () const

Returns the size of the URL.

Search the documentation, FAQ, qt-interest archive and more (uses www.trolltech.com):

This file is part of the Qt toolkit, copyright © 1995-2001 Trolltech, all rights reserved.