Package net.sf.tweety.logics.dl.syntax
Class Complement
- java.lang.Object
 - 
- net.sf.tweety.logics.dl.syntax.ComplexConcept
 - 
- net.sf.tweety.logics.dl.syntax.Complement
 
 
 
- 
- All Implemented Interfaces:
 Formula,ClassicalFormula,Conjunctable,Disjunctable,Invertable,ProbabilityAware,SimpleLogicalFormula
public class Complement extends ComplexConcept
This class models the complement (negation) in description logics.- Author:
 - Anna Gessler
 
 
- 
- 
Field Summary
Fields Modifier and Type Field Description private ComplexConceptformulaThe negated formula. 
- 
Constructor Summary
Constructors Constructor Description Complement(ComplexConcept formula)Create a new complement with the given DLFormula. 
- 
Method Summary
Modifier and Type Method Description ComplexConceptclone()Creates a deep copy of this formulaComplexConceptcollapseAssociativeFormulas()This method collapses all associative operations appearing in this term, e.g.booleanequals(java.lang.Object obj)ComplexConceptgetFormula()java.util.Set<Predicate>getPredicates()Processes the set of all predicates which appear in this formulaDlSignaturegetSignature()Returns the signature of the language of this formula.inthashCode()booleanisLiteral()java.lang.StringtoString()- 
Methods inherited from class net.sf.tweety.logics.dl.syntax.ComplexConcept
combineWithAnd, combineWithOr, complement, getAtoms, getPredicateCls, getUniformProbability 
 - 
 
 - 
 
- 
- 
Field Detail
- 
formula
private ComplexConcept formula
The negated formula. 
 - 
 
- 
Constructor Detail
- 
Complement
public Complement(ComplexConcept formula)
Create a new complement with the given DLFormula.- Parameters:
 formula- some concept
 
 - 
 
- 
Method Detail
- 
getPredicates
public java.util.Set<Predicate> getPredicates()
Description copied from interface:SimpleLogicalFormulaProcesses the set of all predicates which appear in this formula- Specified by:
 getPredicatesin interfaceSimpleLogicalFormula- Specified by:
 getPredicatesin classComplexConcept- Returns:
 - all predicates that appear in this formula
 
 
- 
clone
public ComplexConcept clone()
Description copied from class:ComplexConceptCreates a deep copy of this formula- Specified by:
 clonein interfaceSimpleLogicalFormula- Specified by:
 clonein classComplexConcept- Returns:
 - the cloned formula
 
 
- 
collapseAssociativeFormulas
public ComplexConcept collapseAssociativeFormulas()
Description copied from class:ComplexConceptThis method collapses all associative operations appearing in this term, e.g. every a||(b||c) becomes a||b||c.- Specified by:
 collapseAssociativeFormulasin classComplexConcept- Returns:
 - the collapsed formula.
 
 
- 
toString
public java.lang.String toString()
- Overrides:
 toStringin classjava.lang.Object
 
- 
hashCode
public int hashCode()
- Specified by:
 hashCodein interfaceSimpleLogicalFormula- Specified by:
 hashCodein classComplexConcept
 
- 
isLiteral
public boolean isLiteral()
- Returns:
 - true if the formula represents a literal in the language or false otherwise
 
 
- 
getFormula
public ComplexConcept getFormula()
 
- 
getSignature
public DlSignature getSignature()
Description copied from interface:FormulaReturns the signature of the language of this formula.- Specified by:
 getSignaturein interfaceFormula- Specified by:
 getSignaturein classComplexConcept- Returns:
 - the signature of the language of this formula.
 
 
- 
equals
public boolean equals(java.lang.Object obj)
- Specified by:
 equalsin interfaceSimpleLogicalFormula- Specified by:
 equalsin classComplexConcept
 
 - 
 
 -