Interface IWiktionaryDataHandler
- All Known Implementing Classes:
OntolexBasedRDFDataHandler, PostTranslationDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler, WiktionaryDataHandler
public interface IWiktionaryDataHandler
-
Method Summary
Modifier and TypeMethodDescriptionorg.apache.jena.rdf.model.ResourceaddTo(org.apache.jena.rdf.model.Resource target, Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> pv) org.apache.jena.rdf.model.ResourceaddToCurrentWordSense(Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> context) voidbuildDatacubeObservations(String l, TranslationGlossesStat translationGlossesStat, EvaluationStats.Stat stat, String dumpFileVersion) voidclose the dataset that eventually backs up the different feature boxes.voidcomputeStatistics(org.apache.jena.rdf.model.Model statsModel, org.apache.jena.rdf.model.Model sourceModel, String dumpVersion) org.apache.jena.rdf.model.ResourcecreateGlossResource(String gloss) org.apache.jena.rdf.model.ResourcecreateGlossResource(String gloss, int rank) org.apache.jena.rdf.model.Resourceorg.apache.jena.rdf.model.ResourcecreateGlossResource(StructuredGloss gloss, int rank) org.apache.jena.rdf.model.Resourcevoiddump(org.apache.jena.rdf.model.Model model, OutputStream out, String format) Write a serialized represention of this model in a specified language.voiddumpAllFeaturesAsHDT(OutputStream ostream, boolean isExolex) voidEnable the extraction of morphological data in a second Model if available.voidvoidvoidreturns the short (2 letter code) id of the language of the current LexicalEntryorg.apache.jena.rdf.model.Modelorg.apache.jena.rdf.model.Modelreturns the short (2 letter code) id of the language of the language editionorg.apache.jena.rdf.model.ModelvoidinitializeLanguageSection(String language) voidvoidinitializePageExtraction(String wiktionaryPageName) booleanintvoidpopulateMetadata(org.apache.jena.rdf.model.Model metadataModel, org.apache.jena.rdf.model.Model sourceModel, String dumpFilename, String extractorVersion, boolean isExolex) voidvoidregisterDerivation(String derived) voidregisterDerivation(String derived, String note) org.apache.jena.rdf.model.ResourceregisterExample(String ex, Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> context) Register example ex for the current lexical sense.org.apache.jena.rdf.model.ResourceregisterExampleOnResource(String ex, Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> context, org.apache.jena.rdf.model.Resource sense) Register example ex for a given lexical sense.voidregisterInflection(String languageCode, String pos, String inflection, String canonicalForm, int defNumber, HashSet<PropertyObjectPair> properties) voidregisterInflection(String languageCode, String pos, String inflection, String canonicalForm, int defNumber, HashSet<PropertyObjectPair> properties, HashSet<PronunciationPair> pronunciations) voidregisterInflection(InflectionData key, Set<String> value) org.apache.jena.rdf.model.ResourceRegister definition def for the current lexical entry.org.apache.jena.rdf.model.ResourceregisterNewDefinition(String def, int lvl) Register definition def for the current lexical entry.org.apache.jena.rdf.model.ResourceregisterNewDefinition(String def, String senseNumber) Register definition def for the current lexical entry.voidregisterNymRelation(String target, String synRelation) voidregisterNymRelation(String target, String synRelation, org.apache.jena.rdf.model.Resource gloss, String usage) default voidregisterNymRelationOnCurrentSense(String target, String synRelation) voidregisterNymRelationOnCurrentSense(String target, String synRelation, org.apache.jena.rdf.model.Resource gloss, String usage) voidregisterPronunciation(String pron, String lang) voidregisterPropertyOnCanonicalForm(org.apache.jena.rdf.model.Property p, org.apache.jena.rdf.model.RDFNode r) voidregisterPropertyOnLexicalEntry(org.apache.jena.rdf.model.Property p, org.apache.jena.rdf.model.RDFNode r) voidregisterTranslation(String lang, org.apache.jena.rdf.model.Resource currentGlose, String usage, String word)
-
Method Details
-
closeDataset
void closeDataset()close the dataset that eventually backs up the different feature boxes.Does nothing when there is no dataset backing up the boxes.
-
enableEndolexFeatures
Enable the extraction of morphological data in a second Model if available.- Parameters:
f- Feature
-
enableExolexFeatures
-
getFeatureBox
-
getEndolexFeatureBox
-
getExolexFeatureBox
-
isDisabled
-
initializePageExtraction
-
finalizePageExtraction
void finalizePageExtraction() -
initializeLanguageSection
-
finalizeLanguageSection
void finalizeLanguageSection() -
getCurrentEntryLanguage
String getCurrentEntryLanguage()returns the short (2 letter code) id of the language of the current LexicalEntry- Returns:
- current entry short language code
-
getExtractedLanguage
String getExtractedLanguage()returns the short (2 letter code) id of the language of the language edition- Returns:
- wiktionary edition short language code
-
initializeLexicalEntry
-
registerNewDefinition
Register definition def for the current lexical entry.This method will compute a sense number based on the rank of the definition in the entry.
It is equivalent to registerNewDefinition(def, 1);
- Parameters:
def- a string- Returns:
-
registerNewDefinition
Register definition def for the current lexical entry.This method will compute a sense number based on the rank of the definition in the entry, taking into account the level of the definition. 1, 1a, 1b, 1c, 2, etc.
- Parameters:
def- the definition stringlvl- an integer giving the level of the definition (1 or 2).- Returns:
-
registerExample
org.apache.jena.rdf.model.Resource registerExample(String ex, Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> context) Register example ex for the current lexical sense.- Parameters:
ex- the example stringcontext- map of property + RDFNode that are to be attached to the example object.- Returns:
- a Resource
-
registerExampleOnResource
org.apache.jena.rdf.model.Resource registerExampleOnResource(String ex, Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> context, org.apache.jena.rdf.model.Resource sense) Register example ex for a given lexical sense.- Parameters:
ex- the example stringcontext- map of property + RDFNode that are to be attached to the example object.sense- the Resource of the lexical sens are to be attached with the example object.- Returns:
- a Resource
-
registerNewDefinition
Register definition def for the current lexical entry.This method will use senseNumber as a sense number for this definition.
- Parameters:
def- the definition stringsenseNumber- a string giving the sense number of the definition.- Returns:
-
registerAlternateSpelling
-
registerNymRelation
-
getGlossFilter
AbstractGlossFilter getGlossFilter() -
createGlossResource
-
createGlossResource
-
createGlossResource
-
createGlossResource
-
registerNymRelation
-
registerTranslation
-
registerPronunciation
-
nbEntries
int nbEntries() -
currentPagename
String currentPagename() -
dump
Write a serialized represention of this model in a specified language. The language in which to write the model is specified by the lang argument. Predefined values are "RDF/XML", "RDF/XML-ABBREV", "N-TRIPLE", "TURTLE", (and "TTL") and "N3". The default value, represented by null, is "RDF/XML".- Parameters:
model- the Model to be dumpedout- an OutputStreamformat- a String
-
registerNymRelationOnCurrentSense
-
registerNymRelationOnCurrentSense
-
registerPropertyOnLexicalEntry
void registerPropertyOnLexicalEntry(org.apache.jena.rdf.model.Property p, org.apache.jena.rdf.model.RDFNode r) -
registerPropertyOnCanonicalForm
void registerPropertyOnCanonicalForm(org.apache.jena.rdf.model.Property p, org.apache.jena.rdf.model.RDFNode r) -
registerDerivation
-
registerDerivation
-
registerInflection
void registerInflection(String languageCode, String pos, String inflection, String canonicalForm, int defNumber, HashSet<PropertyObjectPair> properties, HashSet<PronunciationPair> pronunciations) -
registerInflection
-
registerInflection
-
currentWiktionaryPos
String currentWiktionaryPos() -
currentLexinfoPos
org.apache.jena.rdf.model.Resource currentLexinfoPos() -
populateMetadata
-
buildDatacubeObservations
void buildDatacubeObservations(String l, TranslationGlossesStat translationGlossesStat, EvaluationStats.Stat stat, String dumpFileVersion) -
computeStatistics
void computeStatistics(org.apache.jena.rdf.model.Model statsModel, org.apache.jena.rdf.model.Model sourceModel, String dumpVersion) -
dumpAllFeaturesAsHDT
-
addTo
org.apache.jena.rdf.model.Resource addTo(org.apache.jena.rdf.model.Resource target, Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> pv) -
addToCurrentWordSense
org.apache.jena.rdf.model.Resource addToCurrentWordSense(Set<org.apache.commons.lang3.tuple.Pair<org.apache.jena.rdf.model.Property, org.apache.jena.rdf.model.RDFNode>> context)
-