/** * Compiles the <class>IRootFilesAdvice</class> from the <code>info</code> into one <class>IRootFilesAdvice</class> * and returns the result. * @param configSpec * @return a compilation of <class>IRootfilesAdvice</class> from the <code>info</code>. */ private IRootFilesAdvice getAdvice(String configSpec) { Collection<IRootFilesAdvice> advice = info.getAdvice(configSpec, true, null, null, IRootFilesAdvice.class); ArrayList<File> inclusions = new ArrayList<File>(); ArrayList<File> exclusions = new ArrayList<File>(); File root = null; for (IRootFilesAdvice entry : advice) { // TODO for now we simply get root from the first advice that has one if (root == null) root = entry.getRoot(); File[] list = entry.getIncludedFiles(); if (list != null) inclusions.addAll(Arrays.asList(list)); list = entry.getExcludedFiles(); if (list != null) exclusions.addAll(Arrays.asList(list)); } File[] includeList = inclusions.toArray(new File[inclusions.size()]); File[] excludeList = exclusions.toArray(new File[exclusions.size()]); return new RootFilesAdvice(root, includeList, excludeList, configSpec); }
/** * Compiles the <class>IRootFilesAdvice</class> from the <code>info</code> into one <class>IRootFilesAdvice</class> * and returns the result. * @param configSpec * @return a compilation of <class>IRootfilesAdvice</class> from the <code>info</code>. */ private IRootFilesAdvice getAdvice(String configSpec) { Collection<IRootFilesAdvice> advice = info.getAdvice(configSpec, true, null, null, IRootFilesAdvice.class); ArrayList<File> inclusions = new ArrayList<File>(); ArrayList<File> exclusions = new ArrayList<File>(); File root = null; for (IRootFilesAdvice entry : advice) { // TODO for now we simply get root from the first advice that has one if (root == null) root = entry.getRoot(); File[] list = entry.getIncludedFiles(); if (list != null) inclusions.addAll(Arrays.asList(list)); list = entry.getExcludedFiles(); if (list != null) exclusions.addAll(Arrays.asList(list)); } File[] includeList = inclusions.toArray(new File[inclusions.size()]); File[] excludeList = exclusions.toArray(new File[exclusions.size()]); return new RootFilesAdvice(root, includeList, excludeList, configSpec); }
/** * Compiles the <class>IRootFilesAdvice</class> from the <code>info</code> into one <class>IRootFilesAdvice</class> * and returns the result. * @param configSpec * @return a compilation of <class>IRootfilesAdvice</class> from the <code>info</code>. */ private IRootFilesAdvice getAdvice(String configSpec) { Collection<IRootFilesAdvice> advice = info.getAdvice(configSpec, true, null, null, IRootFilesAdvice.class); ArrayList<File> inclusions = new ArrayList<File>(); ArrayList<File> exclusions = new ArrayList<File>(); File root = null; for (IRootFilesAdvice entry : advice) { // TODO for now we simply get root from the first advice that has one if (root == null) root = entry.getRoot(); File[] list = entry.getIncludedFiles(); if (list != null) inclusions.addAll(Arrays.asList(list)); list = entry.getExcludedFiles(); if (list != null) exclusions.addAll(Arrays.asList(list)); } File[] includeList = inclusions.toArray(new File[inclusions.size()]); File[] excludeList = exclusions.toArray(new File[exclusions.size()]); return new RootFilesAdvice(root, includeList, excludeList, configSpec); }
/** * Compiles the <class>IRootFilesAdvice</class> from the <code>info</code> into one <class>IRootFilesAdvice</class> * and returns the result. * @param configSpec * @return a compilation of <class>IRootfilesAdvice</class> from the <code>info</code>. */ private IRootFilesAdvice getAdvice(String configSpec) { Collection<IRootFilesAdvice> advice = info.getAdvice(configSpec, true, null, null, IRootFilesAdvice.class); ArrayList<File> inclusions = new ArrayList<>(); ArrayList<File> exclusions = new ArrayList<>(); File root = null; for (IRootFilesAdvice entry : advice) { // TODO for now we simply get root from the first advice that has one if (root == null) root = entry.getRoot(); File[] list = entry.getIncludedFiles(); if (list != null) inclusions.addAll(Arrays.asList(list)); list = entry.getExcludedFiles(); if (list != null) exclusions.addAll(Arrays.asList(list)); } File[] includeList = inclusions.toArray(new File[inclusions.size()]); File[] excludeList = exclusions.toArray(new File[exclusions.size()]); return new RootFilesAdvice(root, includeList, excludeList, configSpec); }
publishArtifact(descriptor, advice.getIncludedFiles(), advice.getExcludedFiles(), info, createPrefixComputer(advice.getRoot()));
publishArtifact(descriptor, advice.getIncludedFiles(), advice.getExcludedFiles(), info, createPrefixComputer(advice.getRoot()));
publishArtifact(descriptor, advice.getIncludedFiles(), advice.getExcludedFiles(), info, createPrefixComputer(advice.getRoot()));
publishArtifact(descriptor, advice.getIncludedFiles(), advice.getExcludedFiles(), info, createPrefixComputer(advice.getRoot()));