From: Olivier Lamy Date: Thu, 8 Sep 2011 09:33:57 +0000 (+0000) Subject: [MRM-1510] api to configure NetworkProxy : use it webapp X-Git-Tag: archiva-1.4-M1~354 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=84775832fdab4b3622ad95b4fe7237184859adda;p=archiva.git [MRM-1510] api to configure NetworkProxy : use it webapp git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1166586 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/archiva-modules/archiva-web/archiva-webapp/src/main/java/org/apache/maven/archiva/web/action/admin/networkproxies/NetworkProxiesAction.java b/archiva-modules/archiva-web/archiva-webapp/src/main/java/org/apache/maven/archiva/web/action/admin/networkproxies/NetworkProxiesAction.java index 0215120d8..1d73e032e 100644 --- a/archiva-modules/archiva-web/archiva-webapp/src/main/java/org/apache/maven/archiva/web/action/admin/networkproxies/NetworkProxiesAction.java +++ b/archiva-modules/archiva-web/archiva-webapp/src/main/java/org/apache/maven/archiva/web/action/admin/networkproxies/NetworkProxiesAction.java @@ -20,9 +20,9 @@ package org.apache.maven.archiva.web.action.admin.networkproxies; */ import com.opensymphony.xwork2.Preparable; +import org.apache.archiva.admin.repository.networkproxy.NetworkProxy; +import org.apache.archiva.admin.repository.networkproxy.NetworkProxyAdmin; import org.apache.archiva.security.common.ArchivaRoleConstants; -import org.apache.maven.archiva.configuration.ArchivaConfiguration; -import org.apache.maven.archiva.configuration.NetworkProxyConfiguration; import org.apache.maven.archiva.web.action.AbstractActionSupport; import org.codehaus.plexus.redback.rbac.Resource; import org.codehaus.redback.integration.interceptor.SecureAction; @@ -47,14 +47,14 @@ public class NetworkProxiesAction { @Inject - private ArchivaConfiguration configuration; + private NetworkProxyAdmin networkProxyAdmin; - private List networkProxies; + private List networkProxies; public void prepare() throws Exception { - networkProxies = configuration.getConfiguration().getNetworkProxies(); + networkProxies = getNetworkProxyAdmin().getNetworkProxies(); } public SecureActionBundle getSecureActionBundle() @@ -68,13 +68,23 @@ public class NetworkProxiesAction return bundle; } - public List getNetworkProxies() + public List getNetworkProxies() { return networkProxies; } - public void setNetworkProxies( List networkProxies ) + public void setNetworkProxies( List networkProxies ) { this.networkProxies = networkProxies; } + + public NetworkProxyAdmin getNetworkProxyAdmin() + { + return networkProxyAdmin; + } + + public void setNetworkProxyAdmin( NetworkProxyAdmin networkProxyAdmin ) + { + this.networkProxyAdmin = networkProxyAdmin; + } }