From: Kai Moritz Date: Fri, 11 Jun 2021 11:32:20 +0000 (+0200) Subject: WIP X-Git-Tag: wip-initialer-commit~23 X-Git-Url: http://juplo.de/gitweb/?a=commitdiff_plain;h=0ac40a774b84928360395db6a431fee2bda6723b;p=demos%2Fkafka%2Fdemos-kafka-payment-system-setup WIP --- diff --git a/transfer/src/main/java/de/juplo/kafka/payment/transfer/OrderBean.java b/transfer/src/main/java/de/juplo/kafka/payment/transfer/OrderBean.java deleted file mode 100644 index 6c724cc..0000000 --- a/transfer/src/main/java/de/juplo/kafka/payment/transfer/OrderBean.java +++ /dev/null @@ -1,84 +0,0 @@ -package de.juplo.kafka.payment.transfer; - -import javax.validation.constraints.NotNull; - - -/** - * Simple DTO used by the REST interface - */ -public class OrderBean -{ - @NotNull(message = "Cannot be null") - private long id; - @NotNull(message = "Cannot be null") - private long customerId; - @NotNull(message = "Cannot be null") - private long productId; - @NotNull(message = "Cannot be null") - private int quantity; - - - public OrderBean() {} - - public OrderBean( - final long id, - final long customerId, - final long productId, - final int quantity) - { - this.id = id; - this.customerId = customerId; - this.productId = productId; - this.quantity = quantity; - } - - public long getId() - { - return id; - } - - public long getCustomerId() - { - return customerId; - } - - public long getProductId() - { - return productId; - } - - public int getQuantity() - { - return quantity; - } - - - @Override - public boolean equals(final Object o) { - if (this == o) - return true; - if (o == null || this.getClass() != o.getClass()) - return false; - - final OrderBean orderBean = (OrderBean) o; - - return this.customerId == orderBean.customerId; - } - - @Override - public String toString() - { - return "{" + - "id=" + id + - ", customerId=" + customerId + - ", productId=" + productId + - ", quantity=" + quantity + - '}'; - } - - @Override - public int hashCode() - { - return Long.hashCode(this.id); - } -}