]> source.dussan.org Git - archiva.git/commitdiff
fix compilation
authorOlivier Lamy <olamy@apache.org>
Tue, 29 Jan 2013 00:09:10 +0000 (00:09 +0000)
committerOlivier Lamy <olamy@apache.org>
Tue, 29 Jan 2013 00:09:10 +0000 (00:09 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/redback/redback-core/trunk@1439711 13f79535-47bb-0310-9956-ffa450edef68

redback-rbac/redback-rbac-providers/redback-rbac-ldap/src/main/java/org/apache/archiva/redback/rbac/ldap/LdapRbacManager.java

index f37221354c800b9cf6dcb16d5743ac56978c91b5..566f597a7d56dd24a333710b367214fac145c5b2 100644 (file)
@@ -26,6 +26,7 @@ import org.apache.archiva.redback.common.ldap.connection.LdapConnection;
 import org.apache.archiva.redback.common.ldap.connection.LdapConnectionFactory;
 import org.apache.archiva.redback.common.ldap.connection.LdapException;
 import org.apache.archiva.redback.common.ldap.role.LdapRoleMapper;
+import org.apache.archiva.redback.common.ldap.role.LdapRoleMapperConfiguration;
 import org.apache.archiva.redback.components.cache.Cache;
 import org.apache.archiva.redback.configuration.UserConfiguration;
 import org.apache.archiva.redback.configuration.UserConfigurationKeys;
@@ -102,6 +103,10 @@ public class LdapRbacManager
     @Inject
     private LdapController ldapController;
 
+    @Inject
+    @Named( value = "ldapRoleMapperConfiguration#default" )
+    private LdapRoleMapperConfiguration ldapRoleMapperConfiguration;
+
     @Inject
     @Named( value = "cache#ldapRoles" )
     private Cache<String, Role> rolesCache;
@@ -206,7 +211,7 @@ public class LdapRbacManager
     {
         try
         {
-            Collection<Collection<String>> roleNames = ldapRoleMapper.getLdapGroupMappings().values();
+            Collection<Collection<String>> roleNames = ldapRoleMapperConfiguration.getLdapGroupMappings().values();
 
             Set<Role> roles = new HashSet<Role>();
 
@@ -356,7 +361,7 @@ public class LdapRbacManager
         }
 
         List<Role> roles = new ArrayList<Role>( groups.size() );
-        Map<String, Collection<String>> mappedGroups = ldapRoleMapper.getLdapGroupMappings();
+        Map<String, Collection<String>> mappedGroups = ldapRoleMapperConfiguration.getLdapGroupMappings();
         for ( String group : groups )
         {
             Collection<String> roleNames = mappedGroups.get( group );