- 1.83.0 (latest)
- 1.81.0
- 1.80.0
- 1.78.0
- 1.76.0
- 1.74.0
- 1.73.0
- 1.72.0
- 1.71.0
- 1.70.0
- 1.68.0
- 1.66.0
- 1.65.0
- 1.62.0
- 1.61.0
- 1.60.0
- 1.58.0
- 1.57.0
- 1.56.0
- 1.55.0
- 1.54.0
- 1.53.0
- 1.52.0
- 1.51.0
- 1.50.0
- 1.49.0
- 1.47.0
- 1.46.0
- 1.45.0
- 1.44.0
- 1.43.0
- 1.42.0
- 1.41.0
- 1.40.0
- 1.39.0
- 1.38.0
- 1.37.0
- 1.35.0
- 1.34.0
- 1.33.0
- 1.32.0
- 1.31.0
- 1.30.0
- 1.29.0
- 1.28.0
- 1.27.0
- 1.26.0
- 1.25.0
- 1.22.0
- 1.21.0
- 1.20.0
- 1.19.0
- 1.18.0
- 1.17.0
- 1.16.0
- 1.15.0
- 1.14.0
- 1.13.0
- 1.12.0
- 1.11.0
- 1.10.0
- 1.9.0
- 1.7.0
- 1.6.0
- 1.5.0
- 1.4.0
- 1.3.0
- 1.2.0
- 1.1.14
- 0.1.2
public static final class BreakRule.FrequencyConstraint.Builder extends GeneratedMessage.Builder<BreakRule.FrequencyConstraint.Builder> implements BreakRule.FrequencyConstraintOrBuilder One may further constrain the frequency and duration of the breaks
specified above, by enforcing a minimum break frequency, such as
"There must be a break of at least 1 hour every 12 hours". Assuming that
this can be interpreted as "Within any sliding time window of 12h, there
must be at least one break of at least one hour", that example would
translate to the following FrequencyConstraint:
`
{
min_break_duration { seconds: 3600 } # 1 hour.
max_inter_break_duration { seconds: 39600 } # 11 hours (12 - 1 = 11).
}
The timing and duration of the breaks in the solution will respect all
such constraints, in addition to the time windows and minimum durations
already specified in the BreakRequest.
A FrequencyConstraint may in practice apply to non-consecutive breaks.
For example, the following schedule honors the "1h every 12h" example:
`
04:00 vehicle start
.. performing travel and visits ..
09:00 1 hour break
10:00 end of the break
.. performing travel and visits ..
12:00 20-min lunch break
12:20 end of the break
.. performing travel and visits ..
21:00 1 hour break
22:00 end of the break
.. performing travel and visits ..
23:59 vehicle end
Protobuf type google.cloud.optimization.v1.BreakRule.FrequencyConstraint
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > BreakRule.FrequencyConstraint.BuilderImplements
BreakRule.FrequencyConstraintOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public BreakRule.FrequencyConstraint build()| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint |
|
buildPartial()
public BreakRule.FrequencyConstraint buildPartial()| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint |
|
clear()
public BreakRule.FrequencyConstraint.Builder clear()| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
clearMaxInterBreakDuration()
public BreakRule.FrequencyConstraint.Builder clearMaxInterBreakDuration() Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
clearMinBreakDuration()
public BreakRule.FrequencyConstraint.Builder clearMinBreakDuration() Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
getDefaultInstanceForType()
public BreakRule.FrequencyConstraint getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getMaxInterBreakDuration()
public Duration getMaxInterBreakDuration() Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Duration |
The maxInterBreakDuration. |
getMaxInterBreakDurationBuilder()
public Duration.Builder getMaxInterBreakDurationBuilder() Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Builder |
|
getMaxInterBreakDurationOrBuilder()
public DurationOrBuilder getMaxInterBreakDurationOrBuilder() Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
DurationOrBuilder |
|
getMinBreakDuration()
public Duration getMinBreakDuration() Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Duration |
The minBreakDuration. |
getMinBreakDurationBuilder()
public Duration.Builder getMinBreakDurationBuilder() Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Builder |
|
getMinBreakDurationOrBuilder()
public DurationOrBuilder getMinBreakDurationOrBuilder() Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
DurationOrBuilder |
|
hasMaxInterBreakDuration()
public boolean hasMaxInterBreakDuration() Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the maxInterBreakDuration field is set. |
hasMinBreakDuration()
public boolean hasMinBreakDuration() Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the minBreakDuration field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(BreakRule.FrequencyConstraint other)
public BreakRule.FrequencyConstraint.Builder mergeFrom(BreakRule.FrequencyConstraint other)| Parameter | |
|---|---|
| Name | Description |
other |
BreakRule.FrequencyConstraint |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public BreakRule.FrequencyConstraint.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public BreakRule.FrequencyConstraint.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
mergeMaxInterBreakDuration(Duration value)
public BreakRule.FrequencyConstraint.Builder mergeMaxInterBreakDuration(Duration value) Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
Duration |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
mergeMinBreakDuration(Duration value)
public BreakRule.FrequencyConstraint.Builder mergeMinBreakDuration(Duration value) Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
Duration |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
setMaxInterBreakDuration(Duration value)
public BreakRule.FrequencyConstraint.Builder setMaxInterBreakDuration(Duration value) Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
Duration |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
setMaxInterBreakDuration(Duration.Builder builderForValue)
public BreakRule.FrequencyConstraint.Builder setMaxInterBreakDuration(Duration.Builder builderForValue) Required. Maximum allowed span of any interval of time in the route that
does not include at least partially a break of duration >=
min_break_duration. Must be positive.
.google.protobuf.Duration max_inter_break_duration = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
Builder |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
setMinBreakDuration(Duration value)
public BreakRule.FrequencyConstraint.Builder setMinBreakDuration(Duration value) Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
Duration |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|
setMinBreakDuration(Duration.Builder builderForValue)
public BreakRule.FrequencyConstraint.Builder setMinBreakDuration(Duration.Builder builderForValue) Required. Minimum break duration for this constraint. Nonnegative.
See description of FrequencyConstraint.
.google.protobuf.Duration min_break_duration = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
Builder |
| Returns | |
|---|---|
| Type | Description |
BreakRule.FrequencyConstraint.Builder |
|