Skip to content

Update generated SDKs #722

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 2 additions & 35 deletions changes.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,9 @@
**Api changes**

<details>
<summary>Removed Method(s)</summary>

- :warning: removed method `apiRoot.withProjectKey().me().businessUnits().withId().delete()`
- :warning: removed method `apiRoot.withProjectKey().me().businessUnits().withKey().delete()`
</details>


<details>
<summary>Added Property(s)</summary>

- added property `applicationMode` to type `CartDiscountValueAbsolute`
- added property `applicationMode` to type `CartDiscountValueAbsoluteDraft`
</details>


<details>
<summary>Added Type(s)</summary>

- added type `DiscountApplicationMode`
- added type `DeliveryCustomFieldAddedMessage`
- added type `DeliveryCustomFieldChangedMessage`
- added type `DeliveryCustomFieldRemovedMessage`
- added type `DeliveryCustomTypeRemovedMessage`
- added type `DeliveryCustomTypeSetMessage`
- added type `DeliveryCustomFieldAddedMessagePayload`
- added type `DeliveryCustomFieldChangedMessagePayload`
- added type `DeliveryCustomFieldRemovedMessagePayload`
- added type `DeliveryCustomTypeRemovedMessagePayload`
- added type `DeliveryCustomTypeSetMessagePayload`
</details>

**Import changes**

<details>
<summary>Added Type(s)</summary>

- added type `ReferencedResourceNotFound`
- added property `staged` to type `ProductVariantDeletedMessage`
- added property `staged` to type `ProductVariantDeletedMessagePayload`
</details>

Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
* .resource(resourceBuilder -> resourceBuilder)
* .resourceVersion(0.3)
* .plusRemovedImageUrls(removedImageUrlsBuilder -> removedImageUrlsBuilder)
* .staged(true)
* .build()
* </code></pre>
* </div>
Expand Down Expand Up @@ -61,6 +62,14 @@ public interface ProductVariantDeletedMessage extends Message {
@JsonProperty("removedImageUrls")
public List<String> getRemovedImageUrls();

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @return staged
*/
@NotNull
@JsonProperty("staged")
public Boolean getStaged();

/**
* <p>Unique identifier of the Product Variant that was added.</p>
* @param variant value to be set
Expand All @@ -83,6 +92,13 @@ public interface ProductVariantDeletedMessage extends Message {

public void setRemovedImageUrls(final List<String> removedImageUrls);

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @param staged value to be set
*/

public void setStaged(final Boolean staged);

/**
* factory method
* @return instance of ProductVariantDeletedMessage
Expand Down Expand Up @@ -110,6 +126,7 @@ public static ProductVariantDeletedMessage of(final ProductVariantDeletedMessage
instance.setResourceUserProvidedIdentifiers(template.getResourceUserProvidedIdentifiers());
instance.setVariant(template.getVariant());
instance.setRemovedImageUrls(template.getRemovedImageUrls());
instance.setStaged(template.getStaged());
return instance;
}

Expand Down Expand Up @@ -139,6 +156,7 @@ public static ProductVariantDeletedMessage deepCopy(@Nullable final ProductVaria
instance.setVariant(com.commercetools.api.models.product.ProductVariant.deepCopy(template.getVariant()));
instance.setRemovedImageUrls(
Optional.ofNullable(template.getRemovedImageUrls()).map(ArrayList::new).orElse(null));
instance.setStaged(template.getStaged());
return instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
* .resource(resourceBuilder -> resourceBuilder)
* .resourceVersion(0.3)
* .plusRemovedImageUrls(removedImageUrlsBuilder -> removedImageUrlsBuilder)
* .staged(true)
* .build()
* </code></pre>
* </div>
Expand Down Expand Up @@ -59,6 +60,8 @@ public class ProductVariantDeletedMessageBuilder implements Builder<ProductVaria

private java.util.List<String> removedImageUrls;

private Boolean staged;

/**
* <p>Unique identifier of the Message. Can be used to track which Messages have been processed.</p>
* @param id value to be set
Expand Down Expand Up @@ -331,6 +334,17 @@ public ProductVariantDeletedMessageBuilder plusRemovedImageUrls(final String...
return this;
}

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @param staged value to be set
* @return Builder
*/

public ProductVariantDeletedMessageBuilder staged(final Boolean staged) {
this.staged = staged;
return this;
}

/**
* <p>Unique identifier of the Message. Can be used to track which Messages have been processed.</p>
* @return id
Expand Down Expand Up @@ -443,6 +457,15 @@ public java.util.List<String> getRemovedImageUrls() {
return this.removedImageUrls;
}

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @return staged
*/

public Boolean getStaged() {
return this.staged;
}

/**
* builds ProductVariantDeletedMessage with checking for non-null required values
* @return ProductVariantDeletedMessage
Expand All @@ -456,8 +479,10 @@ public ProductVariantDeletedMessage build() {
Objects.requireNonNull(resource, ProductVariantDeletedMessage.class + ": resource is missing");
Objects.requireNonNull(resourceVersion, ProductVariantDeletedMessage.class + ": resourceVersion is missing");
Objects.requireNonNull(removedImageUrls, ProductVariantDeletedMessage.class + ": removedImageUrls is missing");
Objects.requireNonNull(staged, ProductVariantDeletedMessage.class + ": staged is missing");
return new ProductVariantDeletedMessageImpl(id, version, createdAt, lastModifiedAt, lastModifiedBy, createdBy,
sequenceNumber, resource, resourceVersion, resourceUserProvidedIdentifiers, variant, removedImageUrls);
sequenceNumber, resource, resourceVersion, resourceUserProvidedIdentifiers, variant, removedImageUrls,
staged);
}

/**
Expand All @@ -466,7 +491,8 @@ public ProductVariantDeletedMessage build() {
*/
public ProductVariantDeletedMessage buildUnchecked() {
return new ProductVariantDeletedMessageImpl(id, version, createdAt, lastModifiedAt, lastModifiedBy, createdBy,
sequenceNumber, resource, resourceVersion, resourceUserProvidedIdentifiers, variant, removedImageUrls);
sequenceNumber, resource, resourceVersion, resourceUserProvidedIdentifiers, variant, removedImageUrls,
staged);
}

