From 680aed78d5a58249ae56ca36b5f495bb579bce1a Mon Sep 17 00:00:00 2001 From: Lukasz Jarocki Date: Thu, 26 Aug 2021 16:24:36 +0200 Subject: SONAR-15313 drop endpoints from WebAPI deprecated since 7.X Co-authored-by: Lukasz Jarocki Co-authored-by: Philippe Perrin Co-authored-by: MikeBirnstiehl --- .../ws/client/issue/IssuesWsParameters.java | 14 --- .../sonarqube/ws/client/issues/IssuesService.java | 3 - .../sonarqube/ws/client/issues/SearchRequest.java | 47 ---------- .../ws/client/permissions/PermissionsService.java | 50 ++-------- .../SearchGlobalPermissionsRequest.java | 33 ------- .../ws/client/project/ProjectsWsParameters.java | 2 - .../ws/client/projects/BulkUpdateKeyRequest.java | 94 ------------------- .../ws/client/projects/ProjectsService.java | 18 ---- .../client/qualitygates/QualitygatesService.java | 15 --- .../client/qualitygates/UnsetDefaultRequest.java | 47 ---------- .../sonarqube/ws/client/sources/HashRequest.java | 47 ---------- .../ws/client/sources/SourcesService.java | 15 --- .../sonarqube/ws/client/views/CreateRequest.java | 19 ---- .../org/sonarqube/ws/client/views/ModeRequest.java | 102 --------------------- .../sonarqube/ws/client/views/RegexpRequest.java | 59 ------------ .../ws/client/views/SetNoneModeRequest.java | 47 ++++++++++ .../sonarqube/ws/client/views/ViewsService.java | 53 +++-------- 17 files changed, 68 insertions(+), 597 deletions(-) delete mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/SearchGlobalPermissionsRequest.java delete mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/projects/BulkUpdateKeyRequest.java delete mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/UnsetDefaultRequest.java delete mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/sources/HashRequest.java delete mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/views/ModeRequest.java delete mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/views/RegexpRequest.java create mode 100644 sonar-ws/src/main/java/org/sonarqube/ws/client/views/SetNoneModeRequest.java (limited to 'sonar-ws/src/main/java/org/sonarqube/ws/client') diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/issue/IssuesWsParameters.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/issue/IssuesWsParameters.java index c13d096064f..e37e39ae4e1 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/issue/IssuesWsParameters.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/issue/IssuesWsParameters.java @@ -55,7 +55,6 @@ public class IssuesWsParameters { public static final String PARAM_RESOLVED = "resolved"; public static final String PARAM_COMPONENT_KEYS = "componentKeys"; public static final String PARAM_COMPONENT_UUIDS = "componentUuids"; - public static final String PARAM_MODULE_UUIDS = "moduleUuids"; public static final String PARAM_PROJECTS = "projects"; public static final String PARAM_DIRECTORIES = "directories"; public static final String PARAM_FILES = "files"; @@ -72,11 +71,6 @@ public class IssuesWsParameters { public static final String PARAM_SEND_NOTIFICATIONS = "sendNotifications"; public static final String PARAM_ASSIGNEES = "assignees"; - /** - * @deprecated since 7.7, please use 'author' instead - */ - @Deprecated - public static final String DEPRECATED_PARAM_AUTHORS = "authors"; public static final String PARAM_AUTHOR = "author"; public static final String PARAM_SCOPES = "scopes"; @@ -96,18 +90,10 @@ public class IssuesWsParameters { public static final String PARAM_CREATED_BEFORE = "createdBefore"; public static final String PARAM_CREATED_IN_LAST = "createdInLast"; public static final String PARAM_SINCE_LEAK_PERIOD = "sinceLeakPeriod"; - public static final String PARAM_PAGE_SIZE = "pageSize"; - public static final String PARAM_PAGE_INDEX = "pageIndex"; public static final String PARAM_ASC = "asc"; public static final String PARAM_ADDITIONAL_FIELDS = "additionalFields"; public static final String PARAM_TIMEZONE = "timeZone"; - /** - * @deprecated since 7.9 - */ - @Deprecated - public static final String FACET_MODE = "facetMode"; - public static final String FACET_MODE_COUNT = "count"; public static final String FACET_MODE_EFFORT = "effort"; private IssuesWsParameters() { diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/IssuesService.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/IssuesService.java index 9eb40fb932f..da93ccfde0c 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/IssuesService.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/IssuesService.java @@ -206,7 +206,6 @@ public class IssuesService extends BaseService { .setParam("assigned", request.getAssigned()) .setParam("assignees", request.getAssignees() == null ? null : request.getAssignees().stream().collect(Collectors.joining(","))) .setParam("author", request.getAuthor()) - .setParam("authors", request.getAuthors() == null ? null : request.getAuthors().stream().collect(Collectors.joining(","))) .setParam("branch", request.getBranch()) .setParam("componentKeys", request.getComponentKeys() == null ? null : request.getComponentKeys().stream().collect(Collectors.joining(","))) .setParam("componentUuids", request.getComponentUuids() == null ? null : request.getComponentUuids().stream().collect(Collectors.joining(","))) @@ -216,12 +215,10 @@ public class IssuesService extends BaseService { .setParam("createdInLast", request.getCreatedInLast()) .setParam("cwe", request.getCwe() == null ? null : request.getCwe().stream().collect(Collectors.joining(","))) .setParam("directories", request.getDirectories() == null ? null : request.getDirectories().stream().collect(Collectors.joining(","))) - .setParam("facetMode", request.getFacetMode()) .setParam("facets", request.getFacets() == null ? null : request.getFacets().stream().collect(Collectors.joining(","))) .setParam("fileUuids", request.getFileUuids() == null ? null : request.getFileUuids().stream().collect(Collectors.joining(","))) .setParam("issues", request.getIssues() == null ? null : request.getIssues().stream().collect(Collectors.joining(","))) .setParam("languages", request.getLanguages() == null ? null : request.getLanguages().stream().collect(Collectors.joining(","))) - .setParam("moduleUuids", request.getModuleUuids() == null ? null : request.getModuleUuids().stream().collect(Collectors.joining(","))) .setParam("onComponentOnly", request.getOnComponentOnly()) .setParam("owaspTop10", request.getOwaspTop10() == null ? null : request.getOwaspTop10().stream().collect(Collectors.joining(","))) .setParam("p", request.getP()) diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/SearchRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/SearchRequest.java index e086c72e4ac..a8024f9d90b 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/SearchRequest.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/issues/SearchRequest.java @@ -36,7 +36,6 @@ public class SearchRequest { private String assigned; private List assignees; private List author; - private List authors; private String branch; private List componentKeys; private List componentUuids; @@ -51,7 +50,6 @@ public class SearchRequest { private List fileUuids; private List issues; private List languages; - private List moduleUuids; private String onComponentOnly; private List owaspTop10; private String p; @@ -152,20 +150,6 @@ public class SearchRequest { return author; } - /** - * Example value: "torvalds@linux-foundation.org" - * @deprecated since 7.7 - */ - @Deprecated - public SearchRequest setAuthors(List authors) { - this.authors = authors; - return this; - } - - public List getAuthors() { - return authors; - } - /** * This is part of the internal API. * Example value: "feature/my_branch" @@ -278,22 +262,6 @@ public class SearchRequest { return directories; } - /** - * Possible values: - *
    - *
  • "count"
  • - *
  • "effort"
  • - *
- */ - public SearchRequest setFacetMode(String facetMode) { - this.facetMode = facetMode; - return this; - } - - public String getFacetMode() { - return facetMode; - } - /** * Possible values: *
    @@ -367,21 +335,6 @@ public class SearchRequest { return languages; } - /** - * This is part of the internal API. - * Example value: "7d8749e8-3070-4903-9188-bdd82933bb92" - * @deprecated since 7.6 - */ - @Deprecated - public SearchRequest setModuleUuids(List moduleUuids) { - this.moduleUuids = moduleUuids; - return this; - } - - public List getModuleUuids() { - return moduleUuids; - } - /** * Possible values: *
      diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/PermissionsService.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/PermissionsService.java index 683bc87dfaf..1ca856f1722 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/PermissionsService.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/PermissionsService.java @@ -22,18 +22,16 @@ package org.sonarqube.ws.client.permissions; import java.util.stream.Collectors; import javax.annotation.Generated; import org.sonarqube.ws.MediaTypes; -import org.sonarqube.ws.client.BaseService; -import org.sonarqube.ws.client.GetRequest; -import org.sonarqube.ws.client.PostRequest; -import org.sonarqube.ws.client.WsConnector; import org.sonarqube.ws.Permissions.CreateTemplateWsResponse; -import org.sonarqube.ws.Permissions.WsGroupsResponse; -import org.sonarqube.ws.Permissions.WsSearchGlobalPermissionsResponse; -import org.sonarqube.ws.Permissions.SearchProjectPermissionsWsResponse; import org.sonarqube.ws.Permissions.SearchTemplatesWsResponse; -import org.sonarqube.ws.Permissions.WsTemplateGroupsResponse; import org.sonarqube.ws.Permissions.UpdateTemplateWsResponse; import org.sonarqube.ws.Permissions.UsersWsResponse; +import org.sonarqube.ws.Permissions.WsGroupsResponse; +import org.sonarqube.ws.Permissions.WsTemplateGroupsResponse; +import org.sonarqube.ws.client.BaseService; +import org.sonarqube.ws.client.GetRequest; +import org.sonarqube.ws.client.PostRequest; +import org.sonarqube.ws.client.WsConnector; /** * @see Further information about this web service online @@ -318,42 +316,6 @@ public class PermissionsService extends BaseService { ).content(); } - /** - * - * This is part of the internal API. - * This is a GET request. - * @see Further information about this action online (including a response example) - * @since 5.2 - * @deprecated since 6.5 - */ - @Deprecated - public WsSearchGlobalPermissionsResponse searchGlobalPermissions(SearchGlobalPermissionsRequest request) { - return call( - new GetRequest(path("search_global_permissions")), - WsSearchGlobalPermissionsResponse.parser()); - } - - /** - * - * This is part of the internal API. - * This is a GET request. - * @see Further information about this action online (including a response example) - * @since 5.2 - * @deprecated since 6.5 - */ - @Deprecated - public SearchProjectPermissionsWsResponse searchProjectPermissions(SearchProjectPermissionsRequest request) { - return call( - new GetRequest(path("search_project_permissions")) - .setParam("p", request.getP()) - .setParam("projectId", request.getProjectId()) - .setParam("projectKey", request.getProjectKey()) - .setParam("ps", request.getPs()) - .setParam("q", request.getQ()) - .setParam("qualifier", request.getQualifier()), - SearchProjectPermissionsWsResponse.parser()); - } - /** * * This is part of the internal API. diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/SearchGlobalPermissionsRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/SearchGlobalPermissionsRequest.java deleted file mode 100644 index 424bc60e778..00000000000 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/permissions/SearchGlobalPermissionsRequest.java +++ /dev/null @@ -1,33 +0,0 @@ -/* - * SonarQube - * Copyright (C) 2009-2021 SonarSource SA - * mailto:info AT sonarsource DOT com - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ -package org.sonarqube.ws.client.permissions; - -import javax.annotation.Generated; - -/** - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 5.2 - */ -@Generated("sonar-ws-generator") -public class SearchGlobalPermissionsRequest { - -} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/project/ProjectsWsParameters.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/project/ProjectsWsParameters.java index cce70ee2f58..f8fe7896742 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/project/ProjectsWsParameters.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/project/ProjectsWsParameters.java @@ -26,10 +26,8 @@ public class ProjectsWsParameters { public static final String CONTROLLER = "api/projects"; public static final String ACTION_CREATE = "create"; - public static final String ACTION_INDEX = "index"; public static final String ACTION_SEARCH = "search"; public static final String ACTION_UPDATE_KEY = "update_key"; - public static final String ACTION_BULK_UPDATE_KEY = "bulk_update_key"; public static final String ACTION_UPDATE_VISIBILITY = "update_visibility"; public static final String PARAM_PROJECT = "project"; diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/BulkUpdateKeyRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/BulkUpdateKeyRequest.java deleted file mode 100644 index 4ca8ea7b1b1..00000000000 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/BulkUpdateKeyRequest.java +++ /dev/null @@ -1,94 +0,0 @@ -/* - * SonarQube - * Copyright (C) 2009-2021 SonarSource SA - * mailto:info AT sonarsource DOT com - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ -package org.sonarqube.ws.client.projects; - -import javax.annotation.Generated; - -/** - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 6.1 - */ -@Generated("sonar-ws-generator") -public class BulkUpdateKeyRequest { - - private String dryRun; - private String from; - private String project; - private String to; - - /** - * Possible values: - *
        - *
      • "true"
      • - *
      • "false"
      • - *
      • "yes"
      • - *
      • "no"
      • - *
      - */ - public BulkUpdateKeyRequest setDryRun(String dryRun) { - this.dryRun = dryRun; - return this; - } - - public String getDryRun() { - return dryRun; - } - - /** - * This is a mandatory parameter. - * Example value: "_old" - */ - public BulkUpdateKeyRequest setFrom(String from) { - this.from = from; - return this; - } - - public String getFrom() { - return from; - } - - /** - * This is a mandatory parameter. - * Example value: "my_old_project" - */ - public BulkUpdateKeyRequest setProject(String project) { - this.project = project; - return this; - } - - public String getProject() { - return project; - } - - /** - * This is a mandatory parameter. - * Example value: "_new" - */ - public BulkUpdateKeyRequest setTo(String to) { - this.to = to; - return this; - } - - public String getTo() { - return to; - } -} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/ProjectsService.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/ProjectsService.java index f28a7289863..12eff3c5400 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/ProjectsService.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/projects/ProjectsService.java @@ -22,7 +22,6 @@ package org.sonarqube.ws.client.projects; import java.util.stream.Collectors; import javax.annotation.Generated; import org.sonarqube.ws.MediaTypes; -import org.sonarqube.ws.Projects.BulkUpdateKeyWsResponse; import org.sonarqube.ws.Projects.CreateWsResponse; import org.sonarqube.ws.Projects.SearchMyProjectsWsResponse; import org.sonarqube.ws.Projects.SearchWsResponse; @@ -61,23 +60,6 @@ public class ProjectsService extends BaseService { ).content(); } - /** - * - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 6.1 - */ - public BulkUpdateKeyWsResponse bulkUpdateKey(BulkUpdateKeyRequest request) { - return call( - new PostRequest(path("bulk_update_key")) - .setParam("dryRun", request.getDryRun()) - .setParam("from", request.getFrom()) - .setParam("project", request.getProject()) - .setParam("to", request.getTo()), - BulkUpdateKeyWsResponse.parser()); - } - /** * * This is part of the internal API. diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/QualitygatesService.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/QualitygatesService.java index 840f39ac8fd..04dc5a5dbea 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/QualitygatesService.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/QualitygatesService.java @@ -266,21 +266,6 @@ public class QualitygatesService extends BaseService { ShowWsResponse.parser()); } - /** - * This is part of the internal API. - * This is a POST request. - * - * @see Further information about this action online (including a response example) - * @since 4.3 - * @deprecated since 7.0 - */ - @Deprecated - public String unsetDefault() { - return call( - new PostRequest(path("unset_default")) - .setMediaType(MediaTypes.JSON)).content(); - } - /** * This is part of the internal API. * This is a POST request. diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/UnsetDefaultRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/UnsetDefaultRequest.java deleted file mode 100644 index 7147a11d40a..00000000000 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/qualitygates/UnsetDefaultRequest.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * SonarQube - * Copyright (C) 2009-2021 SonarSource SA - * mailto:info AT sonarsource DOT com - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ -package org.sonarqube.ws.client.qualitygates; - -import javax.annotation.Generated; - -/** - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 4.3 - */ -@Generated("sonar-ws-generator") -public class UnsetDefaultRequest { - - private String id; - - /** - * This is a mandatory parameter. - * Example value: "1" - */ - public UnsetDefaultRequest setId(String id) { - this.id = id; - return this; - } - - public String getId() { - return id; - } -} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/HashRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/HashRequest.java deleted file mode 100644 index 6edb0fdfcaf..00000000000 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/HashRequest.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * SonarQube - * Copyright (C) 2009-2021 SonarSource SA - * mailto:info AT sonarsource DOT com - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ -package org.sonarqube.ws.client.sources; - -import javax.annotation.Generated; - -/** - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 5.0 - */ -@Generated("sonar-ws-generator") -public class HashRequest { - - private String key; - - /** - * This is a mandatory parameter. - * Example value: "my_project:/src/foo/Bar.php" - */ - public HashRequest setKey(String key) { - this.key = key; - return this; - } - - public String getKey() { - return key; - } -} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/SourcesService.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/SourcesService.java index ee95144e645..00669bda5e0 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/SourcesService.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/sources/SourcesService.java @@ -35,21 +35,6 @@ public class SourcesService extends BaseService { super(wsConnector, "api/sources"); } - /** - * - * This is part of the internal API. - * This is a GET request. - * @see Further information about this action online (including a response example) - * @since 5.0 - */ - public String hash(HashRequest request) { - return call( - new GetRequest(path("hash")) - .setParam("key", request.getKey()) - .setMediaType(MediaTypes.JSON) - ).content(); - } - /** * * This is part of the internal API. diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/CreateRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/CreateRequest.java index b97a6d99b58..05c6bb4849e 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/CreateRequest.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/CreateRequest.java @@ -33,7 +33,6 @@ public class CreateRequest { private String description; private String key; private String name; - private String qualifier; private String visibility; /** @@ -70,24 +69,6 @@ public class CreateRequest { return name; } - /** - * Possible values: - *
        - *
      • "VW"
      • - *
      • "APP"
      • - *
      - * @deprecated since 7.3 - */ - @Deprecated - public CreateRequest setQualifier(String qualifier) { - this.qualifier = qualifier; - return this; - } - - public String getQualifier() { - return qualifier; - } - /** * Possible values: *
        diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ModeRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ModeRequest.java deleted file mode 100644 index bd3593172d0..00000000000 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ModeRequest.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * SonarQube - * Copyright (C) 2009-2021 SonarSource SA - * mailto:info AT sonarsource DOT com - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ -package org.sonarqube.ws.client.views; - -import javax.annotation.Generated; - -/** - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 2.6 - */ -@Generated("sonar-ws-generator") -public class ModeRequest { - - private String key; - private String measure; - private String regexp; - private String selectionMode; - private String value; - - /** - * This is a mandatory parameter. - */ - public ModeRequest setKey(String key) { - this.key = key; - return this; - } - - public String getKey() { - return key; - } - - /** - */ - public ModeRequest setMeasure(String measure) { - this.measure = measure; - return this; - } - - public String getMeasure() { - return measure; - } - - /** - */ - public ModeRequest setRegexp(String regexp) { - this.regexp = regexp; - return this; - } - - public String getRegexp() { - return regexp; - } - - /** - * This is a mandatory parameter. - * Possible values: - *
          - *
        • "MANUAL"
        • - *
        • "REGEXP"
        • - *
        • "MANUAL_MEASURE"
        • - *
        • "REST"
        • - *
        - */ - public ModeRequest setSelectionMode(String selectionMode) { - this.selectionMode = selectionMode; - return this; - } - - public String getSelectionMode() { - return selectionMode; - } - - /** - */ - public ModeRequest setValue(String value) { - this.value = value; - return this; - } - - public String getValue() { - return value; - } -} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/RegexpRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/RegexpRequest.java deleted file mode 100644 index 743090dc706..00000000000 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/RegexpRequest.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * SonarQube - * Copyright (C) 2009-2021 SonarSource SA - * mailto:info AT sonarsource DOT com - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 3 of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - */ -package org.sonarqube.ws.client.views; - -import javax.annotation.Generated; - -/** - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 1.0 - */ -@Generated("sonar-ws-generator") -public class RegexpRequest { - - private String key; - private String regexp; - - /** - * This is a mandatory parameter. - */ - public RegexpRequest setKey(String key) { - this.key = key; - return this; - } - - public String getKey() { - return key; - } - - /** - * This is a mandatory parameter. - */ - public RegexpRequest setRegexp(String regexp) { - this.regexp = regexp; - return this; - } - - public String getRegexp() { - return regexp; - } -} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/SetNoneModeRequest.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/SetNoneModeRequest.java new file mode 100644 index 00000000000..b0582ae231d --- /dev/null +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/SetNoneModeRequest.java @@ -0,0 +1,47 @@ +/* + * SonarQube + * Copyright (C) 2009-2021 SonarSource SA + * mailto:info AT sonarsource DOT com + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +package org.sonarqube.ws.client.views; + +import javax.annotation.Generated; + +/** + * This is part of the internal API. + * This is a POST request. + * @see Further information about this action online (including a response example) + * @since 9.1 + */ +@Generated("sonar-ws-generator") +public class SetNoneModeRequest { + + private String portfolio; + + /** + * This is a mandatory parameter. + */ + public SetNoneModeRequest setPortfolio(String portfolio) { + this.portfolio = portfolio; + return this; + } + + public String getPortfolio() { + return portfolio; + } + +} diff --git a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ViewsService.java b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ViewsService.java index 52ba65115e0..d81260983b8 100644 --- a/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ViewsService.java +++ b/sonar-ws/src/main/java/org/sonarqube/ws/client/views/ViewsService.java @@ -114,7 +114,6 @@ public class ViewsService extends BaseService { .setParam("description", request.getDescription()) .setParam("key", request.getKey()) .setParam("name", request.getName()) - .setParam("qualifier", request.getQualifier()) .setParam("visibility", request.getVisibility()) .setMediaType(MediaTypes.JSON) ).content(); @@ -193,26 +192,6 @@ public class ViewsService extends BaseService { ).content(); } - /** - * - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 2.6 - * @deprecated since 7.4 - */ - public void mode(ModeRequest request) { - call( - new PostRequest(path("mode")) - .setParam("key", request.getKey()) - .setParam("measure", request.getMeasure()) - .setParam("regexp", request.getRegexp()) - .setParam("selectionMode", request.getSelectionMode()) - .setParam("value", request.getValue()) - .setMediaType(MediaTypes.JSON) - ).content(); - } - /** * * This is part of the internal API. @@ -278,23 +257,6 @@ public class ViewsService extends BaseService { ).content(); } - /** - * - * This is part of the internal API. - * This is a POST request. - * @see Further information about this action online (including a response example) - * @since 1.0 - * @deprecated since 7.4 - */ - public void regexp(RegexpRequest request) { - call( - new PostRequest(path("regexp")) - .setParam("key", request.getKey()) - .setParam("regexp", request.getRegexp()) - .setMediaType(MediaTypes.JSON) - ).content(); - } - /** * * This is part of the internal API. @@ -361,6 +323,21 @@ public class ViewsService extends BaseService { ).content(); } + /** + * + * This is part of the internal API. + * This is a POST request. + * @see Further information about this action online (including a response example) + * @since 9.1 + */ + public void setNoneMode(SetNoneModeRequest request) { + call( + new PostRequest(path("set_none_mode")) + .setParam("portfolio", request.getPortfolio()) + .setMediaType(MediaTypes.JSON) + ).content(); + } + /** * * This is part of the internal API. -- cgit v1.2.3