Package net.sf.tweety.arg.social.syntax
Class SocialAbstractArgumentationFramework
- java.lang.Object
-
- net.sf.tweety.commons.BeliefSet<Argument,DungSignature>
-
- net.sf.tweety.arg.dung.syntax.DungTheory
-
- net.sf.tweety.arg.social.syntax.SocialAbstractArgumentationFramework
-
- All Implemented Interfaces:
java.lang.Comparable<DungTheory>,java.lang.Iterable<Argument>,java.util.Collection<Argument>,BeliefBase,Graph<Argument>
public class SocialAbstractArgumentationFramework extends DungTheory
This class implements a social abstract argumentation framework from [Joao Leite, Joao Martins. Social Abstract Argumentation. IJCAI 2011]- Author:
- Matthias Thimm
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Map<Argument,java.lang.Integer>neg_votesThe number of negative votes of argumentsprivate java.util.Map<Argument,java.lang.Integer>pos_votesThe number of positive votes of arguments-
Fields inherited from class net.sf.tweety.commons.BeliefSet
EQUALS_USES_SIGNATURE, signature
-
Fields inherited from interface net.sf.tweety.graphs.Graph
IGNORE_SELFLOOPS, INVERT_SELFLOOPS, REMOVE_SELFLOOPS
-
-
Constructor Summary
Constructors Constructor Description SocialAbstractArgumentationFramework()Creates a new empty social abstract argumentation frameworkSocialAbstractArgumentationFramework(Graph<Argument> graph)Creates a new social abstract argumentation framework from the given graph.
-
Method Summary
Modifier and Type Method Description booleanadd(Argument a)Adds the given node to this graph.booleanadd(DungTheory theory)Adds all arguments and attacks of the given theory to this theoryintgetNegative(Argument arg)Returns the number of negative votes of the given argumentintgetPositive(Argument arg)Returns the number of positive votes of the given argumentbooleanremove(Argument a)Removes the argument and all its attacksjava.lang.StringtoString()voidvoteDown(Argument arg)Adds a negative vote to the given argument.voidvoteDown(Argument arg, int number)Adds the given number of negative votes to the given argumentvoidvoteUp(Argument arg)Adds a positive vote to the given argument.voidvoteUp(Argument arg, int number)Adds the given number of positive votes to the given argument-
Methods inherited from class net.sf.tweety.arg.dung.syntax.DungTheory
add, add, addAllAttacks, addAttack, areAdjacent, compareTo, contains, containsAll, containsAttack, containsCycle, equals, existsDirectedPath, faf, getAdjacencyMatrix, getAttacked, getAttackers, getAttacks, getChildren, getComplementGraph, getComponents, getEdge, getEdges, getMinimalSignature, getNeighbors, getNodes, getNumberOfNodes, getParents, getRestriction, getStronglyConnectedComponents, getSubgraphs, hasAttackBranch, hasDefenseBranch, hashCode, hasSelfLoops, instantiateSignature, isAttackBranch, isAttacked, isAttacked, isAttackedBy, isAttackedBy, isAttackingAllOtherArguments, isCoherent, isDefenseBranch, isIndirectAttack, isRelativelyCoherent, isStable, isSupport, isWeightedGraph, isWellFounded, prettyPrint, remove, removeAll
-
Methods inherited from class net.sf.tweety.commons.BeliefSet
addAll, clear, getSignature, instantiateSet, isEmpty, iterator, remove, retainAll, setSignature, size, toArray, toArray
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getPositive
public int getPositive(Argument arg)
Returns the number of positive votes of the given argument- Parameters:
arg- some argument- Returns:
- the number of positive votes of the given argument
-
getNegative
public int getNegative(Argument arg)
Returns the number of negative votes of the given argument- Parameters:
arg- some argument- Returns:
- the number of negative votes of the given argument
-
voteUp
public void voteUp(Argument arg, int number)
Adds the given number of positive votes to the given argument- Parameters:
arg- some argumentnumber- some number
-
voteUp
public void voteUp(Argument arg)
Adds a positive vote to the given argument.- Parameters:
arg- some argument
-
voteDown
public void voteDown(Argument arg, int number)
Adds the given number of negative votes to the given argument- Parameters:
arg- some argumentnumber- some number
-
voteDown
public void voteDown(Argument arg)
Adds a negative vote to the given argument.- Parameters:
arg- some argument
-
remove
public boolean remove(Argument a)
Description copied from class:DungTheoryRemoves the argument and all its attacks- Overrides:
removein classDungTheory- Parameters:
a- some argument- Returns:
- true if this structure has been changed
-
add
public boolean add(Argument a)
Description copied from interface:GraphAdds the given node to this graph.
-
add
public boolean add(DungTheory theory)
Description copied from class:DungTheoryAdds all arguments and attacks of the given theory to this theory- Overrides:
addin classDungTheory- Parameters:
theory- some Dung theory- Returns:
- "true" if this Dung Theory has been modified
-
toString
public java.lang.String toString()
- Specified by:
toStringin interfaceBeliefBase- Specified by:
toStringin interfaceGraph<Argument>- Overrides:
toStringin classDungTheory
-
-