-
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.
Merge pull request #780 from commercetools/gen-sdk-updates
Update generated SDKs
- Loading branch information
Showing
43 changed files
with
3,847 additions
and
2 deletions.
There are no files selected for viewing
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
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
160 changes: 160 additions & 0 deletions
160
...java-generated/com/commercetools/api/models/message/ShoppingListLineItemAddedMessage.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,160 @@ | ||
|
||
package com.commercetools.api.models.message; | ||
|
||
import java.time.*; | ||
import java.util.*; | ||
import java.util.function.Function; | ||
|
||
import javax.annotation.Nullable; | ||
|
||
import com.commercetools.api.models.shopping_list.ShoppingListLineItem; | ||
import com.fasterxml.jackson.annotation.*; | ||
import com.fasterxml.jackson.databind.annotation.*; | ||
|
||
import io.vrap.rmf.base.client.utils.Generated; | ||
|
||
import jakarta.validation.Valid; | ||
import jakarta.validation.constraints.NotNull; | ||
|
||
/** | ||
* <p>Generated after a successful Add ShoppingListLineItem update action.</p> | ||
* | ||
* <hr> | ||
* Example to create an instance using the builder pattern | ||
* <div class=code-example> | ||
* <pre><code class='java'> | ||
* ShoppingListLineItemAddedMessage shoppingListLineItemAddedMessage = ShoppingListLineItemAddedMessage.builder() | ||
* .id("{id}") | ||
* .version(0.3) | ||
* .createdAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z")) | ||
* .lastModifiedAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z")) | ||
* .sequenceNumber(0.3) | ||
* .resource(resourceBuilder -> resourceBuilder) | ||
* .resourceVersion(0.3) | ||
* .lineItem(lineItemBuilder -> lineItemBuilder) | ||
* .build() | ||
* </code></pre> | ||
* </div> | ||
*/ | ||
@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen") | ||
@JsonDeserialize(as = ShoppingListLineItemAddedMessageImpl.class) | ||
public interface ShoppingListLineItemAddedMessage extends ShoppingListMessage { | ||
|
||
/** | ||
* discriminator value for ShoppingListLineItemAddedMessage | ||
*/ | ||
String SHOPPING_LIST_LINE_ITEM_ADDED = "ShoppingListLineItemAdded"; | ||
|
||
/** | ||
* <p>Line Item that was added to the ShoppingList.</p> | ||
* @return lineItem | ||
*/ | ||
@NotNull | ||
@Valid | ||
@JsonProperty("lineItem") | ||
public ShoppingListLineItem getLineItem(); | ||
|
||
/** | ||
* <p>Line Item that was added to the ShoppingList.</p> | ||
* @param lineItem value to be set | ||
*/ | ||
|
||
public void setLineItem(final ShoppingListLineItem lineItem); | ||
|
||
/** | ||
* factory method | ||
* @return instance of ShoppingListLineItemAddedMessage | ||
*/ | ||
public static ShoppingListLineItemAddedMessage of() { | ||
return new ShoppingListLineItemAddedMessageImpl(); | ||
} | ||
|
||
/** | ||
* factory method to create a shallow copy ShoppingListLineItemAddedMessage | ||
* @param template instance to be copied | ||
* @return copy instance | ||
*/ | ||
public static ShoppingListLineItemAddedMessage of(final ShoppingListLineItemAddedMessage template) { | ||
ShoppingListLineItemAddedMessageImpl instance = new ShoppingListLineItemAddedMessageImpl(); | ||
instance.setId(template.getId()); | ||
instance.setVersion(template.getVersion()); | ||
instance.setCreatedAt(template.getCreatedAt()); | ||
instance.setLastModifiedAt(template.getLastModifiedAt()); | ||
instance.setLastModifiedBy(template.getLastModifiedBy()); | ||
instance.setCreatedBy(template.getCreatedBy()); | ||
instance.setSequenceNumber(template.getSequenceNumber()); | ||
instance.setResource(template.getResource()); | ||
instance.setResourceVersion(template.getResourceVersion()); | ||
instance.setResourceUserProvidedIdentifiers(template.getResourceUserProvidedIdentifiers()); | ||
instance.setLineItem(template.getLineItem()); | ||
return instance; | ||
} | ||
|
||
/** | ||
* factory method to create a deep copy of ShoppingListLineItemAddedMessage | ||
* @param template instance to be copied | ||
* @return copy instance | ||
*/ | ||
@Nullable | ||
public static ShoppingListLineItemAddedMessage deepCopy(@Nullable final ShoppingListLineItemAddedMessage template) { | ||
if (template == null) { | ||
return null; | ||
} | ||
ShoppingListLineItemAddedMessageImpl instance = new ShoppingListLineItemAddedMessageImpl(); | ||
instance.setId(template.getId()); | ||
instance.setVersion(template.getVersion()); | ||
instance.setCreatedAt(template.getCreatedAt()); | ||
instance.setLastModifiedAt(template.getLastModifiedAt()); | ||
instance.setLastModifiedBy( | ||
com.commercetools.api.models.common.LastModifiedBy.deepCopy(template.getLastModifiedBy())); | ||
instance.setCreatedBy(com.commercetools.api.models.common.CreatedBy.deepCopy(template.getCreatedBy())); | ||
instance.setSequenceNumber(template.getSequenceNumber()); | ||
instance.setResource(com.commercetools.api.models.common.Reference.deepCopy(template.getResource())); | ||
instance.setResourceVersion(template.getResourceVersion()); | ||
instance.setResourceUserProvidedIdentifiers(com.commercetools.api.models.message.UserProvidedIdentifiers | ||
.deepCopy(template.getResourceUserProvidedIdentifiers())); | ||
instance.setLineItem( | ||
com.commercetools.api.models.shopping_list.ShoppingListLineItem.deepCopy(template.getLineItem())); | ||
return instance; | ||
} | ||
|
||
/** | ||
* builder factory method for ShoppingListLineItemAddedMessage | ||
* @return builder | ||
*/ | ||
public static ShoppingListLineItemAddedMessageBuilder builder() { | ||
return ShoppingListLineItemAddedMessageBuilder.of(); | ||
} | ||
|
||
/** | ||
* create builder for ShoppingListLineItemAddedMessage instance | ||
* @param template instance with prefilled values for the builder | ||
* @return builder | ||
*/ | ||
public static ShoppingListLineItemAddedMessageBuilder builder(final ShoppingListLineItemAddedMessage template) { | ||
return ShoppingListLineItemAddedMessageBuilder.of(template); | ||
} | ||
|
||
/** | ||
* accessor map function | ||
* @param <T> mapped type | ||
* @param helper function to map the object | ||
* @return mapped value | ||
*/ | ||
default <T> T withShoppingListLineItemAddedMessage(Function<ShoppingListLineItemAddedMessage, T> helper) { | ||
return helper.apply(this); | ||
} | ||
|
||
/** | ||
* gives a TypeReference for usage with Jackson DataBind | ||
* @return TypeReference | ||
*/ | ||
public static com.fasterxml.jackson.core.type.TypeReference<ShoppingListLineItemAddedMessage> typeReference() { | ||
return new com.fasterxml.jackson.core.type.TypeReference<ShoppingListLineItemAddedMessage>() { | ||
@Override | ||
public String toString() { | ||
return "TypeReference<ShoppingListLineItemAddedMessage>"; | ||
} | ||
}; | ||
} | ||
} |
Oops, something went wrong.