summaryrefslogtreecommitdiff
path: root/eaaf_core_api/src
diff options
context:
space:
mode:
authorThomas <>2021-04-21 07:42:50 +0200
committerThomas <>2021-04-21 07:42:50 +0200
commit3cbba3fcda614fa37357822d0eeb543c3e19276e (patch)
tree1941c8a1e78eaa4f9e93d247c9ec26657dd2da22 /eaaf_core_api/src
parent2f5425491ac88ec4b65157ac85bde58fb7dce34c (diff)
downloadEAAF-Components-3cbba3fcda614fa37357822d0eeb543c3e19276e.tar.gz
EAAF-Components-3cbba3fcda614fa37357822d0eeb543c3e19276e.tar.bz2
EAAF-Components-3cbba3fcda614fa37357822d0eeb543c3e19276e.zip
some small updates in central error-handling
Diffstat (limited to 'eaaf_core_api/src')
-rw-r--r--eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/idp/auth/services/IProtocolAuthenticationService.java30
1 files changed, 16 insertions, 14 deletions
diff --git a/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/idp/auth/services/IProtocolAuthenticationService.java b/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/idp/auth/services/IProtocolAuthenticationService.java
index f110d50e..8def4e32 100644
--- a/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/idp/auth/services/IProtocolAuthenticationService.java
+++ b/eaaf_core_api/src/main/java/at/gv/egiz/eaaf/core/api/idp/auth/services/IProtocolAuthenticationService.java
@@ -19,16 +19,18 @@
package at.gv.egiz.eaaf.core.api.idp.auth.services;
+import java.io.IOException;
+
+import javax.annotation.Nonnull;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
import at.gv.egiz.eaaf.core.api.IRequest;
import at.gv.egiz.eaaf.core.api.logging.IStatisticLogger;
import at.gv.egiz.eaaf.core.exceptions.EaafException;
import at.gv.egiz.eaaf.core.exceptions.GuiBuildException;
import at.gv.egiz.eaaf.core.impl.data.Pair;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-import java.io.IOException;
-
public interface IProtocolAuthenticationService {
String PARAM_GUI_ERROMSG = "errorMsg";
@@ -49,8 +51,8 @@ public interface IProtocolAuthenticationService {
* @throws IOException In case of a communication error
* @throws EaafException In case of an application error
*/
- void performAuthentication(HttpServletRequest httpReq, HttpServletResponse httpResp, IRequest pendingReq)
- throws IOException, EaafException;
+ void performAuthentication(@Nonnull HttpServletRequest httpReq, @Nonnull HttpServletResponse httpResp,
+ @Nonnull IRequest pendingReq) throws IOException, EaafException;
/**
* Finalize the requested protocol operation.
@@ -62,8 +64,8 @@ public interface IProtocolAuthenticationService {
* {@link HttpServletResponse}
* @throws EaafException If an internal error occur
*/
- void finalizeAuthentication(HttpServletRequest httpReq, HttpServletResponse httpResp, IRequest pendingReq)
- throws EaafException, IOException;
+ void finalizeAuthentication(@Nonnull HttpServletRequest httpReq, @Nonnull HttpServletResponse httpResp,
+ @Nonnull IRequest pendingReq) throws EaafException, IOException;
/**
* Build protocol-specific error message.
@@ -76,8 +78,8 @@ public interface IProtocolAuthenticationService {
* {@link HttpServletResponse}
* @throws EaafException If an internal error occur
*/
- void buildProtocolSpecificErrorResponse(Throwable throwable, HttpServletRequest req, HttpServletResponse resp,
- IRequest pendingReq) throws IOException, EaafException;
+ void buildProtocolSpecificErrorResponse(@Nonnull Throwable throwable, @Nonnull HttpServletRequest req,
+ @Nonnull HttpServletResponse resp, @Nonnull IRequest pendingReq) throws IOException, EaafException;
/**
* Handles all exceptions with no pending request. Therefore, the error is
@@ -94,8 +96,8 @@ public interface IProtocolAuthenticationService {
* {@link HttpServletResponse}
* @throws EaafException If an internal error occure
*/
- void handleErrorNoRedirect(Throwable throwable, HttpServletRequest req, HttpServletResponse resp,
- boolean writeExceptionToStatisticLog) throws IOException, EaafException;
+ void handleErrorNoRedirect(@Nonnull Throwable throwable, @Nonnull HttpServletRequest req,
+ @Nonnull HttpServletResponse resp, boolean writeExceptionToStatisticLog) throws IOException, EaafException;
/**
* Forward the process to error-handler in case of an error.
@@ -106,8 +108,8 @@ public interface IProtocolAuthenticationService {
* @param resp HTTP response
* @throws GuiBuildException In case of an GUI generation error
*/
- void forwardToErrorHandler(Pair<IRequest, Throwable> errorToHandle, String errorKey,
- HttpServletRequest req, HttpServletResponse resp) throws GuiBuildException;
+ void forwardToErrorHandler(@Nonnull Pair<IRequest, Throwable> errorToHandle, @Nonnull String errorKey,
+ @Nonnull HttpServletRequest req, @Nonnull HttpServletResponse resp) throws GuiBuildException;