]> git.mxchange.org Git - jcontacts-lib.git/blobdiff - src/org/mxchange/jcontacts/model/contact/ContactSessionBeanRemote.java
Updated copyright year
[jcontacts-lib.git] / src / org / mxchange / jcontacts / model / contact / ContactSessionBeanRemote.java
index 78787659e1b036061c9ec06a8776c845e5c5975f..e9a0d64417896d44e6b4ad73cfa412295ddde5ec 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2016 - 2018 Free Software Foundation
+ * Copyright (C) 2016 - 2024 Free Software Foundation
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -19,6 +19,7 @@ package org.mxchange.jcontacts.model.contact;
 import java.io.Serializable;
 import java.util.List;
 import javax.ejb.Remote;
+import org.mxchange.jcontacts.exceptions.ContactNotFoundException;
 
 /**
  * A remote interface for general contact purposes
@@ -28,29 +29,22 @@ import javax.ejb.Remote;
 @Remote
 public interface ContactSessionBeanRemote extends Serializable {
 
-       /**
-        * Checks if the given contact can be found by checking the whole list.
-        * <p>
-        * @param contact Contact instance to check
-        * <p>
-        * @return Whether the found instance or null
-        */
-       Contact lookupContact (final Contact contact);
-
        /**
         * Updates given contact data
         * <p>
-        * @param contact Contact data to update
-        * @param isMobileUnlinked Whether a mobile entry has been unlinked in
-        * contact instance
+        * @param contact            Contact data to update
+        * @param isMobileUnlinked   Whether a mobile entry has been unlinked in
+        *                           contact instance
         * @param isLandlineUnlinked Whether a land-line entry has been unlinked in
-        * contact instance
-        * @param isFaxUnlinked Whether a fax entry has been unlinked in contact
-        * instance
+        *                           contact instance
+        * @param isFaxUnlinked      Whether a fax entry has been unlinked in
+        *                           contact instance
         * <p>
         * @return Updated contact instance
+        * <p>
+        * @throws ContactNotFoundException If the given contact is not found
         */
-       Contact updateContactData (final Contact contact, final boolean isMobileUnlinked, final boolean isLandlineUnlinked, final boolean isFaxUnlinked);
+       Contact updateContactData (final Contact contact, final boolean isMobileUnlinked, final boolean isLandlineUnlinked, final boolean isFaxUnlinked) throws ContactNotFoundException;
 
        /**
         * Updates given contact in database. Please note that the id number must be
@@ -60,14 +54,16 @@ public interface ContactSessionBeanRemote extends Serializable {
         * @param contact Contact to update
         * <p>
         * @return Updated contact instance
+        * <p>
+        * @throws ContactNotFoundException If the given contact is not found
         */
-       Contact updateContactData (final Contact contact);
+       Contact updateContactData (final Contact contact) throws ContactNotFoundException;
 
        /**
         * Returns a list of all found contacts
         * <p>
         * @return A list of call contacts
         */
-       List<Contact> allContacts ();
+       List<Contact> fetchAllContacts ();
 
 }