All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.sap.cloud.sdk.cloudplatform.servlet.AbstractRequestContextFacade Maven / Gradle / Ivy

There is a newer version: 2.28.0
Show newest version
/*
 * Copyright (c) 2019 SAP SE or an SAP affiliate company. All rights reserved.
 */

package com.sap.cloud.sdk.cloudplatform.servlet;

import java.util.Optional;

import javax.annotation.Nonnull;
import javax.servlet.http.HttpServletRequest;

public abstract class AbstractRequestContextFacade implements RequestContextFacade
{
    /**
     * {@inheritDoc}
     */
    @Nonnull
    @Override
    public Optional getCurrentRequest()
    {
        final Optional requestContext = getCurrentRequestContext();

        if( !requestContext.isPresent() ) {
            return Optional.empty();
        }

        return requestContext.get().getRequest();
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy