SemOpt  0.2alpha2-SCC
AF Class Reference

Class encompassing an Argumentation Framework. More...

Public Member Functions

 AF ()
 Simple constructor.
bool readFile (string file)
 Method for parsing a ASPARTIX compliant file.
int numArgs ()
 Returns the number of arguments.
ArgumentgetArgumentByName (string)
 This method returns the pointer to the Argument whose name is given as parameter.
ArgumentgetArgumentByNumber (int position)
 This method returns the pointer to the Argument whose identification number is given as parameter.
SetArgumentsget_arguments () const
 Returns a pointer to the set of arguments.
SetArgumentsIterator begin ()
 Begin of the iterator for the set of arguments.
SetArgumentsIterator end ()
 End of the iterator for the set of arguments.

Detailed Description

Class encompassing an Argumentation Framework.

Author
Mauro Vallati m.val.nosp@m.lati.nosp@m.@hud..nosp@m.ac.u.nosp@m.k

Definition at line 20 of file AF.h.

Member Function Documentation

SetArgumentsIterator AF::begin ( )

Begin of the iterator for the set of arguments.

Return values
SetArgumentsIteratorAn iterator pointing at the first of the elements of the set of arguments

Definition at line 119 of file AF.cpp.

References SetArguments::begin().

SetArgumentsIterator AF::end ( )

End of the iterator for the set of arguments.

Return values
SetArgumentsIteratorAn iterator pointing at the last of the elements of the set of arguments

Definition at line 128 of file AF.cpp.

References SetArguments::end().

SetArguments * AF::get_arguments ( ) const

Returns a pointer to the set of arguments.

Return values
SetArguments*

Definition at line 137 of file AF.cpp.

Argument * AF::getArgumentByName ( string  name)

This method returns the pointer to the Argument whose name is given as parameter.

Parameters
[in]nameThe name of the argument
Return values
Argument*The pointer to the Argument object, or NULL if not found

Definition at line 90 of file AF.cpp.

References SetArguments::getArgumentByName().

Referenced by readFile().

Argument * AF::getArgumentByNumber ( int  num)

This method returns the pointer to the Argument whose identification number is given as parameter.

Parameters
[in]numThe name of the argument
Return values
Argument*The pointer to the Argument object, or NULL if not found

Definition at line 110 of file AF.cpp.

References SetArguments::getArgumentByNumber().

int AF::numArgs ( )

Returns the number of arguments.

Return values
int

Definition at line 99 of file AF.cpp.

References SetArguments::cardinality().

Referenced by Argument::OutVar(), readFile(), and Argument::UndecVar().

bool AF::readFile ( string  file)

Method for parsing a ASPARTIX compliant file.

It uses part of the code from Samer Nofal's, University of Liverpool

Parameters
[in]fileA string representing the (relative/absolute) path to the ASPARTIX compliant file
Return values
boolIt returns True if it can correctly parse the file, False otherwise

Definition at line 35 of file AF.cpp.

References SetArguments::add_Argument(), Argument::add_attacks(), getArgumentByName(), and numArgs().


The documentation for this class was generated from the following files: