Module causal_data :: Class Cclink
[hide private]
[frames] | no frames]

Class Cclink

source code

This class encapsulates a clink object in KAF/NAF

Instance Methods [hide private]
 
__init__(self, node=None)
Constructor of the object
source code
 
__str__(self) source code
string
get_from(self)
Returns the from attribute of the clink
source code
string
get_id(self)
Returns the token identifier
source code
xml Element
get_node(self)
Returns the node of the element
source code
lxml Element
get_node_comment(self)
Returns the lxml element for the comment
source code
string
get_to(self)
Returns the to attribute of the clink
source code
 
set_comment(self, c)
Sets the XML comment for the clink
source code
 
set_from(self, f)
Sets the from attribute
source code
 
set_id(self, this_id)
Set the identifier for the token
source code
 
set_to(self, t)
Sets the to attribute
source code
Method Details [hide private]

__init__(self, node=None)
(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

get_from(self)

source code 

Returns the from attribute of the clink

Returns: string
the from attribute

get_id(self)

source code 

Returns the token identifier

Returns: string
the token identifier

get_node(self)

source code 

Returns the node of the element

Returns: xml Element
the node of the element

get_node_comment(self)

source code 

Returns the lxml element for the comment

Returns: lxml Element
the lxml element for the comment

get_to(self)

source code 

Returns the to attribute of the clink

Returns: string
the to attribute

set_comment(self, c)

source code 

Sets the XML comment for the clink

Parameters:
  • c (string) - the string comment

set_from(self, f)

source code 

Sets the from attribute

Parameters:
  • f (string) - the from attribute

set_id(self, this_id)

source code 

Set the identifier for the token

Parameters:
  • this_id (string) - the identifier

set_to(self, t)

source code 

Sets the to attribute

Parameters:
  • t (string) - the to attribute