@Override public List<Class> getMessageClassToIntercept() { return Collections.emptyList(); }
@Override @SuppressWarnings("unchecked") public Collection<RioSetting<?>> getSupportedSettings() { return Collections.emptyList(); }
@Override @SuppressWarnings("unchecked") public Collection<RioSetting<?>> getSupportedSettings() { return Collections.emptyList(); }
@SuppressWarnings("unchecked") @Override public void close() { //set to empty iterators instead of null. Otherwise I would need //to check for null in all the other methods files = Collections.emptyList().iterator(); representations = Collections.emptyList().iterator(); vcards = Collections.emptyList().iterator(); nextRepresentation = null; currentRepresentation = null; }
public GHRelease getLatestVersion() throws IOException { return (GHRelease) Optional.ofNullable(repository) .map(ghRepository -> { try { return ghRepository.listReleases(); } catch (IOException e) { return Collections.emptyList(); } }).map(t -> t.iterator()) .map(Iterator::next) .orElse(null); }
static List<String> genericFindFiles(File targetDirectory, String[] fileIncludePattern) { if (ArrayUtils.isEmpty(fileIncludePattern)) { return Collections.emptyList(); } DirectoryScanner scanner = new DirectoryScanner(); scanner.setIncludes(fileIncludePattern); scanner.setBasedir(targetDirectory); scanner.scan(); String[] files = scanner.getIncludedFiles(); return fullPathToFiles(files, targetDirectory); }
static List<String> genericFindFiles(File targetDirectory, String[] fileIncludePattern) { if (ArrayUtils.isEmpty(fileIncludePattern)) { return Collections.emptyList(); } DirectoryScanner scanner = new DirectoryScanner(); scanner.setIncludes(fileIncludePattern); scanner.setBasedir(targetDirectory); scanner.scan(); String[] files = scanner.getIncludedFiles(); return fullPathToFiles(files, targetDirectory); }
private List<Container> getContainersToStop(QueryService queryService, ImageConfiguration image) throws DockerAccessException { List<Container> containers; RunImageConfiguration.NamingStrategy strategy = image.getRunConfiguration().getNamingStrategy(); if (strategy == RunImageConfiguration.NamingStrategy.alias) { Container container = queryService.getContainerByName(image.getAlias()); containers = container != null ? Collections.singletonList(container) : Collections.emptyList(); } else { containers = queryService.getContainersForImage(image.getName()); } return containers; }
return Collections.emptyList().iterator();