Class Period.Builder (3.51.0)

public static final class Period.Builder extends GeneratedMessageV3.Builder<Period.Builder> implements PeriodOrBuilder

Represents period in days/months/years.

Protobuf type google.cloud.channel.v1.Period

Implements

PeriodOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Period.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Period.Builder
Overrides

build()

public Period build()
Returns
Type Description
Period

buildPartial()

public Period buildPartial()
Returns
Type Description
Period

clear()

public Period.Builder clear()
Returns
Type Description
Period.Builder
Overrides

clearDuration()

public Period.Builder clearDuration()

Total duration of Period Type defined.

int32 duration = 1;

Returns
Type Description
Period.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public Period.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
Period.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public Period.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
Period.Builder
Overrides

clearPeriodType()

public Period.Builder clearPeriodType()

Period Type.

.google.cloud.channel.v1.PeriodType period_type = 2;

Returns
Type Description
Period.Builder

This builder for chaining.

clone()

public Period.Builder clone()
Returns
Type Description
Period.Builder
Overrides

getDefaultInstanceForType()

public Period getDefaultInstanceForType()
Returns
Type Description
Period

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getDuration()

public int getDuration()

Total duration of Period Type defined.

int32 duration = 1;

Returns
Type Description
int

The duration.

getPeriodType()

public PeriodType getPeriodType()

Period Type.

.google.cloud.channel.v1.PeriodType period_type = 2;

Returns
Type Description
PeriodType

The periodType.

getPeriodTypeValue()

public int getPeriodTypeValue()

Period Type.

.google.cloud.channel.v1.PeriodType period_type = 2;

Returns
Type Description
int

The enum numeric value on the wire for periodType.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(Period other)

public Period.Builder mergeFrom(Period other)
Parameter
Name Description
other Period
Returns
Type Description
Period.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Period.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Period.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public Period.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
Period.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Period.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Period.Builder
Overrides

setDuration(int value)

public Period.Builder setDuration(int value)

Total duration of Period Type defined.

int32 duration = 1;

Parameter
Name Description
value int

The duration to set.

Returns
Type Description
Period.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public Period.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Period.Builder
Overrides

setPeriodType(PeriodType value)

public Period.Builder setPeriodType(PeriodType value)

Period Type.

.google.cloud.channel.v1.PeriodType period_type = 2;

Parameter
Name Description
value PeriodType

The periodType to set.

Returns
Type Description
Period.Builder

This builder for chaining.

setPeriodTypeValue(int value)

public Period.Builder setPeriodTypeValue(int value)

Period Type.

.google.cloud.channel.v1.PeriodType period_type = 2;

Parameter
Name Description
value int

The enum numeric value on the wire for periodType to set.

Returns
Type Description
Period.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public Period.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
Period.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final Period.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Period.Builder
Overrides