本文整理匯總了PHP中FileSet::setExcludes方法的典型用法代碼示例。如果您正苦於以下問題:PHP FileSet::setExcludes方法的具體用法?PHP FileSet::setExcludes怎麽用?PHP FileSet::setExcludes使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類FileSet
的用法示例。
在下文中一共展示了FileSet::setExcludes方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: setExcludes
/**
* Sets the set of exclude patterns. Patterns may be separated by a comma
* or a space.
*
* @param string $excludes the string containing the exclude patterns
*/
public function setExcludes($excludes)
{
$this->fileset->setExcludes($excludes);
}
示例2: getSQLDescriptors
/**
* Returns a file descriptior with the sql files
* @return FileSet
*/
protected function getSQLDescriptors()
{
$xml = $this->getManifest()->getManifestAsSimpleXML();
$db = $xml->Database;
$sqlList = new FileSet();
$sqlList->setDir($this->project->getUserProperty("PATH_Icinga"));
$includes = null;
if (!$db->SQLRoutines) {
$sqlList->setExcludes("**");
}
return $sqlList;
foreach ($db->SQLRoutines->children() as $type => $content) {
$type = (string) $type;
$content = $this->getPath((string) $content);
switch ($type) {
case 'File':
if ($includes != "") {
$includes .= ",";
}
$includes .= $content;
break;
case 'Folder':
if ($includes != "") {
$includes .= ",";
}
$includes .= $content . "/**";
break;
}
}
$sqlList->setIncludes($includes);
return $sqlList;
}