-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
49e14e5
commit 06c4b8d
Showing
429 changed files
with
31,154 additions
and
2,273 deletions.
There are no files selected for viewing
214 changes: 188 additions & 26 deletions
214
commercetools/commercetools-graphql-api/src/main/resources/graphql/schema.graphqls
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
109 changes: 109 additions & 0 deletions
109
.../src/main/java-generated/com/commercetools/api/client/ByProjectKeyProductsSearchHead.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
|
||
package com.commercetools.api.client; | ||
|
||
import java.net.URI; | ||
import java.time.Duration; | ||
import java.util.ArrayList; | ||
import java.util.List; | ||
import java.util.concurrent.CompletableFuture; | ||
|
||
import com.fasterxml.jackson.core.type.TypeReference; | ||
|
||
import io.vrap.rmf.base.client.*; | ||
import io.vrap.rmf.base.client.utils.Generated; | ||
|
||
import org.apache.commons.lang3.builder.EqualsBuilder; | ||
import org.apache.commons.lang3.builder.HashCodeBuilder; | ||
|
||
/** | ||
* <p>Checks whether a search index for the Project's Products exists.</p> | ||
* | ||
* <hr> | ||
* <div class=code-example> | ||
* <pre><code class='java'>{@code | ||
* CompletableFuture<ApiHttpResponse<com.fasterxml.jackson.databind.JsonNode>> result = apiRoot | ||
* .withProjectKey("{projectKey}") | ||
* .products() | ||
* .search() | ||
* .head() | ||
* .execute() | ||
* }</code></pre> | ||
* </div> | ||
*/ | ||
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen") | ||
public class ByProjectKeyProductsSearchHead | ||
extends TypeApiMethod<ByProjectKeyProductsSearchHead, com.fasterxml.jackson.databind.JsonNode> | ||
implements com.commercetools.api.client.ErrorableTrait<ByProjectKeyProductsSearchHead>, | ||
com.commercetools.api.client.Deprecatable200Trait<ByProjectKeyProductsSearchHead> { | ||
|
||
@Override | ||
public TypeReference<com.fasterxml.jackson.databind.JsonNode> resultType() { | ||
return new TypeReference<com.fasterxml.jackson.databind.JsonNode>() { | ||
}; | ||
} | ||
|
||
private String projectKey; | ||
|
||
public ByProjectKeyProductsSearchHead(final ApiHttpClient apiHttpClient, String projectKey) { | ||
super(apiHttpClient); | ||
this.projectKey = projectKey; | ||
} | ||
|
||
public ByProjectKeyProductsSearchHead(ByProjectKeyProductsSearchHead t) { | ||
super(t); | ||
this.projectKey = t.projectKey; | ||
} | ||
|
||
@Override | ||
protected ApiHttpRequest buildHttpRequest() { | ||
List<String> params = new ArrayList<>(getQueryParamUriStrings()); | ||
String httpRequestPath = String.format("%s/products/search", this.projectKey); | ||
if (!params.isEmpty()) { | ||
httpRequestPath += "?" + String.join("&", params); | ||
} | ||
return new ApiHttpRequest(ApiHttpMethod.HEAD, URI.create(httpRequestPath), getHeaders(), null); | ||
} | ||
|
||
@Override | ||
public ApiHttpResponse<com.fasterxml.jackson.databind.JsonNode> executeBlocking(final ApiHttpClient client, | ||
final Duration timeout) { | ||
return executeBlocking(client, timeout, com.fasterxml.jackson.databind.JsonNode.class); | ||
} | ||
|
||
@Override | ||
public CompletableFuture<ApiHttpResponse<com.fasterxml.jackson.databind.JsonNode>> execute( | ||
final ApiHttpClient client) { | ||
return execute(client, com.fasterxml.jackson.databind.JsonNode.class); | ||
} | ||
|
||
public String getProjectKey() { | ||
return this.projectKey; | ||
} | ||
|
||
public void setProjectKey(final String projectKey) { | ||
this.projectKey = projectKey; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) | ||
return true; | ||
|
||
if (o == null || getClass() != o.getClass()) | ||
return false; | ||
|
||
ByProjectKeyProductsSearchHead that = (ByProjectKeyProductsSearchHead) o; | ||
|
||
return new EqualsBuilder().append(projectKey, that.projectKey).isEquals(); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return new HashCodeBuilder(17, 37).append(projectKey).toHashCode(); | ||
} | ||
|
||
@Override | ||
protected ByProjectKeyProductsSearchHead copy() { | ||
return new ByProjectKeyProductsSearchHead(this); | ||
} | ||
} |
130 changes: 130 additions & 0 deletions
130
.../src/main/java-generated/com/commercetools/api/client/ByProjectKeyProductsSearchPost.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,130 @@ | ||
|
||
package com.commercetools.api.client; | ||
|
||
import java.net.URI; | ||
import java.time.Duration; | ||
import java.util.ArrayList; | ||
import java.util.List; | ||
import java.util.concurrent.CompletableFuture; | ||
|
||
import com.fasterxml.jackson.core.type.TypeReference; | ||
|
||
import io.vrap.rmf.base.client.*; | ||
import io.vrap.rmf.base.client.utils.Generated; | ||
|
||
import org.apache.commons.lang3.builder.EqualsBuilder; | ||
import org.apache.commons.lang3.builder.HashCodeBuilder; | ||
|
||
/** | ||
* | ||
* | ||
* <hr> | ||
* <div class=code-example> | ||
* <pre><code class='java'>{@code | ||
* CompletableFuture<ApiHttpResponse<com.commercetools.api.models.product_search.ProductPagedSearchResponse>> result = apiRoot | ||
* .withProjectKey("{projectKey}") | ||
* .products() | ||
* .search() | ||
* .post(null) | ||
* .execute() | ||
* }</code></pre> | ||
* </div> | ||
*/ | ||
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen") | ||
public class ByProjectKeyProductsSearchPost extends | ||
TypeBodyApiMethod<ByProjectKeyProductsSearchPost, com.commercetools.api.models.product_search.ProductPagedSearchResponse, com.commercetools.api.models.product_search.ProductSearchRequest> | ||
implements com.commercetools.api.client.ErrorableTrait<ByProjectKeyProductsSearchPost> { | ||
|
||
@Override | ||
public TypeReference<com.commercetools.api.models.product_search.ProductPagedSearchResponse> resultType() { | ||
return new TypeReference<com.commercetools.api.models.product_search.ProductPagedSearchResponse>() { | ||
}; | ||
} | ||
|
||
private String projectKey; | ||
|
||
private com.commercetools.api.models.product_search.ProductSearchRequest productSearchRequest; | ||
|
||
public ByProjectKeyProductsSearchPost(final ApiHttpClient apiHttpClient, String projectKey, | ||
com.commercetools.api.models.product_search.ProductSearchRequest productSearchRequest) { | ||
super(apiHttpClient); | ||
this.projectKey = projectKey; | ||
this.productSearchRequest = productSearchRequest; | ||
} | ||
|
||
public ByProjectKeyProductsSearchPost(ByProjectKeyProductsSearchPost t) { | ||
super(t); | ||
this.projectKey = t.projectKey; | ||
this.productSearchRequest = t.productSearchRequest; | ||
} | ||
|
||
@Override | ||
protected ApiHttpRequest buildHttpRequest() { | ||
List<String> params = new ArrayList<>(getQueryParamUriStrings()); | ||
String httpRequestPath = String.format("%s/products/search", this.projectKey); | ||
if (!params.isEmpty()) { | ||
httpRequestPath += "?" + String.join("&", params); | ||
} | ||
return new ApiHttpRequest(ApiHttpMethod.POST, URI.create(httpRequestPath), getHeaders(), | ||
io.vrap.rmf.base.client.utils.json.JsonUtils | ||
.executing(() -> apiHttpClient().getSerializerService().toJsonByteArray(productSearchRequest))); | ||
|
||
} | ||
|
||
@Override | ||
public ApiHttpResponse<com.commercetools.api.models.product_search.ProductPagedSearchResponse> executeBlocking( | ||
final ApiHttpClient client, final Duration timeout) { | ||
return executeBlocking(client, timeout, | ||
com.commercetools.api.models.product_search.ProductPagedSearchResponse.class); | ||
} | ||
|
||
@Override | ||
public CompletableFuture<ApiHttpResponse<com.commercetools.api.models.product_search.ProductPagedSearchResponse>> execute( | ||
final ApiHttpClient client) { | ||
return execute(client, com.commercetools.api.models.product_search.ProductPagedSearchResponse.class); | ||
} | ||
|
||
public String getProjectKey() { | ||
return this.projectKey; | ||
} | ||
|
||
public void setProjectKey(final String projectKey) { | ||
this.projectKey = projectKey; | ||
} | ||
|
||
public com.commercetools.api.models.product_search.ProductSearchRequest getBody() { | ||
return productSearchRequest; | ||
} | ||
|
||
public ByProjectKeyProductsSearchPost withBody( | ||
com.commercetools.api.models.product_search.ProductSearchRequest productSearchRequest) { | ||
ByProjectKeyProductsSearchPost t = copy(); | ||
t.productSearchRequest = productSearchRequest; | ||
return t; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) | ||
return true; | ||
|
||
if (o == null || getClass() != o.getClass()) | ||
return false; | ||
|
||
ByProjectKeyProductsSearchPost that = (ByProjectKeyProductsSearchPost) o; | ||
|
||
return new EqualsBuilder().append(projectKey, that.projectKey) | ||
.append(productSearchRequest, that.productSearchRequest) | ||
.isEquals(); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return new HashCodeBuilder(17, 37).append(projectKey).append(productSearchRequest).toHashCode(); | ||
} | ||
|
||
@Override | ||
protected ByProjectKeyProductsSearchPost copy() { | ||
return new ByProjectKeyProductsSearchPost(this); | ||
} | ||
} |
129 changes: 129 additions & 0 deletions
129
...ain/java-generated/com/commercetools/api/client/ByProjectKeyProductsSearchPostString.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,129 @@ | ||
|
||
package com.commercetools.api.client; | ||
|
||
import java.net.URI; | ||
import java.nio.charset.StandardCharsets; | ||
import java.time.Duration; | ||
import java.util.ArrayList; | ||
import java.util.List; | ||
import java.util.concurrent.CompletableFuture; | ||
|
||
import com.fasterxml.jackson.core.type.TypeReference; | ||
|
||
import io.vrap.rmf.base.client.*; | ||
import io.vrap.rmf.base.client.utils.Generated; | ||
|
||
import org.apache.commons.lang3.builder.EqualsBuilder; | ||
import org.apache.commons.lang3.builder.HashCodeBuilder; | ||
|
||
/** | ||
* | ||
* | ||
* <hr> | ||
* <div class=code-example> | ||
* <pre><code class='java'>{@code | ||
* CompletableFuture<ApiHttpResponse<com.commercetools.api.models.product_search.ProductPagedSearchResponse>> result = apiRoot | ||
* .withProjectKey("{projectKey}") | ||
* .products() | ||
* .search() | ||
* .post("") | ||
* .execute() | ||
* }</code></pre> | ||
* </div> | ||
*/ | ||
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen") | ||
public class ByProjectKeyProductsSearchPostString extends | ||
StringBodyApiMethod<ByProjectKeyProductsSearchPostString, com.commercetools.api.models.product_search.ProductPagedSearchResponse> | ||
implements com.commercetools.api.client.ErrorableTrait<ByProjectKeyProductsSearchPostString> { | ||
|
||
@Override | ||
public TypeReference<com.commercetools.api.models.product_search.ProductPagedSearchResponse> resultType() { | ||
return new TypeReference<com.commercetools.api.models.product_search.ProductPagedSearchResponse>() { | ||
}; | ||
} | ||
|
||
private String projectKey; | ||
|
||
private String productSearchRequest; | ||
|
||
public ByProjectKeyProductsSearchPostString(final ApiHttpClient apiHttpClient, String projectKey, | ||
String productSearchRequest) { | ||
super(apiHttpClient); | ||
this.projectKey = projectKey; | ||
this.productSearchRequest = productSearchRequest; | ||
} | ||
|
||
public ByProjectKeyProductsSearchPostString(ByProjectKeyProductsSearchPostString t) { | ||
super(t); | ||
this.projectKey = t.projectKey; | ||
this.productSearchRequest = t.productSearchRequest; | ||
} | ||
|
||
@Override | ||
protected ApiHttpRequest buildHttpRequest() { | ||
List<String> params = new ArrayList<>(getQueryParamUriStrings()); | ||
String httpRequestPath = String.format("%s/products/search", this.projectKey); | ||
if (!params.isEmpty()) { | ||
httpRequestPath += "?" + String.join("&", params); | ||
} | ||
return new ApiHttpRequest(ApiHttpMethod.POST, URI.create(httpRequestPath), getHeaders(), | ||
productSearchRequest.getBytes(StandardCharsets.UTF_8)); | ||
|
||
} | ||
|
||
@Override | ||
public ApiHttpResponse<com.commercetools.api.models.product_search.ProductPagedSearchResponse> executeBlocking( | ||
final ApiHttpClient client, final Duration timeout) { | ||
return executeBlocking(client, timeout, | ||
com.commercetools.api.models.product_search.ProductPagedSearchResponse.class); | ||
} | ||
|
||
@Override | ||
public CompletableFuture<ApiHttpResponse<com.commercetools.api.models.product_search.ProductPagedSearchResponse>> execute( | ||
final ApiHttpClient client) { | ||
return execute(client, com.commercetools.api.models.product_search.ProductPagedSearchResponse.class); | ||
} | ||
|
||
public String getProjectKey() { | ||
return this.projectKey; | ||
} | ||
|
||
public void setProjectKey(final String projectKey) { | ||
this.projectKey = projectKey; | ||
} | ||
|
||
public String getBody() { | ||
return productSearchRequest; | ||
} | ||
|
||
public ByProjectKeyProductsSearchPostString withBody(String productSearchRequest) { | ||
ByProjectKeyProductsSearchPostString t = copy(); | ||
t.productSearchRequest = productSearchRequest; | ||
return t; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) | ||
return true; | ||
|
||
if (o == null || getClass() != o.getClass()) | ||
return false; | ||
|
||
ByProjectKeyProductsSearchPostString that = (ByProjectKeyProductsSearchPostString) o; | ||
|
||
return new EqualsBuilder().append(projectKey, that.projectKey) | ||
.append(productSearchRequest, that.productSearchRequest) | ||
.isEquals(); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return new HashCodeBuilder(17, 37).append(projectKey).append(productSearchRequest).toHashCode(); | ||
} | ||
|
||
@Override | ||
protected ByProjectKeyProductsSearchPostString copy() { | ||
return new ByProjectKeyProductsSearchPostString(this); | ||
} | ||
} |
Oops, something went wrong.