Class IntervalConstraintProto.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderType>
com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
com.google.ortools.sat.IntervalConstraintProto.Builder
All Implemented Interfaces:
IntervalConstraintProtoOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, java.lang.Cloneable
Enclosing class:
IntervalConstraintProto

public static final class IntervalConstraintProto.Builder
extends com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
implements IntervalConstraintProtoOrBuilder
 This "special" constraint not only enforces (start + size == end) and (size
 >= 0) but can also be referred by other constraints using this "interval"
 concept.
 
Protobuf type operations_research.sat.IntervalConstraintProto
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • getDefaultInstanceForType

      public IntervalConstraintProto getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public IntervalConstraintProto build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public IntervalConstraintProto buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • clone

      Specified by:
      clone in interface com.google.protobuf.Message.Builder
      Specified by:
      clone in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clone in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • setField

      public IntervalConstraintProto.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
      Specified by:
      setField in interface com.google.protobuf.Message.Builder
      Overrides:
      setField in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • clearField

      public IntervalConstraintProto.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
      Specified by:
      clearField in interface com.google.protobuf.Message.Builder
      Overrides:
      clearField in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • clearOneof

      public IntervalConstraintProto.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
      Specified by:
      clearOneof in interface com.google.protobuf.Message.Builder
      Overrides:
      clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • setRepeatedField

      public IntervalConstraintProto.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)
      Specified by:
      setRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • addRepeatedField

      public IntervalConstraintProto.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • mergeFrom

      public IntervalConstraintProto.Builder mergeFrom​(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<IntervalConstraintProto.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • mergeFrom

      public IntervalConstraintProto.Builder mergeFrom​(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<IntervalConstraintProto.Builder>
      Throws:
      java.io.IOException
    • getStart

      public int getStart()
      int32 start = 1;
      Specified by:
      getStart in interface IntervalConstraintProtoOrBuilder
      Returns:
      The start.
    • setStart

      public IntervalConstraintProto.Builder setStart​(int value)
      int32 start = 1;
      Parameters:
      value - The start to set.
      Returns:
      This builder for chaining.
    • clearStart

      public IntervalConstraintProto.Builder clearStart()
      int32 start = 1;
      Returns:
      This builder for chaining.
    • getEnd

      public int getEnd()
      int32 end = 2;
      Specified by:
      getEnd in interface IntervalConstraintProtoOrBuilder
      Returns:
      The end.
    • setEnd

      public IntervalConstraintProto.Builder setEnd​(int value)
      int32 end = 2;
      Parameters:
      value - The end to set.
      Returns:
      This builder for chaining.
    • clearEnd

      int32 end = 2;
      Returns:
      This builder for chaining.
    • getSize

      public int getSize()
      int32 size = 3;
      Specified by:
      getSize in interface IntervalConstraintProtoOrBuilder
      Returns:
      The size.
    • setSize

      public IntervalConstraintProto.Builder setSize​(int value)
      int32 size = 3;
      Parameters:
      value - The size to set.
      Returns:
      This builder for chaining.
    • clearSize

      public IntervalConstraintProto.Builder clearSize()
      int32 size = 3;
      Returns:
      This builder for chaining.
    • hasStartView

      public boolean hasStartView()
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
      Specified by:
      hasStartView in interface IntervalConstraintProtoOrBuilder
      Returns:
      Whether the startView field is set.
    • getStartView

      public LinearExpressionProto getStartView()
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
      Specified by:
      getStartView in interface IntervalConstraintProtoOrBuilder
      Returns:
      The startView.
    • setStartView

       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
    • setStartView

      public IntervalConstraintProto.Builder setStartView​(LinearExpressionProto.Builder builderForValue)
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
    • mergeStartView

      public IntervalConstraintProto.Builder mergeStartView​(LinearExpressionProto value)
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
    • clearStartView

      public IntervalConstraintProto.Builder clearStartView()
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
    • getStartViewBuilder

      public LinearExpressionProto.Builder getStartViewBuilder()
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
    • getStartViewOrBuilder

      public LinearExpressionProtoOrBuilder getStartViewOrBuilder()
       EXPERIMENTAL: This will become the new way to specify an interval.
       Depending on the parameters, the presolve will convert the old way to the
       new way. Do not forget to add an associated linear constraint if you use
       this directly.
       If any of this field is set, then all must be set and the ones above will
       be ignored.
       IMPORTANT: For now, this constraint do not enforce any relations on the
       view, and a linear constraint must be added together with this to enforce
       enforcement => start_view + size_view == end_view. An enforcement =>
       size_view >=0 might also be needed.
       IMPORTANT: For now, we just support affine relation. We could easily
       create an intermediate variable to support full linear expression, but this
       isn't done currently.
       
      .operations_research.sat.LinearExpressionProto start_view = 4;
      Specified by:
      getStartViewOrBuilder in interface IntervalConstraintProtoOrBuilder
    • hasEndView

      public boolean hasEndView()
      .operations_research.sat.LinearExpressionProto end_view = 5;
      Specified by:
      hasEndView in interface IntervalConstraintProtoOrBuilder
      Returns:
      Whether the endView field is set.
    • getEndView

      public LinearExpressionProto getEndView()
      .operations_research.sat.LinearExpressionProto end_view = 5;
      Specified by:
      getEndView in interface IntervalConstraintProtoOrBuilder
      Returns:
      The endView.
    • setEndView

      .operations_research.sat.LinearExpressionProto end_view = 5;
    • setEndView

      public IntervalConstraintProto.Builder setEndView​(LinearExpressionProto.Builder builderForValue)
      .operations_research.sat.LinearExpressionProto end_view = 5;
    • mergeEndView

      .operations_research.sat.LinearExpressionProto end_view = 5;
    • clearEndView

      public IntervalConstraintProto.Builder clearEndView()
      .operations_research.sat.LinearExpressionProto end_view = 5;
    • getEndViewBuilder

      public LinearExpressionProto.Builder getEndViewBuilder()
      .operations_research.sat.LinearExpressionProto end_view = 5;
    • getEndViewOrBuilder

      public LinearExpressionProtoOrBuilder getEndViewOrBuilder()
      .operations_research.sat.LinearExpressionProto end_view = 5;
      Specified by:
      getEndViewOrBuilder in interface IntervalConstraintProtoOrBuilder
    • hasSizeView

      public boolean hasSizeView()
      .operations_research.sat.LinearExpressionProto size_view = 6;
      Specified by:
      hasSizeView in interface IntervalConstraintProtoOrBuilder
      Returns:
      Whether the sizeView field is set.
    • getSizeView

      public LinearExpressionProto getSizeView()
      .operations_research.sat.LinearExpressionProto size_view = 6;
      Specified by:
      getSizeView in interface IntervalConstraintProtoOrBuilder
      Returns:
      The sizeView.
    • setSizeView

      .operations_research.sat.LinearExpressionProto size_view = 6;
    • setSizeView

      public IntervalConstraintProto.Builder setSizeView​(LinearExpressionProto.Builder builderForValue)
      .operations_research.sat.LinearExpressionProto size_view = 6;
    • mergeSizeView

      public IntervalConstraintProto.Builder mergeSizeView​(LinearExpressionProto value)
      .operations_research.sat.LinearExpressionProto size_view = 6;
    • clearSizeView

      public IntervalConstraintProto.Builder clearSizeView()
      .operations_research.sat.LinearExpressionProto size_view = 6;
    • getSizeViewBuilder

      public LinearExpressionProto.Builder getSizeViewBuilder()
      .operations_research.sat.LinearExpressionProto size_view = 6;
    • getSizeViewOrBuilder

      public LinearExpressionProtoOrBuilder getSizeViewOrBuilder()
      .operations_research.sat.LinearExpressionProto size_view = 6;
      Specified by:
      getSizeViewOrBuilder in interface IntervalConstraintProtoOrBuilder
    • setUnknownFields

      public final IntervalConstraintProto.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      setUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>
    • mergeUnknownFields

      public final IntervalConstraintProto.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
      Specified by:
      mergeUnknownFields in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<IntervalConstraintProto.Builder>