Class: Google::Apis::LanguageV1::PartOfSpeech
- Inherits:
-
Object
- Object
- Google::Apis::LanguageV1::PartOfSpeech
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/language_v1/classes.rb,
generated/google/apis/language_v1/representations.rb,
generated/google/apis/language_v1/representations.rb
Overview
Represents part of speech information for a token. Parts of speech are as defined in http://www.lrec-conf.org/proceedings/lrec2012/pdf/274_Paper.pdf
Instance Attribute Summary collapse
-
#aspect ⇒ String
The grammatical aspect.
-
#case ⇒ String
The grammatical case.
-
#form ⇒ String
The grammatical form.
-
#gender ⇒ String
The grammatical gender.
-
#mood ⇒ String
The grammatical mood.
-
#number ⇒ String
The grammatical number.
-
#person ⇒ String
The grammatical person.
-
#proper ⇒ String
The grammatical properness.
-
#reciprocity ⇒ String
The grammatical reciprocity.
-
#tag ⇒ String
The part of speech tag.
-
#tense ⇒ String
The grammatical tense.
-
#voice ⇒ String
The grammatical voice.
Instance Method Summary collapse
-
#initialize(**args) ⇒ PartOfSpeech
constructor
A new instance of PartOfSpeech.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ PartOfSpeech
Returns a new instance of PartOfSpeech
282 283 284 |
# File 'generated/google/apis/language_v1/classes.rb', line 282 def initialize(**args) update!(**args) end |
Instance Attribute Details
#aspect ⇒ String
The grammatical aspect.
Corresponds to the JSON property aspect
240 241 242 |
# File 'generated/google/apis/language_v1/classes.rb', line 240 def aspect @aspect end |
#case ⇒ String
The grammatical case.
Corresponds to the JSON property case
270 271 272 |
# File 'generated/google/apis/language_v1/classes.rb', line 270 def case @case end |
#form ⇒ String
The grammatical form.
Corresponds to the JSON property form
225 226 227 |
# File 'generated/google/apis/language_v1/classes.rb', line 225 def form @form end |
#gender ⇒ String
The grammatical gender.
Corresponds to the JSON property gender
255 256 257 |
# File 'generated/google/apis/language_v1/classes.rb', line 255 def gender @gender end |
#mood ⇒ String
The grammatical mood.
Corresponds to the JSON property mood
245 246 247 |
# File 'generated/google/apis/language_v1/classes.rb', line 245 def mood @mood end |
#number ⇒ String
The grammatical number.
Corresponds to the JSON property number
230 231 232 |
# File 'generated/google/apis/language_v1/classes.rb', line 230 def number @number end |
#person ⇒ String
The grammatical person.
Corresponds to the JSON property person
260 261 262 |
# File 'generated/google/apis/language_v1/classes.rb', line 260 def person @person end |
#proper ⇒ String
The grammatical properness.
Corresponds to the JSON property proper
265 266 267 |
# File 'generated/google/apis/language_v1/classes.rb', line 265 def proper @proper end |
#reciprocity ⇒ String
The grammatical reciprocity.
Corresponds to the JSON property reciprocity
280 281 282 |
# File 'generated/google/apis/language_v1/classes.rb', line 280 def reciprocity @reciprocity end |
#tag ⇒ String
The part of speech tag.
Corresponds to the JSON property tag
250 251 252 |
# File 'generated/google/apis/language_v1/classes.rb', line 250 def tag @tag end |
#tense ⇒ String
The grammatical tense.
Corresponds to the JSON property tense
275 276 277 |
# File 'generated/google/apis/language_v1/classes.rb', line 275 def tense @tense end |
#voice ⇒ String
The grammatical voice.
Corresponds to the JSON property voice
235 236 237 |
# File 'generated/google/apis/language_v1/classes.rb', line 235 def voice @voice end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
287 288 289 290 291 292 293 294 295 296 297 298 299 300 |
# File 'generated/google/apis/language_v1/classes.rb', line 287 def update!(**args) @form = args[:form] if args.key?(:form) @number = args[:number] if args.key?(:number) @voice = args[:voice] if args.key?(:voice) @aspect = args[:aspect] if args.key?(:aspect) @mood = args[:mood] if args.key?(:mood) @tag = args[:tag] if args.key?(:tag) @gender = args[:gender] if args.key?(:gender) @person = args[:person] if args.key?(:person) @proper = args[:proper] if args.key?(:proper) @case = args[:case] if args.key?(:case) @tense = args[:tense] if args.key?(:tense) @reciprocity = args[:reciprocity] if args.key?(:reciprocity) end |