All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.commercetools.graphql.api.client.DeletePaymentGraphQLQuery Maven / Gradle / Ivy

There is a newer version: 17.15.1
Show newest version
package com.commercetools.graphql.api.client;

import com.netflix.graphql.dgs.client.codegen.GraphQLQuery;
import java.lang.Boolean;
import java.lang.Long;
import java.lang.Override;
import java.lang.String;
import java.util.HashSet;
import java.util.Set;

public class DeletePaymentGraphQLQuery extends GraphQLQuery {
  public DeletePaymentGraphQLQuery(Long version, Boolean personalDataErasure, String id, String key,
      String queryName, Set fieldsSet) {
    super("mutation", queryName);
    if (version != null || fieldsSet.contains("version")) {
        getInput().put("version", version);
    }if (personalDataErasure != null || fieldsSet.contains("personalDataErasure")) {
        getInput().put("personalDataErasure", personalDataErasure);
    }if (id != null || fieldsSet.contains("id")) {
        getInput().put("id", id);
    }if (key != null || fieldsSet.contains("key")) {
        getInput().put("key", key);
    }
  }

  public DeletePaymentGraphQLQuery() {
    super("mutation");
  }

  @Override
  public String getOperationName() {
     return "deletePayment";
                    
  }

  public static Builder newRequest() {
    return new Builder();
  }

  public static class Builder {
    private Set fieldsSet = new HashSet<>();

    private Long version;

    private Boolean personalDataErasure;

    private String id;

    private String key;

    private String queryName;

    public DeletePaymentGraphQLQuery build() {
      return new DeletePaymentGraphQLQuery(version, personalDataErasure, id, key, queryName, fieldsSet);
               
    }

    public Builder version(Long version) {
      this.version = version;
      this.fieldsSet.add("version");
      return this;
    }

    public Builder personalDataErasure(Boolean personalDataErasure) {
      this.personalDataErasure = personalDataErasure;
      this.fieldsSet.add("personalDataErasure");
      return this;
    }

    /**
     * Queries with specified ID
     */
    public Builder id(String id) {
      this.id = id;
      this.fieldsSet.add("id");
      return this;
    }

    /**
     * Queries with specified key
     */
    public Builder key(String key) {
      this.key = key;
      this.fieldsSet.add("key");
      return this;
    }

    public Builder queryName(String queryName) {
      this.queryName = queryName;
      return this;
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy