Class CustomResourceFilter

java.lang.Object
net.bull.javamelody.CustomResourceFilter
All Implemented Interfaces:
Filter

public class CustomResourceFilter extends Object implements Filter
Servlet filter to customize resources in html reports, such as css file.
For example, add the following, before the monitoring filter, in the web.xml file of your webapp, in order to use your own css or icons:
 <filter>
        <filter-name>customResourceFilter</filter-name>
        <filter-class>net.bull.javamelody.CustomResourceFilter</filter-class>
        <init-param>
                <param-name>monitoring.css</param-name>
                <param-value>/customMonitoring.css</param-value>
        </init-param>
        <init-param>
                <param-name>bullets/green.png</param-name>
                <param-value>/static/bullets/red.png</param-value>
        </init-param>
 </filter>
 <filter-mapping>
        <filter-name>customResourceFilter</filter-name>
        <url-pattern>/monitoring</url-pattern>
 </filter-mapping>
 
Then add files "customMonitoring.css" and "static/bullets/red.png" at the root of the web content in your webapp.
You can replace every web resource in this directory and sub-directories
Author:
Emeric Vernat