From 514c309bfdb6c5ce1d4244ba1e7b2e278d6a83e6 Mon Sep 17 00:00:00 2001 From: Roland Haeder Date: Fri, 9 Oct 2015 21:36:03 +0200 Subject: [PATCH] Continued: - Bean method addAddressbook() should be "basicly finished" - Same for isAddressbookNameUsed() - renamed isLoggedIn() to isUserLoggedIn() to make it more clear --- .../beans/addressbook/AddressbookWebController.java | 9 +++++++++ .../addressbook/beans/login/UserLoginWebBean.java | 2 +- .../addressbook/beans/login/UserLoginWebController.java | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/java/org/mxchange/addressbook/beans/addressbook/AddressbookWebController.java b/src/java/org/mxchange/addressbook/beans/addressbook/AddressbookWebController.java index 56af2ea7..d4adf218 100644 --- a/src/java/org/mxchange/addressbook/beans/addressbook/AddressbookWebController.java +++ b/src/java/org/mxchange/addressbook/beans/addressbook/AddressbookWebController.java @@ -52,4 +52,13 @@ public interface AddressbookWebController extends Serializable { * @param addressbookName Address book name */ public void setAddressbookName(final String addressbookName); + + /** + * Checks if the given address book name is already used by the user. + *

+ * @param addressbookName Address book name to check + *

+ * @return Whether the name has already been used by the user + */ + public boolean isAddressbookNameUsed(final String addressbookName); } diff --git a/src/java/org/mxchange/addressbook/beans/login/UserLoginWebBean.java b/src/java/org/mxchange/addressbook/beans/login/UserLoginWebBean.java index feff2584..a145db84 100644 --- a/src/java/org/mxchange/addressbook/beans/login/UserLoginWebBean.java +++ b/src/java/org/mxchange/addressbook/beans/login/UserLoginWebBean.java @@ -107,7 +107,7 @@ public class UserLoginWebBean implements UserLoginWebController { } @Override - public boolean isLoggedIn () { + public boolean isUserLoggedIn () { // Compare instance return (this.getLoggedInUser() instanceof User); } diff --git a/src/java/org/mxchange/addressbook/beans/login/UserLoginWebController.java b/src/java/org/mxchange/addressbook/beans/login/UserLoginWebController.java index 89e51846..ff8adf55 100644 --- a/src/java/org/mxchange/addressbook/beans/login/UserLoginWebController.java +++ b/src/java/org/mxchange/addressbook/beans/login/UserLoginWebController.java @@ -52,5 +52,5 @@ public interface UserLoginWebController extends Serializable { *

* @return Whether the user is logged-in */ - public boolean isLoggedIn (); + public boolean isUserLoggedIn (); } -- 2.39.5