Class Condition.TimeRange.Builder (2.6.0)

See more code actions.
public static final class Condition.TimeRange.Builder extends GeneratedMessageV3.Builder<Condition.TimeRange.Builder> implements Condition.TimeRangeOrBuilder

Used for time-dependent conditions. Example: Want to have rule applied for week long sale.

Protobuf type google.cloud.retail.v2.Condition.TimeRange

com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Condition.TimeRange build()
Returns
TypeDescription
Condition.TimeRange

buildPartial()

public Condition.TimeRange buildPartial()
Returns
TypeDescription
Condition.TimeRange

clear()

public Condition.TimeRange.Builder clear()
Returns Overrides

clearEndTime()

public Condition.TimeRange.Builder clearEndTime()

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Returns

clearField(Descriptors.FieldDescriptor field)

public Condition.TimeRange.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public Condition.TimeRange.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns Overrides

clearStartTime()

public Condition.TimeRange.Builder clearStartTime()

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Returns

clone()

public Condition.TimeRange.Builder clone()
Returns Overrides

getDefaultInstanceForType()

public Condition.TimeRange getDefaultInstanceForType()
Returns
TypeDescription
Condition.TimeRange

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getEndTime()

public Timestamp getEndTime()

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Returns
TypeDescription
Timestamp

The endTime.

getEndTimeBuilder()

public Timestamp.Builder getEndTimeBuilder()

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Returns
TypeDescription
Builder

getEndTimeOrBuilder()

public TimestampOrBuilder getEndTimeOrBuilder()

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Returns
TypeDescription
TimestampOrBuilder

getStartTime()

public Timestamp getStartTime()

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Returns
TypeDescription
Timestamp

The startTime.

getStartTimeBuilder()

public Timestamp.Builder getStartTimeBuilder()

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Returns
TypeDescription
Builder

getStartTimeOrBuilder()

public TimestampOrBuilder getStartTimeOrBuilder()

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Returns
TypeDescription
TimestampOrBuilder

hasEndTime()

public boolean hasEndTime()

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Returns
TypeDescription
boolean

Whether the endTime field is set.

hasStartTime()

public boolean hasStartTime()

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Returns
TypeDescription
boolean

Whether the startTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeEndTime(Timestamp value)

public Condition.TimeRange.Builder mergeEndTime(Timestamp value)

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Parameter
NameDescription
valueTimestamp
Returns

mergeFrom(Condition.TimeRange other)

public Condition.TimeRange.Builder mergeFrom(Condition.TimeRange other)
Parameter
NameDescription
otherCondition.TimeRange
Returns

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

public Condition.TimeRange.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns Overrides

mergeStartTime(Timestamp value)

public Condition.TimeRange.Builder mergeStartTime(Timestamp value)

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Parameter
NameDescription
valueTimestamp
Returns

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Condition.TimeRange.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns Overrides

setEndTime(Timestamp value)

public Condition.TimeRange.Builder setEndTime(Timestamp value)

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Parameter
NameDescription
valueTimestamp
Returns

setEndTime(Timestamp.Builder builderForValue)

public Condition.TimeRange.Builder setEndTime(Timestamp.Builder builderForValue)

End of time range. Range is inclusive.

.google.protobuf.Timestamp end_time = 2;

Parameter
NameDescription
builderForValueBuilder
Returns

setField(Descriptors.FieldDescriptor field, Object value)

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

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

public Condition.TimeRange.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns Overrides

setStartTime(Timestamp value)

public Condition.TimeRange.Builder setStartTime(Timestamp value)

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Parameter
NameDescription
valueTimestamp
Returns

setStartTime(Timestamp.Builder builderForValue)

public Condition.TimeRange.Builder setStartTime(Timestamp.Builder builderForValue)

Start of time range. Range is inclusive.

.google.protobuf.Timestamp start_time = 1;

Parameter
NameDescription
builderForValueBuilder
Returns

setUnknownFields(UnknownFieldSet unknownFields)

public final Condition.TimeRange.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns Overrides