ch.uzh.ifi.attempto.acewiki.core.ontology
Class VerbRole

java.lang.Object
  extended by ch.uzh.ifi.attempto.acewiki.core.ontology.OntologyElement
      extended by ch.uzh.ifi.attempto.acewiki.core.ontology.Role
          extended by ch.uzh.ifi.attempto.acewiki.core.ontology.VerbRole
All Implemented Interfaces:
java.lang.Comparable<OntologyElement>

public class VerbRole
extends Role

This class stands for roles that are represented by a transitive verb. Transitive verbs have three word forms: a third singular form, a bare infinitive form , and a passive form. The bare infinitive form is used in the case of negation and plural. The passive form always ends with the word "by".

0: third singular form. 1: bare infinitive form. 2: passive form.

Examples: ["gives", "give", "given by"]; ["knows", "know", "known by"].

Author:
Tobias Kuhn

Constructor Summary
VerbRole()
          Creates a new verb role.
 
Method Summary
protected  void changeWords(java.lang.String... words)
          Changes the word forms without updating the ontology indexes.
 java.lang.String getInternalType()
          Returns the word type as it is used internally.
 java.lang.String getPastPart()
          Returns the past participle which is the passive form without the "by".
 java.lang.String getPrettyPastPart()
          Returns the pretty-printed past participle.
 java.lang.String getType()
          Returns the word type as it is shown to the user.
 java.lang.String[] getWords()
          Returns the word forms.
 
Methods inherited from class ch.uzh.ifi.attempto.acewiki.core.ontology.OntologyElement
add, compareTo, edit, getHeadword, getOntology, getPrettyWord, getSentences, getURI, getURISuffix, getWord, getWord, log, registerAt, remove, setWords, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

VerbRole

public VerbRole()
Creates a new verb role.

Method Detail

getWords

public java.lang.String[] getWords()
Description copied from class: OntologyElement
Returns the word forms. The position in the array corresponds to the word form id.

Specified by:
getWords in class OntologyElement
Returns:
An array containing the word forms.

changeWords

protected void changeWords(java.lang.String... words)
Description copied from class: OntologyElement
Changes the word forms without updating the ontology indexes. The order reflects the word form ids.

Specified by:
changeWords in class OntologyElement
Parameters:
words - The word forms.

getPastPart

public java.lang.String getPastPart()
Returns the past participle which is the passive form without the "by". E.g. for the passive form "given by", the past participle is "given".

Returns:
The past participle form.

getPrettyPastPart

public java.lang.String getPrettyPastPart()
Returns the pretty-printed past participle. The pretty printing replaces underscores by blanks.

Returns:
The pretty-printed past participle form.
See Also:
getPastPart()

getType

public java.lang.String getType()
Description copied from class: OntologyElement
Returns the word type as it is shown to the user. Newer versions of AceWiki can savely change this value.

Specified by:
getType in class OntologyElement
Returns:
The word type.

getInternalType

public java.lang.String getInternalType()
Description copied from class: OntologyElement
Returns the word type as it is used internally. Changing this value in newer versions of AceWiki breaks backwards compatibility for loading ontologies.

Specified by:
getInternalType in class OntologyElement
Returns:
The internal word type.


Copyright 2008, Attempto Group, University of Zurich (see http://attempto.ifi.uzh.ch)