Multicatch and override

This commit is contained in:
Eric Barboni 2014-04-11 23:29:44 +02:00
parent 4444ed0e1d
commit d44d957734
9 changed files with 91 additions and 31 deletions

View File

@ -87,7 +87,6 @@ import javax.inject.Inject;
import javax.inject.Named; import javax.inject.Named;
import java.io.File; import java.io.File;
import java.io.IOException; import java.io.IOException;
import java.io.RandomAccessFile;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Collections; import java.util.Collections;
import java.util.HashMap; import java.util.HashMap;
@ -136,7 +135,7 @@ public class DefaultRepositoryProxyConnectors
private Map<String, List<ProxyConnector>> proxyConnectorMap = new HashMap<>(); private Map<String, List<ProxyConnector>> proxyConnectorMap = new HashMap<>();
private Map<String, ProxyInfo> networkProxyMap = new ConcurrentHashMap<String, ProxyInfo>(); private Map<String, ProxyInfo> networkProxyMap = new ConcurrentHashMap<>();
@Inject @Inject
private WagonFactory wagonFactory; private WagonFactory wagonFactory;
@ -302,6 +301,7 @@ public class DefaultRepositoryProxyConnectors
return proxyConnectorRuleConfigurations; return proxyConnectorRuleConfigurations;
} }
@Override
public File fetchFromProxies( ManagedRepositoryContent repository, ArtifactReference artifact ) public File fetchFromProxies( ManagedRepositoryContent repository, ArtifactReference artifact )
throws ProxyDownloadException throws ProxyDownloadException
{ {
@ -313,7 +313,7 @@ public class DefaultRepositoryProxyConnectors
requestProperties.setProperty( "managedRepositoryId", repository.getId() ); requestProperties.setProperty( "managedRepositoryId", repository.getId() );
List<ProxyConnector> connectors = getProxyConnectors( repository ); List<ProxyConnector> connectors = getProxyConnectors( repository );
Map<String, Exception> previousExceptions = new LinkedHashMap<String, Exception>(); Map<String, Exception> previousExceptions = new LinkedHashMap<>();
for ( ProxyConnector connector : connectors ) for ( ProxyConnector connector : connectors )
{ {
if ( connector.isDisabled() ) if ( connector.isDisabled() )
@ -354,12 +354,7 @@ public class DefaultRepositoryProxyConnectors
log.debug( "Artifact {} not updated on repository \"{}\".", Keys.toKey( artifact ), log.debug( "Artifact {} not updated on repository \"{}\".", Keys.toKey( artifact ),
targetRepository.getRepository().getId() ); targetRepository.getRepository().getId() );
} }
catch ( ProxyException e ) catch ( ProxyException | RepositoryAdminException e )
{
validatePolicies( this.downloadErrorPolicies, connector.getPolicies(), requestProperties, artifact,
targetRepository, localFile, e, previousExceptions );
}
catch ( RepositoryAdminException e )
{ {
validatePolicies( this.downloadErrorPolicies, connector.getPolicies(), requestProperties, artifact, validatePolicies( this.downloadErrorPolicies, connector.getPolicies(), requestProperties, artifact,
targetRepository, localFile, e, previousExceptions ); targetRepository, localFile, e, previousExceptions );
@ -377,6 +372,7 @@ public class DefaultRepositoryProxyConnectors
return null; return null;
} }
@Override
public File fetchFromProxies( ManagedRepositoryContent repository, String path ) public File fetchFromProxies( ManagedRepositoryContent repository, String path )
{ {
File localFile = new File( repository.getRepoRoot(), path ); File localFile = new File( repository.getRepoRoot(), path );
@ -450,6 +446,7 @@ public class DefaultRepositoryProxyConnectors
return null; return null;
} }
@Override
public File fetchMetatadaFromProxies( ManagedRepositoryContent repository, String logicalPath ) public File fetchMetatadaFromProxies( ManagedRepositoryContent repository, String logicalPath )
{ {
File localFile = new File( repository.getRepoRoot(), logicalPath ); File localFile = new File( repository.getRepoRoot(), logicalPath );
@ -496,14 +493,7 @@ public class DefaultRepositoryProxyConnectors
targetRepository.getRepository().getId(), e ); targetRepository.getRepository().getId(), e );
} }
catch ( ProxyException e ) catch ( ProxyException | RepositoryAdminException e )
{
log.warn(
"Transfer error from repository {} for versioned Metadata {}, continuing to next repository. Error message: {}",
targetRepository.getRepository().getId(), logicalPath, e.getMessage() );
log.debug( "Full stack trace", e );
}
catch ( RepositoryAdminException e )
{ {
log.warn( log.warn(
"Transfer error from repository {} for versioned Metadata {}, continuing to next repository. Error message: {}", "Transfer error from repository {} for versioned Metadata {}, continuing to next repository. Error message: {}",
@ -550,6 +540,7 @@ public class DefaultRepositoryProxyConnectors
* @param repository * @param repository
* @throws ProxyException * @throws ProxyException
* @throws NotModifiedException * @throws NotModifiedException
* @throws org.apache.archiva.admin.model.RepositoryAdminException
*/ */
protected void transferResources( ProxyConnector connector, RemoteRepositoryContent remoteRepository, File tmpMd5, protected void transferResources( ProxyConnector connector, RemoteRepositoryContent remoteRepository, File tmpMd5,
File tmpSha1, File tmpResource, String url, String remotePath, File resource, File tmpSha1, File tmpResource, String url, String remotePath, File resource,
@ -669,6 +660,7 @@ public class DefaultRepositoryProxyConnectors
/** /**
* Test if the provided ManagedRepositoryContent has any proxies configured for it. * Test if the provided ManagedRepositoryContent has any proxies configured for it.
*/ */
@Override
public boolean hasProxies( ManagedRepositoryContent repository ) public boolean hasProxies( ManagedRepositoryContent repository )
{ {
synchronized ( this.proxyConnectorMap ) synchronized ( this.proxyConnectorMap )
@ -700,12 +692,7 @@ public class DefaultRepositoryProxyConnectors
return false; return false;
} }
if ( !file.isFile() ) return file.isFile();
{
return false;
}
return true;
} }
/** /**
@ -1204,12 +1191,7 @@ public class DefaultRepositoryProxyConnectors
wagon.connect( wagonRepository, authInfo, networkProxy ); wagon.connect( wagonRepository, authInfo, networkProxy );
connected = true; connected = true;
} }
catch ( ConnectionException e ) catch ( ConnectionException | AuthenticationException e )
{
log.warn( "Could not connect to {}: {}", remoteRepository.getRepository().getName(), e.getMessage() );
connected = false;
}
catch ( AuthenticationException e )
{ {
log.warn( "Could not connect to {}: {}", remoteRepository.getRepository().getName(), e.getMessage() ); log.warn( "Could not connect to {}: {}", remoteRepository.getRepository().getName(), e.getMessage() );
connected = false; connected = false;
@ -1256,6 +1238,7 @@ public class DefaultRepositoryProxyConnectors
/** /**
* TODO: Ensure that list is correctly ordered based on configuration. See MRM-477 * TODO: Ensure that list is correctly ordered based on configuration. See MRM-477
*/ */
@Override
public List<ProxyConnector> getProxyConnectors( ManagedRepositoryContent repository ) public List<ProxyConnector> getProxyConnectors( ManagedRepositoryContent repository )
{ {
synchronized ( this.proxyConnectorMap ) synchronized ( this.proxyConnectorMap )
@ -1271,6 +1254,7 @@ public class DefaultRepositoryProxyConnectors
} }
} }
@Override
public void afterConfigurationChange( Registry registry, String propertyName, Object propertyValue ) public void afterConfigurationChange( Registry registry, String propertyName, Object propertyValue )
{ {
if ( ConfigurationNames.isNetworkProxy( propertyName ) || ConfigurationNames.isManagedRepositories( if ( ConfigurationNames.isNetworkProxy( propertyName ) || ConfigurationNames.isManagedRepositories(
@ -1304,6 +1288,7 @@ public class DefaultRepositoryProxyConnectors
} }
@Override
public void beforeConfigurationChange( Registry registry, String propertyName, Object propertyValue ) public void beforeConfigurationChange( Registry registry, String propertyName, Object propertyValue )
{ {
/* do nothing */ /* do nothing */

View File

@ -38,6 +38,7 @@ public class ProxyConnectorOrderComparator
return INSTANCE; return INSTANCE;
} }
@Override
public int compare( ProxyConnector o1, ProxyConnector o2 ) public int compare( ProxyConnector o1, ProxyConnector o2 )
{ {
if ( o1 == null && o2 == null ) if ( o1 == null && o2 == null )

View File

@ -30,22 +30,26 @@ import org.springframework.stereotype.Service;
public class MockRepositoryArchivaTaskScheduler public class MockRepositoryArchivaTaskScheduler
implements RepositoryArchivaTaskScheduler implements RepositoryArchivaTaskScheduler
{ {
@Override
public boolean isProcessingRepositoryTask( String repositoryId ) public boolean isProcessingRepositoryTask( String repositoryId )
{ {
return false; return false;
} }
@Override
public boolean isProcessingRepositoryTask( RepositoryTask task ) public boolean isProcessingRepositoryTask( RepositoryTask task )
{ {
return false; return false;
} }
@Override
public void queueTask( RepositoryTask task ) public void queueTask( RepositoryTask task )
throws TaskQueueException throws TaskQueueException
{ {
// no op // no op
} }
@Override
public boolean unQueueTask( RepositoryTask task ) public boolean unQueueTask( RepositoryTask task )
throws TaskQueueException throws TaskQueueException
{ {

View File

@ -37,157 +37,187 @@ import java.util.List;
public class TestMetadataRepository public class TestMetadataRepository
implements MetadataRepository implements MetadataRepository
{ {
@Override
public ProjectMetadata getProject( String repoId, String namespace, String projectId ) public ProjectMetadata getProject( String repoId, String namespace, String projectId )
{ {
return null; return null;
} }
@Override
public ProjectVersionMetadata getProjectVersion( String repoId, String namespace, String projectId, public ProjectVersionMetadata getProjectVersion( String repoId, String namespace, String projectId,
String projectVersion ) String projectVersion )
{ {
return null; return null;
} }
@Override
public Collection<String> getArtifactVersions( String repoId, String namespace, String projectId, public Collection<String> getArtifactVersions( String repoId, String namespace, String projectId,
String projectVersion ) String projectVersion )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public Collection<ProjectVersionReference> getProjectReferences( String repoId, String namespace, String projectId, public Collection<ProjectVersionReference> getProjectReferences( String repoId, String namespace, String projectId,
String projectVersion ) String projectVersion )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public Collection<String> getRootNamespaces( String repoId ) public Collection<String> getRootNamespaces( String repoId )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public Collection<String> getNamespaces( String repoId, String namespace ) public Collection<String> getNamespaces( String repoId, String namespace )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public Collection<String> getProjects( String repoId, String namespace ) public Collection<String> getProjects( String repoId, String namespace )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public Collection<String> getProjectVersions( String repoId, String namespace, String projectId ) public Collection<String> getProjectVersions( String repoId, String namespace, String projectId )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public void updateProject( String repoId, ProjectMetadata project ) public void updateProject( String repoId, ProjectMetadata project )
{ {
// no op // no op
} }
@Override
public void updateArtifact( String repoId, String namespace, String projectId, String projectVersion, public void updateArtifact( String repoId, String namespace, String projectId, String projectVersion,
ArtifactMetadata artifactMeta ) ArtifactMetadata artifactMeta )
{ {
// no op // no op
} }
@Override
public void updateProjectVersion( String repoId, String namespace, String projectId, public void updateProjectVersion( String repoId, String namespace, String projectId,
ProjectVersionMetadata versionMetadata ) ProjectVersionMetadata versionMetadata )
{ {
// no op // no op
} }
@Override
public void updateNamespace( String repoId, String namespace ) public void updateNamespace( String repoId, String namespace )
{ {
// no op // no op
} }
@Override
public List<String> getMetadataFacets( String repodId, String facetId ) public List<String> getMetadataFacets( String repodId, String facetId )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public MetadataFacet getMetadataFacet( String repositoryId, String facetId, String name ) public MetadataFacet getMetadataFacet( String repositoryId, String facetId, String name )
{ {
return null; return null;
} }
@Override
public void addMetadataFacet( String repositoryId, MetadataFacet metadataFacet ) public void addMetadataFacet( String repositoryId, MetadataFacet metadataFacet )
{ {
// no op // no op
} }
@Override
public void removeMetadataFacets( String repositoryId, String facetId ) public void removeMetadataFacets( String repositoryId, String facetId )
{ {
// no op // no op
} }
@Override
public void removeMetadataFacet( String repoId, String facetId, String name ) public void removeMetadataFacet( String repoId, String facetId, String name )
{ {
// no op // no op
} }
@Override
public List<ArtifactMetadata> getArtifactsByDateRange( String repoId, Date startTime, Date endTime ) public List<ArtifactMetadata> getArtifactsByDateRange( String repoId, Date startTime, Date endTime )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public Collection<String> getRepositories() public Collection<String> getRepositories()
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public List<ArtifactMetadata> getArtifactsByChecksum( String repoId, String checksum ) public List<ArtifactMetadata> getArtifactsByChecksum( String repoId, String checksum )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public void removeArtifact( String repositoryId, String namespace, String project, String version, String id ) public void removeArtifact( String repositoryId, String namespace, String project, String version, String id )
{ {
// no op // no op
} }
@Override
public void removeRepository( String repoId ) public void removeRepository( String repoId )
{ {
// no op // no op
} }
@Override
public Collection<ArtifactMetadata> getArtifacts( String repoId, String namespace, String projectId, public Collection<ArtifactMetadata> getArtifacts( String repoId, String namespace, String projectId,
String projectVersion ) String projectVersion )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public void save() public void save()
{ {
// no op // no op
} }
@Override
public void close() public void close()
{ {
// no op // no op
} }
@Override
public void revert() public void revert()
{ {
// no op // no op
} }
@Override
public boolean canObtainAccess( Class<?> aClass ) public boolean canObtainAccess( Class<?> aClass )
{ {
return false; return false;
} }
@Override
public <T>T obtainAccess( Class<T> aClass ) public <T>T obtainAccess( Class<T> aClass )
{ {
return null; //To change body of implemented methods use File | Settings | File Templates. return null; //To change body of implemented methods use File | Settings | File Templates.
} }
@Override
public List<ArtifactMetadata> getArtifacts( String repositoryId ) public List<ArtifactMetadata> getArtifacts( String repositoryId )
{ {
return Collections.emptyList(); return Collections.emptyList();
} }
@Override
public void removeArtifact( String repositoryId, String namespace, String project, String version, public void removeArtifact( String repositoryId, String namespace, String project, String version,
MetadataFacet metadataFacet ) MetadataFacet metadataFacet )
throws MetadataRepositoryException throws MetadataRepositoryException
@ -195,30 +225,35 @@ public class TestMetadataRepository
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }
@Override
public void removeArtifact( ArtifactMetadata artifactMetadata, String baseVersion ) public void removeArtifact( ArtifactMetadata artifactMetadata, String baseVersion )
throws MetadataRepositoryException throws MetadataRepositoryException
{ {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }
@Override
public void removeNamespace( String repositoryId, String namespace ) public void removeNamespace( String repositoryId, String namespace )
throws MetadataRepositoryException throws MetadataRepositoryException
{ {
} }
@Override
public void removeProjectVersion( String repoId, String namespace, String projectId, String projectVersion ) public void removeProjectVersion( String repoId, String namespace, String projectId, String projectVersion )
throws MetadataRepositoryException throws MetadataRepositoryException
{ {
} }
@Override
public void removeProject( String repositoryId, String namespace, String projectId ) public void removeProject( String repositoryId, String namespace, String projectId )
throws MetadataRepositoryException throws MetadataRepositoryException
{ {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException();
} }
@Override
public boolean hasMetadataFacet( String repositoryId, String facetId ) public boolean hasMetadataFacet( String repositoryId, String facetId )
throws MetadataRepositoryException throws MetadataRepositoryException
{ {

View File

@ -1,7 +1,6 @@
package org.apache.archiva.metadata.repository; package org.apache.archiva.metadata.repository;
import org.codehaus.plexus.personality.plexus.lifecycle.phase.Configurable; import org.codehaus.plexus.personality.plexus.lifecycle.phase.Configurable;
import org.codehaus.plexus.personality.plexus.lifecycle.phase.Initializable;
import org.codehaus.plexus.personality.plexus.lifecycle.phase.Startable; import org.codehaus.plexus.personality.plexus.lifecycle.phase.Startable;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
@ -29,6 +28,7 @@ public class TestRepositorySessionFactory
{ {
private MetadataResolver resolver; private MetadataResolver resolver;
@Override
public RepositorySession createSession() public RepositorySession createSession()
{ {
return new RepositorySession( new TestMetadataRepository(), resolver ); return new RepositorySession( new TestMetadataRepository(), resolver );

View File

@ -38,7 +38,6 @@ import org.apache.archiva.proxy.model.RepositoryProxyConnectors;
import org.apache.archiva.repository.ManagedRepositoryContent; import org.apache.archiva.repository.ManagedRepositoryContent;
import org.apache.archiva.test.utils.ArchivaSpringJUnit4ClassRunner; import org.apache.archiva.test.utils.ArchivaSpringJUnit4ClassRunner;
import org.apache.commons.io.FileUtils; import org.apache.commons.io.FileUtils;
import org.apache.commons.lang.ArrayUtils;
import org.apache.maven.index.NexusIndexer; import org.apache.maven.index.NexusIndexer;
import org.apache.maven.index.context.IndexingContext; import org.apache.maven.index.context.IndexingContext;
import org.apache.maven.wagon.Wagon; import org.apache.maven.wagon.Wagon;

View File

@ -138,6 +138,7 @@ public class HttpProxyTransferTest
Handler handler = new AbstractHandler() Handler handler = new AbstractHandler()
{ {
@Override
public void handle( String s, Request request, HttpServletRequest httpServletRequest, public void handle( String s, Request request, HttpServletRequest httpServletRequest,
HttpServletResponse response ) HttpServletResponse response )
throws IOException, ServletException throws IOException, ServletException

View File

@ -82,16 +82,19 @@ public class MockConfiguration
} ); } );
} }
@Override
public void addChangeListener( org.apache.archiva.redback.components.registry.RegistryListener listener ) public void addChangeListener( org.apache.archiva.redback.components.registry.RegistryListener listener )
{ {
registryListeners.add( listener ); registryListeners.add( listener );
} }
@Override
public Configuration getConfiguration() public Configuration getConfiguration()
{ {
return configuration; return configuration;
} }
@Override
public void save( Configuration configuration ) public void save( Configuration configuration )
throws RegistryException throws RegistryException
{ {
@ -113,21 +116,25 @@ public class MockConfiguration
} }
} }
@Override
public void addListener( ConfigurationListener listener ) public void addListener( ConfigurationListener listener )
{ {
configListeners.add( listener ); configListeners.add( listener );
} }
@Override
public void removeListener( ConfigurationListener listener ) public void removeListener( ConfigurationListener listener )
{ {
configListeners.remove( listener ); configListeners.remove( listener );
} }
@Override
public boolean isDefaulted() public boolean isDefaulted()
{ {
return false; return false;
} }
@Override
public void reload() public void reload()
{ {
// no op // no op

View File

@ -54,6 +54,7 @@ public class WagonDelegate
private String contentToGet; private String contentToGet;
@Override
public void get( String resourceName, File destination ) public void get( String resourceName, File destination )
throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
{ {
@ -62,6 +63,7 @@ public class WagonDelegate
create( destination ); create( destination );
} }
@Override
public boolean getIfNewer( String resourceName, File destination, long timestamp ) public boolean getIfNewer( String resourceName, File destination, long timestamp )
throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
{ {
@ -72,18 +74,21 @@ public class WagonDelegate
return result; return result;
} }
@Override
public void put( File source, String destination ) public void put( File source, String destination )
throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
{ {
delegate.put( source, destination ); delegate.put( source, destination );
} }
@Override
public void putDirectory( File sourceDirectory, String destinationDirectory ) public void putDirectory( File sourceDirectory, String destinationDirectory )
throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
{ {
delegate.putDirectory( sourceDirectory, destinationDirectory ); delegate.putDirectory( sourceDirectory, destinationDirectory );
} }
@Override
public boolean resourceExists( String resourceName ) public boolean resourceExists( String resourceName )
throws TransferFailedException, AuthorizationException throws TransferFailedException, AuthorizationException
{ {
@ -91,72 +96,85 @@ public class WagonDelegate
} }
@SuppressWarnings ("unchecked") @SuppressWarnings ("unchecked")
@Override
public List<String> getFileList( String destinationDirectory ) public List<String> getFileList( String destinationDirectory )
throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
{ {
return delegate.getFileList( destinationDirectory ); return delegate.getFileList( destinationDirectory );
} }
@Override
public boolean supportsDirectoryCopy() public boolean supportsDirectoryCopy()
{ {
return delegate.supportsDirectoryCopy(); return delegate.supportsDirectoryCopy();
} }
@Override
public void setTimeout( int val ) public void setTimeout( int val )
{ {
// ignore // ignore
} }
@Override
public int getTimeout() public int getTimeout()
{ {
return 0; return 0;
} }
@Override
public void setReadTimeout( int timeoutValue ) public void setReadTimeout( int timeoutValue )
{ {
// ignore // ignore
} }
@Override
public int getReadTimeout() public int getReadTimeout()
{ {
return 0; return 0;
} }
@Override
public Repository getRepository() public Repository getRepository()
{ {
return delegate.getRepository(); return delegate.getRepository();
} }
@Override
public void connect( Repository source ) public void connect( Repository source )
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
delegate.connect( source ); delegate.connect( source );
} }
@Override
public void connect( Repository source, ProxyInfo proxyInfo ) public void connect( Repository source, ProxyInfo proxyInfo )
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
delegate.connect( source, proxyInfo ); delegate.connect( source, proxyInfo );
} }
@Override
public void connect( Repository source, ProxyInfoProvider proxyInfoProvider ) public void connect( Repository source, ProxyInfoProvider proxyInfoProvider )
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
delegate.connect( source, proxyInfoProvider ); delegate.connect( source, proxyInfoProvider );
} }
@Override
public void connect( Repository source, AuthenticationInfo authenticationInfo ) public void connect( Repository source, AuthenticationInfo authenticationInfo )
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
delegate.connect( source, authenticationInfo ); delegate.connect( source, authenticationInfo );
} }
@Override
public void connect( Repository source, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo ) public void connect( Repository source, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo )
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
delegate.connect( source, authenticationInfo, proxyInfo ); delegate.connect( source, authenticationInfo, proxyInfo );
} }
@Override
public void connect( Repository source, AuthenticationInfo authenticationInfo, ProxyInfoProvider proxyInfoProvider ) public void connect( Repository source, AuthenticationInfo authenticationInfo, ProxyInfoProvider proxyInfoProvider )
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
@ -164,53 +182,63 @@ public class WagonDelegate
} }
@SuppressWarnings ("deprecation") @SuppressWarnings ("deprecation")
@Override
public void openConnection() public void openConnection()
throws ConnectionException, AuthenticationException throws ConnectionException, AuthenticationException
{ {
delegate.openConnection(); delegate.openConnection();
} }
@Override
public void disconnect() public void disconnect()
throws ConnectionException throws ConnectionException
{ {
delegate.disconnect(); delegate.disconnect();
} }
@Override
public void addSessionListener( SessionListener listener ) public void addSessionListener( SessionListener listener )
{ {
delegate.addSessionListener( listener ); delegate.addSessionListener( listener );
} }
@Override
public void removeSessionListener( SessionListener listener ) public void removeSessionListener( SessionListener listener )
{ {
delegate.removeSessionListener( listener ); delegate.removeSessionListener( listener );
} }
@Override
public boolean hasSessionListener( SessionListener listener ) public boolean hasSessionListener( SessionListener listener )
{ {
return delegate.hasSessionListener( listener ); return delegate.hasSessionListener( listener );
} }
@Override
public void addTransferListener( TransferListener listener ) public void addTransferListener( TransferListener listener )
{ {
delegate.addTransferListener( listener ); delegate.addTransferListener( listener );
} }
@Override
public void removeTransferListener( TransferListener listener ) public void removeTransferListener( TransferListener listener )
{ {
delegate.removeTransferListener( listener ); delegate.removeTransferListener( listener );
} }
@Override
public boolean hasTransferListener( TransferListener listener ) public boolean hasTransferListener( TransferListener listener )
{ {
return delegate.hasTransferListener( listener ); return delegate.hasTransferListener( listener );
} }
@Override
public boolean isInteractive() public boolean isInteractive()
{ {
return delegate.isInteractive(); return delegate.isInteractive();
} }
@Override
public void setInteractive( boolean interactive ) public void setInteractive( boolean interactive )
{ {
delegate.setInteractive( interactive ); delegate.setInteractive( interactive );