br.com.arsmachina.accesslogger.services.impl
Class URLEndingAccessFilterRule

java.lang.Object
  extended by br.com.arsmachina.accesslogger.services.impl.URLEndingAccessFilterRule
All Implemented Interfaces:
AccessFilterRule

public class URLEndingAccessFilterRule
extends Object
implements AccessFilterRule

AccessFilterRule that accepts requests which ends with a given string and ignores the others.

Author:
Thiago H. de Paula Figueiredo

Constructor Summary
URLEndingAccessFilterRule(String ending)
          Single constructor of this class.
 
Method Summary
 Boolean accept(String path)
          Tells if a request to a given path must be logged or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

URLEndingAccessFilterRule

public URLEndingAccessFilterRule(String ending)
Single constructor of this class.

Parameters:
ending - a String containing the request ending. It cannot be null nor the empty string.
Method Detail

accept

public Boolean accept(String path)
Description copied from interface: AccessFilterRule
Tells if a request to a given path must be logged or not. This method can return null to say it cannot decide to log to request or not, leaving the decision for other AccessFilterRules.

Specified by:
accept in interface AccessFilterRule
Parameters:
path - a String. It cannot be null.
Returns:
true, false or null.
See Also:
AccessFilterRule.accept(java.lang.String)


Copyright © 2008-2009 Thiago H. de Paula Figueiredo. All Rights Reserved.