From 9653084311289ac311117c75b0e39e5adf42aa22 Mon Sep 17 00:00:00 2001 From: Roland Haeder Date: Sun, 10 Apr 2016 15:15:22 +0200 Subject: [PATCH] renamed method as it now returns only size() --- .../jshopcore/model/basket/BaseBasket.java | 18 +++++++++--------- .../jshopcore/model/basket/Basket.java | 6 +++--- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/org/mxchange/jshopcore/model/basket/BaseBasket.java b/src/org/mxchange/jshopcore/model/basket/BaseBasket.java index 476c529..b6a3b8a 100644 --- a/src/org/mxchange/jshopcore/model/basket/BaseBasket.java +++ b/src/org/mxchange/jshopcore/model/basket/BaseBasket.java @@ -96,15 +96,6 @@ public abstract class BaseBasket implements Basket< return this.deque.getLast(); } - @Override - public int getLastNumRows () { - // Is the list empty? - assert this.isEmpty() : "deque is empty"; //NOI18N - - // It is size-1 - return (this.deque.size() - 1); - } - @Override public boolean isAdded (final T item) { // item must not be null @@ -138,4 +129,13 @@ public abstract class BaseBasket implements Basket< return this.deque.isEmpty(); } + @Override + public int size () { + // Is the list empty? + assert this.isEmpty() : "deque is empty"; //NOI18N + + // It is size-1 + return this.deque.size(); + } + } diff --git a/src/org/mxchange/jshopcore/model/basket/Basket.java b/src/org/mxchange/jshopcore/model/basket/Basket.java index c963ba2..075006b 100644 --- a/src/org/mxchange/jshopcore/model/basket/Basket.java +++ b/src/org/mxchange/jshopcore/model/basket/Basket.java @@ -65,11 +65,11 @@ public interface Basket extends Serializable { T getLast (); /** - * Getter for last num rows + * Getter for basket size *

- * @return Last num rows + * @return Basket size */ - int getLastNumRows (); + int size (); /** * Checks whether the given item has already been added by checking the -- 2.39.5