]> git.mxchange.org Git - jaddressbook-lib.git/blobdiff - src/org/mxchange/addressbook/model/addressbook/AddressbookSessionBeanRemote.java
Continued:
[jaddressbook-lib.git] / src / org / mxchange / addressbook / model / addressbook / AddressbookSessionBeanRemote.java
index 0fe67bba81ead39ebbe4291e31b1d744aca18eb0..fc3231091225e99dafbbf9c32ccad4cdbac4af79 100644 (file)
@@ -20,6 +20,7 @@ import java.io.Serializable;
 import java.util.List;
 import javax.ejb.Remote;
 import org.mxchange.addressbook.exceptions.AddressbookNameAlreadyUsedException;
+import org.mxchange.addressbook.exceptions.AddressbookNotFoundException;
 import org.mxchange.addressbook.model.addressbook.entry.AddressbookEntry;
 import org.mxchange.jusercore.model.user.User;
 
@@ -31,6 +32,19 @@ import org.mxchange.jusercore.model.user.User;
 @Remote
 public interface AddressbookSessionBeanRemote extends Serializable {
 
+       /**
+        * Some getter for an address book instance from given id number. If the
+        * address book is not found, an exception is thrown.
+        * <p>
+        * @param addressbookId Id number for address book instance
+        * @return Address book instance
+        * @throws org.mxchange.addressbook.exceptions.AddressbookNotFoundException
+        * If the address book cannot be found by given id number
+        * @throws NullPointerException If addressbookId is null
+        * @throws IllegalArgumentException If the id number is below 1
+        */
+       public Addressbook getAddressbookById (final Long addressbookId) throws AddressbookNotFoundException;
+
        /**
         * Returns a list of all entries of given address book, whether the assigned
         * user is the "owner" or "sharer" of the entry.