Class SimpleAspicOrder<T extends Invertable>
java.lang.Object
org.tweetyproject.commons.AbstractInterpretation<AspicArgumentationTheory<T>, AspicArgument<T>>
org.tweetyproject.comparator.GeneralComparator<AspicArgument<T>, AspicArgumentationTheory<T>>
org.tweetyproject.arg.aspic.order.SimpleAspicOrder<T>
- Type Parameters:
T- is the type of the language that the ASPIC theory's rules range over
- All Implemented Interfaces:
Comparator<AspicArgument<T>>,Interpretation<AspicArgumentationTheory<T>, AspicArgument<T>>
public class SimpleAspicOrder<T extends Invertable>
extends GeneralComparator<AspicArgument<T>, AspicArgumentationTheory<T>>
- Author:
- Nils Geilen A simple comparator for Aspic Arguments, that compares their top rules according to a given list of rules
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a comparator for AspicArguments, that always returns 0SimpleAspicOrder(List<String> rules) Creates a comparator for AspicArguments from a list of AspicInferneceRules This will return a value <0, ==0 or >0 if the first argument's top rule is <,=,> the second argument's top rule -
Method Summary
Modifier and TypeMethodDescriptionintcompare(AspicArgument<T> a, AspicArgument<T> b) booleanReturn true if this ranking contains incomparable arguments, false otherwisebooleanisIncomparable(AspicArgument<T> a, AspicArgument<T> b) Returns "true" iff a and b are incomparable (i.e.booleanReturns "true" iff a is strictly less acceptable than b or a is equally acceptable as b or a and b are not comparable, i.e.booleansatisfies(AspicArgument<T> formula) Checks whether this interpretation satisfies the given formula.booleansatisfies(AspicArgumentationTheory<T> beliefBase) Checks whether this interpretation satisfies the given knowledge base.toString()Methods inherited from class org.tweetyproject.comparator.GeneralComparator
getMaximallyAcceptedArguments, getMinimallyAcceptedArguments, isEquallyAcceptableThan, isEquivalent, isStrictlyLessAcceptableThan, isStrictlyMoreAcceptableThan, isStrictlyMoreOrEquallyAcceptableThanMethods inherited from class org.tweetyproject.commons.AbstractInterpretation
satisfiesMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
SimpleAspicOrder
public SimpleAspicOrder()Creates a comparator for AspicArguments, that always returns 0 -
SimpleAspicOrder
-
-
Method Details
-
compare
- Specified by:
comparein interfaceComparator<T extends Invertable>- Overrides:
comparein classGeneralComparator<AspicArgument<T extends Invertable>, AspicArgumentationTheory<T extends Invertable>>
-
toString
-
satisfies
Description copied from interface:InterpretationChecks whether this interpretation satisfies the given formula.- Parameters:
formula- a formula .- Returns:
- "true" if this interpretation satisfies the given formula.
- Throws:
IllegalArgumentException- if the formula does not correspond to the expected language.
-
satisfies
Description copied from interface:InterpretationChecks whether this interpretation satisfies the given knowledge base.- Parameters:
beliefBase- a knowledge base.- Returns:
- "true" if this interpretation satisfies the given knowledge base.
- Throws:
IllegalArgumentException- IllegalArgumentException if the knowledgebase does not correspond to the expected language.
-
isStrictlyLessOrEquallyAcceptableThan
Description copied from class:GeneralComparatorReturns "true" iff a is strictly less acceptable than b or a is equally acceptable as b or a and b are not comparable, i.e. a >= b (or a ~ b)- Specified by:
isStrictlyLessOrEquallyAcceptableThanin classGeneralComparator<AspicArgument<T extends Invertable>, AspicArgumentationTheory<T extends Invertable>>- Parameters:
a- some comparable elementb- some comparable element- Returns:
- "true" iff a is strictly less acceptable than b or a is equally acceptable as b
-
isIncomparable
Description copied from class:GeneralComparatorReturns "true" iff a and b are incomparable (i.e. this ranking is a partial ranking).- Specified by:
isIncomparablein classGeneralComparator<AspicArgument<T extends Invertable>, AspicArgumentationTheory<T extends Invertable>>- Parameters:
a- comparable elementb- comparable element- Returns:
- "true" iff a and b are incomparable
-
containsIncomparableArguments
public boolean containsIncomparableArguments()Description copied from class:GeneralComparatorReturn true if this ranking contains incomparable arguments, false otherwise- Specified by:
containsIncomparableArgumentsin classGeneralComparator<AspicArgument<T extends Invertable>, AspicArgumentationTheory<T extends Invertable>>- Returns:
- true if this ranking contains incomparable arguments, false otherwise
-