Top Description Fields Constructors Methods
org.codehaus.janino

public Class FilterWarningHandler

extends Object
implements WarningHandler
Class Inheritance
All Implemented Interfaces
org.codehaus.commons.compiler.WarningHandler
Imports
org.codehaus.commons.compiler.CompileException, .Location, .WarningHandler, org.codehaus.commons.compiler.util.StringPattern, org.codehaus.commons.nullanalysis.Nullable

Invokes a delegate iff the handle of the warning matches one or more of a set of StringPatterns.

Field Summary

Modifier and TypeField and Description
private final WarningHandler
private final StringPattern[]

Constructor Summary

AccessConstructor and Description
public
FilterWarningHandler(StringPattern[] handlePatterns, WarningHandler delegate)

Popular values for the handlePatterns parameter are StringPattern#PATTERNS_ALL and StringPattern#PATTERNS_NONE.

Method Summary

Modifier and TypeMethod and Description
public void
handleWarning(String
A string describing the category of the warning; used for filtering iff non-null
handle
,
String message, Location location)

Implements org.codehaus.commons.compiler.WarningHandler.handleWarning.

May or may not choose to throw a CompileException.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

delegateback to summary
private final WarningHandler delegate
handlePatternsback to summary
private final StringPattern[] handlePatterns

Constructor Detail

FilterWarningHandlerback to summary
public FilterWarningHandler(StringPattern[] handlePatterns, WarningHandler delegate)

Popular values for the handlePatterns parameter are StringPattern#PATTERNS_ALL and StringPattern#PATTERNS_NONE.

Method Detail

handleWarningback to summary
public void handleWarning(String handle, String message, Location location) throws CompileException

Implements org.codehaus.commons.compiler.WarningHandler.handleWarning.

Doc from org.codehaus.commons.compiler.WarningHandler.handleWarning.

May or may not choose to throw a CompileException.

Parameters
handle:String

A string describing the category of the warning; used for filtering iff non-null

Annotations
@Override
Exceptions
CompileException:
This WarningHandler wishes to terminate compilation, e.g. because "too many" warnings have been reported