Example usage for org.springframework.web.context.request RequestAttributes REFERENCE_REQUEST

List of usage examples for org.springframework.web.context.request RequestAttributes REFERENCE_REQUEST

Introduction

In this page you can find the example usage for org.springframework.web.context.request RequestAttributes REFERENCE_REQUEST.

Prototype

String REFERENCE_REQUEST

To view the source code for org.springframework.web.context.request RequestAttributes REFERENCE_REQUEST.

Click Source Link

Document

Name of the standard reference to the request object: "request".

Usage

From source file:org.jdal.vaadin.VaadinUtils.java

public static HttpServletRequest getRequest() {
    return (HttpServletRequest) RequestContextHolder.getRequestAttributes()
            .resolveReference(RequestAttributes.REFERENCE_REQUEST);
}

From source file:com.sibvisions.rad.server.security.spring.authentication.SecurityManagerPreparerApplicationListener.java

/**
 * {@inheritDoc}//from  w  ww .  jav a 2s.  c  o m
 */
public void onApplicationEvent(InteractiveAuthenticationSuccessEvent pEvent) {
    RequestAttributes requestAttributes = RequestContextHolder.getRequestAttributes();

    if (requestAttributes != null) {
        Object request = requestAttributes.resolveReference(RequestAttributes.REFERENCE_REQUEST);

        if (request != null && request instanceof HttpServletRequest) {
            doPrepareParameters((HttpServletRequest) request);
        }
    }
}