Faceted Project Framework
Version 1.3

org.eclipse.wst.common.project.facet.core
Interface IConstraint


public interface IConstraint

Models a single constraint in the constraint expression.

Author:
Konstantin Komissarchik

Nested Class Summary
static class IConstraint.Type
          The enumeration of operator types.
 
Method Summary
 IStatus check(Collection<IProjectFacetVersion> facets)
          Checks this constraint against the given set of project facets.
 IStatus check(Collection<IProjectFacetVersion> facets, boolean validateSoftDependencies)
          Checks this constraint against the given set of project facets.
 Object getOperand(int index)
          Returns the operand at the specified position.
 List<Object> getOperands()
          Returns the list operands.
 IConstraint.Type getType()
          Returns the operator type
 

Method Detail

getType

IConstraint.Type getType()
Returns the operator type

Returns:
the operator type

getOperands

List<Object> getOperands()
Returns the list operands.

Returns:
the list of operands

getOperand

Object getOperand(int index)
Returns the operand at the specified position.

Parameters:
index - the position of the operand in the list of operands
Returns:
the operand

check

IStatus check(Collection<IProjectFacetVersion> facets)
Checks this constraint against the given set of project facets.

Parameters:
facets - a set of project facets
Returns:
a status object with severity of IStatus.OK if the constraint was satisfied or otherwise a MultiStatus composed of individual status objects for each of the problems

check

IStatus check(Collection<IProjectFacetVersion> facets,
              boolean validateSoftDependencies)
Checks this constraint against the given set of project facets.

Parameters:
facets - a set of project facets
validateSoftDependencies - if true soft dependencies will be treated as required
Returns:
a status object with severity of IStatus.OK if the constraint was satisfied or otherwise a MultiStatus composed of individual status objects for each of the problems

Faceted Project Framework
Version 1.3

Copyright (c) 2008 BEA Systems, Inc. and others. All rights reserved.