Class BabelExample

java.lang.Object
it.uniroma1.lcl.babelnet.data.BabelExample
All Implemented Interfaces:
Example

public class BabelExample extends Object implements Example
An example sentence in BabelNet.
Author:
vannella
  • Constructor Details

    • BabelExample

      public BabelExample(BabelSenseSource source, String sourceSense, it.uniroma1.lcl.jlt.util.Language language, String example)
      Creates a new instance of a BabelExample
      Parameters:
      source - the gloss source
      sourceSense - the sense the gloss defines
      language - the language the gloss is written in
      example - the example string
    • BabelExample

      public BabelExample(BabelSenseSource source, String sourceSense, it.uniroma1.lcl.jlt.util.Language language, String example, Set<BabelTokenWord> tokens)
      Creates a new instance of a BabelExample
      Parameters:
      source - the gloss source
      sourceSense - the sense the gloss defines
      language - the language the gloss is written in
      example - the example string
      tokens - the tokens that belong to the gloss
  • Method Details

    • getSource

      public BabelSenseSource getSource()
      The region where the concept for this example lies.
      Returns:
      the region where the example concept lies
    • getSourceSense

      public String getSourceSense()
      The sense from which this example is taken
      Returns:
      the corresponding sense for the example
    • getLanguage

      public it.uniroma1.lcl.jlt.util.Language getLanguage()
      The language for this example
      Returns:
      the example language
    • getExample

      public String getExample()
      Returns the example sentence.
      Returns:
      the example content as a String.
    • getLicense

      public BabelLicense getLicense()
      Gets the license for this Babel example
      Returns:
      the license
    • getTokensWordExample

      public Set<BabelTokenWord> getTokensWordExample()
      Gets a list of BabelTokenWords. Each BabelTokenWord corresponds to the lemma that appears in this Babel example and for which it is an usage example.
      Returns:
      the list of lemmas in this Babel example.
    • toString

      public String toString()
      Overrides:
      toString in class Object