org.apache.avalon.repository.provider
Interface InitialContext

All Known Implementing Classes:
DefaultInitialContext

public interface InitialContext

The initial context established by an initial repository factory.

Version:
$Revision: 1.14 $ $Date: 2004/03/04 03:26:41 $
Author:
Avalon Development Team

Field Summary
static String CACHE_KEY
          The property key used when resolving the default cache directory.
static String FACTORY_ARTIFACTS_KEY
          The property key used when resolving a sequence of factory artifact references.
static String HOSTS_KEY
          The property key used when evaluating the default remote hosts.
static String IMPLEMENTATION_KEY
          The property key used when resolving the default implementation artifact spec.
static String LINE
           
static String ONLINE_KEY
          The property key used declare the online connection policy.
static String PROXY_HOST_KEY
           
static String PROXY_PASSWORD_KEY
           
static String PROXY_PORT_KEY
           
static String PROXY_USERNAME_KEY
           
 
Method Summary
 String getApplicationKey()
          Return the application key.
 File getInitialCacheDirectory()
          Return cache root directory.
 Factory getInitialFactory()
          Return the initial repository factory.
 String[] getInitialHosts()
          Return the initial set of host names.
 File getInitialWorkingDirectory()
          Return the base working directory.
 boolean getOnlineMode()
          Return the online mode.
 Repository getRepository()
          Return the repository.
 Manifest install(URL url)
          Install a block archive into the repository.
 Builder newBuilder(Artifact artifact)
          Create a factory builder using a supplied artifact.
 Builder newBuilder(ClassLoader classloader, Artifact artifact)
          Create a factory builder using a supplied artifact.
 

Field Detail

IMPLEMENTATION_KEY

public static final String IMPLEMENTATION_KEY
The property key used when resolving the default implementation artifact spec.

See Also:
Constant Field Values

ONLINE_KEY

public static final String ONLINE_KEY
The property key used declare the online connection policy.

See Also:
Constant Field Values

FACTORY_ARTIFACTS_KEY

public static final String FACTORY_ARTIFACTS_KEY
The property key used when resolving a sequence of factory artifact references.

See Also:
Constant Field Values

CACHE_KEY

public static final String CACHE_KEY
The property key used when resolving the default cache directory.

See Also:
Constant Field Values

HOSTS_KEY

public static final String HOSTS_KEY
The property key used when evaluating the default remote hosts. The value assigned to this property is a comma seperated list of urls.

See Also:
Constant Field Values

PROXY_HOST_KEY

public static final String PROXY_HOST_KEY
See Also:
Constant Field Values

PROXY_PORT_KEY

public static final String PROXY_PORT_KEY
See Also:
Constant Field Values

PROXY_USERNAME_KEY

public static final String PROXY_USERNAME_KEY
See Also:
Constant Field Values

PROXY_PASSWORD_KEY

public static final String PROXY_PASSWORD_KEY
See Also:
Constant Field Values

LINE

public static final String LINE
See Also:
Constant Field Values
Method Detail

getApplicationKey

public String getApplicationKey()
Return the application key. The value of the key may be used to resolve property files by using the convention [key].properties.

Returns:
the application key.

getOnlineMode

public boolean getOnlineMode()
Return the online mode.

Returns:
the online mode

getInitialCacheDirectory

public File getInitialCacheDirectory()
Return cache root directory.

Returns:
the cache directory

getInitialWorkingDirectory

public File getInitialWorkingDirectory()
Return the base working directory.

Returns:
the base directory

getInitialHosts

public String[] getInitialHosts()
Return the initial set of host names.

Returns:
the host names sequence

getInitialFactory

public Factory getInitialFactory()
Return the initial repository factory.

Returns:
the initial repository factory

getRepository

public Repository getRepository()
Return the repository.

Returns:
the repository

newBuilder

public Builder newBuilder(Artifact artifact)
                   throws Exception
Create a factory builder using a supplied artifact.

Parameters:
artifact - the factory artifact
Returns:
the factory builder
Throws:
Exception - if a builder creation error occurs

newBuilder

public Builder newBuilder(ClassLoader classloader,
                          Artifact artifact)
                   throws Exception
Create a factory builder using a supplied artifact.

Parameters:
classloader - the parent classloader
artifact - the factory artifact
Returns:
the factory
Throws:
Exception - if a factory creation error occurs

install

public Manifest install(URL url)
                 throws RepositoryException
Install a block archive into the repository.

Parameters:
url - the block archive url
Returns:
the block manifest
Throws:
RepositoryException


Copyright © The Apache Software Foundation. All Rights Reserved.