From dd207a8d9aba5a03af76dbc67bc451ece2afc35b Mon Sep 17 00:00:00 2001 From: Teryk Bellahsene Date: Wed, 3 Feb 2016 16:41:16 +0100 Subject: [PATCH] SONAR-7266 Rename project parameters creation method --- .../java/org/sonar/server/permission/ws/AddGroupAction.java | 4 ++-- .../java/org/sonar/server/permission/ws/AddUserAction.java | 4 ++-- .../java/org/sonar/server/permission/ws/GroupsAction.java | 4 ++-- .../server/permission/ws/PermissionsWsParametersBuilder.java | 2 +- .../org/sonar/server/permission/ws/RemoveGroupAction.java | 4 ++-- .../java/org/sonar/server/permission/ws/RemoveUserAction.java | 4 ++-- .../server/permission/ws/SearchProjectPermissionsAction.java | 4 ++-- .../main/java/org/sonar/server/permission/ws/UsersAction.java | 4 ++-- .../server/permission/ws/template/ApplyTemplateAction.java | 4 ++-- 9 files changed, 17 insertions(+), 17 deletions(-) diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddGroupAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddGroupAction.java index f7d3b7e9aed..0b71274a71b 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddGroupAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddGroupAction.java @@ -31,7 +31,7 @@ import org.sonarqube.ws.client.permission.AddGroupWsRequest; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createGroupIdParameter; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createGroupNameParameter; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createPermissionParameter; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonar.server.usergroups.ws.WsGroupRef.newWsGroupRef; import static org.sonarqube.ws.client.permission.PermissionsWsParameters.PARAM_GROUP_ID; @@ -68,7 +68,7 @@ public class AddGroupAction implements PermissionsWsAction { createPermissionParameter(action); createGroupNameParameter(action); createGroupIdParameter(action); - createProjectParameter(action); + createProjectParameters(action); } @Override diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddUserAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddUserAction.java index fe5a8008523..7b22599ad24 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddUserAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/AddUserAction.java @@ -31,7 +31,7 @@ import org.sonarqube.ws.client.permission.AddUserWsRequest; import static org.sonar.server.permission.ws.PermissionRequestValidator.validatePermission; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createPermissionParameter; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createUserLoginParameter; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonarqube.ws.client.permission.PermissionsWsParameters.PARAM_PERMISSION; @@ -65,7 +65,7 @@ public class AddUserAction implements PermissionsWsAction { createPermissionParameter(action); createUserLoginParameter(action); - createProjectParameter(action); + createProjectParameters(action); } @Override diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/GroupsAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/GroupsAction.java index 0ce8148848b..c7359fcd7c5 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/GroupsAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/GroupsAction.java @@ -45,7 +45,7 @@ import static org.sonar.server.permission.ws.PermissionQueryParser.fromSelection import static org.sonar.server.permission.ws.PermissionRequestValidator.validateGlobalPermission; import static org.sonar.server.permission.ws.PermissionRequestValidator.validateProjectPermission; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createPermissionParameter; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonar.server.ws.WsUtils.writeProtobuf; import static org.sonarqube.ws.client.permission.PermissionsWsParameters.PARAM_PERMISSION; @@ -82,7 +82,7 @@ public class GroupsAction implements PermissionsWsAction { .setHandler(this); createPermissionParameter(action); - createProjectParameter(action); + createProjectParameters(action); } @Override diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/PermissionsWsParametersBuilder.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/PermissionsWsParametersBuilder.java index 78a2dbf1ab3..e4b8dee414d 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/PermissionsWsParametersBuilder.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/PermissionsWsParametersBuilder.java @@ -81,7 +81,7 @@ public class PermissionsWsParametersBuilder { .setExampleValue("42"); } - public static void createProjectParameter(NewAction action) { + public static void createProjectParameters(NewAction action) { createProjectIdParameter(action); createProjectKeyParameter(action); } diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveGroupAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveGroupAction.java index 923c322c5ec..56bd4560948 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveGroupAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveGroupAction.java @@ -33,7 +33,7 @@ import static org.sonar.server.permission.ws.PermissionRequestValidator.validate import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createGroupIdParameter; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createGroupNameParameter; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createPermissionParameter; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonar.server.usergroups.ws.WsGroupRef.newWsGroupRef; import static org.sonarqube.ws.client.permission.PermissionsWsParameters.PARAM_GROUP_ID; @@ -70,7 +70,7 @@ public class RemoveGroupAction implements PermissionsWsAction { createPermissionParameter(action); createGroupNameParameter(action); createGroupIdParameter(action); - createProjectParameter(action); + createProjectParameters(action); } @Override diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveUserAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveUserAction.java index a7506fdcf46..1df5574dd25 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveUserAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/RemoveUserAction.java @@ -31,7 +31,7 @@ import org.sonarqube.ws.client.permission.RemoveUserWsRequest; import static org.sonar.server.permission.ws.PermissionRequestValidator.validatePermission; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createPermissionParameter; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createUserLoginParameter; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonarqube.ws.client.permission.PermissionsWsParameters.PARAM_PERMISSION; @@ -65,7 +65,7 @@ public class RemoveUserAction implements PermissionsWsAction { createPermissionParameter(action); createUserLoginParameter(action); - createProjectParameter(action); + createProjectParameters(action); } @Override diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/SearchProjectPermissionsAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/SearchProjectPermissionsAction.java index b84efa83477..90009578fe4 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/SearchProjectPermissionsAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/SearchProjectPermissionsAction.java @@ -42,7 +42,7 @@ import static org.sonar.server.permission.PermissionPrivilegeChecker.checkGlobal import static org.sonar.server.permission.PermissionPrivilegeChecker.checkProjectAdminUserByComponentKey; import static org.sonar.server.permission.PermissionPrivilegeChecker.checkProjectAdminUserByComponentUuid; import static org.sonar.server.permission.ws.PermissionRequestValidator.validateQualifier; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonar.server.ws.WsParameterBuilder.QualifierParameterContext.newQualifierParameterContext; import static org.sonar.server.ws.WsParameterBuilder.createRootQualifierParameter; @@ -80,7 +80,7 @@ public class SearchProjectPermissionsAction implements PermissionsWsAction { .addSearchQuery("sonarq", "project names", "project keys") .setHandler(this); - createProjectParameter(action); + createProjectParameters(action); createRootQualifierParameter(action, newQualifierParameterContext(userSession, i18n, resourceTypes)) .setSince("5.3"); } diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/UsersAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/UsersAction.java index 4ab728545e7..e5cdacac106 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/UsersAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/UsersAction.java @@ -45,7 +45,7 @@ import static org.sonar.server.permission.PermissionPrivilegeChecker.checkProjec import static org.sonar.server.permission.ws.PermissionQueryParser.fromSelectionModeToMembership; import static org.sonar.server.permission.ws.PermissionRequestValidator.validatePermission; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createPermissionParameter; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.WsProjectRef.newOptionalWsProjectRef; import static org.sonar.server.ws.WsUtils.writeProtobuf; import static org.sonarqube.ws.client.permission.PermissionsWsParameters.PARAM_PERMISSION; @@ -83,7 +83,7 @@ public class UsersAction implements PermissionsWsAction { .setHandler(this); createPermissionParameter(action); - createProjectParameter(action); + createProjectParameters(action); } @Override diff --git a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/template/ApplyTemplateAction.java b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/template/ApplyTemplateAction.java index 52a930bc150..54b93a9ad2e 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/template/ApplyTemplateAction.java +++ b/server/sonar-server/src/main/java/org/sonar/server/permission/ws/template/ApplyTemplateAction.java @@ -33,7 +33,7 @@ import org.sonar.server.permission.ws.PermissionsWsAction; import org.sonarqube.ws.client.permission.ApplyTemplateWsRequest; import static java.util.Collections.singletonList; -import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameter; +import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createProjectParameters; import static org.sonar.server.permission.ws.PermissionsWsParametersBuilder.createTemplateParameters; import static org.sonar.server.permission.ws.WsProjectRef.newWsProjectRef; import static org.sonar.server.permission.ws.WsTemplateRef.newTemplateRef; @@ -64,7 +64,7 @@ public class ApplyTemplateAction implements PermissionsWsAction { .setHandler(this); createTemplateParameters(action); - createProjectParameter(action); + createProjectParameters(action); } @Override -- 2.39.5