Package com.saperion.rs
Class RestService
java.lang.Object
com.saperion.rs.RestService
- Direct Known Subclasses:
AbstractFreemarkerResource
,AbstractWeblinkService
,ContentService
,FederatedSearch
,HTMLGateway
,InfoResource
This class represents the base class for all REST service classes.
- Author:
- sts
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.saperion.common.logging.Logger
This class's logger. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
checkConnection
(jakarta.servlet.http.HttpServletRequest request) Checks the existence of the SaClassicConnector in the given request.com.saperion.connector.SaClassicConnector
getConnection
(jakarta.servlet.http.HttpServletRequest request) Returns the SaClassicConnector instance from the given request if existing.
-
Field Details
-
LOGGER
public static final com.saperion.common.logging.Logger LOGGERThis class's logger.
-
-
Constructor Details
-
RestService
public RestService()
-
-
Method Details
-
checkConnection
public void checkConnection(jakarta.servlet.http.HttpServletRequest request) Checks the existence of the SaClassicConnector in the given request. Throws WebApplicationException if no SaClassicConnector is existing in the given request.- Parameters:
request
- The request to inspect.
-
getConnection
public com.saperion.connector.SaClassicConnector getConnection(jakarta.servlet.http.HttpServletRequest request) Returns the SaClassicConnector instance from the given request if existing. Calls checkConnection to determine the existence of the SaClassicConnector.- Parameters:
request
- The request to get the SaClassicConnector from.- Returns:
- the SaClassicConnector if existing
-