本页内容

Utils::QrcCache Class

class Utils::QrcCache

QrcCache 类用于缓存已解析的 QRC 文件的内容。更多内容...

Header: #include <QrcCache>

公共函数

Utils::QrcParser::ConstPtr addPath(const Utils::FilePath &path, const QString &contents)
void clear()
Utils::QrcParser::ConstPtr parsedPath(const Utils::FilePath &path)
void removePath(const Utils::FilePath &path)
Utils::QrcParser::ConstPtr updatePath(const Utils::FilePath &path, const QString &contents)

详细说明

另请参阅 Utils::QrcParser 。

成员函数文档

Utils::QrcParser::ConstPtr QrcCache::addPath(const Utils::FilePath &path, const QString &contents)

解析位于path 的 QRC 文件,并缓存解析器。如果contents 不为空,则将其作为文件内容使用,而不会从文件系统中读取。

返回解析是否成功。

另请参阅 QrcParser::errorMessages() 和QrcParser::parseQrcFile()。

void QrcCache::clear()

清除缓存中的内容。

Utils::QrcParser::ConstPtr QrcCache::parsedPath(const Utils::FilePath &path)

返回位于path 的 QRC 文件的缓存 QRC 解析器。

void QrcCache::removePath(const Utils::FilePath &path)

从缓存中删除path 。

Utils::QrcParser::ConstPtr QrcCache::updatePath(const Utils::FilePath &path, const QString &contents)

重新解析位于path 的 QRC 文件,并返回该文件的contents 。

Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.