/*
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
 * in compliance with the License. You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under the License
 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
 * or implied. See the License for the specific language governing permissions and limitations under
 * the License.
 */
/*
 * This code was generated by https://github.com/googleapis/google-api-java-client-services/
 * Modify at your own risk.
 */

package com.google.api.services.recommender.v1beta1;

/**
 * Service definition for Recommender (v1beta1).
 *
 * <p>
 * 
 * </p>
 *
 * <p>
 * For more information about this service, see the
 * <a href="https://cloud.google.com/recommender/docs/" target="_blank">API Documentation</a>
 * </p>
 *
 * <p>
 * This service uses {@link RecommenderRequestInitializer} to initialize global parameters via its
 * {@link Builder}.
 * </p>
 *
 * @since 1.3
 * @author Google, Inc.
 */
@SuppressWarnings("javadoc")
public class Recommender extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient {

  // Note: Leave this static initializer at the top of the file.
  static {
    com.google.api.client.util.Preconditions.checkState(
        (com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION == 1 &&
        (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION >= 32 ||
        (com.google.api.client.googleapis.GoogleUtils.MINOR_VERSION == 31 &&
        com.google.api.client.googleapis.GoogleUtils.BUGFIX_VERSION >= 1))) ||
        com.google.api.client.googleapis.GoogleUtils.MAJOR_VERSION >= 2,
        "You are currently running with version %s of google-api-client. " +
        "You need at least version 1.31.1 of google-api-client to run version " +
        "2.0.0 of the Recommender API library.", com.google.api.client.googleapis.GoogleUtils.VERSION);
  }

  /**
   * The default encoded root URL of the service. This is determined when the library is generated
   * and normally should not be changed.
   *
   * @since 1.7
   */
  public static final String DEFAULT_ROOT_URL = "https://recommender.googleapis.com/";

  /**
   * The default encoded mTLS root URL of the service. This is determined when the library is generated
   * and normally should not be changed.
   *
   * @since 1.31
   */
  public static final String DEFAULT_MTLS_ROOT_URL = "https://recommender.mtls.googleapis.com/";

  /**
   * The default encoded service path of the service. This is determined when the library is
   * generated and normally should not be changed.
   *
   * @since 1.7
   */
  public static final String DEFAULT_SERVICE_PATH = "";

  /**
   * The default encoded batch path of the service. This is determined when the library is
   * generated and normally should not be changed.
   *
   * @since 1.23
   */
  public static final String DEFAULT_BATCH_PATH = "batch";

  /**
   * The default encoded base URL of the service. This is determined when the library is generated
   * and normally should not be changed.
   */
  public static final String DEFAULT_BASE_URL = DEFAULT_ROOT_URL + DEFAULT_SERVICE_PATH;

  /**
   * Constructor.
   *
   * <p>
   * Use {@link Builder} if you need to specify any of the optional parameters.
   * </p>
   *
   * @param transport HTTP transport, which should normally be:
   *        <ul>
   *        <li>Google App Engine:
   *        {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}</li>
   *        <li>Android: {@code newCompatibleTransport} from
   *        {@code com.google.api.client.extensions.android.http.AndroidHttp}</li>
   *        <li>Java: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()}
   *        </li>
   *        </ul>
   * @param jsonFactory JSON factory, which may be:
   *        <ul>
   *        <li>Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}</li>
   *        <li>Google GSON: {@code com.google.api.client.json.gson.GsonFactory}</li>
   *        <li>Android Honeycomb or higher:
   *        {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}</li>
   *        </ul>
   * @param httpRequestInitializer HTTP request initializer or {@code null} for none
   * @since 1.7
   */
  public Recommender(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory,
      com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) {
    this(new Builder(transport, jsonFactory, httpRequestInitializer));
  }

  /**
   * @param builder builder
   */
  Recommender(Builder builder) {
    super(builder);
  }

