Class PartOfSpeech.Builder (2.31.0)

public static final class PartOfSpeech.Builder extends GeneratedMessageV3.Builder<PartOfSpeech.Builder> 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 type google.cloud.language.v1.PartOfSpeech

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public PartOfSpeech.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
PartOfSpeech.Builder
Overrides

build()

public PartOfSpeech build()
Returns
TypeDescription
PartOfSpeech

buildPartial()

public PartOfSpeech buildPartial()
Returns
TypeDescription
PartOfSpeech

clear()

public PartOfSpeech.Builder clear()
Returns
TypeDescription
PartOfSpeech.Builder
Overrides

clearAspect()

public PartOfSpeech.Builder clearAspect()

The grammatical aspect.

.google.cloud.language.v1.PartOfSpeech.Aspect aspect = 2;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearCase()

public PartOfSpeech.Builder clearCase()

The grammatical case.

.google.cloud.language.v1.PartOfSpeech.Case case = 3;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public PartOfSpeech.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
PartOfSpeech.Builder
Overrides

clearForm()

public PartOfSpeech.Builder clearForm()

The grammatical form.

.google.cloud.language.v1.PartOfSpeech.Form form = 4;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearGender()

public PartOfSpeech.Builder clearGender()

The grammatical gender.

.google.cloud.language.v1.PartOfSpeech.Gender gender = 5;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearMood()

public PartOfSpeech.Builder clearMood()

The grammatical mood.

.google.cloud.language.v1.PartOfSpeech.Mood mood = 6;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearNumber()

public PartOfSpeech.Builder clearNumber()

The grammatical number.

.google.cloud.language.v1.PartOfSpeech.Number number = 7;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public PartOfSpeech.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
PartOfSpeech.Builder
Overrides

clearPerson()

public PartOfSpeech.Builder clearPerson()

The grammatical person.

.google.cloud.language.v1.PartOfSpeech.Person person = 8;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearProper()

public PartOfSpeech.Builder clearProper()

The grammatical properness.

.google.cloud.language.v1.PartOfSpeech.Proper proper = 9;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearReciprocity()

public PartOfSpeech.Builder clearReciprocity()

The grammatical reciprocity.

.google.cloud.language.v1.PartOfSpeech.Reciprocity reciprocity = 10;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearTag()

public PartOfSpeech.Builder clearTag()

The part of speech tag.

.google.cloud.language.v1.PartOfSpeech.Tag tag = 1;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearTense()

public PartOfSpeech.Builder clearTense()

The grammatical tense.

.google.cloud.language.v1.PartOfSpeech.Tense tense = 11;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clearVoice()

public PartOfSpeech.Builder clearVoice()

The grammatical voice.

.google.cloud.language.v1.PartOfSpeech.Voice voice = 12;

Returns
TypeDescription
PartOfSpeech.Builder

This builder for chaining.

clone()

public PartOfSpeech.Builder clone()
Returns
TypeDescription
PartOfSpeech.Builder
Overrides

getAspect()

public PartOfSpeech.Aspect getAspect()

The grammatical aspect.

.google.cloud.language.v1.PartOfSpeech.Aspect aspect = 2;

Returns
TypeDescription
PartOfSpeech.Aspect

The aspect.

getAspectValue()

public int getAspectValue()

The grammatical aspect.

.google.cloud.language.v1.PartOfSpeech.Aspect aspect = 2;

Returns
TypeDescription
int

The enum numeric value on the wire for aspect.

getCase()

public PartOfSpeech.Case getCase()

The grammatical case.

.google.cloud.language.v1.PartOfSpeech.Case case = 3;

Returns
TypeDescription
PartOfSpeech.Case

The case.

getCaseValue()

public int getCaseValue()

The grammatical case.

.google.cloud.language.v1.PartOfSpeech.Case case = 3;

Returns
TypeDescription
int

The enum numeric value on the wire for case.

getDefaultInstanceForType()

public PartOfSpeech getDefaultInstanceForType()
Returns
TypeDescription
PartOfSpeech

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getForm()

public PartOfSpeech.Form getForm()

The grammatical form.

.google.cloud.language.v1.PartOfSpeech.Form form = 4;

Returns
TypeDescription
PartOfSpeech.Form

The form.

getFormValue()

public int getFormValue()

The grammatical form.

.google.cloud.language.v1.PartOfSpeech.Form form = 4;

<
Returns
TypeDescription
int