ter.API.EngineSearch
Class GroupCriterion

java.lang.Object
  |
  +--ter.API.EngineSearch.GroupCriterion
Direct Known Subclasses:
MembersGroupCriterion, NameGroupCriterion, ProtectionGroupCriterion, RangeGroupCriterion

public abstract class GroupCriterion
extends java.lang.Object

Title: GroupCriterion

Description:

Copyright: Copyright (c) 2003

Company: UNICE

Version:
1.0
Author:
Zerbib Gabriel, Charbit Lucas, Galbois Xavier Gahide Jérôme

Constructor Summary
GroupCriterion()
           
 
Method Summary
 void addCriterion(Criterion c)
          Add a criterion to the group
 boolean evaluateCriterion(java.lang.reflect.Member m)
          Evaluate if a member is a result for the search in this group of criterion.
 java.util.ArrayList getCriterion()
           
 java.lang.String getName()
           
abstract  void selectLogicalLinkCriterion(Criterion c, int ll)
          Deprecated. the mediator has not been implemented.
abstract  void selectStatesCriterion(Criterion c, int state)
          Deprecated. the mediator has not been implemented.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroupCriterion

public GroupCriterion()
Method Detail

getName

public java.lang.String getName()
Returns:
the name of the group of criterion

addCriterion

public void addCriterion(Criterion c)
Add a criterion to the group

Parameters:
c - the Criterion to add.

selectStatesCriterion

public abstract void selectStatesCriterion(Criterion c,
                                           int state)
Deprecated. the mediator has not been implemented.

This the mediator for selecting a criterion. Thank to this method, we are able to apply simple rukes like : "only one criterion can be selected at once at the state YES"

Parameters:
c - the criterion to set.
state - the state to set c
See Also:
EngineSearchConst

selectLogicalLinkCriterion

public abstract void selectLogicalLinkCriterion(Criterion c,
                                                int ll)
Deprecated. the mediator has not been implemented.

Parameters:
c - the criterion to set
ll - the logical Value ( AND ORN NOT )
See Also:
EngineSearchConst

getCriterion

public java.util.ArrayList getCriterion()
Returns:
all the criterion of the group

evaluateCriterion

public boolean evaluateCriterion(java.lang.reflect.Member m)
                          throws SearchEngineException
Evaluate if a member is a result for the search in this group of criterion.

Parameters:
m - the member to evaluate
Returns:
true if the evaluation of all the criterion beetween them are true.
Throws:
SearchEngineException
See Also:
Criterion.isCriterionValid(Member m)