Obsolete Members for QFile

以下成员源于类 QFile 已过时。 提供它们是为使旧源代码能继续工作。强烈建议不要在新代码中使用它们。

公共类型

(obsolete) typedef EncoderFn

公共函数

(obsolete) QString readLink () const

静态公共成员

(obsolete) QString readLink (const QString & fileName )
(obsolete) void setDecodingFunction (QFile::DecoderFn function )
(obsolete) void setEncodingFunction (QFile::EncoderFn function )

成员类型文档编制

typedef QFile:: EncoderFn

This typedef is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.

这是采用以下签名的函数指针的 typedef:

QByteArray myEncoderFunc(const QString &fileName);
					

另请参阅 setEncodingFunction () 和 encodeName ().

成员函数文档编制

QString QFile:: readLink () const

此函数已过时。提供它是为使旧源代码能继续工作。强烈建议不要在新代码中使用它。

使用 symLinkTarget () 代替。

此函数已过时。提供它是为使旧源代码能继续工作。强烈建议不要在新代码中使用它。

使用 symLinkTarget () 代替。

[static] void QFile:: setDecodingFunction ( QFile::DecoderFn function )

此函数已过时。提供它是为使旧源代码能继续工作。强烈建议不要在新代码中使用它。

This function does nothing. It is provided for compatibility with Qt 4 code that attempted to set a different decoding function for file names. That feature is flawed and no longer supported in Qt 5.

另请参阅 setEncodingFunction () 和 decodeName ().

[static] void QFile:: setEncodingFunction ( QFile::EncoderFn function )

此函数已过时。提供它是为使旧源代码能继续工作。强烈建议不要在新代码中使用它。

This function does nothing. It is provided for compatibility with Qt 4 code that attempted to set a different encoding function for file names. That feature is flawed and no longer supported in Qt 5.

另请参阅 encodeName () 和 setDecodingFunction ().