class documentation
class BabelSynsetRelation:
Class that models a relation to a synset ID in the BabelNet network.
| Static Method | from |
Create a new instance of BabelSynsetRelation from an input record in the same format as found in BabelNetIndexField. |
| Method | __init__ |
init method |
| Instance Variable | language |
The language of the relation. |
| Instance Variable | pointer |
The relation type. |
| Instance Variable | target |
The target offset. |
| Property | id |
Get the target as a BabelSynsetID. |
| Method | __eq__ |
Undocumented |
| Method | __hash__ |
Undocumented |
| Method | __repr__ |
Undocumented |
| Method | __str__ |
Undocumented |
Create a new instance of BabelSynsetRelation from an input record in the same format as found in BabelNetIndexField.
| Parameters | |
edge:str | The String representation of the edge. |
| Returns | |
BabelSynsetRelation | Relation instance. |
| Raises | |
RuntimeError | if the relation is invalid |
def __init__(self, language, pointer, target):
init method
| Parameters | |
language:Language | The language of the relation. |
pointer:BabelPointer | The relation type. |
target:str | The target offset. |