/**
Expand Down Expand Up @@ -496,6 +522,7 @@ public static ProductVariantDeletedMessageBuilder of(final ProductVariantDeleted
builder.resourceUserProvidedIdentifiers = template.getResourceUserProvidedIdentifiers();
builder.variant = template.getVariant();
builder.removedImageUrls = template.getRemovedImageUrls();
builder.staged = template.getStaged();
return builder;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ public class ProductVariantDeletedMessageImpl implements ProductVariantDeletedMe

private java.util.List<String> removedImageUrls;

private Boolean staged;

/**
* create instance with all properties
*/
Expand All @@ -62,7 +64,8 @@ public class ProductVariantDeletedMessageImpl implements ProductVariantDeletedMe
@JsonProperty("resourceVersion") final Long resourceVersion,
@JsonProperty("resourceUserProvidedIdentifiers") final com.commercetools.api.models.message.UserProvidedIdentifiers resourceUserProvidedIdentifiers,
@JsonProperty("variant") final com.commercetools.api.models.product.ProductVariant variant,
@JsonProperty("removedImageUrls") final java.util.List<String> removedImageUrls) {
@JsonProperty("removedImageUrls") final java.util.List<String> removedImageUrls,
@JsonProperty("staged") final Boolean staged) {
this.id = id;
this.version = version;
this.createdAt = createdAt;
Expand All @@ -75,6 +78,7 @@ public class ProductVariantDeletedMessageImpl implements ProductVariantDeletedMe
this.resourceUserProvidedIdentifiers = resourceUserProvidedIdentifiers;
this.variant = variant;
this.removedImageUrls = removedImageUrls;
this.staged = staged;
this.type = PRODUCT_VARIANT_DELETED;
}

Expand Down Expand Up @@ -189,6 +193,14 @@ public java.util.List<String> getRemovedImageUrls() {
return this.removedImageUrls;
}

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
*/

public Boolean getStaged() {
return this.staged;
}

public void setId(final String id) {
this.id = id;
}
Expand Down Expand Up @@ -242,6 +254,10 @@ public void setRemovedImageUrls(final java.util.List<String> removedImageUrls) {
this.removedImageUrls = removedImageUrls;
}

public void setStaged(final Boolean staged) {
this.staged = staged;
}

