Class Period.Builder (3.41.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
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Period build()
Returns
TypeDescription
Period

buildPartial()

public Period buildPartial()
Returns
TypeDescription
Period

clear()

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

clearDuration()

public Period.Builder clearDuration()

Total duration of Period Type defined.

int32 duration = 1;

Returns
TypeDescription
Period.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearPeriodType()

public Period.Builder clearPeriodType()

Period Type.

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

Returns
TypeDescription
Period.Builder

This builder for chaining.

clone()

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

getDefaultInstanceForType()

public Period getDefaultInstanceForType()
Returns
TypeDescription
Period

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDuration()

public int getDuration()

Total duration of Period Type defined.

int32 duration = 1;

Returns
TypeDescription
int

The duration.

getPeriodType()

public PeriodType getPeriodType()

Period Type.

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

Returns
TypeDescription
PeriodType

The periodType.

getPeriodTypeValue()

public int getPeriodTypeValue()

Period Type.

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

Returns
TypeDescription
int

The enum numeric value on the wire for periodType.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(Period other)

public Period.Builder mergeFrom(Period other)
Parameter
NameDescription
otherPeriod
Returns
TypeDescription
Period.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Period.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Period.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Period.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Period.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Period.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Period.Builder
Overrides

setDuration(int value)

public Period.Builder setDuration(int value)

Total duration of Period Type defined.

int32 duration = 1;

Parameter
NameDescription
valueint

The duration to set.

Returns
TypeDescription
Period.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setPeriodType(PeriodType value)

public Period.Builder setPeriodType(PeriodType value)

Period Type.

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

Parameter
NameDescription
valuePeriodType

The periodType to set.

Returns
TypeDescription
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
NameDescription
valueint

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

Returns
TypeDescription
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
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Period.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final Period.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Period.Builder
Overrides