]> git.mxchange.org Git - addressbook-war.git/blobdiff - src/java/org/mxchange/addressbook/beans/contact/AddressbookAdminContactWebRequestController.java
Continued with contacts:
[addressbook-war.git] / src / java / org / mxchange / addressbook / beans / contact / AddressbookAdminContactWebRequestController.java
index 25fcfc5311003f9e91aea0bc0235179d7888142f..4719ac8b1b1b45458591c7ad41e4998428ef4b23 100644 (file)
@@ -18,6 +18,7 @@ package org.mxchange.addressbook.beans.contact;
 
 import java.io.Serializable;
 import java.util.Date;
+import java.util.List;
 import org.mxchange.jcontacts.contact.Contact;
 import org.mxchange.jcontacts.contact.gender.Gender;
 import org.mxchange.jcountry.data.Country;
@@ -30,6 +31,35 @@ import org.mxchange.jphone.phonenumbers.mobileprovider.MobileProvider;
  */
 public interface AddressbookAdminContactWebRequestController extends Serializable {
 
+       /**
+        * Adds contact data to database and redirects on success. If the contact is
+        * already found, a proper exception is thrown.
+        * <p>
+        * @return Redirect outcome
+        */
+       String addContact ();
+
+       /**
+        * Returns a list of all found contacts
+        * <p>
+        * @return A list of all contacts.
+        */
+       List<Contact> allContacts ();
+
+       /**
+        * Checks whether there are contacts.
+        * <p>
+        * @return Whether contacts are there
+        */
+       boolean hasContacts ();
+
+       /**
+        * Creates an instance from contact data
+        * <p>
+        * @return New contact instance
+        */
+       Contact createContactInstance ();
+
        /**
         * Copies given contact's data to this controller
         * <p>