Class: WordNet::Word
Overview
WordNet word model class
Constant Summary
Constants included from Constants
Constants::DEFAULT_DB_OPTIONS, Constants::DELIM, Constants::DELIM_RE, Constants::DOMAIN_TYPES, Constants::DomainSymbols, Constants::HOLONYM_SYMBOLS, Constants::HOLONYM_TYPES, Constants::HYPERNYM_SYMBOLS, Constants::HYPERNYM_TYPES, Constants::HYPONYM_SYMBOLS, Constants::HYPONYM_TYPES, Constants::LEXFILES, Constants::MEMBER_SYMBOLS, Constants::MEMBER_TYPES, Constants::MERONYM_SYMBOLS, Constants::MERONYM_TYPES, Constants::POINTER_SUBTYPES, Constants::POINTER_SYMBOLS, Constants::POINTER_TYPES, Constants::SUB_DELIM, Constants::SUB_DELIM_RE, Constants::SYNTACTIC_CATEGORIES, Constants::SYNTACTIC_SYMBOLS, Constants::VERB_SENTS
Instance Method Summary collapse
-
#adjective_satellites ⇒ Object
Return a dataset for all of the Word’s Synsets that are adjective satellites.
-
#adjectives ⇒ Object
Return a dataset for all of the Word’s Synsets that are adjectives.
-
#adverbs ⇒ Object
Return a dataset for all of the Word’s Synsets that are adverbs.
-
#morphs ⇒ Object
The WordNet::Morphs related to the word.
-
#nouns ⇒ Object
Return a dataset for all of the Word’s Synsets that are nouns.
-
#senses ⇒ Object
The WordNet::Sense objects that relate the word with its Synsets.
-
#synsets ⇒ Object
The WordNet::Synsets related to the word via its senses.
-
#to_s ⇒ Object
Return the stringified word; alias for #lemma.
-
#verbs ⇒ Object
Return a dataset for all of the Word’s Synsets that are verbs.
Instance Method Details
#adjective_satellites ⇒ Object
Return a dataset for all of the Word’s Synsets that are adjective satellites.
135 136 137 |
# File 'lib/wordnet/word.rb', line 135 def adjective_satellites return synsets_dataset.adjective_satellites end |
#adjectives ⇒ Object
Return a dataset for all of the Word’s Synsets that are adjectives.
123 124 125 |
# File 'lib/wordnet/word.rb', line 123 def adjectives return synsets_dataset.adjectives end |
#adverbs ⇒ Object
Return a dataset for all of the Word’s Synsets that are adverbs.
129 130 131 |
# File 'lib/wordnet/word.rb', line 129 def adverbs return synsets_dataset.adverbs end |
#morphs ⇒ Object
The WordNet::Morphs related to the word
80 81 82 83 |
# File 'lib/wordnet/word.rb', line 80 many_to_many :morphs, join_table: :morphmaps, left_key: :wordid, right_key: :morphid |
#nouns ⇒ Object
Return a dataset for all of the Word’s Synsets that are nouns.
111 112 113 |
# File 'lib/wordnet/word.rb', line 111 def nouns return synsets_dataset.nouns end |
#senses ⇒ Object
The WordNet::Sense objects that relate the word with its Synsets
67 68 69 |
# File 'lib/wordnet/word.rb', line 67 one_to_many :senses, key: :wordid, primary_key: :wordid |
#synsets ⇒ Object
The WordNet::Synsets related to the word via its senses
73 74 75 76 |
# File 'lib/wordnet/word.rb', line 73 many_to_many :synsets, join_table: :senses, left_key: :wordid, right_key: :synsetid |
#to_s ⇒ Object
Return the stringified word; alias for #lemma.
105 106 107 |
# File 'lib/wordnet/word.rb', line 105 def to_s return self.lemma end |
#verbs ⇒ Object
Return a dataset for all of the Word’s Synsets that are verbs.
117 118 119 |
# File 'lib/wordnet/word.rb', line 117 def verbs return synsets_dataset.verbs end |