de.lmu.ifi.dbs.elki.utilities.optionhandling.constraints
Class ListGreaterEqualConstraint<N extends Number>

java.lang.Object
  extended by de.lmu.ifi.dbs.elki.utilities.optionhandling.constraints.AbstractNumberConstraint<List<N>>
      extended by de.lmu.ifi.dbs.elki.utilities.optionhandling.constraints.ListGreaterEqualConstraint<N>
Type Parameters:
N - Number type
All Implemented Interfaces:
ParameterConstraint<List<N>>

public class ListGreaterEqualConstraint<N extends Number>
extends AbstractNumberConstraint<List<N>>

Represents a Greater-Equal-Than-Number parameter constraint for a list of number values. All values of the list parameter (ListParameter) tested have to be greater than or equal to the specified constraint value.


Field Summary
 
Fields inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.constraints.AbstractNumberConstraint
constraintValue
 
Constructor Summary
ListGreaterEqualConstraint(N constraintValue)
          Creates a Greater-Equal-Than-Number parameter constraint.
 
Method Summary
 String getDescription(String parameterName)
          Returns a description of this constraint.
 void test(List<N> t)
          Checks if all number values of the specified list parameter are greater than or equal to the constraint value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ListGreaterEqualConstraint

public ListGreaterEqualConstraint(N constraintValue)
Creates a Greater-Equal-Than-Number parameter constraint.

That is, all values of the list parameter tested have to be greater than or equal to the specified constraint value.

Parameters:
constraintValue - parameter constraint value
Method Detail

test

public void test(List<N> t)
          throws ParameterException
Checks if all number values of the specified list parameter are greater than or equal to the constraint value. If not, a parameter exception is thrown.

Parameters:
t - Value to be checked whether or not it fulfills the underlying parameter constraint.
Throws:
ParameterException - if the parameter to be tested does not fulfill the parameter constraint

getDescription

public String getDescription(String parameterName)
Description copied from interface: ParameterConstraint
Returns a description of this constraint.

Parameters:
parameterName - the name of the parameter this constraint is used for
Returns:
a description of this constraint

Release 0.4.0 (2011-09-20_1324)