Package org.gradle.api.internal.file.collections

Examples of org.gradle.api.internal.file.collections.DefaultConfigurableFileCollection


public class DefaultClasspath implements Classpath {
    private final FileCollection files;

    public DefaultClasspath(FileResolver fileResolver, TaskResolver taskResolver) {
        files = new DefaultConfigurableFileCollection(fileResolver, taskResolver);
    }
View Full Code Here


    private TaskExecutionHistory history;
    private final TaskMutator taskMutator;

    public DefaultTaskOutputs(FileResolver resolver, TaskInternal task, TaskMutator taskMutator) {
        this.taskMutator = taskMutator;
        outputFiles = new DefaultConfigurableFileCollection(String.format("%s output files", task), resolver, null);
        outputFiles.builtBy(task);
    }
View Full Code Here

    private final Map<String, Object> properties = new HashMap<String, Object>();

    public DefaultTaskInputs(FileResolver resolver, TaskInternal task, TaskMutator taskMutator) {
        this.resolver = resolver;
        this.taskMutator = taskMutator;
        inputFiles = new DefaultConfigurableFileCollection(String.format("%s input files", task), resolver, null);
        sourceFiles = new DefaultConfigurableFileCollection(String.format("%s source files", task), resolver, null);
    }
View Full Code Here

    public FileCollection resolveFiles(Object... paths) {
        if (paths.length == 1 && paths[0] instanceof FileCollection) {
            return (FileCollection) paths[0];
        }
        return new DefaultConfigurableFileCollection(this, null, paths);
    }
View Full Code Here

    public URI uri(Object path) {
        return fileResolver.resolveUri(path);
    }

    public ConfigurableFileCollection files(Object... paths) {
        return new DefaultConfigurableFileCollection(fileResolver, taskResolver, paths);
    }
View Full Code Here

    private String maxHeapSize;
    private boolean assertionsEnabled;
    private boolean debug;

    public JvmOptions(FileResolver resolver) {
        this.bootstrapClasspath = new DefaultConfigurableFileCollection(resolver, null);
        immutableSystemProperties.put(FILE_ENCODING_KEY, Charset.defaultCharset().name());
        immutableSystemProperties.put(USER_LANGUAGE_KEY, DEFAULT_LOCALE.getLanguage());
        immutableSystemProperties.put(USER_COUNTRY_KEY, DEFAULT_LOCALE.getCountry());
        immutableSystemProperties.put(USER_VARIANT_KEY, DEFAULT_LOCALE.getVariant());
    }
View Full Code Here

    public JavaExecHandleBuilder(FileResolver fileResolver) {
        super(fileResolver);
        this.fileResolver = fileResolver;
        javaOptions = new DefaultJavaForkOptions(fileResolver);
        classpath = new DefaultConfigurableFileCollection(fileResolver, null);
        executable(javaOptions.getExecutable());
    }
View Full Code Here

                if (expected instanceof UnionFileCollection) {
                    UnionFileCollection collection = (UnionFileCollection) expected;
                    return new ArrayList<FileCollection>(collection.getSources());
                }
                if (expected instanceof DefaultConfigurableFileCollection) {
                    DefaultConfigurableFileCollection collection = (DefaultConfigurableFileCollection) expected;
                    return new ArrayList<FileCollection>((Set) collection.getFrom());
                }
                if (expected instanceof CompositeFileCollection) {
                    CompositeFileCollection collection = (CompositeFileCollection) expected;
                    DefaultFileCollectionResolveContext context = new DefaultFileCollectionResolveContext();
                    collection.resolve(context);
                    return context.resolveAsFileCollections();
                }
                throw new RuntimeException("Cannot get children of " + expected);
            }
View Full Code Here

    private FileResolver fileResolver;

    public DefaultSourceSetOutput(String sourceSetDisplayName, FileResolver fileResolver, TaskResolver taskResolver) {
        this.fileResolver = fileResolver;
        String displayName = String.format("%s output", sourceSetDisplayName);
        outputDirectories = new DefaultConfigurableFileCollection(displayName, fileResolver, taskResolver, new Callable() {
            public Object call() throws Exception {
                return getClassesDir();
            }
        }, new Callable() {
            public Object call() throws Exception {
                return getResourcesDir();
            }
        });
        dirs = new DefaultConfigurableFileCollection("dirs", fileResolver, taskResolver);
    }
View Full Code Here

TOP

Related Classes of org.gradle.api.internal.file.collections.DefaultConfigurableFileCollection

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.