ShrinkWrap Resolver API 2.0.0-alpha-3

org.jboss.shrinkwrap.resolver.api
Class Resolvers

java.lang.Object
  extended by org.jboss.shrinkwrap.resolver.api.Resolvers

public class Resolvers
extends Object

Client entry point to resolve artifacts from a set of coordinates in a repository-based system. To create a new instance, pass the desired view (subtype of ResolverSystem) into either use(Class) or use(Class, ClassLoader).

Author:
Andrew Lee Rubinger

Constructor Summary
Resolvers()
           
 
Method Summary
static
<RESOLVERSYSTEMTYPE extends ResolverSystem,CONFIGURABLERESOLVERSYSTEMTYPE extends ConfigurableResolverSystem<RESOLVERSYSTEMTYPE>>
ConfiguredResolverSystemFactory<RESOLVERSYSTEMTYPE,CONFIGURABLERESOLVERSYSTEMTYPE>
configure(Class<CONFIGURABLERESOLVERSYSTEMTYPE> clazz)
          Returns a factory to create configured ResolverSystem instances of the specified type.
static
<RESOLVERSYSTEMTYPE extends ResolverSystem,CONFIGURABLERESOLVERSYSTEMTYPE extends ConfigurableResolverSystem<RESOLVERSYSTEMTYPE>>
ConfiguredResolverSystemFactory<RESOLVERSYSTEMTYPE,CONFIGURABLERESOLVERSYSTEMTYPE>
configure(Class<CONFIGURABLERESOLVERSYSTEMTYPE> clazz, ClassLoader cl)
          Returns a factory to create configured ResolverSystem instances of the specified type.
static
<RESOLVERSYSTEMTYPE extends ResolverSystem>
RESOLVERSYSTEMTYPE
use(Class<RESOLVERSYSTEMTYPE> clazz)
          Creates and returns a new instance of the specified view type.
static
<RESOLVERSYSTEMTYPE extends ResolverSystem>
RESOLVERSYSTEMTYPE
use(Class<RESOLVERSYSTEMTYPE> clazz, ClassLoader cl)
          Creates and returns a new instance of the specified view type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Resolvers

public Resolvers()
Method Detail

configure

public static <RESOLVERSYSTEMTYPE extends ResolverSystem,CONFIGURABLERESOLVERSYSTEMTYPE extends ConfigurableResolverSystem<RESOLVERSYSTEMTYPE>> ConfiguredResolverSystemFactory<RESOLVERSYSTEMTYPE,CONFIGURABLERESOLVERSYSTEMTYPE> configure(Class<CONFIGURABLERESOLVERSYSTEMTYPE> clazz)
                                                                                                                                                                                  throws IllegalArgumentException
Returns a factory to create configured ResolverSystem instances of the specified type. New instances will be created using the current Thread.getContextClassLoader().

Parameters:
clazz -
Returns:
Throws:
IllegalArgumentException - If the type is not specified

configure

public static <RESOLVERSYSTEMTYPE extends ResolverSystem,CONFIGURABLERESOLVERSYSTEMTYPE extends ConfigurableResolverSystem<RESOLVERSYSTEMTYPE>> ConfiguredResolverSystemFactory<RESOLVERSYSTEMTYPE,CONFIGURABLERESOLVERSYSTEMTYPE> configure(Class<CONFIGURABLERESOLVERSYSTEMTYPE> clazz,
                                                                                                                                                                                                                                             ClassLoader cl)
                                                                                                                                                                                  throws IllegalArgumentException
Returns a factory to create configured ResolverSystem instances of the specified type. New instances will be created using the specified ClassLoader.

Parameters:
clazz -
cl -
Returns:
Throws:
IllegalArgumentException - If the type or ClassLoader is not specified

use

public static <RESOLVERSYSTEMTYPE extends ResolverSystem> RESOLVERSYSTEMTYPE use(Class<RESOLVERSYSTEMTYPE> clazz)
                                                     throws IllegalArgumentException
Creates and returns a new instance of the specified view type.

Parameters:
clazz -
Returns:
Throws:
IllegalArgumentException

use

public static <RESOLVERSYSTEMTYPE extends ResolverSystem> RESOLVERSYSTEMTYPE use(Class<RESOLVERSYSTEMTYPE> clazz,
                                                                                 ClassLoader cl)
                                                     throws IllegalArgumentException
Creates and returns a new instance of the specified view type.

Parameters:
clazz -
Returns:
Throws:
IllegalArgumentException - If either argument is not supplied

ShrinkWrap Resolver API 2.0.0-alpha-3

Copyright © 2012 JBoss by Red Hat. All Rights Reserved.