net.shibboleth.utilities.java.support.logic
Class CaseInsensitiveStringMatchPredicate

java.lang.Object
  extended by net.shibboleth.utilities.java.support.logic.CaseInsensitiveStringMatchPredicate
All Implemented Interfaces:
com.google.common.base.Predicate<CharSequence>

public class CaseInsensitiveStringMatchPredicate
extends Object
implements com.google.common.base.Predicate<CharSequence>

A Predicate that checks that a given input string matches a target string while ignoring case. If a given input is null this predicate returns false.


Field Summary
private  String target
          The target string.
 
Constructor Summary
CaseInsensitiveStringMatchPredicate(String matchString)
          Constructor.
 
Method Summary
 boolean apply(CharSequence input)
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.google.common.base.Predicate
equals
 

Field Detail

target

private final String target
The target string.

Constructor Detail

CaseInsensitiveStringMatchPredicate

public CaseInsensitiveStringMatchPredicate(@Nonnull
                                           String matchString)
Constructor.

Parameters:
matchString - that string against which predicate inputs will be checked
Method Detail

apply

public boolean apply(CharSequence input)

Specified by:
apply in interface com.google.common.base.Predicate<CharSequence>


Copyright © 1999-2012. All Rights Reserved.