From: Roland Häder Date: Fri, 3 Nov 2017 21:40:38 +0000 (+0100) Subject: Continued: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=bc32a6b51431bfe39894522f3a5aabf5da4bd5f9;p=jcontacts-business-lib.git Continued: - add first business method addEmployee() Signed-off-by: Roland Häder --- diff --git a/src/org/mxchange/jcontactsbusiness/model/employee/AdminEmployeeSessionBeanRemote.java b/src/org/mxchange/jcontactsbusiness/model/employee/AdminEmployeeSessionBeanRemote.java index 5b7c896..a09a6d5 100644 --- a/src/org/mxchange/jcontactsbusiness/model/employee/AdminEmployeeSessionBeanRemote.java +++ b/src/org/mxchange/jcontactsbusiness/model/employee/AdminEmployeeSessionBeanRemote.java @@ -18,6 +18,7 @@ package org.mxchange.jcontactsbusiness.model.employee; import java.io.Serializable; import javax.ejb.Remote; +import org.mxchange.jcontactsbusiness.exceptions.employee.EmployeeAlreadyAddedException; /** * An interface for administrative purposes on handling company employee data @@ -27,4 +28,16 @@ import javax.ejb.Remote; @Remote public interface AdminEmployeeSessionBeanRemote extends Serializable { + /** + * Adds given employee instance to database. If already found, a proper + * exception is thrown. + *

+ * @param employee Employee instance to be added + *

+ * @return Updated employee instance + *

+ * @throws EmployeeAlreadyAddedException + */ + Employable addEmployee (final Employable employee) throws EmployeeAlreadyAddedException; + }