summaryrefslogtreecommitdiffstats
path: root/archiva-modules/archiva-web/archiva-web-common
diff options
context:
space:
mode:
authorEric <Eric@Eric-PC>2014-04-10 04:15:00 +0200
committerEric <Eric@Eric-PC>2014-04-10 04:15:00 +0200
commitd56c43d4df863645c928b460f106453a3f49d3c9 (patch)
tree28f17243c67d14ecce8ec9d8fae405a4c5bfa402 /archiva-modules/archiva-web/archiva-web-common
parente4514664f42578066ef3393ea005f35d7972c085 (diff)
parentd9de8dc7afe4a1e22257a9437d68649eee8f3047 (diff)
downloadarchiva-d56c43d4df863645c928b460f106453a3f49d3c9.tar.gz
archiva-d56c43d4df863645c928b460f106453a3f49d3c9.zip
Merge origin/master
Diffstat (limited to 'archiva-modules/archiva-web/archiva-web-common')
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java2
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/rss/RssFeedServlet.java2
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java12
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLdapRoleMapperConfiguration.java2
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java4
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaRbacManager.java12
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java4
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java4
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/remotedownload/AbstractDownloadTest.java2
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/SecuritySystemStub.java2
-rw-r--r--archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/webtest/memory/TestMetadataRepository.java4
11 files changed, 25 insertions, 25 deletions
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java
index 59c352b25..936e1598f 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/api/DefaultFileUploadService.java
@@ -604,7 +604,7 @@ public class DefaultFileUploadService
String artifactId, String version, String packaging )
throws RepositoryMetadataException
{
- List<String> availableVersions = new ArrayList<String>();
+ List<String> availableVersions = new ArrayList<>();
String latestVersion = version;
File projectDir = new File( targetPath ).getParentFile();
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/rss/RssFeedServlet.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/rss/RssFeedServlet.java
index e822c6b1d..cc9ae88db 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/rss/RssFeedServlet.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/rss/RssFeedServlet.java
@@ -240,7 +240,7 @@ public class RssFeedServlet
UnauthorizedException
{
String auth = req.getHeader( "Authorization" );
- List<String> repoIds = new ArrayList<String>();
+ List<String> repoIds = new ArrayList<>();
if ( repositoryId != null )
{
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java
index 652b5d088..d2aae47ba 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java
@@ -259,7 +259,7 @@ public class ArchivaConfigurableUsersManager
public List<User> findUsersByEmailKey( String emailKey, boolean orderAscending )
throws UserManagerException
{
- List<User> users = new ArrayList<User>();
+ List<User> users = new ArrayList<>();
for ( UserManager userManager : userManagerPerId.values() )
{
@@ -275,7 +275,7 @@ public class ArchivaConfigurableUsersManager
public List<User> findUsersByFullNameKey( String fullNameKey, boolean orderAscending )
throws UserManagerException
{
- List<User> users = new ArrayList<User>();
+ List<User> users = new ArrayList<>();
for ( UserManager userManager : userManagerPerId.values() )
{
@@ -291,7 +291,7 @@ public class ArchivaConfigurableUsersManager
public List<User> findUsersByQuery( UserQuery query )
throws UserManagerException
{
- List<User> users = new ArrayList<User>();
+ List<User> users = new ArrayList<>();
for ( UserManager userManager : userManagerPerId.values() )
{
@@ -307,7 +307,7 @@ public class ArchivaConfigurableUsersManager
public List<User> findUsersByUsernameKey( String usernameKey, boolean orderAscending )
throws UserManagerException
{
- List<User> users = new ArrayList<User>();
+ List<User> users = new ArrayList<>();
for ( UserManager userManager : userManagerPerId.values() )
{
@@ -328,7 +328,7 @@ public class ArchivaConfigurableUsersManager
public List<User> getUsers()
throws UserManagerException
{
- List<User> users = new ArrayList<User>();
+ List<User> users = new ArrayList<>();
for ( UserManager userManager : userManagerPerId.values() )
{
@@ -344,7 +344,7 @@ public class ArchivaConfigurableUsersManager
public List<User> getUsers( boolean orderAscending )
throws UserManagerException
{
- List<User> users = new ArrayList<User>();
+ List<User> users = new ArrayList<>();
for ( UserManager userManager : userManagerPerId.values() )
{
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLdapRoleMapperConfiguration.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLdapRoleMapperConfiguration.java
index 0cf358328..ec129a515 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLdapRoleMapperConfiguration.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLdapRoleMapperConfiguration.java
@@ -155,7 +155,7 @@ public class ArchivaLdapRoleMapperConfiguration
RedbackRuntimeConfiguration redbackRuntimeConfiguration =
redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration();
- List<LdapGroupMapping> ldapGroupMappings = new ArrayList<LdapGroupMapping>( mappings.size() );
+ List<LdapGroupMapping> ldapGroupMappings = new ArrayList<>( mappings.size() );
for ( Map.Entry<String, List<String>> entry : mappings.entrySet() )
{
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java
index a6090cec1..2b14fe227 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java
@@ -75,7 +75,7 @@ public class ArchivaLockedAdminEnvironmentCheck
List<String> userManagerImpls =
redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls();
- userManagers = new ArrayList<UserManager>( userManagerImpls.size() );
+ userManagers = new ArrayList<>( userManagerImpls.size() );
for ( String beanId : userManagerImpls )
{
@@ -100,7 +100,7 @@ public class ArchivaLockedAdminEnvironmentCheck
{
continue;
}
- List<String> roles = new ArrayList<String>();
+ List<String> roles = new ArrayList<>();
roles.add( RedbackRoleConstants.SYSTEM_ADMINISTRATOR_ROLE );
List<UserAssignment> systemAdminstrators;
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaRbacManager.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaRbacManager.java
index 7320d5a99..c511b0274 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaRbacManager.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaRbacManager.java
@@ -250,7 +250,7 @@ public class ArchivaRbacManager
throw new RbacManagerException( lastException.getMessage(), lastException );
}
- return new ArrayList<Role>( allRoles.values() );
+ return new ArrayList<>( allRoles.values() );
}
public void removeRole( Role role )
@@ -381,7 +381,7 @@ public class ArchivaRbacManager
{
throw new RbacManagerException( lastException.getMessage(), lastException );
}
- return new ArrayList<Permission>( allPermissions.values() );
+ return new ArrayList<>( allPermissions.values() );
}
public void removePermission( Permission permission )
@@ -505,7 +505,7 @@ public class ArchivaRbacManager
{
throw new RbacManagerException( lastException.getMessage(), lastException );
}
- return new ArrayList<Operation>( allOperations.values() );
+ return new ArrayList<>( allOperations.values() );
}
public void removeOperation( Operation operation )
@@ -629,7 +629,7 @@ public class ArchivaRbacManager
{
throw new RbacManagerException( lastException.getMessage(), lastException );
}
- return new ArrayList<Resource>( allResources.values() );
+ return new ArrayList<>( allResources.values() );
}
public void removeResource( Resource resource )
@@ -820,13 +820,13 @@ public class ArchivaRbacManager
{
throw new RbacManagerException( lastException.getMessage(), lastException );
}
- return new ArrayList<UserAssignment>( allUserAssignments.values() );
+ return new ArrayList<>( allUserAssignments.values() );
}
public List<UserAssignment> getUserAssignmentsForRoles( Collection<String> roleNames )
throws RbacManagerException
{
- List<UserAssignment> allUserAssignments = new ArrayList<UserAssignment>();
+ List<UserAssignment> allUserAssignments = new ArrayList<>();
boolean allFailed = true;
Exception lastException = null;
for ( RBACManager rbacManager : rbacManagersPerId.values() )
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java
index e54a503b0..4707c322e 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java
@@ -78,7 +78,7 @@ public class ArchivaUserManagerAuthenticator
List<String> userManagerImpls =
redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls();
- userManagers = new ArrayList<UserManager>( userManagerImpls.size() );
+ userManagers = new ArrayList<>( userManagerImpls.size() );
for ( String beanId : userManagerImpls )
{
@@ -99,7 +99,7 @@ public class ArchivaUserManagerAuthenticator
String username = null;
Exception resultException = null;
PasswordBasedAuthenticationDataSource source = (PasswordBasedAuthenticationDataSource) ds;
- List<AuthenticationFailureCause> authnResultErrors = new ArrayList<AuthenticationFailureCause>();
+ List<AuthenticationFailureCause> authnResultErrors = new ArrayList<>();
for ( UserManager userManager : userManagers )
{
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java
index 3f4c20909..7d7ac0b75 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/startup/SecuritySynchronization.java
@@ -181,12 +181,12 @@ public class SecuritySynchronization
stopWatch.reset();
stopWatch.start();
- List<String> violations = new ArrayList<String>();
+ List<String> violations = new ArrayList<>();
for ( Entry<String, EnvironmentCheck> entry : checkers.entrySet() )
{
EnvironmentCheck check = entry.getValue();
- List<String> v = new ArrayList<String>();
+ List<String> v = new ArrayList<>();
check.validateEnvironment( v );
log.info( "Environment Check: {} -> {} violation(s)", entry.getKey(), v.size() );
for ( String s : v )
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/remotedownload/AbstractDownloadTest.java b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/remotedownload/AbstractDownloadTest.java
index 03dd1d229..2e35ba670 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/remotedownload/AbstractDownloadTest.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/remotedownload/AbstractDownloadTest.java
@@ -294,7 +294,7 @@ public abstract class AbstractDownloadTest
{
try
{
- List<String> entriesNames = new ArrayList<String>();
+ List<String> entriesNames = new ArrayList<>();
Enumeration<? extends ZipEntry> entries = zipFile.entries();
while ( entries.hasMoreElements() )
{
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/SecuritySystemStub.java b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/SecuritySystemStub.java
index f38a0d6a6..e9e717d4c 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/SecuritySystemStub.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/web/rss/SecuritySystemStub.java
@@ -52,7 +52,7 @@ public class SecuritySystemStub
{
Map<String, String> users = new HashMap<String, String>();
- List<String> repoIds = new ArrayList<String>();
+ List<String> repoIds = new ArrayList<>();
public SecuritySystemStub()
{
diff --git a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/webtest/memory/TestMetadataRepository.java b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/webtest/memory/TestMetadataRepository.java
index 8f9fc13bd..940fa6e15 100644
--- a/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/webtest/memory/TestMetadataRepository.java
+++ b/archiva-modules/archiva-web/archiva-web-common/src/test/java/org/apache/archiva/webtest/memory/TestMetadataRepository.java
@@ -40,9 +40,9 @@ public class TestMetadataRepository
private static final String TEST_NAMESPACE = "org.apache.archiva";
- private List<ArtifactMetadata> artifacts = new ArrayList<ArtifactMetadata>();
+ private List<ArtifactMetadata> artifacts = new ArrayList<>();
- private List<String> versions = new ArrayList<String>();
+ private List<String> versions = new ArrayList<>();
public TestMetadataRepository()
{