From bc32a6b51431bfe39894522f3a5aabf5da4bd5f9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Fri, 3 Nov 2017 22:40:38 +0100 Subject: [PATCH] Continued: - add first business method addEmployee() MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../employee/AdminEmployeeSessionBeanRemote.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) 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; + } -- 2.39.5