@Controller
public class GenerateQRCodeController
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected static java.util.logging.Logger |
log |
static java.lang.String |
PARAMETER_DATA |
static java.lang.String |
PARAMETER_HEIGHT |
static java.lang.String |
PARAMETER_WIDTH |
static java.lang.String |
PNG_CONTENT_TYPE |
Constructor and Description |
---|
GenerateQRCodeController() |
Modifier and Type | Method and Description |
---|---|
void |
generateQRCode(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Main controller action generating a QR Code image for a given qr code
|
org.springframework.http.ResponseEntity<java.lang.Object> |
handleException(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
java.lang.Exception e)
Exception handler for this controller.
|
protected static java.util.logging.Logger log
public static final java.lang.String PARAMETER_DATA
public static final java.lang.String PARAMETER_WIDTH
public static final java.lang.String PARAMETER_HEIGHT
public static final java.lang.String PNG_CONTENT_TYPE
@GetMapping(value="${paywall.qrcode.url:/paywall/genqrcode}") public void generateQRCode(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws java.lang.Exception
request
- the related http request.response
- the related http response.java.lang.Exception
- if problems occurred, handled by handleException method.@ExceptionHandler(value=java.lang.Exception.class) public org.springframework.http.ResponseEntity<java.lang.Object> handleException(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, java.lang.Exception e)
request
- the related http request.response
- the related http response.e
- the related exception