Class LdoNegation
- java.lang.Object
-
- net.sf.tweety.arg.dung.ldo.syntax.LdoFormula
-
- net.sf.tweety.arg.dung.ldo.syntax.LdoNegation
-
- All Implemented Interfaces:
Formula
,ClassicalFormula
,Conjunctable
,Disjunctable
,Invertable
,ProbabilityAware
,SimpleLogicalFormula
public class LdoNegation extends LdoFormula
This class models classical negation of ldo logic.- Author:
- Matthias Thimm, Tim Janus
-
-
Constructor Summary
Constructors Constructor Description LdoNegation(LdoFormula formula)
Creates a new negation with the given formula.
-
Method Summary
Modifier and Type Method Description LdoFormula
clone()
Creates a deep copy of this formulaboolean
equals(java.lang.Object obj)
java.util.Set<LdoArgument>
getAtoms()
Processes the set of all atoms which appear in this formulaLdoFormula
getFormula()
Returns the formula within this negation.java.util.Set<LdoFormula>
getLiterals()
Returns all literals, i.e.java.util.Set<PlPredicate>
getPredicates()
Processes the set of all predicates which appear in this formulaDungSignature
getSignature()
Returns the signature of the language of this formula.int
hashCode()
boolean
isLiteral()
java.lang.String
toString()
-
Methods inherited from class net.sf.tweety.arg.dung.ldo.syntax.LdoFormula
combineWithAnd, combineWithOr, complement, getDividers, getPredicateCls, getUniformProbability
-
-
-
-
Constructor Detail
-
LdoNegation
public LdoNegation(LdoFormula formula)
Creates a new negation with the given formula.- Parameters:
formula
- the formula within the negation.
-
-
Method Detail
-
getFormula
public LdoFormula getFormula()
Returns the formula within this negation.- Returns:
- the formula within this negation.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfaceSimpleLogicalFormula
- Specified by:
hashCode
in classLdoFormula
-
equals
public boolean equals(java.lang.Object obj)
- Specified by:
equals
in interfaceSimpleLogicalFormula
- Specified by:
equals
in classLdoFormula
-
getPredicates
public java.util.Set<PlPredicate> getPredicates()
Description copied from interface:SimpleLogicalFormula
Processes the set of all predicates which appear in this formula- Specified by:
getPredicates
in interfaceSimpleLogicalFormula
- Specified by:
getPredicates
in classLdoFormula
- Returns:
- all predicates that appear in this formula
-
clone
public LdoFormula clone()
Description copied from interface:SimpleLogicalFormula
Creates a deep copy of this formula- Specified by:
clone
in interfaceSimpleLogicalFormula
- Specified by:
clone
in classLdoFormula
- Returns:
- the cloned formula
-
getAtoms
public java.util.Set<LdoArgument> getAtoms()
Description copied from interface:SimpleLogicalFormula
Processes the set of all atoms which appear in this formula- Specified by:
getAtoms
in interfaceSimpleLogicalFormula
- Specified by:
getAtoms
in classLdoFormula
- Returns:
- The set of all atoms
-
isLiteral
public boolean isLiteral()
- Specified by:
isLiteral
in interfaceSimpleLogicalFormula
- Overrides:
isLiteral
in classLdoFormula
- Returns:
- true if the formula represents a literal in the language or false otherwise
-
getLiterals
public java.util.Set<LdoFormula> getLiterals()
Description copied from class:LdoFormula
Returns all literals, i.e. all formulas of the form "a" or "!a" where "a" is a proposition, that appear in this formula.- Specified by:
getLiterals
in classLdoFormula
- Returns:
- all literals appearing in this formula.
-
getSignature
public DungSignature getSignature()
Description copied from interface:Formula
Returns the signature of the language of this formula.- Specified by:
getSignature
in interfaceFormula
- Overrides:
getSignature
in classLdoFormula
- Returns:
- the signature of the language of this formula.
-
-