public class ENWordFormHandler extends Object implements TemplateParser.ITemplateHandler, IWordFormHandler
| Modifier and Type | Field and Description |
|---|---|
protected String |
lemma |
protected List<IWiktionaryWordForm> |
wordForms |
| Constructor and Description |
|---|
ENWordFormHandler(String lemma)
Initializes the handler for the specified lemma.
|
protected List<IWiktionaryWordForm> wordForms
protected String lemma
public ENWordFormHandler(String lemma)
public String handle(TemplateParser.Template template)
TemplateParser.ITemplateHandlerTemplateParser for every template that occurs
in a text. The parser replaces the template by the result of this
method. If null is returned, no substitution is made,
but the original template string remains in the text.handle in interface TemplateParser.ITemplateHandlerprotected void handleNounTemplate(TemplateParser.Template template)
protected void handleProperNounTemplate(TemplateParser.Template template)
protected void handleVerbTemplate(TemplateParser.Template template)
protected void handleAdjectiveTemplate(TemplateParser.Template template)
protected WiktionaryWordForm createWordForm(String wordForm)
protected IWiktionaryWordForm createPlural(String wordForm, String pluralParam)
protected IWiktionaryWordForm createFormThirdPerson(String wordForm)
protected IWiktionaryWordForm createFormPresentParticiple(String wordForm)
protected IWiktionaryWordForm createFormSimplePast(String wordForm)
protected IWiktionaryWordForm createFormPastParticiple(String wordForm)
protected IWiktionaryWordForm createAdjectiveForm(String wordForm, GrammaticalDegree degree)
public boolean parse(String line)
IWordFormHandlerIWordFormHandler.getWordForms()
once all lines have been parsed.parse in interface IWordFormHandlerline - a line of wikitextpublic List<IWiktionaryWordForm> getWordForms()
getWordForms in interface IWordFormHandlerpublic List<GrammaticalGender> getGenders()
getGenders in interface IWordFormHandlerCopyright © 2011-2016 Ubiquitous Knowledge Processing (UKP) Lab. All Rights Reserved.