Package org.eclipse.aether.impl

Examples of org.eclipse.aether.impl.DefaultServiceLocator


        final ServiceLocator sl = this.serviceLocator;
        return null != sl ? sl : (this.serviceLocator = newServiceLocator());
    }

    private static ServiceLocator newServiceLocator() {
        final DefaultServiceLocator sl = MavenRepositorySystemUtils
                .newServiceLocator()
                .addService(RepositoryConnectorFactory.class,
                        FileRepositoryConnectorFactory.class)
                .addService(RepositoryConnectorFactory.class,
                        WagonRepositoryConnectorFactory.class)
                .setServices(WagonProvider.class, new AhcWagonProvider());
        sl.setErrorHandler(errorHandler());
        if (LegacySlf4jLoggerFactory.AVAILABLE)
            sl.setService(LoggerFactory.class, LegacySlf4jLoggerFactory.class);
        return sl;
    }
View Full Code Here


        /*
         * Aether's components implement org.eclipse.aether.spi.locator.Service to ease manual wiring and using the
         * pre-populated DefaultServiceLocator, we only need to register the repository connector and transporter
         * factories.
         */
        DefaultServiceLocator locator = MavenRepositorySystemUtils.newServiceLocator();
        locator.addService(RepositoryConnectorFactory.class, BasicRepositoryConnectorFactory.class );
        locator.addService(TransporterFactory.class, FileTransporterFactory.class );
        locator.addService(TransporterFactory.class, HttpTransporterFactory.class );
        /*locator.setService(UpdatePolicyAnalyzer.class, MyUpdatePolicyAnalyzer.class);
        locator.setService(UpdateCheckManager.class, ForceUpdateCheckManager.class);
        locator.setService(LocalRepositoryManagerFactory.class, ConfigurableLocalRepositoryManagerFactory.class);*/

        return locator.getService(RepositorySystem.class);
    }
View Full Code Here

TOP

Related Classes of org.eclipse.aether.impl.DefaultServiceLocator

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.