• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

hazendaz / sitemesh2 / 59

22 Mar 2026 02:30AM UTC coverage: 40.347%. Remained the same
59

push

github

hazendaz
[mvn] Update maven wrapper

698 of 1891 branches covered (36.91%)

Branch coverage included in aggregate %.

1555 of 3693 relevant lines covered (42.11%)

0.42 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/main/java/com/opensymphony/module/sitemesh/filter/PageRequestWrapper.java
1
/*
2
 * SPDX-License-Identifier: Apache-2.0
3
 * Copyright 2011-2026 Hazendaz
4
 */
5
/* This software is published under the terms of the OpenSymphony Software
6
 * License version 1.1, of which a copy has been included with this
7
 * distribution in the LICENSE.txt file. */
8
package com.opensymphony.module.sitemesh.filter;
9

10
import jakarta.servlet.RequestDispatcher;
11
import jakarta.servlet.http.HttpServletRequest;
12
import jakarta.servlet.http.HttpServletRequestWrapper;
13

14
/**
15
 * Will wrap a request for the {@link RequestDispatcherWrapper}.
16
 *
17
 * @author <a href="mailto:joeo@enigmastation.com">Joseph B. Ottinger</a>
18
 */
19
public class PageRequestWrapper extends HttpServletRequestWrapper {
20

21
    // TODO - pull this from a config file
22
    /** The Constant SUPPRESS_IF_MODIFIED_HEADER. */
23
    private static final boolean SUPPRESS_IF_MODIFIED_HEADER = true;
24

25
    /**
26
     * Instantiates a new page request wrapper.
27
     *
28
     * @param request
29
     *            the request
30
     */
31
    public PageRequestWrapper(HttpServletRequest request) {
32
        super(request);
×
33
    }
×
34

35
    @Override
36
    public RequestDispatcher getRequestDispatcher(String s) {
37
        return new RequestDispatcherWrapper(super.getRequestDispatcher(s));
×
38
    }
39

40
    @Override
41
    public String getHeader(String string) {
42
        // suppress 'if-modified-since' header, so that decorators can modify the response.
43
        if (SUPPRESS_IF_MODIFIED_HEADER && "IF-MODIFIED-SINCE".equalsIgnoreCase(string)) {
×
44
            return "";
×
45
        }
46
        return super.getHeader(string);
×
47
    }
48
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc