Extending Qt Creator Manual | FileName

Extending Qt Creator Manual 4.6.2

# FileName Class

(Utils::FileName)

The FileName class is a light-weight convenience class for filenames. More...

Header: | #include <FileName>

- List of all members, including inherited members

## Public Functions

| FileName()
| FileName(const QFileInfo &info)
FileName & | appendPath(const QString &s)
FileName & | appendString(const QString &str)
FileName & | appendString(QChar str)
bool | endsWith(const QString &s) const
bool | exists() const
QString | fileName(int pathComponents = 0) const
bool | isChildOf(const FileName &s) const
bool | isChildOf(const QDir &dir) const
FileName | parentDir() const
FileName | relativeChildPath(const FileName &parent) const
QFileInfo | toFileInfo() const
const QString & | toString() const
QString | toUserOutput() const
bool | operator!=(const FileName &other) const
bool | operator<(const FileName &other) const
bool | operator<=(const FileName &other) const
bool | operator==(const FileName &other) const
bool | operator>(const FileName &other) const
bool | operator>=(const FileName &other) const

## Static Public Members

FileName | fromLatin1(const QByteArray &filename)
FileName | fromString(const QString &filename)
FileName | fromString(const QString &filename, const QString &defaultExtension)
FileName | fromUserInput(const QString &filename)
FileName | fromUtf8(const char *filename, int filenameSize = -1)

## Detailed Description

The FileName class is a light-weight convenience class for filenames.

On windows filenames are compared case insensitively.

## Member Function Documentation

### FileName::FileName()

Default constructs an instance of FileName.

### FileName::FileName(const QFileInfo &info)

Default constructs an instance of FileName.

### FileName &FileName::appendPath(const QString &s)

### FileName &FileName::appendString(const QString &str)

### FileName &FileName::appendString(QChar str)

### bool FileName::endsWith(const QString &s) const

### bool FileName::exists() const

### QString FileName::fileName(int pathComponents = 0) const

### `[static]` FileName FileName::fromLatin1(const QByteArray &filename)

### `[static]` FileName FileName::fromString(const QString &filename)

### `[static]` FileName FileName::fromString(const QString &filename, const QString &defaultExtension)

### `[static]` FileName FileName::fromUserInput(const QString &filename)

### `[static]` FileName FileName::fromUtf8(const char *filename, int filenameSize = -1)

### bool FileName::isChildOf(const FileName &s) const

### bool FileName::isChildOf(const QDir &dir) const

### FileName FileName::parentDir() const

### FileName FileName::relativeChildPath(const FileName &parent) const

### QFileInfo FileName::toFileInfo() const

### const QString &FileName::toString() const

### QString FileName::toUserOutput() const

### bool FileName::operator!=(const FileName &other) const

### bool FileName::operator<(const FileName &other) const

### bool FileName::operator<=(const FileName &other) const

### bool FileName::operator==(const FileName &other) const

### bool FileName::operator>(const FileName &other) const

### bool FileName::operator>=(const FileName &other) const