  @Override
  protected void initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest<?> httpClientRequest) throws java.io.IOException {
    super.initialize(httpClientRequest);
  }

  /**
   * An accessor for creating requests from the BillingAccounts collection.
   *
   * <p>The typical use is:</p>
   * <pre>
   *   {@code Recommender recommender = new Recommender(...);}
   *   {@code Recommender.BillingAccounts.List request = recommender.billingAccounts().list(parameters ...)}
   * </pre>
   *
   * @return the resource collection
   */
  public BillingAccounts billingAccounts() {
    return new BillingAccounts();
  }

  /**
   * The "billingAccounts" collection of methods.
   */
  public class BillingAccounts {

    /**
     * An accessor for creating requests from the Locations collection.
     *
     * <p>The typical use is:</p>
     * <pre>
     *   {@code Recommender recommender = new Recommender(...);}
     *   {@code Recommender.Locations.List request = recommender.locations().list(parameters ...)}
     * </pre>
     *
     * @return the resource collection
     */
    public Locations locations() {
      return new Locations();
    }

    /**
     * The "locations" collection of methods.
     */
    public class Locations {

      /**
       * An accessor for creating requests from the InsightTypes collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.InsightTypes.List request = recommender.insightTypes().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public InsightTypes insightTypes() {
        return new InsightTypes();
      }

      /**
       * The "insightTypes" collection of methods.
       */
      public class InsightTypes {

        /**
         * Gets the requested InsightTypeConfig. There is only one instance of the config for each
         * InsightType.
         *
         * Create a request for the method "insightTypes.getConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link GetConfig#execute()} method to invoke the remote operation.
         *
         * @param name Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` * `orga
         *        nizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/
         *        config`
         * @return the request
         */
        public GetConfig getConfig(java.lang.String name) throws java.io.IOException {
          GetConfig result = new GetConfig(name);
          initialize(result);
          return result;
        }

        public class GetConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");

          /**
           * Gets the requested InsightTypeConfig. There is only one instance of the config for each
           * InsightType.
           *
           * Create a request for the method "insightTypes.getConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link GetConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * GetConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` * `orga
         *        nizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/
         *        config`
           * @since 1.13
           */
          protected GetConfig(java.lang.String name) {
            super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
          }

          @Override
          public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
            return super.executeUsingHead();
          }

          @Override
          public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
            return super.buildHttpRequestUsingHead();
          }

          @Override
          public GetConfig set$Xgafv(java.lang.String $Xgafv) {
            return (GetConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public GetConfig setAccessToken(java.lang.String accessToken) {
            return (GetConfig) super.setAccessToken(accessToken);
          }

          @Override
          public GetConfig setAlt(java.lang.String alt) {
            return (GetConfig) super.setAlt(alt);
          }

          @Override
          public GetConfig setCallback(java.lang.String callback) {
            return (GetConfig) super.setCallback(callback);
          }

          @Override
          public GetConfig setFields(java.lang.String fields) {
            return (GetConfig) super.setFields(fields);
          }

          @Override
          public GetConfig setKey(java.lang.String key) {
            return (GetConfig) super.setKey(key);
          }

          @Override
          public GetConfig setOauthToken(java.lang.String oauthToken) {
            return (GetConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public GetConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (GetConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public GetConfig setQuotaUser(java.lang.String quotaUser) {
            return (GetConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public GetConfig setUploadType(java.lang.String uploadType) {
            return (GetConfig) super.setUploadType(uploadType);
          }

          @Override
          public GetConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (GetConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Required. Name of the InsightTypeConfig to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           * * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
           * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/co
           * nfig` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGH
           * T_TYPE_ID]/config`
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Required. Name of the InsightTypeConfig to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           * * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
           * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/co
           * nfig` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGH
           * T_TYPE_ID]/config`
           */
          public GetConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          @Override
          public GetConfig set(String parameterName, Object value) {
            return (GetConfig) super.set(parameterName, value);
          }
        }
        /**
         * Updates an InsightTypeConfig change. This will create a new revision of the config.
         *
         * Create a request for the method "insightTypes.updateConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link UpdateConfig#execute()} method to invoke the remote operation.
         *
         * @param name Name of insight type config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
         * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig}
         * @return the request
         */
        public UpdateConfig updateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig content) throws java.io.IOException {
          UpdateConfig result = new UpdateConfig(name, content);
          initialize(result);
          return result;
        }

        public class UpdateConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");

          /**
           * Updates an InsightTypeConfig change. This will create a new revision of the config.
           *
           * Create a request for the method "insightTypes.updateConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link UpdateConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * UpdateConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Name of insight type config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig}
           * @since 1.13
           */
          protected UpdateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig content) {
            super(Recommender.this, "PATCH", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
          }

          @Override
          public UpdateConfig set$Xgafv(java.lang.String $Xgafv) {
            return (UpdateConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public UpdateConfig setAccessToken(java.lang.String accessToken) {
            return (UpdateConfig) super.setAccessToken(accessToken);
          }

          @Override
          public UpdateConfig setAlt(java.lang.String alt) {
            return (UpdateConfig) super.setAlt(alt);
          }

          @Override
          public UpdateConfig setCallback(java.lang.String callback) {
            return (UpdateConfig) super.setCallback(callback);
          }

          @Override
          public UpdateConfig setFields(java.lang.String fields) {
            return (UpdateConfig) super.setFields(fields);
          }

          @Override
          public UpdateConfig setKey(java.lang.String key) {
            return (UpdateConfig) super.setKey(key);
          }

          @Override
          public UpdateConfig setOauthToken(java.lang.String oauthToken) {
            return (UpdateConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public UpdateConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (UpdateConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public UpdateConfig setQuotaUser(java.lang.String quotaUser) {
            return (UpdateConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public UpdateConfig setUploadType(java.lang.String uploadType) {
            return (UpdateConfig) super.setUploadType(uploadType);
          }

          @Override
          public UpdateConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (UpdateConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Name of insight type config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Name of insight type config. Eg,
         projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Name of insight type config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          public UpdateConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          /** The list of fields to be updated. */
          @com.google.api.client.util.Key
          private String updateMask;

          /** The list of fields to be updated.
           */
          public String getUpdateMask() {
            return updateMask;
          }

          /** The list of fields to be updated. */
          public UpdateConfig setUpdateMask(String updateMask) {
            this.updateMask = updateMask;
            return this;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          @com.google.api.client.util.Key
          private java.lang.Boolean validateOnly;

          /** If true, validate the request and preview the change, but do not actually update it.
           */
          public java.lang.Boolean getValidateOnly() {
            return validateOnly;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          public UpdateConfig setValidateOnly(java.lang.Boolean validateOnly) {
            this.validateOnly = validateOnly;
            return this;
          }

          @Override
          public UpdateConfig set(String parameterName, Object value) {
            return (UpdateConfig) super.set(parameterName, value);
          }
        }

        /**
         * An accessor for creating requests from the Insights collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Insights.List request = recommender.insights().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Insights insights() {
          return new Insights();
        }

        /**
         * The "insights" collection of methods.
         */
        public class Insights {

          /**
           * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
           * insight type.
           *
           * Create a request for the method "insights.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
             * insight type.
             *
             * Create a request for the method "insights.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
           * for the specified insight type.
           *
           * Create a request for the method "insights.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/insights";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+$");

            /**
             * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
             * for the specified insight type.
             *
             * Create a request for the method "insights.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ INSIGHT_TYPE_ID refers to
           supported insight types: https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Optional. Filter expression to restrict the insights returned. Supported filter fields: *
           `stateInfo.state` * `insightSubtype` * `severity` * `targetResources` Examples: * `stateInfo.state
           = ACTIVE OR stateInfo.state = DISMISSED` * `insightSubtype = PERMISSIONS_USAGE` * `severity =
           CRITICAL OR severity = HIGH` * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
           central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL OR severity =
           HIGH)` The max allowed filter length is 500 characters. (These expressions are based on the filter
           language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender API
           * that they have applied some action based on the insight. This stops the insight content from
           * being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified insight.
           *
           * Create a request for the method "insights.markAccepted".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkAccepted#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
           * @return the request
           */
          public MarkAccepted markAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) throws java.io.IOException {
            MarkAccepted result = new MarkAccepted(name, content);
            initialize(result);
            return result;
          }

          public class MarkAccepted extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}:markAccepted";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender
             * API that they have applied some action based on the insight. This stops the insight content
             * from being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires
             * the recommender.*.update IAM permission for the specified insight.
             *
             * Create a request for the method "insights.markAccepted".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkAccepted#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkAccepted#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
             * @since 1.13
             */
            protected MarkAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public MarkAccepted set$Xgafv(java.lang.String $Xgafv) {
              return (MarkAccepted) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkAccepted setAccessToken(java.lang.String accessToken) {
              return (MarkAccepted) super.setAccessToken(accessToken);
            }

            @Override
            public MarkAccepted setAlt(java.lang.String alt) {
              return (MarkAccepted) super.setAlt(alt);
            }

            @Override
            public MarkAccepted setCallback(java.lang.String callback) {
              return (MarkAccepted) super.setCallback(callback);
            }

            @Override
            public MarkAccepted setFields(java.lang.String fields) {
              return (MarkAccepted) super.setFields(fields);
            }

            @Override
            public MarkAccepted setKey(java.lang.String key) {
              return (MarkAccepted) super.setKey(key);
            }

            @Override
            public MarkAccepted setOauthToken(java.lang.String oauthToken) {
              return (MarkAccepted) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkAccepted setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkAccepted) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkAccepted setQuotaUser(java.lang.String quotaUser) {
              return (MarkAccepted) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkAccepted setUploadType(java.lang.String uploadType) {
              return (MarkAccepted) super.setUploadType(uploadType);
            }

            @Override
            public MarkAccepted setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkAccepted) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public MarkAccepted setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkAccepted set(String parameterName, Object value) {
              return (MarkAccepted) super.set(parameterName, value);
            }
          }

        }
      }
      /**
       * An accessor for creating requests from the Recommenders collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.Recommenders.List request = recommender.recommenders().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public Recommenders recommenders() {
        return new Recommenders();
      }

      /**
       * The "recommenders" collection of methods.
       */
      public class Recommenders {

        /**
         * Gets the requested Recommender Config. There is only one instance of the config for each
         * Recommender.
         *
         * Create a request for the method "recommenders.getConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link GetConfig#execute()} method to invoke the remote operation.
         *
         * @param name Required. Name of the Recommendation Config to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `organ
         *        izations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `b
         *        illingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/con
         *        fig`
         * @return the request
         */
        public GetConfig getConfig(java.lang.String name) throws java.io.IOException {
          GetConfig result = new GetConfig(name);
          initialize(result);
          return result;
        }

        public class GetConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");

          /**
           * Gets the requested Recommender Config. There is only one instance of the config for each
           * Recommender.
           *
           * Create a request for the method "recommenders.getConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link GetConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * GetConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Required. Name of the Recommendation Config to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `organ
         *        izations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `b
         *        illingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/con
         *        fig`
           * @since 1.13
           */
          protected GetConfig(java.lang.String name) {
            super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
          }

          @Override
          public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
            return super.executeUsingHead();
          }

          @Override
          public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
            return super.buildHttpRequestUsingHead();
          }

          @Override
          public GetConfig set$Xgafv(java.lang.String $Xgafv) {
            return (GetConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public GetConfig setAccessToken(java.lang.String accessToken) {
            return (GetConfig) super.setAccessToken(accessToken);
          }

          @Override
          public GetConfig setAlt(java.lang.String alt) {
            return (GetConfig) super.setAlt(alt);
          }

          @Override
          public GetConfig setCallback(java.lang.String callback) {
            return (GetConfig) super.setCallback(callback);
          }

          @Override
          public GetConfig setFields(java.lang.String fields) {
            return (GetConfig) super.setFields(fields);
          }

          @Override
          public GetConfig setKey(java.lang.String key) {
            return (GetConfig) super.setKey(key);
          }

          @Override
          public GetConfig setOauthToken(java.lang.String oauthToken) {
            return (GetConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public GetConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (GetConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public GetConfig setQuotaUser(java.lang.String quotaUser) {
            return (GetConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public GetConfig setUploadType(java.lang.String uploadType) {
            return (GetConfig) super.setUploadType(uploadType);
          }

          @Override
          public GetConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (GetConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Required. Name of the Recommendation Config to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
           * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `or
           * ganizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * ` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDE
           * R_ID]/config`
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Required. Name of the Recommendation Config to get. Acceptable formats: *
         `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config`
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Required. Name of the Recommendation Config to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
           * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `or
           * ganizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * ` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDE
           * R_ID]/config`
           */
          public GetConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          @Override
          public GetConfig set(String parameterName, Object value) {
            return (GetConfig) super.set(parameterName, value);
          }
        }
        /**
         * Updates a Recommender Config. This will create a new revision of the config.
         *
         * Create a request for the method "recommenders.updateConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link UpdateConfig#execute()} method to invoke the remote operation.
         *
         * @param name Name of recommender config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
         * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig}
         * @return the request
         */
        public UpdateConfig updateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig content) throws java.io.IOException {
          UpdateConfig result = new UpdateConfig(name, content);
          initialize(result);
          return result;
        }

        public class UpdateConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");

          /**
           * Updates a Recommender Config. This will create a new revision of the config.
           *
           * Create a request for the method "recommenders.updateConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link UpdateConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * UpdateConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Name of recommender config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig}
           * @since 1.13
           */
          protected UpdateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig content) {
            super(Recommender.this, "PATCH", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
          }

          @Override
          public UpdateConfig set$Xgafv(java.lang.String $Xgafv) {
            return (UpdateConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public UpdateConfig setAccessToken(java.lang.String accessToken) {
            return (UpdateConfig) super.setAccessToken(accessToken);
          }

          @Override
          public UpdateConfig setAlt(java.lang.String alt) {
            return (UpdateConfig) super.setAlt(alt);
          }

          @Override
          public UpdateConfig setCallback(java.lang.String callback) {
            return (UpdateConfig) super.setCallback(callback);
          }

          @Override
          public UpdateConfig setFields(java.lang.String fields) {
            return (UpdateConfig) super.setFields(fields);
          }

          @Override
          public UpdateConfig setKey(java.lang.String key) {
            return (UpdateConfig) super.setKey(key);
          }

          @Override
          public UpdateConfig setOauthToken(java.lang.String oauthToken) {
            return (UpdateConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public UpdateConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (UpdateConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public UpdateConfig setQuotaUser(java.lang.String quotaUser) {
            return (UpdateConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public UpdateConfig setUploadType(java.lang.String uploadType) {
            return (UpdateConfig) super.setUploadType(uploadType);
          }

          @Override
          public UpdateConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (UpdateConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Name of recommender config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Name of recommender config. Eg,
         projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Name of recommender config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          public UpdateConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          /** The list of fields to be updated. */
          @com.google.api.client.util.Key
          private String updateMask;

          /** The list of fields to be updated.
           */
          public String getUpdateMask() {
            return updateMask;
          }

          /** The list of fields to be updated. */
          public UpdateConfig setUpdateMask(String updateMask) {
            this.updateMask = updateMask;
            return this;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          @com.google.api.client.util.Key
          private java.lang.Boolean validateOnly;

          /** If true, validate the request and preview the change, but do not actually update it.
           */
          public java.lang.Boolean getValidateOnly() {
            return validateOnly;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          public UpdateConfig setValidateOnly(java.lang.Boolean validateOnly) {
            this.validateOnly = validateOnly;
            return this;
          }

          @Override
          public UpdateConfig set(String parameterName, Object value) {
            return (UpdateConfig) super.set(parameterName, value);
          }
        }

        /**
         * An accessor for creating requests from the Recommendations collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Recommendations.List request = recommender.recommendations().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Recommendations recommendations() {
          return new Recommendations();
        }

        /**
         * The "recommendations" collection of methods.
         */
        public class Recommendations {

          /**
           * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
           * specified recommender.
           *
           * Create a request for the method "recommendations.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
             * specified recommender.
             *
             * Create a request for the method "recommendations.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
           * permission for the specified recommender.
           *
           * Create a request for the method "recommendations.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/recommendations";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+$");

            /**
             * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
             * permission for the specified recommender.
             *
             * Create a request for the method "recommendations.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ RECOMMENDER_ID refers to
           supported recommenders: https://cloud.google.com/recommender/docs/recommenders.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Filter expression to restrict the recommendations returned. Supported filter fields: *
           `state_info.state` * `recommenderSubtype` * `priority` * `targetResources` Examples: *
           `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` * `recommenderSubtype = REMOVE_ROLE OR
           recommenderSubtype = REPLACE_ROLE` * `priority = P1 OR priority = P2` * `targetResources :
           //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` * `stateInfo.state
           = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed filter length is 500 characters.
           (These expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
           * Recommender API that they are starting to apply the recommendation themselves. This stops the
           * recommendation content from being updated. Associated insights are frozen and placed in the
           * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or ACTIVE
           * state. Requires the recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markClaimed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkClaimed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
           * @return the request
           */
          public MarkClaimed markClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) throws java.io.IOException {
            MarkClaimed result = new MarkClaimed(name, content);
            initialize(result);
            return result;
          }

          public class MarkClaimed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markClaimed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
             * Recommender API that they are starting to apply the recommendation themselves. This stops the
             * recommendation content from being updated. Associated insights are frozen and placed in the
             * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or
             * ACTIVE state. Requires the recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markClaimed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkClaimed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkClaimed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
             * @since 1.13
             */
            protected MarkClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkClaimed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkClaimed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkClaimed setAccessToken(java.lang.String accessToken) {
              return (MarkClaimed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkClaimed setAlt(java.lang.String alt) {
              return (MarkClaimed) super.setAlt(alt);
            }

            @Override
            public MarkClaimed setCallback(java.lang.String callback) {
              return (MarkClaimed) super.setCallback(callback);
            }

            @Override
            public MarkClaimed setFields(java.lang.String fields) {
              return (MarkClaimed) super.setFields(fields);
            }

            @Override
            public MarkClaimed setKey(java.lang.String key) {
              return (MarkClaimed) super.setKey(key);
            }

            @Override
            public MarkClaimed setOauthToken(java.lang.String oauthToken) {
              return (MarkClaimed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkClaimed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkClaimed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkClaimed setQuotaUser(java.lang.String quotaUser) {
              return (MarkClaimed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkClaimed setUploadType(java.lang.String uploadType) {
              return (MarkClaimed) super.setUploadType(uploadType);
            }

            @Override
            public MarkClaimed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkClaimed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkClaimed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkClaimed set(String parameterName, Object value) {
              return (MarkClaimed) super.set(parameterName, value);
            }
          }
          /**
           * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
           * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
           * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markDismissed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkDismissed#execute()} method to invoke the remote operation.
           *
           * @param name Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
           * @return the request
           */
          public MarkDismissed markDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) throws java.io.IOException {
            MarkDismissed result = new MarkDismissed(name, content);
            initialize(result);
            return result;
          }

          public class MarkDismissed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markDismissed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
             * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
             * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markDismissed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkDismissed#execute()} method to invoke the remote
             * operation. <p> {@link MarkDismissed#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
             * @since 1.13
             */
            protected MarkDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkDismissed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkDismissed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkDismissed setAccessToken(java.lang.String accessToken) {
              return (MarkDismissed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkDismissed setAlt(java.lang.String alt) {
              return (MarkDismissed) super.setAlt(alt);
            }

            @Override
            public MarkDismissed setCallback(java.lang.String callback) {
              return (MarkDismissed) super.setCallback(callback);
            }

            @Override
            public MarkDismissed setFields(java.lang.String fields) {
              return (MarkDismissed) super.setFields(fields);
            }

            @Override
            public MarkDismissed setKey(java.lang.String key) {
              return (MarkDismissed) super.setKey(key);
            }

            @Override
            public MarkDismissed setOauthToken(java.lang.String oauthToken) {
              return (MarkDismissed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkDismissed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkDismissed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkDismissed setQuotaUser(java.lang.String quotaUser) {
              return (MarkDismissed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkDismissed setUploadType(java.lang.String uploadType) {
              return (MarkDismissed) super.setUploadType(uploadType);
            }

            @Override
            public MarkDismissed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkDismissed) super.setUploadProtocol(uploadProtocol);
            }

            /** Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Name of the recommendation. */
            public MarkDismissed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkDismissed set(String parameterName, Object value) {
              return (MarkDismissed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Failed. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation failed.
           * This stops the recommendation content from being updated. Associated insights are frozen and
           * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
           * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission for
           * the specified recommender.
           *
           * Create a request for the method "recommendations.markFailed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkFailed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
           * @return the request
           */
          public MarkFailed markFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) throws java.io.IOException {
            MarkFailed result = new MarkFailed(name, content);
            initialize(result);
            return result;
          }

          public class MarkFailed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markFailed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Failed. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation failed.
             * This stops the recommendation content from being updated. Associated insights are frozen and
             * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
             * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission
             * for the specified recommender.
             *
             * Create a request for the method "recommendations.markFailed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkFailed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkFailed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
             * @since 1.13
             */
            protected MarkFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkFailed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkFailed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkFailed setAccessToken(java.lang.String accessToken) {
              return (MarkFailed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkFailed setAlt(java.lang.String alt) {
              return (MarkFailed) super.setAlt(alt);
            }

            @Override
            public MarkFailed setCallback(java.lang.String callback) {
              return (MarkFailed) super.setCallback(callback);
            }

            @Override
            public MarkFailed setFields(java.lang.String fields) {
              return (MarkFailed) super.setFields(fields);
            }

            @Override
            public MarkFailed setKey(java.lang.String key) {
              return (MarkFailed) super.setKey(key);
            }

            @Override
            public MarkFailed setOauthToken(java.lang.String oauthToken) {
              return (MarkFailed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkFailed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkFailed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkFailed setQuotaUser(java.lang.String quotaUser) {
              return (MarkFailed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkFailed setUploadType(java.lang.String uploadType) {
              return (MarkFailed) super.setUploadType(uploadType);
            }

            @Override
            public MarkFailed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkFailed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkFailed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkFailed set(String parameterName, Object value) {
              return (MarkFailed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation was
           * successful. This stops the recommendation content from being updated. Associated insights are
           * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
           * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update
           * IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markSucceeded".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
           * @return the request
           */
          public MarkSucceeded markSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) throws java.io.IOException {
            MarkSucceeded result = new MarkSucceeded(name, content);
            initialize(result);
            return result;
          }

          public class MarkSucceeded extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markSucceeded";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation was
             * successful. This stops the recommendation content from being updated. Associated insights are
             * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
             * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markSucceeded".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote
             * operation. <p> {@link MarkSucceeded#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
             * @since 1.13
             */
            protected MarkSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkSucceeded set$Xgafv(java.lang.String $Xgafv) {
              return (MarkSucceeded) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkSucceeded setAccessToken(java.lang.String accessToken) {
              return (MarkSucceeded) super.setAccessToken(accessToken);
            }

            @Override
            public MarkSucceeded setAlt(java.lang.String alt) {
              return (MarkSucceeded) super.setAlt(alt);
            }

            @Override
            public MarkSucceeded setCallback(java.lang.String callback) {
              return (MarkSucceeded) super.setCallback(callback);
            }

            @Override
            public MarkSucceeded setFields(java.lang.String fields) {
              return (MarkSucceeded) super.setFields(fields);
            }

            @Override
            public MarkSucceeded setKey(java.lang.String key) {
              return (MarkSucceeded) super.setKey(key);
            }

            @Override
            public MarkSucceeded setOauthToken(java.lang.String oauthToken) {
              return (MarkSucceeded) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkSucceeded setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkSucceeded) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkSucceeded setQuotaUser(java.lang.String quotaUser) {
              return (MarkSucceeded) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkSucceeded setUploadType(java.lang.String uploadType) {
              return (MarkSucceeded) super.setUploadType(uploadType);
            }

            @Override
            public MarkSucceeded setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkSucceeded) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkSucceeded setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^billingAccounts/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkSucceeded set(String parameterName, Object value) {
              return (MarkSucceeded) super.set(parameterName, value);
            }
          }

        }
      }
    }
  }

  /**
   * An accessor for creating requests from the Folders collection.
   *
   * <p>The typical use is:</p>
   * <pre>
   *   {@code Recommender recommender = new Recommender(...);}
   *   {@code Recommender.Folders.List request = recommender.folders().list(parameters ...)}
   * </pre>
   *
   * @return the resource collection
   */
  public Folders folders() {
    return new Folders();
  }

  /**
   * The "folders" collection of methods.
   */
  public class Folders {

    /**
     * An accessor for creating requests from the Locations collection.
     *
     * <p>The typical use is:</p>
     * <pre>
     *   {@code Recommender recommender = new Recommender(...);}
     *   {@code Recommender.Locations.List request = recommender.locations().list(parameters ...)}
     * </pre>
     *
     * @return the resource collection
     */
    public Locations locations() {
      return new Locations();
    }

    /**
     * The "locations" collection of methods.
     */
    public class Locations {

      /**
       * An accessor for creating requests from the InsightTypes collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.InsightTypes.List request = recommender.insightTypes().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public InsightTypes insightTypes() {
        return new InsightTypes();
      }

      /**
       * The "insightTypes" collection of methods.
       */
      public class InsightTypes {

        /**
         * An accessor for creating requests from the Insights collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Insights.List request = recommender.insights().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Insights insights() {
          return new Insights();
        }

        /**
         * The "insights" collection of methods.
         */
        public class Insights {

          /**
           * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
           * insight type.
           *
           * Create a request for the method "insights.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
             * insight type.
             *
             * Create a request for the method "insights.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
           * for the specified insight type.
           *
           * Create a request for the method "insights.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/insights";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+$");

            /**
             * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
             * for the specified insight type.
             *
             * Create a request for the method "insights.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ INSIGHT_TYPE_ID refers to
           supported insight types: https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Optional. Filter expression to restrict the insights returned. Supported filter fields: *
           `stateInfo.state` * `insightSubtype` * `severity` * `targetResources` Examples: * `stateInfo.state
           = ACTIVE OR stateInfo.state = DISMISSED` * `insightSubtype = PERMISSIONS_USAGE` * `severity =
           CRITICAL OR severity = HIGH` * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
           central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL OR severity =
           HIGH)` The max allowed filter length is 500 characters. (These expressions are based on the filter
           language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender API
           * that they have applied some action based on the insight. This stops the insight content from
           * being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified insight.
           *
           * Create a request for the method "insights.markAccepted".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkAccepted#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
           * @return the request
           */
          public MarkAccepted markAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) throws java.io.IOException {
            MarkAccepted result = new MarkAccepted(name, content);
            initialize(result);
            return result;
          }

          public class MarkAccepted extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}:markAccepted";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender
             * API that they have applied some action based on the insight. This stops the insight content
             * from being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires
             * the recommender.*.update IAM permission for the specified insight.
             *
             * Create a request for the method "insights.markAccepted".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkAccepted#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkAccepted#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
             * @since 1.13
             */
            protected MarkAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public MarkAccepted set$Xgafv(java.lang.String $Xgafv) {
              return (MarkAccepted) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkAccepted setAccessToken(java.lang.String accessToken) {
              return (MarkAccepted) super.setAccessToken(accessToken);
            }

            @Override
            public MarkAccepted setAlt(java.lang.String alt) {
              return (MarkAccepted) super.setAlt(alt);
            }

            @Override
            public MarkAccepted setCallback(java.lang.String callback) {
              return (MarkAccepted) super.setCallback(callback);
            }

            @Override
            public MarkAccepted setFields(java.lang.String fields) {
              return (MarkAccepted) super.setFields(fields);
            }

            @Override
            public MarkAccepted setKey(java.lang.String key) {
              return (MarkAccepted) super.setKey(key);
            }

            @Override
            public MarkAccepted setOauthToken(java.lang.String oauthToken) {
              return (MarkAccepted) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkAccepted setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkAccepted) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkAccepted setQuotaUser(java.lang.String quotaUser) {
              return (MarkAccepted) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkAccepted setUploadType(java.lang.String uploadType) {
              return (MarkAccepted) super.setUploadType(uploadType);
            }

            @Override
            public MarkAccepted setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkAccepted) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public MarkAccepted setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkAccepted set(String parameterName, Object value) {
              return (MarkAccepted) super.set(parameterName, value);
            }
          }

        }
      }
      /**
       * An accessor for creating requests from the Recommenders collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.Recommenders.List request = recommender.recommenders().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public Recommenders recommenders() {
        return new Recommenders();
      }

      /**
       * The "recommenders" collection of methods.
       */
      public class Recommenders {

        /**
         * An accessor for creating requests from the Recommendations collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Recommendations.List request = recommender.recommendations().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Recommendations recommendations() {
          return new Recommendations();
        }

        /**
         * The "recommendations" collection of methods.
         */
        public class Recommendations {

          /**
           * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
           * specified recommender.
           *
           * Create a request for the method "recommendations.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
             * specified recommender.
             *
             * Create a request for the method "recommendations.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
           * permission for the specified recommender.
           *
           * Create a request for the method "recommendations.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/recommendations";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/recommenders/[^/]+$");

            /**
             * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
             * permission for the specified recommender.
             *
             * Create a request for the method "recommendations.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ RECOMMENDER_ID refers to
           supported recommenders: https://cloud.google.com/recommender/docs/recommenders.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Filter expression to restrict the recommendations returned. Supported filter fields: *
           `state_info.state` * `recommenderSubtype` * `priority` * `targetResources` Examples: *
           `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` * `recommenderSubtype = REMOVE_ROLE OR
           recommenderSubtype = REPLACE_ROLE` * `priority = P1 OR priority = P2` * `targetResources :
           //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` * `stateInfo.state
           = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed filter length is 500 characters.
           (These expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
           * Recommender API that they are starting to apply the recommendation themselves. This stops the
           * recommendation content from being updated. Associated insights are frozen and placed in the
           * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or ACTIVE
           * state. Requires the recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markClaimed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkClaimed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
           * @return the request
           */
          public MarkClaimed markClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) throws java.io.IOException {
            MarkClaimed result = new MarkClaimed(name, content);
            initialize(result);
            return result;
          }

          public class MarkClaimed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markClaimed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
             * Recommender API that they are starting to apply the recommendation themselves. This stops the
             * recommendation content from being updated. Associated insights are frozen and placed in the
             * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or
             * ACTIVE state. Requires the recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markClaimed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkClaimed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkClaimed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
             * @since 1.13
             */
            protected MarkClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkClaimed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkClaimed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkClaimed setAccessToken(java.lang.String accessToken) {
              return (MarkClaimed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkClaimed setAlt(java.lang.String alt) {
              return (MarkClaimed) super.setAlt(alt);
            }

            @Override
            public MarkClaimed setCallback(java.lang.String callback) {
              return (MarkClaimed) super.setCallback(callback);
            }

            @Override
            public MarkClaimed setFields(java.lang.String fields) {
              return (MarkClaimed) super.setFields(fields);
            }

            @Override
            public MarkClaimed setKey(java.lang.String key) {
              return (MarkClaimed) super.setKey(key);
            }

            @Override
            public MarkClaimed setOauthToken(java.lang.String oauthToken) {
              return (MarkClaimed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkClaimed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkClaimed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkClaimed setQuotaUser(java.lang.String quotaUser) {
              return (MarkClaimed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkClaimed setUploadType(java.lang.String uploadType) {
              return (MarkClaimed) super.setUploadType(uploadType);
            }

            @Override
            public MarkClaimed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkClaimed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkClaimed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkClaimed set(String parameterName, Object value) {
              return (MarkClaimed) super.set(parameterName, value);
            }
          }
          /**
           * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
           * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
           * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markDismissed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkDismissed#execute()} method to invoke the remote operation.
           *
           * @param name Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
           * @return the request
           */
          public MarkDismissed markDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) throws java.io.IOException {
            MarkDismissed result = new MarkDismissed(name, content);
            initialize(result);
            return result;
          }

          public class MarkDismissed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markDismissed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
             * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
             * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markDismissed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkDismissed#execute()} method to invoke the remote
             * operation. <p> {@link MarkDismissed#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
             * @since 1.13
             */
            protected MarkDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkDismissed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkDismissed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkDismissed setAccessToken(java.lang.String accessToken) {
              return (MarkDismissed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkDismissed setAlt(java.lang.String alt) {
              return (MarkDismissed) super.setAlt(alt);
            }

            @Override
            public MarkDismissed setCallback(java.lang.String callback) {
              return (MarkDismissed) super.setCallback(callback);
            }

            @Override
            public MarkDismissed setFields(java.lang.String fields) {
              return (MarkDismissed) super.setFields(fields);
            }

            @Override
            public MarkDismissed setKey(java.lang.String key) {
              return (MarkDismissed) super.setKey(key);
            }

            @Override
            public MarkDismissed setOauthToken(java.lang.String oauthToken) {
              return (MarkDismissed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkDismissed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkDismissed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkDismissed setQuotaUser(java.lang.String quotaUser) {
              return (MarkDismissed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkDismissed setUploadType(java.lang.String uploadType) {
              return (MarkDismissed) super.setUploadType(uploadType);
            }

            @Override
            public MarkDismissed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkDismissed) super.setUploadProtocol(uploadProtocol);
            }

            /** Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Name of the recommendation. */
            public MarkDismissed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkDismissed set(String parameterName, Object value) {
              return (MarkDismissed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Failed. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation failed.
           * This stops the recommendation content from being updated. Associated insights are frozen and
           * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
           * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission for
           * the specified recommender.
           *
           * Create a request for the method "recommendations.markFailed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkFailed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
           * @return the request
           */
          public MarkFailed markFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) throws java.io.IOException {
            MarkFailed result = new MarkFailed(name, content);
            initialize(result);
            return result;
          }

          public class MarkFailed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markFailed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Failed. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation failed.
             * This stops the recommendation content from being updated. Associated insights are frozen and
             * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
             * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission
             * for the specified recommender.
             *
             * Create a request for the method "recommendations.markFailed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkFailed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkFailed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
             * @since 1.13
             */
            protected MarkFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkFailed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkFailed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkFailed setAccessToken(java.lang.String accessToken) {
              return (MarkFailed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkFailed setAlt(java.lang.String alt) {
              return (MarkFailed) super.setAlt(alt);
            }

            @Override
            public MarkFailed setCallback(java.lang.String callback) {
              return (MarkFailed) super.setCallback(callback);
            }

            @Override
            public MarkFailed setFields(java.lang.String fields) {
              return (MarkFailed) super.setFields(fields);
            }

            @Override
            public MarkFailed setKey(java.lang.String key) {
              return (MarkFailed) super.setKey(key);
            }

            @Override
            public MarkFailed setOauthToken(java.lang.String oauthToken) {
              return (MarkFailed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkFailed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkFailed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkFailed setQuotaUser(java.lang.String quotaUser) {
              return (MarkFailed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkFailed setUploadType(java.lang.String uploadType) {
              return (MarkFailed) super.setUploadType(uploadType);
            }

            @Override
            public MarkFailed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkFailed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkFailed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkFailed set(String parameterName, Object value) {
              return (MarkFailed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation was
           * successful. This stops the recommendation content from being updated. Associated insights are
           * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
           * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update
           * IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markSucceeded".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
           * @return the request
           */
          public MarkSucceeded markSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) throws java.io.IOException {
            MarkSucceeded result = new MarkSucceeded(name, content);
            initialize(result);
            return result;
          }

          public class MarkSucceeded extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markSucceeded";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation was
             * successful. This stops the recommendation content from being updated. Associated insights are
             * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
             * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markSucceeded".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote
             * operation. <p> {@link MarkSucceeded#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
             * @since 1.13
             */
            protected MarkSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkSucceeded set$Xgafv(java.lang.String $Xgafv) {
              return (MarkSucceeded) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkSucceeded setAccessToken(java.lang.String accessToken) {
              return (MarkSucceeded) super.setAccessToken(accessToken);
            }

            @Override
            public MarkSucceeded setAlt(java.lang.String alt) {
              return (MarkSucceeded) super.setAlt(alt);
            }

            @Override
            public MarkSucceeded setCallback(java.lang.String callback) {
              return (MarkSucceeded) super.setCallback(callback);
            }

            @Override
            public MarkSucceeded setFields(java.lang.String fields) {
              return (MarkSucceeded) super.setFields(fields);
            }

            @Override
            public MarkSucceeded setKey(java.lang.String key) {
              return (MarkSucceeded) super.setKey(key);
            }

            @Override
            public MarkSucceeded setOauthToken(java.lang.String oauthToken) {
              return (MarkSucceeded) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkSucceeded setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkSucceeded) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkSucceeded setQuotaUser(java.lang.String quotaUser) {
              return (MarkSucceeded) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkSucceeded setUploadType(java.lang.String uploadType) {
              return (MarkSucceeded) super.setUploadType(uploadType);
            }

            @Override
            public MarkSucceeded setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkSucceeded) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkSucceeded setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^folders/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkSucceeded set(String parameterName, Object value) {
              return (MarkSucceeded) super.set(parameterName, value);
            }
          }

        }
      }
    }
  }

  /**
   * An accessor for creating requests from the InsightTypes collection.
   *
   * <p>The typical use is:</p>
   * <pre>
   *   {@code Recommender recommender = new Recommender(...);}
   *   {@code Recommender.InsightTypes.List request = recommender.insightTypes().list(parameters ...)}
   * </pre>
   *
   * @return the resource collection
   */
  public InsightTypes insightTypes() {
    return new InsightTypes();
  }

  /**
   * The "insightTypes" collection of methods.
   */
  public class InsightTypes {

    /**
     * Lists available InsightTypes. No IAM permissions are required.
     *
     * Create a request for the method "insightTypes.list".
     *
     * This request holds the parameters needed by the recommender server.  After setting any optional
     * parameters, call the {@link List#execute()} method to invoke the remote operation.
     *
     * @return the request
     */
    public List list() throws java.io.IOException {
      List result = new List();
      initialize(result);
      return result;
    }

    public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightTypesResponse> {

      private static final String REST_PATH = "v1beta1/insightTypes";

      /**
       * Lists available InsightTypes. No IAM permissions are required.
       *
       * Create a request for the method "insightTypes.list".
       *
       * This request holds the parameters needed by the the recommender server.  After setting any
       * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
       * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
       * must be called to initialize this instance immediately after invoking the constructor. </p>
       *
       * @since 1.13
       */
      protected List() {
        super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightTypesResponse.class);
      }

      @Override
      public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
        return super.executeUsingHead();
      }

      @Override
      public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
        return super.buildHttpRequestUsingHead();
      }

      @Override
      public List set$Xgafv(java.lang.String $Xgafv) {
        return (List) super.set$Xgafv($Xgafv);
      }

      @Override
      public List setAccessToken(java.lang.String accessToken) {
        return (List) super.setAccessToken(accessToken);
      }

      @Override
      public List setAlt(java.lang.String alt) {
        return (List) super.setAlt(alt);
      }

      @Override
      public List setCallback(java.lang.String callback) {
        return (List) super.setCallback(callback);
      }

      @Override
      public List setFields(java.lang.String fields) {
        return (List) super.setFields(fields);
      }

      @Override
      public List setKey(java.lang.String key) {
        return (List) super.setKey(key);
      }

      @Override
      public List setOauthToken(java.lang.String oauthToken) {
        return (List) super.setOauthToken(oauthToken);
      }

      @Override
      public List setPrettyPrint(java.lang.Boolean prettyPrint) {
        return (List) super.setPrettyPrint(prettyPrint);
      }

      @Override
      public List setQuotaUser(java.lang.String quotaUser) {
        return (List) super.setQuotaUser(quotaUser);
      }

      @Override
      public List setUploadType(java.lang.String uploadType) {
        return (List) super.setUploadType(uploadType);
      }

      @Override
      public List setUploadProtocol(java.lang.String uploadProtocol) {
        return (List) super.setUploadProtocol(uploadProtocol);
      }

      /**
       * Optional. The number of InsightTypes to return per page. The service may return fewer than
       * this value.
       */
      @com.google.api.client.util.Key
      private java.lang.Integer pageSize;

      /** Optional. The number of InsightTypes to return per page. The service may return fewer than this
     value.
       */
      public java.lang.Integer getPageSize() {
        return pageSize;
      }

      /**
       * Optional. The number of InsightTypes to return per page. The service may return fewer than
       * this value.
       */
      public List setPageSize(java.lang.Integer pageSize) {
        this.pageSize = pageSize;
        return this;
      }

      /**
       * Optional. A page token, received from a previous `ListRecommenders` call. Provide this to
       * retrieve the subsequent page.
       */
      @com.google.api.client.util.Key
      private java.lang.String pageToken;

      /** Optional. A page token, received from a previous `ListRecommenders` call. Provide this to retrieve
     the subsequent page.
       */
      public java.lang.String getPageToken() {
        return pageToken;
      }

      /**
       * Optional. A page token, received from a previous `ListRecommenders` call. Provide this to
       * retrieve the subsequent page.
       */
      public List setPageToken(java.lang.String pageToken) {
        this.pageToken = pageToken;
        return this;
      }

      @Override
      public List set(String parameterName, Object value) {
        return (List) super.set(parameterName, value);
      }
    }

  }

  /**
   * An accessor for creating requests from the Organizations collection.
   *
   * <p>The typical use is:</p>
   * <pre>
   *   {@code Recommender recommender = new Recommender(...);}
   *   {@code Recommender.Organizations.List request = recommender.organizations().list(parameters ...)}
   * </pre>
   *
   * @return the resource collection
   */
  public Organizations organizations() {
    return new Organizations();
  }

  /**
   * The "organizations" collection of methods.
   */
  public class Organizations {

    /**
     * An accessor for creating requests from the Locations collection.
     *
     * <p>The typical use is:</p>
     * <pre>
     *   {@code Recommender recommender = new Recommender(...);}
     *   {@code Recommender.Locations.List request = recommender.locations().list(parameters ...)}
     * </pre>
     *
     * @return the resource collection
     */
    public Locations locations() {
      return new Locations();
    }

    /**
     * The "locations" collection of methods.
     */
    public class Locations {

      /**
       * An accessor for creating requests from the InsightTypes collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.InsightTypes.List request = recommender.insightTypes().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public InsightTypes insightTypes() {
        return new InsightTypes();
      }

      /**
       * The "insightTypes" collection of methods.
       */
      public class InsightTypes {

        /**
         * Gets the requested InsightTypeConfig. There is only one instance of the config for each
         * InsightType.
         *
         * Create a request for the method "insightTypes.getConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link GetConfig#execute()} method to invoke the remote operation.
         *
         * @param name Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` * `orga
         *        nizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/
         *        config`
         * @return the request
         */
        public GetConfig getConfig(java.lang.String name) throws java.io.IOException {
          GetConfig result = new GetConfig(name);
          initialize(result);
          return result;
        }

        public class GetConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");

          /**
           * Gets the requested InsightTypeConfig. There is only one instance of the config for each
           * InsightType.
           *
           * Create a request for the method "insightTypes.getConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link GetConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * GetConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` * `orga
         *        nizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/
         *        config`
           * @since 1.13
           */
          protected GetConfig(java.lang.String name) {
            super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
          }

          @Override
          public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
            return super.executeUsingHead();
          }

          @Override
          public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
            return super.buildHttpRequestUsingHead();
          }

          @Override
          public GetConfig set$Xgafv(java.lang.String $Xgafv) {
            return (GetConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public GetConfig setAccessToken(java.lang.String accessToken) {
            return (GetConfig) super.setAccessToken(accessToken);
          }

          @Override
          public GetConfig setAlt(java.lang.String alt) {
            return (GetConfig) super.setAlt(alt);
          }

          @Override
          public GetConfig setCallback(java.lang.String callback) {
            return (GetConfig) super.setCallback(callback);
          }

          @Override
          public GetConfig setFields(java.lang.String fields) {
            return (GetConfig) super.setFields(fields);
          }

          @Override
          public GetConfig setKey(java.lang.String key) {
            return (GetConfig) super.setKey(key);
          }

          @Override
          public GetConfig setOauthToken(java.lang.String oauthToken) {
            return (GetConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public GetConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (GetConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public GetConfig setQuotaUser(java.lang.String quotaUser) {
            return (GetConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public GetConfig setUploadType(java.lang.String uploadType) {
            return (GetConfig) super.setUploadType(uploadType);
          }

          @Override
          public GetConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (GetConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Required. Name of the InsightTypeConfig to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           * * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
           * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/co
           * nfig` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGH
           * T_TYPE_ID]/config`
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Required. Name of the InsightTypeConfig to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           * * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
           * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/co
           * nfig` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGH
           * T_TYPE_ID]/config`
           */
          public GetConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          @Override
          public GetConfig set(String parameterName, Object value) {
            return (GetConfig) super.set(parameterName, value);
          }
        }
        /**
         * Updates an InsightTypeConfig change. This will create a new revision of the config.
         *
         * Create a request for the method "insightTypes.updateConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link UpdateConfig#execute()} method to invoke the remote operation.
         *
         * @param name Name of insight type config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
         * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig}
         * @return the request
         */
        public UpdateConfig updateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig content) throws java.io.IOException {
          UpdateConfig result = new UpdateConfig(name, content);
          initialize(result);
          return result;
        }

        public class UpdateConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");

          /**
           * Updates an InsightTypeConfig change. This will create a new revision of the config.
           *
           * Create a request for the method "insightTypes.updateConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link UpdateConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * UpdateConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Name of insight type config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig}
           * @since 1.13
           */
          protected UpdateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig content) {
            super(Recommender.this, "PATCH", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
          }

          @Override
          public UpdateConfig set$Xgafv(java.lang.String $Xgafv) {
            return (UpdateConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public UpdateConfig setAccessToken(java.lang.String accessToken) {
            return (UpdateConfig) super.setAccessToken(accessToken);
          }

          @Override
          public UpdateConfig setAlt(java.lang.String alt) {
            return (UpdateConfig) super.setAlt(alt);
          }

          @Override
          public UpdateConfig setCallback(java.lang.String callback) {
            return (UpdateConfig) super.setCallback(callback);
          }

          @Override
          public UpdateConfig setFields(java.lang.String fields) {
            return (UpdateConfig) super.setFields(fields);
          }

          @Override
          public UpdateConfig setKey(java.lang.String key) {
            return (UpdateConfig) super.setKey(key);
          }

          @Override
          public UpdateConfig setOauthToken(java.lang.String oauthToken) {
            return (UpdateConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public UpdateConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (UpdateConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public UpdateConfig setQuotaUser(java.lang.String quotaUser) {
            return (UpdateConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public UpdateConfig setUploadType(java.lang.String uploadType) {
            return (UpdateConfig) super.setUploadType(uploadType);
          }

          @Override
          public UpdateConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (UpdateConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Name of insight type config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Name of insight type config. Eg,
         projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Name of insight type config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          public UpdateConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          /** The list of fields to be updated. */
          @com.google.api.client.util.Key
          private String updateMask;

          /** The list of fields to be updated.
           */
          public String getUpdateMask() {
            return updateMask;
          }

          /** The list of fields to be updated. */
          public UpdateConfig setUpdateMask(String updateMask) {
            this.updateMask = updateMask;
            return this;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          @com.google.api.client.util.Key
          private java.lang.Boolean validateOnly;

          /** If true, validate the request and preview the change, but do not actually update it.
           */
          public java.lang.Boolean getValidateOnly() {
            return validateOnly;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          public UpdateConfig setValidateOnly(java.lang.Boolean validateOnly) {
            this.validateOnly = validateOnly;
            return this;
          }

          @Override
          public UpdateConfig set(String parameterName, Object value) {
            return (UpdateConfig) super.set(parameterName, value);
          }
        }

        /**
         * An accessor for creating requests from the Insights collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Insights.List request = recommender.insights().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Insights insights() {
          return new Insights();
        }

        /**
         * The "insights" collection of methods.
         */
        public class Insights {

          /**
           * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
           * insight type.
           *
           * Create a request for the method "insights.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
             * insight type.
             *
             * Create a request for the method "insights.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
           * for the specified insight type.
           *
           * Create a request for the method "insights.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/insights";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+$");

            /**
             * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
             * for the specified insight type.
             *
             * Create a request for the method "insights.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ INSIGHT_TYPE_ID refers to
           supported insight types: https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Optional. Filter expression to restrict the insights returned. Supported filter fields: *
           `stateInfo.state` * `insightSubtype` * `severity` * `targetResources` Examples: * `stateInfo.state
           = ACTIVE OR stateInfo.state = DISMISSED` * `insightSubtype = PERMISSIONS_USAGE` * `severity =
           CRITICAL OR severity = HIGH` * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
           central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL OR severity =
           HIGH)` The max allowed filter length is 500 characters. (These expressions are based on the filter
           language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender API
           * that they have applied some action based on the insight. This stops the insight content from
           * being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified insight.
           *
           * Create a request for the method "insights.markAccepted".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkAccepted#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
           * @return the request
           */
          public MarkAccepted markAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) throws java.io.IOException {
            MarkAccepted result = new MarkAccepted(name, content);
            initialize(result);
            return result;
          }

          public class MarkAccepted extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}:markAccepted";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender
             * API that they have applied some action based on the insight. This stops the insight content
             * from being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires
             * the recommender.*.update IAM permission for the specified insight.
             *
             * Create a request for the method "insights.markAccepted".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkAccepted#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkAccepted#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
             * @since 1.13
             */
            protected MarkAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public MarkAccepted set$Xgafv(java.lang.String $Xgafv) {
              return (MarkAccepted) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkAccepted setAccessToken(java.lang.String accessToken) {
              return (MarkAccepted) super.setAccessToken(accessToken);
            }

            @Override
            public MarkAccepted setAlt(java.lang.String alt) {
              return (MarkAccepted) super.setAlt(alt);
            }

            @Override
            public MarkAccepted setCallback(java.lang.String callback) {
              return (MarkAccepted) super.setCallback(callback);
            }

            @Override
            public MarkAccepted setFields(java.lang.String fields) {
              return (MarkAccepted) super.setFields(fields);
            }

            @Override
            public MarkAccepted setKey(java.lang.String key) {
              return (MarkAccepted) super.setKey(key);
            }

            @Override
            public MarkAccepted setOauthToken(java.lang.String oauthToken) {
              return (MarkAccepted) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkAccepted setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkAccepted) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkAccepted setQuotaUser(java.lang.String quotaUser) {
              return (MarkAccepted) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkAccepted setUploadType(java.lang.String uploadType) {
              return (MarkAccepted) super.setUploadType(uploadType);
            }

            @Override
            public MarkAccepted setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkAccepted) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public MarkAccepted setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkAccepted set(String parameterName, Object value) {
              return (MarkAccepted) super.set(parameterName, value);
            }
          }

        }
      }
      /**
       * An accessor for creating requests from the Recommenders collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.Recommenders.List request = recommender.recommenders().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public Recommenders recommenders() {
        return new Recommenders();
      }

      /**
       * The "recommenders" collection of methods.
       */
      public class Recommenders {

        /**
         * Gets the requested Recommender Config. There is only one instance of the config for each
         * Recommender.
         *
         * Create a request for the method "recommenders.getConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link GetConfig#execute()} method to invoke the remote operation.
         *
         * @param name Required. Name of the Recommendation Config to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `organ
         *        izations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `b
         *        illingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/con
         *        fig`
         * @return the request
         */
        public GetConfig getConfig(java.lang.String name) throws java.io.IOException {
          GetConfig result = new GetConfig(name);
          initialize(result);
          return result;
        }

        public class GetConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");

          /**
           * Gets the requested Recommender Config. There is only one instance of the config for each
           * Recommender.
           *
           * Create a request for the method "recommenders.getConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link GetConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * GetConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Required. Name of the Recommendation Config to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `organ
         *        izations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `b
         *        illingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/con
         *        fig`
           * @since 1.13
           */
          protected GetConfig(java.lang.String name) {
            super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
          }

          @Override
          public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
            return super.executeUsingHead();
          }

          @Override
          public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
            return super.buildHttpRequestUsingHead();
          }

          @Override
          public GetConfig set$Xgafv(java.lang.String $Xgafv) {
            return (GetConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public GetConfig setAccessToken(java.lang.String accessToken) {
            return (GetConfig) super.setAccessToken(accessToken);
          }

          @Override
          public GetConfig setAlt(java.lang.String alt) {
            return (GetConfig) super.setAlt(alt);
          }

          @Override
          public GetConfig setCallback(java.lang.String callback) {
            return (GetConfig) super.setCallback(callback);
          }

          @Override
          public GetConfig setFields(java.lang.String fields) {
            return (GetConfig) super.setFields(fields);
          }

          @Override
          public GetConfig setKey(java.lang.String key) {
            return (GetConfig) super.setKey(key);
          }

          @Override
          public GetConfig setOauthToken(java.lang.String oauthToken) {
            return (GetConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public GetConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (GetConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public GetConfig setQuotaUser(java.lang.String quotaUser) {
            return (GetConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public GetConfig setUploadType(java.lang.String uploadType) {
            return (GetConfig) super.setUploadType(uploadType);
          }

          @Override
          public GetConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (GetConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Required. Name of the Recommendation Config to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
           * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `or
           * ganizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * ` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDE
           * R_ID]/config`
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Required. Name of the Recommendation Config to get. Acceptable formats: *
         `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config`
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Required. Name of the Recommendation Config to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
           * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `or
           * ganizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * ` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDE
           * R_ID]/config`
           */
          public GetConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          @Override
          public GetConfig set(String parameterName, Object value) {
            return (GetConfig) super.set(parameterName, value);
          }
        }
        /**
         * Updates a Recommender Config. This will create a new revision of the config.
         *
         * Create a request for the method "recommenders.updateConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link UpdateConfig#execute()} method to invoke the remote operation.
         *
         * @param name Name of recommender config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
         * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig}
         * @return the request
         */
        public UpdateConfig updateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig content) throws java.io.IOException {
          UpdateConfig result = new UpdateConfig(name, content);
          initialize(result);
          return result;
        }

        public class UpdateConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");

          /**
           * Updates a Recommender Config. This will create a new revision of the config.
           *
           * Create a request for the method "recommenders.updateConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link UpdateConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * UpdateConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Name of recommender config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig}
           * @since 1.13
           */
          protected UpdateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig content) {
            super(Recommender.this, "PATCH", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
          }

          @Override
          public UpdateConfig set$Xgafv(java.lang.String $Xgafv) {
            return (UpdateConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public UpdateConfig setAccessToken(java.lang.String accessToken) {
            return (UpdateConfig) super.setAccessToken(accessToken);
          }

          @Override
          public UpdateConfig setAlt(java.lang.String alt) {
            return (UpdateConfig) super.setAlt(alt);
          }

          @Override
          public UpdateConfig setCallback(java.lang.String callback) {
            return (UpdateConfig) super.setCallback(callback);
          }

          @Override
          public UpdateConfig setFields(java.lang.String fields) {
            return (UpdateConfig) super.setFields(fields);
          }

          @Override
          public UpdateConfig setKey(java.lang.String key) {
            return (UpdateConfig) super.setKey(key);
          }

          @Override
          public UpdateConfig setOauthToken(java.lang.String oauthToken) {
            return (UpdateConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public UpdateConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (UpdateConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public UpdateConfig setQuotaUser(java.lang.String quotaUser) {
            return (UpdateConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public UpdateConfig setUploadType(java.lang.String uploadType) {
            return (UpdateConfig) super.setUploadType(uploadType);
          }

          @Override
          public UpdateConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (UpdateConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Name of recommender config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Name of recommender config. Eg,
         projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Name of recommender config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          public UpdateConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          /** The list of fields to be updated. */
          @com.google.api.client.util.Key
          private String updateMask;

          /** The list of fields to be updated.
           */
          public String getUpdateMask() {
            return updateMask;
          }

          /** The list of fields to be updated. */
          public UpdateConfig setUpdateMask(String updateMask) {
            this.updateMask = updateMask;
            return this;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          @com.google.api.client.util.Key
          private java.lang.Boolean validateOnly;

          /** If true, validate the request and preview the change, but do not actually update it.
           */
          public java.lang.Boolean getValidateOnly() {
            return validateOnly;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          public UpdateConfig setValidateOnly(java.lang.Boolean validateOnly) {
            this.validateOnly = validateOnly;
            return this;
          }

          @Override
          public UpdateConfig set(String parameterName, Object value) {
            return (UpdateConfig) super.set(parameterName, value);
          }
        }

        /**
         * An accessor for creating requests from the Recommendations collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Recommendations.List request = recommender.recommendations().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Recommendations recommendations() {
          return new Recommendations();
        }

        /**
         * The "recommendations" collection of methods.
         */
        public class Recommendations {

          /**
           * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
           * specified recommender.
           *
           * Create a request for the method "recommendations.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
             * specified recommender.
             *
             * Create a request for the method "recommendations.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
           * permission for the specified recommender.
           *
           * Create a request for the method "recommendations.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/recommendations";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+$");

            /**
             * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
             * permission for the specified recommender.
             *
             * Create a request for the method "recommendations.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ RECOMMENDER_ID refers to
           supported recommenders: https://cloud.google.com/recommender/docs/recommenders.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Filter expression to restrict the recommendations returned. Supported filter fields: *
           `state_info.state` * `recommenderSubtype` * `priority` * `targetResources` Examples: *
           `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` * `recommenderSubtype = REMOVE_ROLE OR
           recommenderSubtype = REPLACE_ROLE` * `priority = P1 OR priority = P2` * `targetResources :
           //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` * `stateInfo.state
           = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed filter length is 500 characters.
           (These expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
           * Recommender API that they are starting to apply the recommendation themselves. This stops the
           * recommendation content from being updated. Associated insights are frozen and placed in the
           * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or ACTIVE
           * state. Requires the recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markClaimed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkClaimed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
           * @return the request
           */
          public MarkClaimed markClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) throws java.io.IOException {
            MarkClaimed result = new MarkClaimed(name, content);
            initialize(result);
            return result;
          }

          public class MarkClaimed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markClaimed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
             * Recommender API that they are starting to apply the recommendation themselves. This stops the
             * recommendation content from being updated. Associated insights are frozen and placed in the
             * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or
             * ACTIVE state. Requires the recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markClaimed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkClaimed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkClaimed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
             * @since 1.13
             */
            protected MarkClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkClaimed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkClaimed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkClaimed setAccessToken(java.lang.String accessToken) {
              return (MarkClaimed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkClaimed setAlt(java.lang.String alt) {
              return (MarkClaimed) super.setAlt(alt);
            }

            @Override
            public MarkClaimed setCallback(java.lang.String callback) {
              return (MarkClaimed) super.setCallback(callback);
            }

            @Override
            public MarkClaimed setFields(java.lang.String fields) {
              return (MarkClaimed) super.setFields(fields);
            }

            @Override
            public MarkClaimed setKey(java.lang.String key) {
              return (MarkClaimed) super.setKey(key);
            }

            @Override
            public MarkClaimed setOauthToken(java.lang.String oauthToken) {
              return (MarkClaimed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkClaimed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkClaimed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkClaimed setQuotaUser(java.lang.String quotaUser) {
              return (MarkClaimed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkClaimed setUploadType(java.lang.String uploadType) {
              return (MarkClaimed) super.setUploadType(uploadType);
            }

            @Override
            public MarkClaimed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkClaimed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkClaimed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkClaimed set(String parameterName, Object value) {
              return (MarkClaimed) super.set(parameterName, value);
            }
          }
          /**
           * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
           * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
           * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markDismissed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkDismissed#execute()} method to invoke the remote operation.
           *
           * @param name Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
           * @return the request
           */
          public MarkDismissed markDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) throws java.io.IOException {
            MarkDismissed result = new MarkDismissed(name, content);
            initialize(result);
            return result;
          }

          public class MarkDismissed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markDismissed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
             * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
             * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markDismissed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkDismissed#execute()} method to invoke the remote
             * operation. <p> {@link MarkDismissed#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
             * @since 1.13
             */
            protected MarkDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkDismissed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkDismissed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkDismissed setAccessToken(java.lang.String accessToken) {
              return (MarkDismissed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkDismissed setAlt(java.lang.String alt) {
              return (MarkDismissed) super.setAlt(alt);
            }

            @Override
            public MarkDismissed setCallback(java.lang.String callback) {
              return (MarkDismissed) super.setCallback(callback);
            }

            @Override
            public MarkDismissed setFields(java.lang.String fields) {
              return (MarkDismissed) super.setFields(fields);
            }

            @Override
            public MarkDismissed setKey(java.lang.String key) {
              return (MarkDismissed) super.setKey(key);
            }

            @Override
            public MarkDismissed setOauthToken(java.lang.String oauthToken) {
              return (MarkDismissed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkDismissed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkDismissed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkDismissed setQuotaUser(java.lang.String quotaUser) {
              return (MarkDismissed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkDismissed setUploadType(java.lang.String uploadType) {
              return (MarkDismissed) super.setUploadType(uploadType);
            }

            @Override
            public MarkDismissed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkDismissed) super.setUploadProtocol(uploadProtocol);
            }

            /** Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Name of the recommendation. */
            public MarkDismissed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkDismissed set(String parameterName, Object value) {
              return (MarkDismissed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Failed. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation failed.
           * This stops the recommendation content from being updated. Associated insights are frozen and
           * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
           * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission for
           * the specified recommender.
           *
           * Create a request for the method "recommendations.markFailed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkFailed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
           * @return the request
           */
          public MarkFailed markFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) throws java.io.IOException {
            MarkFailed result = new MarkFailed(name, content);
            initialize(result);
            return result;
          }

          public class MarkFailed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markFailed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Failed. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation failed.
             * This stops the recommendation content from being updated. Associated insights are frozen and
             * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
             * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission
             * for the specified recommender.
             *
             * Create a request for the method "recommendations.markFailed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkFailed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkFailed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
             * @since 1.13
             */
            protected MarkFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkFailed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkFailed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkFailed setAccessToken(java.lang.String accessToken) {
              return (MarkFailed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkFailed setAlt(java.lang.String alt) {
              return (MarkFailed) super.setAlt(alt);
            }

            @Override
            public MarkFailed setCallback(java.lang.String callback) {
              return (MarkFailed) super.setCallback(callback);
            }

            @Override
            public MarkFailed setFields(java.lang.String fields) {
              return (MarkFailed) super.setFields(fields);
            }

            @Override
            public MarkFailed setKey(java.lang.String key) {
              return (MarkFailed) super.setKey(key);
            }

            @Override
            public MarkFailed setOauthToken(java.lang.String oauthToken) {
              return (MarkFailed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkFailed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkFailed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkFailed setQuotaUser(java.lang.String quotaUser) {
              return (MarkFailed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkFailed setUploadType(java.lang.String uploadType) {
              return (MarkFailed) super.setUploadType(uploadType);
            }

            @Override
            public MarkFailed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkFailed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkFailed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkFailed set(String parameterName, Object value) {
              return (MarkFailed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation was
           * successful. This stops the recommendation content from being updated. Associated insights are
           * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
           * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update
           * IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markSucceeded".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
           * @return the request
           */
          public MarkSucceeded markSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) throws java.io.IOException {
            MarkSucceeded result = new MarkSucceeded(name, content);
            initialize(result);
            return result;
          }

          public class MarkSucceeded extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markSucceeded";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation was
             * successful. This stops the recommendation content from being updated. Associated insights are
             * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
             * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markSucceeded".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote
             * operation. <p> {@link MarkSucceeded#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
             * @since 1.13
             */
            protected MarkSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkSucceeded set$Xgafv(java.lang.String $Xgafv) {
              return (MarkSucceeded) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkSucceeded setAccessToken(java.lang.String accessToken) {
              return (MarkSucceeded) super.setAccessToken(accessToken);
            }

            @Override
            public MarkSucceeded setAlt(java.lang.String alt) {
              return (MarkSucceeded) super.setAlt(alt);
            }

            @Override
            public MarkSucceeded setCallback(java.lang.String callback) {
              return (MarkSucceeded) super.setCallback(callback);
            }

            @Override
            public MarkSucceeded setFields(java.lang.String fields) {
              return (MarkSucceeded) super.setFields(fields);
            }

            @Override
            public MarkSucceeded setKey(java.lang.String key) {
              return (MarkSucceeded) super.setKey(key);
            }

            @Override
            public MarkSucceeded setOauthToken(java.lang.String oauthToken) {
              return (MarkSucceeded) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkSucceeded setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkSucceeded) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkSucceeded setQuotaUser(java.lang.String quotaUser) {
              return (MarkSucceeded) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkSucceeded setUploadType(java.lang.String uploadType) {
              return (MarkSucceeded) super.setUploadType(uploadType);
            }

            @Override
            public MarkSucceeded setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkSucceeded) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkSucceeded setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^organizations/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkSucceeded set(String parameterName, Object value) {
              return (MarkSucceeded) super.set(parameterName, value);
            }
          }

        }
      }
    }
  }

  /**
   * An accessor for creating requests from the Projects collection.
   *
   * <p>The typical use is:</p>
   * <pre>
   *   {@code Recommender recommender = new Recommender(...);}
   *   {@code Recommender.Projects.List request = recommender.projects().list(parameters ...)}
   * </pre>
   *
   * @return the resource collection
   */
  public Projects projects() {
    return new Projects();
  }

  /**
   * The "projects" collection of methods.
   */
  public class Projects {

    /**
     * An accessor for creating requests from the Locations collection.
     *
     * <p>The typical use is:</p>
     * <pre>
     *   {@code Recommender recommender = new Recommender(...);}
     *   {@code Recommender.Locations.List request = recommender.locations().list(parameters ...)}
     * </pre>
     *
     * @return the resource collection
     */
    public Locations locations() {
      return new Locations();
    }

    /**
     * The "locations" collection of methods.
     */
    public class Locations {

      /**
       * An accessor for creating requests from the InsightTypes collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.InsightTypes.List request = recommender.insightTypes().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public InsightTypes insightTypes() {
        return new InsightTypes();
      }

      /**
       * The "insightTypes" collection of methods.
       */
      public class InsightTypes {

        /**
         * Gets the requested InsightTypeConfig. There is only one instance of the config for each
         * InsightType.
         *
         * Create a request for the method "insightTypes.getConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link GetConfig#execute()} method to invoke the remote operation.
         *
         * @param name Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` * `orga
         *        nizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/
         *        config`
         * @return the request
         */
        public GetConfig getConfig(java.lang.String name) throws java.io.IOException {
          GetConfig result = new GetConfig(name);
          initialize(result);
          return result;
        }

        public class GetConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");

          /**
           * Gets the requested InsightTypeConfig. There is only one instance of the config for each
           * InsightType.
           *
           * Create a request for the method "insightTypes.getConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link GetConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * GetConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` * `orga
         *        nizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/
         *        config`
           * @since 1.13
           */
          protected GetConfig(java.lang.String name) {
            super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
          }

          @Override
          public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
            return super.executeUsingHead();
          }

          @Override
          public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
            return super.buildHttpRequestUsingHead();
          }

          @Override
          public GetConfig set$Xgafv(java.lang.String $Xgafv) {
            return (GetConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public GetConfig setAccessToken(java.lang.String accessToken) {
            return (GetConfig) super.setAccessToken(accessToken);
          }

          @Override
          public GetConfig setAlt(java.lang.String alt) {
            return (GetConfig) super.setAlt(alt);
          }

          @Override
          public GetConfig setCallback(java.lang.String callback) {
            return (GetConfig) super.setCallback(callback);
          }

          @Override
          public GetConfig setFields(java.lang.String fields) {
            return (GetConfig) super.setFields(fields);
          }

          @Override
          public GetConfig setKey(java.lang.String key) {
            return (GetConfig) super.setKey(key);
          }

          @Override
          public GetConfig setOauthToken(java.lang.String oauthToken) {
            return (GetConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public GetConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (GetConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public GetConfig setQuotaUser(java.lang.String quotaUser) {
            return (GetConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public GetConfig setUploadType(java.lang.String uploadType) {
            return (GetConfig) super.setUploadType(uploadType);
          }

          @Override
          public GetConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (GetConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Required. Name of the InsightTypeConfig to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           * * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
           * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/co
           * nfig` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGH
           * T_TYPE_ID]/config`
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Required. Name of the InsightTypeConfig to get. Acceptable formats: *
         `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
         `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Required. Name of the InsightTypeConfig to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config`
           * * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config` *
           * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/co
           * nfig` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGH
           * T_TYPE_ID]/config`
           */
          public GetConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          @Override
          public GetConfig set(String parameterName, Object value) {
            return (GetConfig) super.set(parameterName, value);
          }
        }
        /**
         * Updates an InsightTypeConfig change. This will create a new revision of the config.
         *
         * Create a request for the method "insightTypes.updateConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link UpdateConfig#execute()} method to invoke the remote operation.
         *
         * @param name Name of insight type config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
         * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig}
         * @return the request
         */
        public UpdateConfig updateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig content) throws java.io.IOException {
          UpdateConfig result = new UpdateConfig(name, content);
          initialize(result);
          return result;
        }

        public class UpdateConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");

          /**
           * Updates an InsightTypeConfig change. This will create a new revision of the config.
           *
           * Create a request for the method "insightTypes.updateConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link UpdateConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * UpdateConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Name of insight type config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig}
           * @since 1.13
           */
          protected UpdateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig content) {
            super(Recommender.this, "PATCH", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1InsightTypeConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
          }

          @Override
          public UpdateConfig set$Xgafv(java.lang.String $Xgafv) {
            return (UpdateConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public UpdateConfig setAccessToken(java.lang.String accessToken) {
            return (UpdateConfig) super.setAccessToken(accessToken);
          }

          @Override
          public UpdateConfig setAlt(java.lang.String alt) {
            return (UpdateConfig) super.setAlt(alt);
          }

          @Override
          public UpdateConfig setCallback(java.lang.String callback) {
            return (UpdateConfig) super.setCallback(callback);
          }

          @Override
          public UpdateConfig setFields(java.lang.String fields) {
            return (UpdateConfig) super.setFields(fields);
          }

          @Override
          public UpdateConfig setKey(java.lang.String key) {
            return (UpdateConfig) super.setKey(key);
          }

          @Override
          public UpdateConfig setOauthToken(java.lang.String oauthToken) {
            return (UpdateConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public UpdateConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (UpdateConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public UpdateConfig setQuotaUser(java.lang.String quotaUser) {
            return (UpdateConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public UpdateConfig setUploadType(java.lang.String uploadType) {
            return (UpdateConfig) super.setUploadType(uploadType);
          }

          @Override
          public UpdateConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (UpdateConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Name of insight type config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Name of insight type config. Eg,
         projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Name of insight type config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]/config
           */
          public UpdateConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          /** The list of fields to be updated. */
          @com.google.api.client.util.Key
          private String updateMask;

          /** The list of fields to be updated.
           */
          public String getUpdateMask() {
            return updateMask;
          }

          /** The list of fields to be updated. */
          public UpdateConfig setUpdateMask(String updateMask) {
            this.updateMask = updateMask;
            return this;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          @com.google.api.client.util.Key
          private java.lang.Boolean validateOnly;

          /** If true, validate the request and preview the change, but do not actually update it.
           */
          public java.lang.Boolean getValidateOnly() {
            return validateOnly;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          public UpdateConfig setValidateOnly(java.lang.Boolean validateOnly) {
            this.validateOnly = validateOnly;
            return this;
          }

          @Override
          public UpdateConfig set(String parameterName, Object value) {
            return (UpdateConfig) super.set(parameterName, value);
          }
        }

        /**
         * An accessor for creating requests from the Insights collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Insights.List request = recommender.insights().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Insights insights() {
          return new Insights();
        }

        /**
         * The "insights" collection of methods.
         */
        public class Insights {

          /**
           * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
           * insight type.
           *
           * Create a request for the method "insights.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Gets the requested insight. Requires the recommender.*.get IAM permission for the specified
             * insight type.
             *
             * Create a request for the method "insights.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
           * for the specified insight type.
           *
           * Create a request for the method "insights.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/insights";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+$");

            /**
             * Lists insights for the specified Cloud Resource. Requires the recommender.*.list IAM permission
             * for the specified insight type.
             *
             * Create a request for the method "insights.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        INSIGHT_TYPE_ID refers to supported insight types:
           *        https://cloud.google.com/recommender/docs/insights/insight-types.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListInsightsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ INSIGHT_TYPE_ID refers to
           supported insight types: https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` * `billin
             * gAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/insightTypes/[INSIGHT_TYPE_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * INSIGHT_TYPE_ID refers to supported insight types:
             * https://cloud.google.com/recommender/docs/insights/insight-types.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Optional. Filter expression to restrict the insights returned. Supported filter fields: *
           `stateInfo.state` * `insightSubtype` * `severity` * `targetResources` Examples: * `stateInfo.state
           = ACTIVE OR stateInfo.state = DISMISSED` * `insightSubtype = PERMISSIONS_USAGE` * `severity =
           CRITICAL OR severity = HIGH` * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
           central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL OR severity =
           HIGH)` The max allowed filter length is 500 characters. (These expressions are based on the filter
           language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Optional. Filter expression to restrict the insights returned. Supported filter
             * fields: * `stateInfo.state` * `insightSubtype` * `severity` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `insightSubtype = PERMISSIONS_USAGE` * `severity = CRITICAL OR severity = HIGH` *
             * `targetResources : //compute.googleapis.com/projects/1234/zones/us-
             * central1-a/instances/instance-1` * `stateInfo.state = ACTIVE AND (severity = CRITICAL
             * OR severity = HIGH)` The max allowed filter length is 500 characters. (These
             * expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender API
           * that they have applied some action based on the insight. This stops the insight content from
           * being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified insight.
           *
           * Create a request for the method "insights.markAccepted".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkAccepted#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the insight.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
           * @return the request
           */
          public MarkAccepted markAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) throws java.io.IOException {
            MarkAccepted result = new MarkAccepted(name, content);
            initialize(result);
            return result;
          }

          public class MarkAccepted extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight> {

            private static final String REST_PATH = "v1beta1/{+name}:markAccepted";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");

            /**
             * Marks the Insight State as Accepted. Users can use this method to indicate to the Recommender
             * API that they have applied some action based on the insight. This stops the insight content
             * from being updated. MarkInsightAccepted can be applied to insights in ACTIVE state. Requires
             * the recommender.*.update IAM permission for the specified insight.
             *
             * Create a request for the method "insights.markAccepted".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkAccepted#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkAccepted#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the insight.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest}
             * @since 1.13
             */
            protected MarkAccepted(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkInsightAcceptedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Insight.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
            }

            @Override
            public MarkAccepted set$Xgafv(java.lang.String $Xgafv) {
              return (MarkAccepted) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkAccepted setAccessToken(java.lang.String accessToken) {
              return (MarkAccepted) super.setAccessToken(accessToken);
            }

            @Override
            public MarkAccepted setAlt(java.lang.String alt) {
              return (MarkAccepted) super.setAlt(alt);
            }

            @Override
            public MarkAccepted setCallback(java.lang.String callback) {
              return (MarkAccepted) super.setCallback(callback);
            }

            @Override
            public MarkAccepted setFields(java.lang.String fields) {
              return (MarkAccepted) super.setFields(fields);
            }

            @Override
            public MarkAccepted setKey(java.lang.String key) {
              return (MarkAccepted) super.setKey(key);
            }

            @Override
            public MarkAccepted setOauthToken(java.lang.String oauthToken) {
              return (MarkAccepted) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkAccepted setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkAccepted) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkAccepted setQuotaUser(java.lang.String quotaUser) {
              return (MarkAccepted) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkAccepted setUploadType(java.lang.String uploadType) {
              return (MarkAccepted) super.setUploadType(uploadType);
            }

            @Override
            public MarkAccepted setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkAccepted) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the insight. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the insight.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the insight. */
            public MarkAccepted setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/insightTypes/[^/]+/insights/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkAccepted set(String parameterName, Object value) {
              return (MarkAccepted) super.set(parameterName, value);
            }
          }

        }
      }
      /**
       * An accessor for creating requests from the Recommenders collection.
       *
       * <p>The typical use is:</p>
       * <pre>
       *   {@code Recommender recommender = new Recommender(...);}
       *   {@code Recommender.Recommenders.List request = recommender.recommenders().list(parameters ...)}
       * </pre>
       *
       * @return the resource collection
       */
      public Recommenders recommenders() {
        return new Recommenders();
      }

      /**
       * The "recommenders" collection of methods.
       */
      public class Recommenders {

        /**
         * Gets the requested Recommender Config. There is only one instance of the config for each
         * Recommender.
         *
         * Create a request for the method "recommenders.getConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link GetConfig#execute()} method to invoke the remote operation.
         *
         * @param name Required. Name of the Recommendation Config to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `organ
         *        izations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `b
         *        illingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/con
         *        fig`
         * @return the request
         */
        public GetConfig getConfig(java.lang.String name) throws java.io.IOException {
          GetConfig result = new GetConfig(name);
          initialize(result);
          return result;
        }

        public class GetConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");

          /**
           * Gets the requested Recommender Config. There is only one instance of the config for each
           * Recommender.
           *
           * Create a request for the method "recommenders.getConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link GetConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * GetConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Required. Name of the Recommendation Config to get. Acceptable formats: *
         *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `organ
         *        izations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `b
         *        illingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/con
         *        fig`
           * @since 1.13
           */
          protected GetConfig(java.lang.String name) {
            super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
          }

          @Override
          public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
            return super.executeUsingHead();
          }

          @Override
          public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
            return super.buildHttpRequestUsingHead();
          }

          @Override
          public GetConfig set$Xgafv(java.lang.String $Xgafv) {
            return (GetConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public GetConfig setAccessToken(java.lang.String accessToken) {
            return (GetConfig) super.setAccessToken(accessToken);
          }

          @Override
          public GetConfig setAlt(java.lang.String alt) {
            return (GetConfig) super.setAlt(alt);
          }

          @Override
          public GetConfig setCallback(java.lang.String callback) {
            return (GetConfig) super.setCallback(callback);
          }

          @Override
          public GetConfig setFields(java.lang.String fields) {
            return (GetConfig) super.setFields(fields);
          }

          @Override
          public GetConfig setKey(java.lang.String key) {
            return (GetConfig) super.setKey(key);
          }

          @Override
          public GetConfig setOauthToken(java.lang.String oauthToken) {
            return (GetConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public GetConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (GetConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public GetConfig setQuotaUser(java.lang.String quotaUser) {
            return (GetConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public GetConfig setUploadType(java.lang.String uploadType) {
            return (GetConfig) super.setUploadType(uploadType);
          }

          @Override
          public GetConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (GetConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Required. Name of the Recommendation Config to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
           * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `or
           * ganizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * ` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDE
           * R_ID]/config`
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Required. Name of the Recommendation Config to get. Acceptable formats: *
         `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
         `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config`
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Required. Name of the Recommendation Config to get. Acceptable formats: *
           * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` *
           * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config` * `or
           * ganizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * ` * `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDE
           * R_ID]/config`
           */
          public GetConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          @Override
          public GetConfig set(String parameterName, Object value) {
            return (GetConfig) super.set(parameterName, value);
          }
        }
        /**
         * Updates a Recommender Config. This will create a new revision of the config.
         *
         * Create a request for the method "recommenders.updateConfig".
         *
         * This request holds the parameters needed by the recommender server.  After setting any optional
         * parameters, call the {@link UpdateConfig#execute()} method to invoke the remote operation.
         *
         * @param name Name of recommender config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
         * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig}
         * @return the request
         */
        public UpdateConfig updateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig content) throws java.io.IOException {
          UpdateConfig result = new UpdateConfig(name, content);
          initialize(result);
          return result;
        }

        public class UpdateConfig extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig> {

          private static final String REST_PATH = "v1beta1/{+name}";

          private final java.util.regex.Pattern NAME_PATTERN =
              java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");

          /**
           * Updates a Recommender Config. This will create a new revision of the config.
           *
           * Create a request for the method "recommenders.updateConfig".
           *
           * This request holds the parameters needed by the the recommender server.  After setting any
           * optional parameters, call the {@link UpdateConfig#execute()} method to invoke the remote
           * operation. <p> {@link
           * UpdateConfig#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
           * must be called to initialize this instance immediately after invoking the constructor. </p>
           *
           * @param name Name of recommender config. Eg,
         *        projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig}
           * @since 1.13
           */
          protected UpdateConfig(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig content) {
            super(Recommender.this, "PATCH", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1RecommenderConfig.class);
            this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
          }

          @Override
          public UpdateConfig set$Xgafv(java.lang.String $Xgafv) {
            return (UpdateConfig) super.set$Xgafv($Xgafv);
          }

          @Override
          public UpdateConfig setAccessToken(java.lang.String accessToken) {
            return (UpdateConfig) super.setAccessToken(accessToken);
          }

          @Override
          public UpdateConfig setAlt(java.lang.String alt) {
            return (UpdateConfig) super.setAlt(alt);
          }

          @Override
          public UpdateConfig setCallback(java.lang.String callback) {
            return (UpdateConfig) super.setCallback(callback);
          }

          @Override
          public UpdateConfig setFields(java.lang.String fields) {
            return (UpdateConfig) super.setFields(fields);
          }

          @Override
          public UpdateConfig setKey(java.lang.String key) {
            return (UpdateConfig) super.setKey(key);
          }

          @Override
          public UpdateConfig setOauthToken(java.lang.String oauthToken) {
            return (UpdateConfig) super.setOauthToken(oauthToken);
          }

          @Override
          public UpdateConfig setPrettyPrint(java.lang.Boolean prettyPrint) {
            return (UpdateConfig) super.setPrettyPrint(prettyPrint);
          }

          @Override
          public UpdateConfig setQuotaUser(java.lang.String quotaUser) {
            return (UpdateConfig) super.setQuotaUser(quotaUser);
          }

          @Override
          public UpdateConfig setUploadType(java.lang.String uploadType) {
            return (UpdateConfig) super.setUploadType(uploadType);
          }

          @Override
          public UpdateConfig setUploadProtocol(java.lang.String uploadProtocol) {
            return (UpdateConfig) super.setUploadProtocol(uploadProtocol);
          }

          /**
           * Name of recommender config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          @com.google.api.client.util.Key
          private java.lang.String name;

          /** Name of recommender config. Eg,
         projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          public java.lang.String getName() {
            return name;
          }

          /**
           * Name of recommender config. Eg,
           * projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]/config
           */
          public UpdateConfig setName(java.lang.String name) {
            if (!getSuppressPatternChecks()) {
              com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                  "Parameter name must conform to the pattern " +
                  "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/config$");
            }
            this.name = name;
            return this;
          }

          /** The list of fields to be updated. */
          @com.google.api.client.util.Key
          private String updateMask;

          /** The list of fields to be updated.
           */
          public String getUpdateMask() {
            return updateMask;
          }

          /** The list of fields to be updated. */
          public UpdateConfig setUpdateMask(String updateMask) {
            this.updateMask = updateMask;
            return this;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          @com.google.api.client.util.Key
          private java.lang.Boolean validateOnly;

          /** If true, validate the request and preview the change, but do not actually update it.
           */
          public java.lang.Boolean getValidateOnly() {
            return validateOnly;
          }

          /**
           * If true, validate the request and preview the change, but do not actually update it.
           */
          public UpdateConfig setValidateOnly(java.lang.Boolean validateOnly) {
            this.validateOnly = validateOnly;
            return this;
          }

          @Override
          public UpdateConfig set(String parameterName, Object value) {
            return (UpdateConfig) super.set(parameterName, value);
          }
        }

        /**
         * An accessor for creating requests from the Recommendations collection.
         *
         * <p>The typical use is:</p>
         * <pre>
         *   {@code Recommender recommender = new Recommender(...);}
         *   {@code Recommender.Recommendations.List request = recommender.recommendations().list(parameters ...)}
         * </pre>
         *
         * @return the resource collection
         */
        public Recommendations recommendations() {
          return new Recommendations();
        }

        /**
         * The "recommendations" collection of methods.
         */
        public class Recommendations {

          /**
           * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
           * specified recommender.
           *
           * Create a request for the method "recommendations.get".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link Get#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @return the request
           */
          public Get get(java.lang.String name) throws java.io.IOException {
            Get result = new Get(name);
            initialize(result);
            return result;
          }

          public class Get extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Gets the requested recommendation. Requires the recommender.*.get IAM permission for the
             * specified recommender.
             *
             * Create a request for the method "recommendations.get".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. <p>
             * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @since 1.13
             */
            protected Get(java.lang.String name) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public Get set$Xgafv(java.lang.String $Xgafv) {
              return (Get) super.set$Xgafv($Xgafv);
            }

            @Override
            public Get setAccessToken(java.lang.String accessToken) {
              return (Get) super.setAccessToken(accessToken);
            }

            @Override
            public Get setAlt(java.lang.String alt) {
              return (Get) super.setAlt(alt);
            }

            @Override
            public Get setCallback(java.lang.String callback) {
              return (Get) super.setCallback(callback);
            }

            @Override
            public Get setFields(java.lang.String fields) {
              return (Get) super.setFields(fields);
            }

            @Override
            public Get setKey(java.lang.String key) {
              return (Get) super.setKey(key);
            }

            @Override
            public Get setOauthToken(java.lang.String oauthToken) {
              return (Get) super.setOauthToken(oauthToken);
            }

            @Override
            public Get setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (Get) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public Get setQuotaUser(java.lang.String quotaUser) {
              return (Get) super.setQuotaUser(quotaUser);
            }

            @Override
            public Get setUploadType(java.lang.String uploadType) {
              return (Get) super.setUploadType(uploadType);
            }

            @Override
            public Get setUploadProtocol(java.lang.String uploadProtocol) {
              return (Get) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public Get setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public Get set(String parameterName, Object value) {
              return (Get) super.set(parameterName, value);
            }
          }
          /**
           * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
           * permission for the specified recommender.
           *
           * Create a request for the method "recommendations.list".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link List#execute()} method to invoke the remote operation.
           *
           * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
           * @return the request
           */
          public List list(java.lang.String parent) throws java.io.IOException {
            List result = new List(parent);
            initialize(result);
            return result;
          }

          public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse> {

            private static final String REST_PATH = "v1beta1/{+parent}/recommendations";

            private final java.util.regex.Pattern PARENT_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+$");

            /**
             * Lists recommendations for the specified Cloud Resource. Requires the recommender.*.list IAM
             * permission for the specified recommender.
             *
             * Create a request for the method "recommendations.list".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
             * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param parent Required. The container resource on which to execute the request. Acceptable formats: *
           *        `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           *        `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
           *        LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
           *        RECOMMENDER_ID refers to supported recommenders:
           *        https://cloud.google.com/recommender/docs/recommenders.
             * @since 1.13
             */
            protected List(java.lang.String parent) {
              super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendationsResponse.class);
              this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
            }

            @Override
            public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
              return super.executeUsingHead();
            }

            @Override
            public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
              return super.buildHttpRequestUsingHead();
            }

            @Override
            public List set$Xgafv(java.lang.String $Xgafv) {
              return (List) super.set$Xgafv($Xgafv);
            }

            @Override
            public List setAccessToken(java.lang.String accessToken) {
              return (List) super.setAccessToken(accessToken);
            }

            @Override
            public List setAlt(java.lang.String alt) {
              return (List) super.setAlt(alt);
            }

            @Override
            public List setCallback(java.lang.String callback) {
              return (List) super.setCallback(callback);
            }

            @Override
            public List setFields(java.lang.String fields) {
              return (List) super.setFields(fields);
            }

            @Override
            public List setKey(java.lang.String key) {
              return (List) super.setKey(key);
            }

            @Override
            public List setOauthToken(java.lang.String oauthToken) {
              return (List) super.setOauthToken(oauthToken);
            }

            @Override
            public List setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (List) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public List setQuotaUser(java.lang.String quotaUser) {
              return (List) super.setQuotaUser(quotaUser);
            }

            @Override
            public List setUploadType(java.lang.String uploadType) {
              return (List) super.setUploadType(uploadType);
            }

            @Override
            public List setUploadProtocol(java.lang.String uploadProtocol) {
              return (List) super.setUploadProtocol(uploadProtocol);
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            @com.google.api.client.util.Key
            private java.lang.String parent;

            /** Required. The container resource on which to execute the request. Acceptable formats: *
           `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
           `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` LOCATION here
           refers to GCP Locations: https://cloud.google.com/about/locations/ RECOMMENDER_ID refers to
           supported recommenders: https://cloud.google.com/recommender/docs/recommenders.
             */
            public java.lang.String getParent() {
              return parent;
            }

            /**
             * Required. The container resource on which to execute the request. Acceptable formats:
             * * `projects/[PROJECT_NUMBER]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `projects/[PROJECT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` * `billing
             * Accounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `folders/[FOLDER_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]` *
             * `organizations/[ORGANIZATION_ID]/locations/[LOCATION]/recommenders/[RECOMMENDER_ID]`
             * LOCATION here refers to GCP Locations: https://cloud.google.com/about/locations/
             * RECOMMENDER_ID refers to supported recommenders:
             * https://cloud.google.com/recommender/docs/recommenders.
             */
            public List setParent(java.lang.String parent) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
                    "Parameter parent must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+$");
              }
              this.parent = parent;
              return this;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            @com.google.api.client.util.Key
            private java.lang.String filter;

            /** Filter expression to restrict the recommendations returned. Supported filter fields: *
           `state_info.state` * `recommenderSubtype` * `priority` * `targetResources` Examples: *
           `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` * `recommenderSubtype = REMOVE_ROLE OR
           recommenderSubtype = REPLACE_ROLE` * `priority = P1 OR priority = P2` * `targetResources :
           //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` * `stateInfo.state
           = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed filter length is 500 characters.
           (These expressions are based on the filter language described at https://google.aip.dev/160)
             */
            public java.lang.String getFilter() {
              return filter;
            }

            /**
             * Filter expression to restrict the recommendations returned. Supported filter fields:
             * * `state_info.state` * `recommenderSubtype` * `priority` * `targetResources`
             * Examples: * `stateInfo.state = ACTIVE OR stateInfo.state = DISMISSED` *
             * `recommenderSubtype = REMOVE_ROLE OR recommenderSubtype = REPLACE_ROLE` * `priority =
             * P1 OR priority = P2` * `targetResources :
             * //compute.googleapis.com/projects/1234/zones/us-central1-a/instances/instance-1` *
             * `stateInfo.state = ACTIVE AND (priority = P1 OR priority = P2)` The max allowed
             * filter length is 500 characters. (These expressions are based on the filter language
             * described at https://google.aip.dev/160)
             */
            public List setFilter(java.lang.String filter) {
              this.filter = filter;
              return this;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            @com.google.api.client.util.Key
            private java.lang.Integer pageSize;

            /** Optional. The maximum number of results to return from this request. Non-positive values are
           ignored. If not specified, the server will determine the number of results to return.
             */
            public java.lang.Integer getPageSize() {
              return pageSize;
            }

            /**
             * Optional. The maximum number of results to return from this request. Non-positive
             * values are ignored. If not specified, the server will determine the number of results
             * to return.
             */
            public List setPageSize(java.lang.Integer pageSize) {
              this.pageSize = pageSize;
              return this;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            @com.google.api.client.util.Key
            private java.lang.String pageToken;

            /** Optional. If present, retrieves the next batch of results from the preceding call to this method.
           `page_token` must be the value of `next_page_token` from the previous response. The values of other
           method parameters must be identical to those in the previous call.
             */
            public java.lang.String getPageToken() {
              return pageToken;
            }

            /**
             * Optional. If present, retrieves the next batch of results from the preceding call to
             * this method. `page_token` must be the value of `next_page_token` from the previous
             * response. The values of other method parameters must be identical to those in the
             * previous call.
             */
            public List setPageToken(java.lang.String pageToken) {
              this.pageToken = pageToken;
              return this;
            }

            @Override
            public List set(String parameterName, Object value) {
              return (List) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
           * Recommender API that they are starting to apply the recommendation themselves. This stops the
           * recommendation content from being updated. Associated insights are frozen and placed in the
           * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or ACTIVE
           * state. Requires the recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markClaimed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkClaimed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
           * @return the request
           */
          public MarkClaimed markClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) throws java.io.IOException {
            MarkClaimed result = new MarkClaimed(name, content);
            initialize(result);
            return result;
          }

          public class MarkClaimed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markClaimed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Claimed. Users can use this method to indicate to the
             * Recommender API that they are starting to apply the recommendation themselves. This stops the
             * recommendation content from being updated. Associated insights are frozen and placed in the
             * ACCEPTED state. MarkRecommendationClaimed can be applied to recommendations in CLAIMED or
             * ACTIVE state. Requires the recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markClaimed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkClaimed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkClaimed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest}
             * @since 1.13
             */
            protected MarkClaimed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationClaimedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkClaimed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkClaimed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkClaimed setAccessToken(java.lang.String accessToken) {
              return (MarkClaimed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkClaimed setAlt(java.lang.String alt) {
              return (MarkClaimed) super.setAlt(alt);
            }

            @Override
            public MarkClaimed setCallback(java.lang.String callback) {
              return (MarkClaimed) super.setCallback(callback);
            }

            @Override
            public MarkClaimed setFields(java.lang.String fields) {
              return (MarkClaimed) super.setFields(fields);
            }

            @Override
            public MarkClaimed setKey(java.lang.String key) {
              return (MarkClaimed) super.setKey(key);
            }

            @Override
            public MarkClaimed setOauthToken(java.lang.String oauthToken) {
              return (MarkClaimed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkClaimed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkClaimed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkClaimed setQuotaUser(java.lang.String quotaUser) {
              return (MarkClaimed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkClaimed setUploadType(java.lang.String uploadType) {
              return (MarkClaimed) super.setUploadType(uploadType);
            }

            @Override
            public MarkClaimed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkClaimed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkClaimed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkClaimed set(String parameterName, Object value) {
              return (MarkClaimed) super.set(parameterName, value);
            }
          }
          /**
           * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
           * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
           * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
           * recommender.*.update IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markDismissed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkDismissed#execute()} method to invoke the remote operation.
           *
           * @param name Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
           * @return the request
           */
          public MarkDismissed markDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) throws java.io.IOException {
            MarkDismissed result = new MarkDismissed(name, content);
            initialize(result);
            return result;
          }

          public class MarkDismissed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markDismissed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Mark the Recommendation State as Dismissed. Users can use this method to indicate to the
             * Recommender API that an ACTIVE recommendation has to be marked back as DISMISSED.
             * MarkRecommendationDismissed can be applied to recommendations in ACTIVE state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markDismissed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkDismissed#execute()} method to invoke the remote
             * operation. <p> {@link MarkDismissed#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest}
             * @since 1.13
             */
            protected MarkDismissed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationDismissedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkDismissed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkDismissed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkDismissed setAccessToken(java.lang.String accessToken) {
              return (MarkDismissed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkDismissed setAlt(java.lang.String alt) {
              return (MarkDismissed) super.setAlt(alt);
            }

            @Override
            public MarkDismissed setCallback(java.lang.String callback) {
              return (MarkDismissed) super.setCallback(callback);
            }

            @Override
            public MarkDismissed setFields(java.lang.String fields) {
              return (MarkDismissed) super.setFields(fields);
            }

            @Override
            public MarkDismissed setKey(java.lang.String key) {
              return (MarkDismissed) super.setKey(key);
            }

            @Override
            public MarkDismissed setOauthToken(java.lang.String oauthToken) {
              return (MarkDismissed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkDismissed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkDismissed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkDismissed setQuotaUser(java.lang.String quotaUser) {
              return (MarkDismissed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkDismissed setUploadType(java.lang.String uploadType) {
              return (MarkDismissed) super.setUploadType(uploadType);
            }

            @Override
            public MarkDismissed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkDismissed) super.setUploadProtocol(uploadProtocol);
            }

            /** Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Name of the recommendation. */
            public MarkDismissed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkDismissed set(String parameterName, Object value) {
              return (MarkDismissed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Failed. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation failed.
           * This stops the recommendation content from being updated. Associated insights are frozen and
           * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
           * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission for
           * the specified recommender.
           *
           * Create a request for the method "recommendations.markFailed".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkFailed#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
           * @return the request
           */
          public MarkFailed markFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) throws java.io.IOException {
            MarkFailed result = new MarkFailed(name, content);
            initialize(result);
            return result;
          }

          public class MarkFailed extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markFailed";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Failed. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation failed.
             * This stops the recommendation content from being updated. Associated insights are frozen and
             * placed in the ACCEPTED state. MarkRecommendationFailed can be applied to recommendations in
             * ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update IAM permission
             * for the specified recommender.
             *
             * Create a request for the method "recommendations.markFailed".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkFailed#execute()} method to invoke the remote
             * operation. <p> {@link
             * MarkFailed#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
             * must be called to initialize this instance immediately after invoking the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest}
             * @since 1.13
             */
            protected MarkFailed(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationFailedRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkFailed set$Xgafv(java.lang.String $Xgafv) {
              return (MarkFailed) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkFailed setAccessToken(java.lang.String accessToken) {
              return (MarkFailed) super.setAccessToken(accessToken);
            }

            @Override
            public MarkFailed setAlt(java.lang.String alt) {
              return (MarkFailed) super.setAlt(alt);
            }

            @Override
            public MarkFailed setCallback(java.lang.String callback) {
              return (MarkFailed) super.setCallback(callback);
            }

            @Override
            public MarkFailed setFields(java.lang.String fields) {
              return (MarkFailed) super.setFields(fields);
            }

            @Override
            public MarkFailed setKey(java.lang.String key) {
              return (MarkFailed) super.setKey(key);
            }

            @Override
            public MarkFailed setOauthToken(java.lang.String oauthToken) {
              return (MarkFailed) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkFailed setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkFailed) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkFailed setQuotaUser(java.lang.String quotaUser) {
              return (MarkFailed) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkFailed setUploadType(java.lang.String uploadType) {
              return (MarkFailed) super.setUploadType(uploadType);
            }

            @Override
            public MarkFailed setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkFailed) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkFailed setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkFailed set(String parameterName, Object value) {
              return (MarkFailed) super.set(parameterName, value);
            }
          }
          /**
           * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
           * Recommender API that they have applied the recommendation themselves, and the operation was
           * successful. This stops the recommendation content from being updated. Associated insights are
           * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
           * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the recommender.*.update
           * IAM permission for the specified recommender.
           *
           * Create a request for the method "recommendations.markSucceeded".
           *
           * This request holds the parameters needed by the recommender server.  After setting any optional
           * parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote operation.
           *
           * @param name Required. Name of the recommendation.
           * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
           * @return the request
           */
          public MarkSucceeded markSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) throws java.io.IOException {
            MarkSucceeded result = new MarkSucceeded(name, content);
            initialize(result);
            return result;
          }

          public class MarkSucceeded extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation> {

            private static final String REST_PATH = "v1beta1/{+name}:markSucceeded";

            private final java.util.regex.Pattern NAME_PATTERN =
                java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");

            /**
             * Marks the Recommendation State as Succeeded. Users can use this method to indicate to the
             * Recommender API that they have applied the recommendation themselves, and the operation was
             * successful. This stops the recommendation content from being updated. Associated insights are
             * frozen and placed in the ACCEPTED state. MarkRecommendationSucceeded can be applied to
             * recommendations in ACTIVE, CLAIMED, SUCCEEDED, or FAILED state. Requires the
             * recommender.*.update IAM permission for the specified recommender.
             *
             * Create a request for the method "recommendations.markSucceeded".
             *
             * This request holds the parameters needed by the the recommender server.  After setting any
             * optional parameters, call the {@link MarkSucceeded#execute()} method to invoke the remote
             * operation. <p> {@link MarkSucceeded#initialize(com.google.api.client.googleapis.services.Abstra
             * ctGoogleClientRequest)} must be called to initialize this instance immediately after invoking
             * the constructor. </p>
             *
             * @param name Required. Name of the recommendation.
             * @param content the {@link com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest}
             * @since 1.13
             */
            protected MarkSucceeded(java.lang.String name, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1MarkRecommendationSucceededRequest content) {
              super(Recommender.this, "POST", REST_PATH, content, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1Recommendation.class);
              this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified.");
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
            }

            @Override
            public MarkSucceeded set$Xgafv(java.lang.String $Xgafv) {
              return (MarkSucceeded) super.set$Xgafv($Xgafv);
            }

            @Override
            public MarkSucceeded setAccessToken(java.lang.String accessToken) {
              return (MarkSucceeded) super.setAccessToken(accessToken);
            }

            @Override
            public MarkSucceeded setAlt(java.lang.String alt) {
              return (MarkSucceeded) super.setAlt(alt);
            }

            @Override
            public MarkSucceeded setCallback(java.lang.String callback) {
              return (MarkSucceeded) super.setCallback(callback);
            }

            @Override
            public MarkSucceeded setFields(java.lang.String fields) {
              return (MarkSucceeded) super.setFields(fields);
            }

            @Override
            public MarkSucceeded setKey(java.lang.String key) {
              return (MarkSucceeded) super.setKey(key);
            }

            @Override
            public MarkSucceeded setOauthToken(java.lang.String oauthToken) {
              return (MarkSucceeded) super.setOauthToken(oauthToken);
            }

            @Override
            public MarkSucceeded setPrettyPrint(java.lang.Boolean prettyPrint) {
              return (MarkSucceeded) super.setPrettyPrint(prettyPrint);
            }

            @Override
            public MarkSucceeded setQuotaUser(java.lang.String quotaUser) {
              return (MarkSucceeded) super.setQuotaUser(quotaUser);
            }

            @Override
            public MarkSucceeded setUploadType(java.lang.String uploadType) {
              return (MarkSucceeded) super.setUploadType(uploadType);
            }

            @Override
            public MarkSucceeded setUploadProtocol(java.lang.String uploadProtocol) {
              return (MarkSucceeded) super.setUploadProtocol(uploadProtocol);
            }

            /** Required. Name of the recommendation. */
            @com.google.api.client.util.Key
            private java.lang.String name;

            /** Required. Name of the recommendation.
             */
            public java.lang.String getName() {
              return name;
            }

            /** Required. Name of the recommendation. */
            public MarkSucceeded setName(java.lang.String name) {
              if (!getSuppressPatternChecks()) {
                com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(),
                    "Parameter name must conform to the pattern " +
                    "^projects/[^/]+/locations/[^/]+/recommenders/[^/]+/recommendations/[^/]+$");
              }
              this.name = name;
              return this;
            }

            @Override
            public MarkSucceeded set(String parameterName, Object value) {
              return (MarkSucceeded) super.set(parameterName, value);
            }
          }

        }
      }
    }
  }

  /**
   * An accessor for creating requests from the Recommenders collection.
   *
   * <p>The typical use is:</p>
   * <pre>
   *   {@code Recommender recommender = new Recommender(...);}
   *   {@code Recommender.Recommenders.List request = recommender.recommenders().list(parameters ...)}
   * </pre>
   *
   * @return the resource collection
   */
  public Recommenders recommenders() {
    return new Recommenders();
  }

  /**
   * The "recommenders" collection of methods.
   */
  public class Recommenders {

    /**
     * Lists all available Recommenders. No IAM permissions are required.
     *
     * Create a request for the method "recommenders.list".
     *
     * This request holds the parameters needed by the recommender server.  After setting any optional
     * parameters, call the {@link List#execute()} method to invoke the remote operation.
     *
     * @return the request
     */
    public List list() throws java.io.IOException {
      List result = new List();
      initialize(result);
      return result;
    }

    public class List extends RecommenderRequest<com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendersResponse> {

      private static final String REST_PATH = "v1beta1/recommenders";

      /**
       * Lists all available Recommenders. No IAM permissions are required.
       *
       * Create a request for the method "recommenders.list".
       *
       * This request holds the parameters needed by the the recommender server.  After setting any
       * optional parameters, call the {@link List#execute()} method to invoke the remote operation. <p>
       * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)}
       * must be called to initialize this instance immediately after invoking the constructor. </p>
       *
       * @since 1.13
       */
      protected List() {
        super(Recommender.this, "GET", REST_PATH, null, com.google.api.services.recommender.v1beta1.model.GoogleCloudRecommenderV1beta1ListRecommendersResponse.class);
      }

      @Override
      public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
        return super.executeUsingHead();
      }

      @Override
      public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
        return super.buildHttpRequestUsingHead();
      }

      @Override
      public List set$Xgafv(java.lang.String $Xgafv) {
        return (List) super.set$Xgafv($Xgafv);
      }

      @Override
      public List setAccessToken(java.lang.String accessToken) {
        return (List) super.setAccessToken(accessToken);
      }

      @Override
      public List setAlt(java.lang.String alt) {
        return (List) super.setAlt(alt);
      }

      @Override
      public List setCallback(java.lang.String callback) {
        return (List) super.setCallback(callback);
      }

      @Override
      public List setFields(java.lang.String fields) {
        return (List) super.setFields(fields);
      }

      @Override
      public List setKey(java.lang.String key) {
        return (List) super.setKey(key);
      }

      @Override
      public List setOauthToken(java.lang.String oauthToken) {
        return (List) super.setOauthToken(oauthToken);
      }

      @Override
      public List setPrettyPrint(java.lang.Boolean prettyPrint) {
        return (List) super.setPrettyPrint(prettyPrint);
      }

      @Override
      public List setQuotaUser(java.lang.String quotaUser) {
        return (List) super.setQuotaUser(quotaUser);
      }

      @Override
      public List setUploadType(java.lang.String uploadType) {
        return (List) super.setUploadType(uploadType);
      }

      @Override
      public List setUploadProtocol(java.lang.String uploadProtocol) {
        return (List) super.setUploadProtocol(uploadProtocol);
      }

      /**
       * Optional. The number of RecommenderTypes to return per page. The service may return fewer
       * than this value.
       */
      @com.google.api.client.util.Key
      private java.lang.Integer pageSize;

      /** Optional. The number of RecommenderTypes to return per page. The service may return fewer than this
     value.
       */
      public java.lang.Integer getPageSize() {
        return pageSize;
      }

      /**
       * Optional. The number of RecommenderTypes to return per page. The service may return fewer
       * than this value.
       */
      public List setPageSize(java.lang.Integer pageSize) {
        this.pageSize = pageSize;
        return this;
      }

      /**
       * Optional. A page token, received from a previous `ListRecommenders` call. Provide this to
       * retrieve the subsequent page.
       */
      @com.google.api.client.util.Key
      private java.lang.String pageToken;

      /** Optional. A page token, received from a previous `ListRecommenders` call. Provide this to retrieve
     the subsequent page.
       */
      public java.lang.String getPageToken() {
        return pageToken;
      }

      /**
       * Optional. A page token, received from a previous `ListRecommenders` call. Provide this to
       * retrieve the subsequent page.
       */
      public List setPageToken(java.lang.String pageToken) {
        this.pageToken = pageToken;
        return this;
      }

      @Override
      public List set(String parameterName, Object value) {
        return (List) super.set(parameterName, value);
      }
    }

  }

  /**
   * Builder for {@link Recommender}.
   *
   * <p>
   * Implementation is not thread-safe.
   * </p>
   *
   * @since 1.3.0
   */
  public static final class Builder extends com.google.api.client.googleapis.services.json.AbstractGoogleJsonClient.Builder {

    private static String chooseEndpoint(com.google.api.client.http.HttpTransport transport) {
      // If the GOOGLE_API_USE_MTLS_ENDPOINT environment variable value is "always", use mTLS endpoint.
      // If the env variable is "auto", use mTLS endpoint if and only if the transport is mTLS.
      // Use the regular endpoint for all other cases.
      String useMtlsEndpoint = System.getenv("GOOGLE_API_USE_MTLS_ENDPOINT");
      useMtlsEndpoint = useMtlsEndpoint == null ? "auto" : useMtlsEndpoint;
      if ("always".equals(useMtlsEndpoint) || ("auto".equals(useMtlsEndpoint) && transport != null && transport.isMtls())) {
        return DEFAULT_MTLS_ROOT_URL;
      }
      return DEFAULT_ROOT_URL;
    }

    /**
     * Returns an instance of a new builder.
     *
     * @param transport HTTP transport, which should normally be:
     *        <ul>
     *        <li>Google App Engine:
     *        {@code com.google.api.client.extensions.appengine.http.UrlFetchTransport}</li>
     *        <li>Android: {@code newCompatibleTransport} from
     *        {@code com.google.api.client.extensions.android.http.AndroidHttp}</li>
     *        <li>Java: {@link com.google.api.client.googleapis.javanet.GoogleNetHttpTransport#newTrustedTransport()}
     *        </li>
     *        </ul>
     * @param jsonFactory JSON factory, which may be:
     *        <ul>
     *        <li>Jackson: {@code com.google.api.client.json.jackson2.JacksonFactory}</li>
     *        <li>Google GSON: {@code com.google.api.client.json.gson.GsonFactory}</li>
     *        <li>Android Honeycomb or higher:
     *        {@code com.google.api.client.extensions.android.json.AndroidJsonFactory}</li>
     *        </ul>
     * @param httpRequestInitializer HTTP request initializer or {@code null} for none
     * @since 1.7
     */
    public Builder(com.google.api.client.http.HttpTransport transport, com.google.api.client.json.JsonFactory jsonFactory,
        com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) {
      super(
          transport,
          jsonFactory,
          Builder.chooseEndpoint(transport),
          DEFAULT_SERVICE_PATH,
          httpRequestInitializer,
          false);
      setBatchPath(DEFAULT_BATCH_PATH);
    }

    /** Builds a new instance of {@link Recommender}. */
    @Override
    public Recommender build() {
      return new Recommender(this);
    }

    @Override
    public Builder setRootUrl(String rootUrl) {
      return (Builder) super.setRootUrl(rootUrl);
    }

    @Override
    public Builder setServicePath(String servicePath) {
      return (Builder) super.setServicePath(servicePath);
    }

    @Override
    public Builder setBatchPath(String batchPath) {
      return (Builder) super.setBatchPath(batchPath);
    }

    @Override
    public Builder setHttpRequestInitializer(com.google.api.client.http.HttpRequestInitializer httpRequestInitializer) {
      return (Builder) super.setHttpRequestInitializer(httpRequestInitializer);
    }

    @Override
    public Builder setApplicationName(String applicationName) {
      return (Builder) super.setApplicationName(applicationName);
    }

    @Override
    public Builder setSuppressPatternChecks(boolean suppressPatternChecks) {
      return (Builder) super.setSuppressPatternChecks(suppressPatternChecks);
    }

    @Override
    public Builder setSuppressRequiredParameterChecks(boolean suppressRequiredParameterChecks) {
      return (Builder) super.setSuppressRequiredParameterChecks(suppressRequiredParameterChecks);
    }

    @Override
    public Builder setSuppressAllChecks(boolean suppressAllChecks) {
      return (Builder) super.setSuppressAllChecks(suppressAllChecks);
    }

    /**
     * Set the {@link RecommenderRequestInitializer}.
     *
     * @since 1.12
     */
    public Builder setRecommenderRequestInitializer(
        RecommenderRequestInitializer recommenderRequestInitializer) {
      return (Builder) super.setGoogleClientRequestInitializer(recommenderRequestInitializer);
    }

    @Override
    public Builder setGoogleClientRequestInitializer(
        com.google.api.client.googleapis.services.GoogleClientRequestInitializer googleClientRequestInitializer) {
      return (Builder) super.setGoogleClientRequestInitializer(googleClientRequestInitializer);
    }
  }
}
