Package org.sonatype.aether.repository

Examples of org.sonatype.aether.repository.LocalRepository


    public Aether() {
        this(USER_REPOSITORY, defaultRepositories());
    }

    public Aether(String localRepoDir, List<Repository> repositories) {
        this.localRepository = new LocalRepository(localRepoDir);
        this.remoteRepos = repositories;

//        DefaultServiceLocator locator = new DefaultServiceLocator();
//        locator.setServices(WagonProvider.class, new ManualWagonProvider());
//        locator.addService(RepositoryConnectorFactory.class, WagonRepositoryConnectorFactory.class);
View Full Code Here


        session.setMirrorSelector(MavenUtils.getMirrorSelector());
        session.setAuthenticationSelector(MavenUtils.getAuthSelector());
        session.setCache(new DefaultRepositoryCache());
        session.setUpdatePolicy(updatePolicy);
        session.setChecksumPolicy(checksumPolicy);
        LocalRepository localRepo = new LocalRepository(localRepository);
        session.setLocalRepositoryManager(system.newLocalRepositoryManager(localRepo));
        return session;
    }
View Full Code Here

        return repo.resolveDependencies(session, request, filter);
    }

    private MavenRepositorySystemSession createSession(boolean offline, RepositorySystem repo) {
        MavenRepositorySystemSession session = new MavenRepositorySystemSession();
        LocalRepository localRepository = new LocalRepository(getLocalRepo());
        session.setLocalRepositoryManager(repo.newLocalRepositoryManager(localRepository));

        session.setDependencySelector(
                new AndDependencySelector(new ScopeDependencySelector("test"),
                        new OptionalDependencySelector(), new ExclusionDependencySelector()));
View Full Code Here

    }


    protected MavenRepositorySystemSession createRepositorSystemSession(boolean offline, RepositorySystem repo) {
        final MavenRepositorySystemSession session = new MavenRepositorySystemSession();
        LocalRepository localRepository = new LocalRepository(getLocalRepo());
        session.setLocalRepositoryManager(repo.newLocalRepositoryManager(localRepository));
        session.setDependencySelector(
                new AndDependencySelector(new ScopeDependencySelector("test"),
                        /*
                        // includes only immediate child dependencies
View Full Code Here

   {
      MavenRepositorySystemSession session = new MavenRepositorySystemSession();
      session.setOffline(!environment.isOnline());
      Settings settings = container.getSettings();

      LocalRepository localRepo = new LocalRepository(new File(settings.getLocalRepository()), "");
      session.setLocalRepositoryManager(repoSystem.newLocalRepositoryManager(localRepo));
      session.setTransferErrorCachingEnabled(false);
      session.setNotFoundCachingEnabled(false);

      return session;
View Full Code Here

        return locator.getService( RepositorySystem.class );
    }

    private DefaultRepositorySystemSession newRepositorySystemSession( RepositorySystem system ) {
        LocalRepository localRepo = new LocalRepository(localRepoDir);
        MavenRepositorySystemSession session = new MavenRepositorySystemSession();
        session.setLocalRepositoryManager( system.newLocalRepositoryManager( localRepo ) );
        return session;
    }
View Full Code Here

    }


    public LocalRepository getLocalRepository() {
        if (localRepository == null) {
            localRepository = new LocalRepository(getLocalRepoDir());
        }
        return localRepository;
    }
View Full Code Here

    /**
     * @deprecated
     *      Use {@link LocalRepositorySetting#set(LocalRepository)}
     */
    public void setLocalRepository(String repository) {
        localRepositorySetting.set(new LocalRepository(repository));
    }
View Full Code Here

   {
      MavenRepositorySystemSession session = new MavenRepositorySystemSession();
      session.setOffline(!environment.isOnline());
      Settings settings = container.getSettings();

      LocalRepository localRepo = new LocalRepository(new File(settings.getLocalRepository()), "");
      session.setLocalRepositoryManager(repoSystem.newLocalRepositoryManager(localRepo));
      session.setTransferErrorCachingEnabled(false);
      session.setNotFoundCachingEnabled(false);

      return session;
View Full Code Here

            Metadata metadata = request.getMetadata();
            RemoteRepository repository = request.getRepository();

            if ( repository == null )
            {
                LocalRepository localRepo = session.getLocalRepositoryManager().getRepository();

                metadataResolving( session, trace, metadata, localRepo );

                File localFile = getLocalFile( session, metadata );
View Full Code Here

TOP

Related Classes of org.sonatype.aether.repository.LocalRepository

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.