partage
Class ComplexInstance.ObjectDNF

java.lang.Object
  extended by partage.ComplexInstance.ObjectDNF
All Implemented Interfaces:
ComplexInstance.LogicalObjectFormula
Enclosing class:
ComplexInstance

public static class ComplexInstance.ObjectDNF
extends java.lang.Object
implements ComplexInstance.LogicalObjectFormula

A static class representing a propositional logical formula of objects in disjunctive normal form (allows for a more efficient processing of this kind of preferences).

Version:
july 2007
Author:
Sylvain Bouveret

Constructor Summary
ComplexInstance.ObjectDNF()
           
ComplexInstance.ObjectDNF(int[][] _conjunctiveTerms)
           
 
Method Summary
 void addConjunctiveTerm(int[] _conjunctiveTerm)
          Adds a conjunctive term to the Disjunctive Normal Form.
 int[][] getConjunctiveTerms()
          Returns the array representation of the Disjunctive Normal Form.
 int[] getObjects()
          This methods returns the set of objects concerned by the formula.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ComplexInstance.ObjectDNF

public ComplexInstance.ObjectDNF()

ComplexInstance.ObjectDNF

public ComplexInstance.ObjectDNF(int[][] _conjunctiveTerms)
Method Detail

getConjunctiveTerms

public int[][] getConjunctiveTerms()
Returns the array representation of the Disjunctive Normal Form.

Returns:
an array representing the DNF

addConjunctiveTerm

public void addConjunctiveTerm(int[] _conjunctiveTerm)
Adds a conjunctive term to the Disjunctive Normal Form. A clause is an array of objects (with by convention a minus sign if a specific litteral should be interpreted as negative (the negation of an object).

Parameters:
_conjunctiveTerm - the array representing the conjunctive term to add.

getObjects

public int[] getObjects()
Description copied from interface: ComplexInstance.LogicalObjectFormula
This methods returns the set of objects concerned by the formula.

Specified by:
getObjects in interface ComplexInstance.LogicalObjectFormula
Returns:
the set of objects.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object