Class NoOverlapConstraintProto.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<NoOverlapConstraintProto.Builder>
com.google.protobuf.GeneratedMessage.Builder<NoOverlapConstraintProto.Builder>
com.google.ortools.sat.NoOverlapConstraintProto.Builder
All Implemented Interfaces:
NoOverlapConstraintProtoOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
NoOverlapConstraintProto

public static final class NoOverlapConstraintProto.Builder extends com.google.protobuf.GeneratedMessage.Builder<NoOverlapConstraintProto.Builder> implements NoOverlapConstraintProtoOrBuilder
 All the intervals (index of IntervalConstraintProto) must be disjoint. More
 formally, there must exist a sequence so that for each consecutive intervals,
 we have end_i <= start_{i+1}. In particular, intervals of size zero do matter
 for this constraint. This is also known as a disjunctive constraint in
 scheduling.
 
Protobuf type operations_research.sat.NoOverlapConstraintProto
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<NoOverlapConstraintProto.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.GeneratedMessage.Builder<NoOverlapConstraintProto.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.GeneratedMessage.Builder<NoOverlapConstraintProto.Builder>
    • getDefaultInstanceForType

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

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

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

      public NoOverlapConstraintProto.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<NoOverlapConstraintProto.Builder>
    • mergeFrom

    • isInitialized

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

      public NoOverlapConstraintProto.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws 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<NoOverlapConstraintProto.Builder>
      Throws:
      IOException
    • getIntervalsList

      public List<Integer> getIntervalsList()
      repeated int32 intervals = 1;
      Specified by:
      getIntervalsList in interface NoOverlapConstraintProtoOrBuilder
      Returns:
      A list containing the intervals.
    • getIntervalsCount

      public int getIntervalsCount()
      repeated int32 intervals = 1;
      Specified by:
      getIntervalsCount in interface NoOverlapConstraintProtoOrBuilder
      Returns:
      The count of intervals.
    • getIntervals

      public int getIntervals(int index)
      repeated int32 intervals = 1;
      Specified by:
      getIntervals in interface NoOverlapConstraintProtoOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The intervals at the given index.
    • setIntervals

      public NoOverlapConstraintProto.Builder setIntervals(int index, int value)
      repeated int32 intervals = 1;
      Parameters:
      index - The index to set the value at.
      value - The intervals to set.
      Returns:
      This builder for chaining.
    • addIntervals

      public NoOverlapConstraintProto.Builder addIntervals(int value)
      repeated int32 intervals = 1;
      Parameters:
      value - The intervals to add.
      Returns:
      This builder for chaining.
    • addAllIntervals

      public NoOverlapConstraintProto.Builder addAllIntervals(Iterable<? extends Integer> values)
      repeated int32 intervals = 1;
      Parameters:
      values - The intervals to add.
      Returns:
      This builder for chaining.
    • clearIntervals

      public NoOverlapConstraintProto.Builder clearIntervals()
      repeated int32 intervals = 1;
      Returns:
      This builder for chaining.