Package com.authlete.jaxrs
Class BaseDeviceVerificationEndpoint
- java.lang.Object
-
- com.authlete.jaxrs.BaseEndpoint
-
- com.authlete.jaxrs.BaseDeviceVerificationEndpoint
-
public class BaseDeviceVerificationEndpoint extends BaseEndpoint
A base class for device verification endpoints.- Since:
- 2.18
- Author:
- Hideki Ikeda
-
-
Constructor Summary
Constructors Constructor Description BaseDeviceVerificationEndpoint()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.Response
handle(com.authlete.common.api.AuthleteApi api, DeviceVerificationRequestHandlerSpi spi)
Handle a device verification request.-
Methods inherited from class com.authlete.jaxrs.BaseEndpoint
extractClientCertificate, extractClientCertificateChain, extractHeadersAsPairs, onError, takeAttribute
-
-
-
-
Method Detail
-
handle
public javax.ws.rs.core.Response handle(com.authlete.common.api.AuthleteApi api, DeviceVerificationRequestHandlerSpi spi)
Handle a device verification request.This method internally creates a
DeviceVerificationRequestHandler
instance and calls itsDeviceVerificationRequestHandler.handle()
method. Then, this method uses the value returned from thehandle()
method as a response from this method.When
DeviceVerificationRequestHandler.handle()
method raises aWebApplicationException
, this method callsonError()
method with the exception. The default implementation ofonError()
does nothing. You can override the method as necessary. After callingonError()
method, this method callsgetResponse()
method of the exception and uses the returned value as a response from this method.- Parameters:
api
- An implementation ofAuthleteApi
.spi
- An implementation ofDeviceVerificationRequestHandlerSpi
.- Returns:
- A response that should be returned to the end-user.
-
-