FreeLing
4.0
|
Class predicate stores a predicate and its arguments. More...
#include <language.h>
Public Member Functions | |
predicate () | |
~predicate () | |
predicate (int p, const std::wstring &s) | |
predicate (const predicate &) | |
Copy constructor. | |
predicate & | operator= (const predicate &) |
assignment | |
const std::wstring & | get_sense () const |
get the propbank sense of the predicate | |
int | get_position () const |
get the position of the predicate head | |
bool | has_argument (int p) const |
check whether word in position p is an argument to the predicate | |
void | add_argument (int p, const std::wstring &r) |
add new argument to the predicate | |
const argument & | get_argument_by_pos (int p) const |
get access to an argument by word position | |
Private Attributes | |
std::map< int, int > | arg_index |
int | position |
std::wstring | sense |
Class predicate stores a predicate and its arguments.
freeling::predicate::predicate | ( | int | p, |
const std::wstring & | s | ||
) |
freeling::predicate::predicate | ( | const predicate & | p | ) |
void freeling::predicate::add_argument | ( | int | p, |
const std::wstring & | r | ||
) |
const argument & freeling::predicate::get_argument_by_pos | ( | int | p | ) | const |
int freeling::predicate::get_position | ( | ) | const |
get the position of the predicate head
References position.
Referenced by freeling::sentence::add_predicate().
const wstring & freeling::predicate::get_sense | ( | ) | const |
get the propbank sense of the predicate
References sense.
bool freeling::predicate::has_argument | ( | int | p | ) | const |
check whether word in position p is an argument to the predicate
References arg_index.
std::map<int,int> freeling::predicate::arg_index [private] |
Referenced by add_argument(), get_argument_by_pos(), has_argument(), operator=(), and predicate().
int freeling::predicate::position [private] |
Referenced by get_argument_by_pos(), get_position(), operator=(), and predicate().
std::wstring freeling::predicate::sense [private] |
Referenced by get_sense(), operator=(), and predicate().