Package com.google.cloud.language.v1
Class PartOfSpeech
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessageV3
-
- com.google.cloud.language.v1.PartOfSpeech
-
- All Implemented Interfaces:
PartOfSpeechOrBuilder
,com.google.protobuf.Message
,com.google.protobuf.MessageLite
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Serializable
public final class PartOfSpeech extends com.google.protobuf.GeneratedMessageV3 implements PartOfSpeechOrBuilder
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
Protobuf typegoogle.cloud.language.v1.PartOfSpeech
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
PartOfSpeech.Aspect
The characteristic of a verb that expresses time flow during an event.static class
PartOfSpeech.Builder
Represents part of speech information for a token.static class
PartOfSpeech.Case
The grammatical function performed by a noun or pronoun in a phrase, clause, or sentence.static class
PartOfSpeech.Form
Depending on the language, Form can be categorizing different forms of verbs, adjectives, adverbs, etc.static class
PartOfSpeech.Gender
Gender classes of nouns reflected in the behaviour of associated words.static class
PartOfSpeech.Mood
The grammatical feature of verbs, used for showing modality and attitude.static class
PartOfSpeech.Number
Count distinctions.static class
PartOfSpeech.Person
The distinction between the speaker, second person, third person, etc.static class
PartOfSpeech.Proper
This category shows if the token is part of a proper name.static class
PartOfSpeech.Reciprocity
Reciprocal features of a pronoun.static class
PartOfSpeech.Tag
The part of speech tags enum.static class
PartOfSpeech.Tense
Time reference.static class
PartOfSpeech.Voice
The relationship between the action that a verb expresses and the participants identified by its arguments.-
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
-
-
Field Summary
Fields Modifier and Type Field Description static int
ASPECT_FIELD_NUMBER
static int
CASE_FIELD_NUMBER
static int
FORM_FIELD_NUMBER
static int
GENDER_FIELD_NUMBER
static int
MOOD_FIELD_NUMBER
static int
NUMBER_FIELD_NUMBER
static int
PERSON_FIELD_NUMBER
static int
PROPER_FIELD_NUMBER
static int
RECIPROCITY_FIELD_NUMBER
static int
TAG_FIELD_NUMBER
static int
TENSE_FIELD_NUMBER
static int
VOICE_FIELD_NUMBER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
PartOfSpeech.Aspect
getAspect()
The grammatical aspect.int
getAspectValue()
The grammatical aspect.PartOfSpeech.Case
getCase()
The grammatical case.int
getCaseValue()
The grammatical case.static PartOfSpeech
getDefaultInstance()
PartOfSpeech
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
PartOfSpeech.Form
getForm()
The grammatical form.int
getFormValue()
The grammatical form.PartOfSpeech.Gender
getGender()
The grammatical gender.int
getGenderValue()
The grammatical gender.PartOfSpeech.Mood
getMood()
The grammatical mood.int
getMoodValue()
The grammatical mood.PartOfSpeech.Number
getNumber()
The grammatical number.int
getNumberValue()
The grammatical number.com.google.protobuf.Parser<PartOfSpeech>
getParserForType()
PartOfSpeech.Person
getPerson()
The grammatical person.int
getPersonValue()
The grammatical person.PartOfSpeech.Proper
getProper()
The grammatical properness.int
getProperValue()
The grammatical properness.PartOfSpeech.Reciprocity
getReciprocity()
The grammatical reciprocity.int
getReciprocityValue()
The grammatical reciprocity.int
getSerializedSize()
PartOfSpeech.Tag
getTag()
The part of speech tag.int
getTagValue()
The part of speech tag.PartOfSpeech.Tense
getTense()
The grammatical tense.int
getTenseValue()
The grammatical tense.PartOfSpeech.Voice
getVoice()
The grammatical voice.int
getVoiceValue()
The grammatical voice.int
hashCode()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()
boolean
isInitialized()
static PartOfSpeech.Builder
newBuilder()
static PartOfSpeech.Builder
newBuilder(PartOfSpeech prototype)
PartOfSpeech.Builder
newBuilderForType()
protected PartOfSpeech.Builder
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
protected Object
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
static PartOfSpeech
parseDelimitedFrom(InputStream input)
static PartOfSpeech
parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static PartOfSpeech
parseFrom(byte[] data)
static PartOfSpeech
parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static PartOfSpeech
parseFrom(com.google.protobuf.ByteString data)
static PartOfSpeech
parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static PartOfSpeech
parseFrom(com.google.protobuf.CodedInputStream input)
static PartOfSpeech
parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static PartOfSpeech
parseFrom(InputStream input)
static PartOfSpeech
parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static PartOfSpeech
parseFrom(ByteBuffer data)
static PartOfSpeech
parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.protobuf.Parser<PartOfSpeech>
parser()
PartOfSpeech.Builder
toBuilder()
void
writeTo(com.google.protobuf.CodedOutputStream output)
-
Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
-
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
TAG_FIELD_NUMBER
public static final int TAG_FIELD_NUMBER
- See Also:
- Constant Field Values
-
ASPECT_FIELD_NUMBER
public static final int ASPECT_FIELD_NUMBER
- See Also:
- Constant Field Values
-
CASE_FIELD_NUMBER
public static final int CASE_FIELD_NUMBER
- See Also:
- Constant Field Values
-
FORM_FIELD_NUMBER
public static final int FORM_FIELD_NUMBER
- See Also:
- Constant Field Values
-
GENDER_FIELD_NUMBER
public static final int GENDER_FIELD_NUMBER
- See Also:
- Constant Field Values
-
MOOD_FIELD_NUMBER
public static final int MOOD_FIELD_NUMBER
- See Also:
- Constant Field Values
-
NUMBER_FIELD_NUMBER
public static final int NUMBER_FIELD_NUMBER
- See Also:
- Constant Field Values
-
PERSON_FIELD_NUMBER
public static final int PERSON_FIELD_NUMBER
- See Also:
- Constant Field Values
-
PROPER_FIELD_NUMBER
public static final int PROPER_FIELD_NUMBER
- See Also:
- Constant Field Values
-
RECIPROCITY_FIELD_NUMBER
public static final int RECIPROCITY_FIELD_NUMBER
- See Also:
- Constant Field Values
-
TENSE_FIELD_NUMBER
public static final int TENSE_FIELD_NUMBER
- See Also:
- Constant Field Values
-
VOICE_FIELD_NUMBER
public static final int VOICE_FIELD_NUMBER
- See Also:
- Constant Field Values
-
-
Method Detail
-
newInstance
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
- Overrides:
newInstance
in classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3
-
getTagValue
public int getTagValue()
The part of speech tag.
.google.cloud.language.v1.PartOfSpeech.Tag tag = 1;
- Specified by:
getTagValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for tag.
-
getTag
public PartOfSpeech.Tag getTag()
The part of speech tag.
.google.cloud.language.v1.PartOfSpeech.Tag tag = 1;
- Specified by:
getTag
in interfacePartOfSpeechOrBuilder
- Returns:
- The tag.
-
getAspectValue
public int getAspectValue()
The grammatical aspect.
.google.cloud.language.v1.PartOfSpeech.Aspect aspect = 2;
- Specified by:
getAspectValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for aspect.
-
getAspect
public PartOfSpeech.Aspect getAspect()
The grammatical aspect.
.google.cloud.language.v1.PartOfSpeech.Aspect aspect = 2;
- Specified by:
getAspect
in interfacePartOfSpeechOrBuilder
- Returns:
- The aspect.
-
getCaseValue
public int getCaseValue()
The grammatical case.
.google.cloud.language.v1.PartOfSpeech.Case case = 3;
- Specified by:
getCaseValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for case.
-
getCase
public PartOfSpeech.Case getCase()
The grammatical case.
.google.cloud.language.v1.PartOfSpeech.Case case = 3;
- Specified by:
getCase
in interfacePartOfSpeechOrBuilder
- Returns:
- The case.
-
getFormValue
public int getFormValue()
The grammatical form.
.google.cloud.language.v1.PartOfSpeech.Form form = 4;
- Specified by:
getFormValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for form.
-
getForm
public PartOfSpeech.Form getForm()
The grammatical form.
.google.cloud.language.v1.PartOfSpeech.Form form = 4;
- Specified by:
getForm
in interfacePartOfSpeechOrBuilder
- Returns:
- The form.
-
getGenderValue
public int getGenderValue()
The grammatical gender.
.google.cloud.language.v1.PartOfSpeech.Gender gender = 5;
- Specified by:
getGenderValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for gender.
-
getGender
public PartOfSpeech.Gender getGender()
The grammatical gender.
.google.cloud.language.v1.PartOfSpeech.Gender gender = 5;
- Specified by:
getGender
in interfacePartOfSpeechOrBuilder
- Returns:
- The gender.
-
getMoodValue
public int getMoodValue()
The grammatical mood.
.google.cloud.language.v1.PartOfSpeech.Mood mood = 6;
- Specified by:
getMoodValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for mood.
-
getMood
public PartOfSpeech.Mood getMood()
The grammatical mood.
.google.cloud.language.v1.PartOfSpeech.Mood mood = 6;
- Specified by:
getMood
in interfacePartOfSpeechOrBuilder
- Returns:
- The mood.
-
getNumberValue
public int getNumberValue()
The grammatical number.
.google.cloud.language.v1.PartOfSpeech.Number number = 7;
- Specified by:
getNumberValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for number.
-
getNumber
public PartOfSpeech.Number getNumber()
The grammatical number.
.google.cloud.language.v1.PartOfSpeech.Number number = 7;
- Specified by:
getNumber
in interfacePartOfSpeechOrBuilder
- Returns:
- The number.
-
getPersonValue
public int getPersonValue()
The grammatical person.
.google.cloud.language.v1.PartOfSpeech.Person person = 8;
- Specified by:
getPersonValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for person.
-
getPerson
public PartOfSpeech.Person getPerson()
The grammatical person.
.google.cloud.language.v1.PartOfSpeech.Person person = 8;
- Specified by:
getPerson
in interfacePartOfSpeechOrBuilder
- Returns:
- The person.
-
getProperValue
public int getProperValue()
The grammatical properness.
.google.cloud.language.v1.PartOfSpeech.Proper proper = 9;
- Specified by:
getProperValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for proper.
-
getProper
public PartOfSpeech.Proper getProper()
The grammatical properness.
.google.cloud.language.v1.PartOfSpeech.Proper proper = 9;
- Specified by:
getProper
in interfacePartOfSpeechOrBuilder
- Returns:
- The proper.
-
getReciprocityValue
public int getReciprocityValue()
The grammatical reciprocity.
.google.cloud.language.v1.PartOfSpeech.Reciprocity reciprocity = 10;
- Specified by:
getReciprocityValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for reciprocity.
-
getReciprocity
public PartOfSpeech.Reciprocity getReciprocity()
The grammatical reciprocity.
.google.cloud.language.v1.PartOfSpeech.Reciprocity reciprocity = 10;
- Specified by:
getReciprocity
in interfacePartOfSpeechOrBuilder
- Returns:
- The reciprocity.
-
getTenseValue
public int getTenseValue()
The grammatical tense.
.google.cloud.language.v1.PartOfSpeech.Tense tense = 11;
- Specified by:
getTenseValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for tense.
-
getTense
public PartOfSpeech.Tense getTense()
The grammatical tense.
.google.cloud.language.v1.PartOfSpeech.Tense tense = 11;
- Specified by:
getTense
in interfacePartOfSpeechOrBuilder
- Returns:
- The tense.
-
getVoiceValue
public int getVoiceValue()
The grammatical voice.
.google.cloud.language.v1.PartOfSpeech.Voice voice = 12;
- Specified by:
getVoiceValue
in interfacePartOfSpeechOrBuilder
- Returns:
- The enum numeric value on the wire for voice.
-
getVoice
public PartOfSpeech.Voice getVoice()
The grammatical voice.
.google.cloud.language.v1.PartOfSpeech.Voice voice = 12;
- Specified by:
getVoice
in interfacePartOfSpeechOrBuilder
- Returns:
- The voice.
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessageV3
-
writeTo
public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
- Specified by:
writeTo
in interfacecom.google.protobuf.MessageLite
- Overrides:
writeTo
in classcom.google.protobuf.GeneratedMessageV3
- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSize
in interfacecom.google.protobuf.MessageLite
- Overrides:
getSerializedSize
in classcom.google.protobuf.GeneratedMessageV3
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in interfacecom.google.protobuf.Message
- Overrides:
equals
in classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfacecom.google.protobuf.Message
- Overrides:
hashCode
in classcom.google.protobuf.AbstractMessage
-
parseFrom
public static PartOfSpeech parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static PartOfSpeech parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static PartOfSpeech parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static PartOfSpeech parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static PartOfSpeech parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static PartOfSpeech parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static PartOfSpeech parseFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static PartOfSpeech parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static PartOfSpeech parseDelimitedFrom(InputStream input) throws IOException
- Throws:
IOException
-
parseDelimitedFrom
public static PartOfSpeech parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
parseFrom
public static PartOfSpeech parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
- Throws:
IOException
-
parseFrom
public static PartOfSpeech parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Throws:
IOException
-
newBuilderForType
public PartOfSpeech.Builder newBuilderForType()
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.Message
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.MessageLite
-
newBuilder
public static PartOfSpeech.Builder newBuilder()
-
newBuilder
public static PartOfSpeech.Builder newBuilder(PartOfSpeech prototype)
-
toBuilder
public PartOfSpeech.Builder toBuilder()
- Specified by:
toBuilder
in interfacecom.google.protobuf.Message
- Specified by:
toBuilder
in interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected PartOfSpeech.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
- Specified by:
newBuilderForType
in classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
public static PartOfSpeech getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<PartOfSpeech> parser()
-
getParserForType
public com.google.protobuf.Parser<PartOfSpeech> getParserForType()
- Specified by:
getParserForType
in interfacecom.google.protobuf.Message
- Specified by:
getParserForType
in interfacecom.google.protobuf.MessageLite
- Overrides:
getParserForType
in classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
public PartOfSpeech getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
-