Package org.eclipse.aether.repository

Examples of org.eclipse.aether.repository.RepositoryPolicy


        this.forceRefresh = forceRefresh;
        this.offline = offline;

        this.session = newRepositorySession(system, localRepoPath);

        final RepositoryPolicy policy = new RepositoryPolicy(true, RepositoryPolicy.UPDATE_POLICY_NEVER, RepositoryPolicy.CHECKSUM_POLICY_WARN);
        this.repos = new ArrayList<RemoteRepository>();

        if (repos == null)
            this.repos.add(newRemoteRepository("central", MAVEN_CENTRAL_URL, policy));
        else {
View Full Code Here


        this.forceRefresh = forceRefresh;
        this.offline = offline;

        this.session = newRepositorySession(system, localRepoPath);

        final RepositoryPolicy policy = new RepositoryPolicy(true, RepositoryPolicy.UPDATE_POLICY_NEVER, RepositoryPolicy.CHECKSUM_POLICY_WARN);
        this.repos = new ArrayList<RemoteRepository>();

        if (repos == null)
            this.repos.add(newRemoteRepository("central", MAVEN_CENTRAL_URL, policy));
        else {
View Full Code Here

        AetherResolver ar = new AetherResolver();
        List<org.eclipse.aether.repository.RemoteRepository> transformed =
            ar.transformRemoteRepository(new RemoteRepository[]{r1, r2});
        for(org.eclipse.aether.repository.RemoteRepository r : transformed) {
            RepositoryPolicy snapShotPolicy = r.getPolicy(true);
            RepositoryPolicy releasePolicy = r.getPolicy(false);
            assertTrue(snapShotPolicy.getChecksumPolicy().equals(RemoteRepository.CHECKSUM_POLICY_IGNORE));
            assertTrue(snapShotPolicy.getUpdatePolicy().equals(RemoteRepository.UPDATE_POLICY_ALWAYS));
            assertTrue(releasePolicy.getChecksumPolicy().equals(RemoteRepository.CHECKSUM_POLICY_IGNORE));
            assertTrue(releasePolicy.getUpdatePolicy().equals(RemoteRepository.UPDATE_POLICY_ALWAYS));
        }


        for(org.eclipse.aether.repository.RemoteRepository r : transformed) {
            RemoteRepository rr = ar.transformAetherRemoteRepository(r);
View Full Code Here

        if(repositories==null)
            throw new IllegalArgumentException("repositories must not be null");
        List<org.eclipse.aether.repository.RemoteRepository> remoteRepositories =
            new ArrayList<org.eclipse.aether.repository.RemoteRepository>();
        for(RemoteRepository rr : repositories) {
            RepositoryPolicy releasePolicy = new RepositoryPolicy(true,
                                                                  rr.getReleaseUpdatePolicy(),
                                                                  rr.getReleaseChecksumPolicy());
            RepositoryPolicy snapshotPolicy = new RepositoryPolicy(true,
                                                                   rr.getSnapshotUpdatePolicy(),
                                                                   rr.getSnapshotChecksumPolicy());

            org.eclipse.aether.repository.RemoteRepository.Builder repoBuilder =
                new org.eclipse.aether.repository.RemoteRepository.Builder(rr.getId(), "default", rr.getUrl());
View Full Code Here

TOP

Related Classes of org.eclipse.aether.repository.RepositoryPolicy

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.