Permalink
Browse files

Add proxies URL getter

Signed-off-by: Alin Dreghiciu <adreghiciu@gmail.com>
  • Loading branch information...
1 parent b984063 commit 69b9df001a053fb4516e1b34e256cafdcd9dfdfb @adreghiciu adreghiciu committed Oct 30, 2012
@@ -21,6 +21,8 @@
extends Repository<T, ProxyRepositoryStatus>
{
+ String proxyUri();
+
T withRepoPolicy( final String policy );
T asProxyOf( String remoteUrl );
@@ -78,6 +78,17 @@ ProxyRepositoryStatus convertStatus( final RepositoryStatusResource status )
}
@Override
+ public String proxyUri()
+ {
+ final RepositoryResourceRemoteStorage remoteStorage = settings().getRemoteStorage();
+ if ( remoteStorage == null )
+ {
+ return null;
+ }
+ return remoteStorage.getRemoteStorageUrl();
+ }
+
+ @Override
public T withRepoPolicy( final String policy )
{
settings().setRepoPolicy( policy );

0 comments on commit 69b9df0

Please sign in to comment.