本文整理汇总了C++中FileSpecList::Clear方法的典型用法代码示例。如果您正苦于以下问题:C++ FileSpecList::Clear方法的具体用法?C++ FileSpecList::Clear怎么用?C++ FileSpecList::Clear使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FileSpecList
的用法示例。
在下文中一共展示了FileSpecList::Clear方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
uint32_t
ObjectFileJIT::GetDependentModules (FileSpecList& files)
{
// JIT modules don't have dependencies, but they could
// if external functions are called and we know where they are
files.Clear();
return 0;
}
示例2: if
size_t
FileSpecList::GetFilesMatchingPartialPath (const char *path, bool dir_okay, FileSpecList &matches)
{
#if 0 // FIXME: Just sketching...
matches.Clear();
FileSpec path_spec = FileSpec (path);
if (path_spec.Exists ())
{
FileSpec::FileType type = path_spec.GetFileType();
if (type == FileSpec::eFileTypeSymbolicLink)
// Shouldn't there be a Resolve on a file spec that real-path's it?
{
}
if (type == FileSpec::eFileTypeRegular
|| (type == FileSpec::eFileTypeDirectory && dir_okay))
{
matches.Append (path_spec);
return 1;
}
else if (type == FileSpec::eFileTypeDirectory)
{
// Fill the match list with all the files in the directory:
}
else
{
return 0;
}
}
else
{
ConstString dir_name = path_spec.GetDirectory();
Constring file_name = GetFilename();
if (dir_name == NULL)
{
// Match files in the CWD.
}
else
{
// Match files in the given directory:
}
}
#endif
return 0;
}