Class ExtensionRankingReasoner
java.lang.Object
org.tweetyproject.arg.dung.reasoner.ExtensionRankingReasoner
Reasoner using ranking semantics.
- Author:
- Lars Bengel, Daniel Letkemann
-
Constructor Summary
ConstructorDescriptioncreate a reasoner for the given ordering semantics -
Method Summary
Modifier and TypeMethodDescriptiongetConflicts
(Extension<DungTheory> ext, DungTheory theory) computes the set of conflicts occurring inside extgetDefendedNotIn
(Extension<DungTheory> ext, DungTheory theory) computes the set of arguments outside of ext, which are defended by extgetModel
(DungTheory theory) returns the lowest rank of the "getModels" methodgetModels
(DungTheory theory) compute the ordering over all subsets of theory wrt.get the semantic of OrderingSemanticsReasoner instancegetUnattacked
(Extension<DungTheory> ext, DungTheory theory) computes the set of arguments outside of ext, which are not attacked by extgetUndefended
(Extension<DungTheory> ext, DungTheory theory) computes the set of arguments in ext, which are not defended by ext against outside attackersboolean
-
Constructor Details
-
ExtensionRankingReasoner
create a reasoner for the given ordering semantics- Parameters:
semantics
- an ordering semantics- Throws:
NoSuchMethodException
- if an error occurs
-
-
Method Details
-
getSemantics
get the semantic of OrderingSemanticsReasoner instance- Returns:
- OrderingSemantics enum that was used for creating the reasoner
-
getModel
public List<Extension<DungTheory>> getModel(DungTheory theory) throws InvocationTargetException, IllegalAccessException returns the lowest rank of the "getModels" method- Parameters:
theory
- a dung theory- Returns:
- the list of extensions in the best rank
- Throws:
InvocationTargetException
- should never happenIllegalAccessException
- should never happen
-
getModels
public List<List<Extension<DungTheory>>> getModels(DungTheory theory) throws InvocationTargetException, IllegalAccessException compute the ordering over all subsets of theory wrt. to the ordering semantics this is done by making several comparisons (in lexicographic order) of Base Functions applied to Extensions this implies a total order that is sorted and split into ranks in the end. LOWER levels are ranked BETTER (Ascending order) !!!two extensions in one rank are either equally ranked or incomparable. !!!thus an extension placed in a better rank does not necessarily mean it is better than all the extensions in the rank below- Parameters:
theory
- a dung theory- Returns:
- a list representing the ordering of all subsets of the given graph wrt. the ordering semantics (ascending order)
- Throws:
InvocationTargetException
- should never happenIllegalAccessException
- should never happen
-
getConflicts
computes the set of conflicts occurring inside ext- Parameters:
ext
- an extensiontheory
- a dung theory- Returns:
- set of conflict in ext
-
getUndefended
computes the set of arguments in ext, which are not defended by ext against outside attackers- Parameters:
ext
- an extensiontheory
- a dung theory- Returns:
- set of arguments in ext which are not defended by ext
-
getUnattacked
computes the set of arguments outside of ext, which are not attacked by ext- Parameters:
ext
- an extensiontheory
- a dung theory- Returns:
- set of arguments in theory \ ext which are not attacked by ext
-
getDefendedNotIn
computes the set of arguments outside of ext, which are defended by ext- Parameters:
ext
- an extensiontheory
- a dung theory- Returns:
- set of arguments in theory \ ext which are defended by ext
-
isInstalled
public boolean isInstalled()- Returns:
- this method always returns true because the solver is native
-