KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > mmbase > storage > search > implementation > TestConstraint


1 package org.mmbase.storage.search.implementation;
2
3 import org.mmbase.storage.search.*;
4
5 /**
6  * Test implementation of the <@link Constraint Constraint> interface,
7  * with fixed support level that is specified when creating an instance.
8  *
9  * @author Rob van Maris
10  * @version $Revision: 1.1 $
11  */

12 public class TestConstraint implements Constraint {
13     
14     /** The support level. */
15     private int support;
16     
17     /** Creates a new instance of TestConstraint, with the specified support. */
18     public TestConstraint(int support) {
19         this.support = support;
20     }
21     
22     // javadoc is inherited
23
public int getBasicSupportLevel() {
24         return support;
25     }
26     
27     // javadoc is inherited
28
public boolean isInverse() {
29         return false;
30     }
31     
32 }
33
Popular Tags