"Only FileSystem resources are supported."); if (rc.isEmpty()) { throw new BuildException(MSG_WHEN_COPYING_EMPTY_RC_TO_FILE);
private Resource[] selectOutOfDateResources(final Resource[] initial, final FileNameMapper mapper) { final Resource[] rs = selectFileResources(initial); Resource[] result = ResourceUtils.selectOutOfDateSources(this, rs, mapper, getZipScanner(), ZIP_FILE_TIMESTAMP_GRANULARITY); if (!doFilesonly) { final Union u = new Union(); u.addAll(Arrays.asList(selectDirectoryResources(initial))); final ResourceCollection rc = ResourceUtils.selectSources(this, u, mapper, getZipScanner(), MISSING_DIR_PROVIDER); if (!rc.isEmpty()) { final List<Resource> newer = new ArrayList<>(); newer.addAll(Arrays.asList(((Union) rc).listResources())); newer.addAll(Arrays.asList(result)); result = newer.toArray(result); } } return result; }
if (rc.isEmpty()) { return Collections.emptySet();
/** * Execute the concat task. */ @Override public void execute() { validate(); if (binary && dest == null) { throw new BuildException( "dest|destfile attribute is required for binary concatenation"); } ResourceCollection c = getResources(); if (isUpToDate(c)) { log(dest + " is up-to-date.", Project.MSG_VERBOSE); return; } if (c.isEmpty() && ignoreEmpty) { return; } try { //most of these are defaulted because the concat-as-a-resource code hijacks a lot: ResourceUtils.copyResource(new ConcatResource(c), dest == null ? new LogOutputResource(this, Project.MSG_WARN) : dest, null, null, true, false, append, null, null, getProject(), force); } catch (IOException e) { throw new BuildException("error concatenating content to " + dest, e); } }
final ResourceFactory targets, final ResourceSelectorProvider selector) { if (source.isEmpty()) { logTo.log("No sources found.", Project.MSG_VERBOSE); return Resources.NONE;