]> git.mxchange.org Git - jshop-core.git/blobdiff - src/org/mxchange/jshopcore/model/product/BaseProduct.java
More cleanup
[jshop-core.git] / src / org / mxchange / jshopcore / model / product / BaseProduct.java
index 5faa9bf1cd49f71c089c56986274c6974a86a89a..b1704d63b561fe17e7aa4f615102c7f24a727550 100644 (file)
@@ -7,13 +7,19 @@ package org.mxchange.jshopcore.model.product;
 
 import java.text.MessageFormat;
 import java.util.Objects;
-import org.mxchange.jshopcore.BaseShopCore;
+import org.mxchange.jcoree.BaseEeSystem;
 
 /**
+ * A general product class
  *
  * @author Roland Haeder
  */
-public class BaseProduct extends BaseShopCore implements Product {
+public abstract class BaseProduct extends BaseEeSystem implements Product, Comparable<Product> {
+       /**
+        * Serial number
+        */
+       private static final long serialVersionUID = 48_379_575_267_451L;
+
        /**
         * Availability of product
         */
@@ -42,7 +48,7 @@ public class BaseProduct extends BaseShopCore implements Product {
        @Override
        public int compareTo (final Product product) {
                // Trace message
-               this.getLogger().trace(MessageFormat.format("product={0} - CALLED!", product)); //NOI18N
+               this.getLogger().logTrace(MessageFormat.format("product={0} - CALLED!", product)); //NOI18N
                
                // category should not be null
                if (null == product) {
@@ -50,7 +56,7 @@ public class BaseProduct extends BaseShopCore implements Product {
                }
                
                // Debug message
-               this.getLogger().debug(MessageFormat.format("this.id={0},product.id={1}", this.getItemId(), product.getItemId())); //NOI18N
+               this.getLogger().logDebug(MessageFormat.format("this.id={0},product.id={1}", this.getItemId(), product.getItemId())); //NOI18N
                
                // Is the id the same?
                if (Objects.equals(this.getItemId(), product.getItemId())) {
@@ -66,52 +72,52 @@ public class BaseProduct extends BaseShopCore implements Product {
        }
 
        @Override
-       public final Boolean getAvailable () {
+       public Boolean getAvailable () {
                return this.available;
        }
 
        @Override
-       public final void setAvailable (final Boolean available) {
+       public void setAvailable (final Boolean available) {
                this.available = available;
        }
 
        @Override
-       public final Long getCategoryId () {
+       public Long getCategoryId () {
                return this.categoryId;
        }
 
        @Override
-       public final void setCategoryId (final Long categoryId) {
+       public void setCategoryId (final Long categoryId) {
                this.categoryId = categoryId;
        }
 
        @Override
-       public final Long getItemId () {
+       public Long getItemId () {
                return this.itemId;
        }
 
        @Override
-       public final void setItemId (final Long itemId) {
+       public void setItemId (final Long itemId) {
                this.itemId = itemId;
        }
 
        @Override
-       public final Float getPrice () {
+       public Float getPrice () {
                return this.price;
        }
 
        @Override
-       public final void setPrice (final Float price) {
+       public void setPrice (final Float price) {
                this.price = price;
        }
 
        @Override
-       public final String getTitle () {
+       public String getTitle () {
                return this.title;
        }
 
        @Override
-       public final void setTitle (final String title) {
+       public void setTitle (final String title) {
                this.title = title;
        }
 }