jpaul.Misc
Class SetMembership<T>

java.lang.Object
  extended by jpaul.Misc.Predicate<T>
      extended by jpaul.Misc.SetMembership<T>

public class SetMembership<T>
extends Predicate<T>

SetMembership is a predicate that checks whether an element is member of a specific set.

Version:
$Id: SetMembership.java,v 1.5 2006/03/14 02:29:31 salcianu Exp $
Author:
Alexandru Salcianu - salcianu@alum.mit.edu

Constructor Summary
SetMembership(java.util.Collection<T> set)
          Creates a SetMembership that checks membership in the set set.
 
Method Summary
 boolean check(T t)
          The boolean predicate.
 
Methods inherited from class jpaul.Misc.Predicate
AND, FALSE, FULL_AND, FULL_OR, NOT, OR, TRUE
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SetMembership

public SetMembership(java.util.Collection<T> set)
Creates a SetMembership that checks membership in the set set.

Method Detail

check

public boolean check(T t)
Description copied from class: Predicate
The boolean predicate.

Specified by:
check in class Predicate<T>


Copyright 2005 Alexandru Salcianu - salcianu@alum.mit.edu