@Override
public boolean equals(Object o) {
if (this == o)
Expand All @@ -265,6 +281,7 @@ public boolean equals(Object o) {
.append(resourceUserProvidedIdentifiers, that.resourceUserProvidedIdentifiers)
.append(variant, that.variant)
.append(removedImageUrls, that.removedImageUrls)
.append(staged, that.staged)
.append(id, that.id)
.append(version, that.version)
.append(createdAt, that.createdAt)
Expand All @@ -278,6 +295,7 @@ public boolean equals(Object o) {
.append(resourceUserProvidedIdentifiers, that.resourceUserProvidedIdentifiers)
.append(variant, that.variant)
.append(removedImageUrls, that.removedImageUrls)
.append(staged, that.staged)
.isEquals();
}

Expand All @@ -296,6 +314,7 @@ public int hashCode() {
.append(resourceUserProvidedIdentifiers)
.append(variant)
.append(removedImageUrls)
.append(staged)
.toHashCode();
}

Expand All @@ -314,6 +333,7 @@ public String toString() {
.append("resourceUserProvidedIdentifiers", resourceUserProvidedIdentifiers)
.append("variant", variant)
.append("removedImageUrls", removedImageUrls)
.append("staged", staged)
.build();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
* <pre><code class='java'>
* ProductVariantDeletedMessagePayload productVariantDeletedMessagePayload = ProductVariantDeletedMessagePayload.builder()
* .plusRemovedImageUrls(removedImageUrlsBuilder -> removedImageUrlsBuilder)
* .staged(true)
* .build()
* </code></pre>
* </div>
Expand Down Expand Up @@ -54,6 +55,14 @@ public interface ProductVariantDeletedMessagePayload extends MessagePayload {
@JsonProperty("removedImageUrls")
public List<String> getRemovedImageUrls();

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @return staged
*/
@NotNull
@JsonProperty("staged")
public Boolean getStaged();

/**
* <p>Unique identifier of the Product Variant that was added.</p>
* @param variant value to be set
Expand All @@ -76,6 +85,13 @@ public interface ProductVariantDeletedMessagePayload extends MessagePayload {

public void setRemovedImageUrls(final List<String> removedImageUrls);

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @param staged value to be set
*/

public void setStaged(final Boolean staged);

/**
* factory method
* @return instance of ProductVariantDeletedMessagePayload
Expand All @@ -93,6 +109,7 @@ public static ProductVariantDeletedMessagePayload of(final ProductVariantDeleted
ProductVariantDeletedMessagePayloadImpl instance = new ProductVariantDeletedMessagePayloadImpl();
instance.setVariant(template.getVariant());
instance.setRemovedImageUrls(template.getRemovedImageUrls());
instance.setStaged(template.getStaged());
return instance;
}

Expand All @@ -111,6 +128,7 @@ public static ProductVariantDeletedMessagePayload deepCopy(
instance.setVariant(com.commercetools.api.models.product.ProductVariant.deepCopy(template.getVariant()));
instance.setRemovedImageUrls(
Optional.ofNullable(template.getRemovedImageUrls()).map(ArrayList::new).orElse(null));
instance.setStaged(template.getStaged());
return instance;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
* <pre><code class='java'>
* ProductVariantDeletedMessagePayload productVariantDeletedMessagePayload = ProductVariantDeletedMessagePayload.builder()
* .plusRemovedImageUrls(removedImageUrlsBuilder -> removedImageUrlsBuilder)
* .staged(true)
* .build()
* </code></pre>
* </div>
Expand All @@ -29,6 +30,8 @@ public class ProductVariantDeletedMessagePayloadBuilder implements Builder<Produ

private java.util.List<String> removedImageUrls;

private Boolean staged;

/**
* <p>Unique identifier of the Product Variant that was added.</p>
* @param builder function to build the variant value
Expand Down Expand Up @@ -101,6 +104,17 @@ public ProductVariantDeletedMessagePayloadBuilder plusRemovedImageUrls(final Str
return this;
}

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @param staged value to be set
* @return Builder
*/

public ProductVariantDeletedMessagePayloadBuilder staged(final Boolean staged) {
this.staged = staged;
return this;
}

/**
* <p>Unique identifier of the Product Variant that was added.</p>
* @return variant
Expand All @@ -120,22 +134,32 @@ public java.util.List<String> getRemovedImageUrls() {
return this.removedImageUrls;
}

/**
* <p>If <code>true</code>, this message informs that only the staged ProductVariant has been removed by the update action. If <code>false</code>, both the current and staged ProductVariant have been removed.</p>
* @return staged
*/

public Boolean getStaged() {
return this.staged;
}

/**
* builds ProductVariantDeletedMessagePayload with checking for non-null required values
* @return ProductVariantDeletedMessagePayload
*/
public ProductVariantDeletedMessagePayload build() {
Objects.requireNonNull(removedImageUrls,
ProductVariantDeletedMessagePayload.class + ": removedImageUrls is missing");
return new ProductVariantDeletedMessagePayloadImpl(variant, removedImageUrls);
Objects.requireNonNull(staged, ProductVariantDeletedMessagePayload.class + ": staged is missing");
return new ProductVariantDeletedMessagePayloadImpl(variant, removedImageUrls, staged);
}

/**
* builds ProductVariantDeletedMessagePayload without checking for non-null required values
* @return ProductVariantDeletedMessagePayload
*/
public ProductVariantDeletedMessagePayload buildUnchecked() {
return new ProductVariantDeletedMessagePayloadImpl(variant, removedImageUrls);
return new ProductVariantDeletedMessagePayloadImpl(variant, removedImageUrls, staged);
}

/**
Expand All @@ -155,6 +179,7 @@ public static ProductVariantDeletedMessagePayloadBuilder of(final ProductVariant
ProductVariantDeletedMessagePayloadBuilder builder = new ProductVariantDeletedMessagePayloadBuilder();
builder.variant = template.getVariant();
builder.removedImageUrls = template.getRemovedImageUrls();
builder.staged = template.getStaged();
return builder;
}

Expand Down
Loading
Loading