private boolean isPayloadIndirectOrDirect(final HttpServletRequest request) {
        return Collections.list(request.getHeaders("Link")).stream().map(Link::valueOf).map(Link::getUri)
                .anyMatch(l -> directOrIndirect.contains(l));
    }
private boolean isPayloadIndirectOrDirect ( final HttpServletRequest request ) { return Collections . list ( request . getHeaders ( "Link" ) ) . stream ( ) . map ( Link :: valueOf ) . map ( Link :: getUri ) . anyMatch ( l -> directOrIndirect . contains ( l ) ) ; }
Is the request to create an indirect or direct container.

@param request The current request
@return whether we are acting on/creating an indirect/direct container.