本文整理了Java中org.kie.workbench.common.services.shared.whitelist.WhiteList.isEmpty()
方法的一些代码示例,展示了WhiteList.isEmpty()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WhiteList.isEmpty()
方法的具体详情如下:
包路径:org.kie.workbench.common.services.shared.whitelist.WhiteList
类名称:WhiteList
方法名:isEmpty
暂无
代码示例来源:origin: org.kie.workbench.services/kie-wb-common-services-backend
@Test
public void testNoFile() throws Exception {
tempFiles.deleteFiles();
assertTrue( loader.load( pathToWhiteList ).isEmpty() );
}
}
代码示例来源:origin: org.kie.workbench.services/kie-wb-common-services-backend
/**
* Filter the provided Package names by the Module's white list
* @param module Module for which to filter Package names
* @param packageNames All Package names in the Module
* @return A filtered collection of Package names
*/
@Override
public WhiteList filterPackageNames(final Module module,
final Collection<String> packageNames) {
if (packageNames == null) {
return new WhiteList();
} else if (module instanceof KieModule) {
final WhiteList whiteList = load(((KieModule) module).getPackageNamesWhiteListPath());
if (whiteList.isEmpty()) {
return new WhiteList(packageNames);
} else {
for (Package aPackage : moduleService.resolvePackages(module)) {
whiteList.add(aPackage.getPackageName());
}
return new PackageNameWhiteListFilter(packageNames,
whiteList).getFilteredPackageNames();
}
} else {
return new WhiteList(packageNames);
}
}
内容来源于网络,如有侵权,请联系作者删除!