Module coreference_data :: Class Ccoreferences
[hide private]
[frames] | no frames]

Class Ccoreferences

source code

This class encapsulates the coreference layer (a set of coreference objects)

Instance Methods [hide private]
 
__get_corefs_nodes(self) source code
 
__init__(self, node=None, type='NAF')
Constructor of the object
source code
 
add_coreference(self, coreference) source code
Ccoreference
get_corefs(self)
Iterator that returns all the coreference objects
source code
xml Element
get_node(self)
Returns the node of the element
source code
 
to_kaf(self)
Converts the coreference layer to KAF
source code
 
to_naf(self)
Converts the coreference layer to NAF
source code
Method Details [hide private]

__init__(self, node=None, type='NAF')
(Constructor)

source code 

Constructor of the object

Parameters:
  • node (xml Element or None (to create and empty one)) - this is the node of the element. If it is None it will create a new object
  • type (string) - the type of the object (KAF or NAF)

get_corefs(self)

source code 

Iterator that returns all the coreference objects

Returns: Ccoreference
list of coreference objects (iterator)

get_node(self)

source code 

Returns the node of the element

Returns: xml Element
the node of the element