5package com.google.ortools.sat;
19 com.google.protobuf.GeneratedMessageV3 implements
22private static final long serialVersionUID = 0L;
28 intervals_ = emptyIntList();
32 @SuppressWarnings({
"unused"})
34 UnusedPrivateParameter unused) {
38 public static final com.google.protobuf.Descriptors.Descriptor
40 return com.google.ortools.sat.CpModelProtobuf.internal_static_operations_research_sat_NoOverlapConstraintProto_descriptor;
44 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
46 return com.google.ortools.sat.CpModelProtobuf.internal_static_operations_research_sat_NoOverlapConstraintProto_fieldAccessorTable
47 .ensureFieldAccessorsInitialized(
48 com.google.ortools.sat.NoOverlapConstraintProto.class, com.google.ortools.sat.NoOverlapConstraintProto.Builder.class);
52 @SuppressWarnings(
"serial")
53 private com.google.protobuf.Internal.IntList intervals_ =
60 public java.util.List<java.lang.Integer>
69 return intervals_.size();
77 return intervals_.getInt(index);
79 private int intervalsMemoizedSerializedSize = -1;
81 private byte memoizedIsInitialized = -1;
88 memoizedIsInitialized = 1;
93 public void writeTo(com.google.protobuf.CodedOutputStream output)
94 throws java.io.IOException {
97 output.writeUInt32NoTag(10);
98 output.writeUInt32NoTag(intervalsMemoizedSerializedSize);
100 for (
int i = 0; i < intervals_.size(); i++) {
101 output.writeInt32NoTag(intervals_.getInt(i));
103 getUnknownFields().writeTo(output);
108 int size = memoizedSize;
109 if (size != -1)
return size;
114 for (
int i = 0; i < intervals_.size(); i++) {
115 dataSize += com.google.protobuf.CodedOutputStream
116 .computeInt32SizeNoTag(intervals_.getInt(i));
121 size += com.google.protobuf.CodedOutputStream
122 .computeInt32SizeNoTag(dataSize);
124 intervalsMemoizedSerializedSize = dataSize;
126 size += getUnknownFields().getSerializedSize();
132 public boolean equals(
final java.lang.Object obj) {
136 if (!(obj instanceof com.google.ortools.sat.NoOverlapConstraintProto)) {
137 return super.equals(obj);
143 if (!getUnknownFields().equals(other.getUnknownFields()))
return false;
149 if (memoizedHashCode != 0) {
150 return memoizedHashCode;
158 hash = (29 * hash) + getUnknownFields().hashCode();
159 memoizedHashCode = hash;
164 java.nio.ByteBuffer data)
165 throws com.google.protobuf.InvalidProtocolBufferException {
166 return PARSER.parseFrom(data);
169 java.nio.ByteBuffer data,
170 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
171 throws com.google.protobuf.InvalidProtocolBufferException {
172 return PARSER.parseFrom(data, extensionRegistry);
175 com.google.protobuf.ByteString data)
176 throws com.google.protobuf.InvalidProtocolBufferException {
177 return PARSER.parseFrom(data);
180 com.google.protobuf.ByteString data,
181 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
182 throws com.google.protobuf.InvalidProtocolBufferException {
183 return PARSER.parseFrom(data, extensionRegistry);
186 throws com.google.protobuf.InvalidProtocolBufferException {
187 return PARSER.parseFrom(data);
191 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
192 throws com.google.protobuf.InvalidProtocolBufferException {
193 return PARSER.parseFrom(data, extensionRegistry);
196 throws java.io.IOException {
197 return com.google.protobuf.GeneratedMessageV3
198 .parseWithIOException(PARSER, input);
201 java.io.InputStream input,
202 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
203 throws java.io.IOException {
204 return com.google.protobuf.GeneratedMessageV3
205 .parseWithIOException(PARSER, input, extensionRegistry);
209 throws java.io.IOException {
210 return com.google.protobuf.GeneratedMessageV3
211 .parseDelimitedWithIOException(PARSER, input);
215 java.io.InputStream input,
216 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
217 throws java.io.IOException {
218 return com.google.protobuf.GeneratedMessageV3
219 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
222 com.google.protobuf.CodedInputStream input)
223 throws java.io.IOException {
224 return com.google.protobuf.GeneratedMessageV3
225 .parseWithIOException(PARSER, input);
228 com.google.protobuf.CodedInputStream input,
229 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
230 throws java.io.IOException {
231 return com.google.protobuf.GeneratedMessageV3
232 .parseWithIOException(PARSER, input, extensionRegistry);
245 return this == DEFAULT_INSTANCE
251 com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
267 com.google.protobuf.GeneratedMessageV3.
Builder<Builder> implements
270 public static final com.google.protobuf.Descriptors.Descriptor
272 return com.google.ortools.sat.CpModelProtobuf.internal_static_operations_research_sat_NoOverlapConstraintProto_descriptor;
276 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
278 return com.google.ortools.sat.CpModelProtobuf.internal_static_operations_research_sat_NoOverlapConstraintProto_fieldAccessorTable
279 .ensureFieldAccessorsInitialized(
280 com.google.ortools.sat.NoOverlapConstraintProto.class, com.google.ortools.sat.NoOverlapConstraintProto.Builder.class);
289 com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
297 intervals_ = emptyIntList();
302 public com.google.protobuf.Descriptors.Descriptor
304 return com.google.ortools.sat.CpModelProtobuf.internal_static_operations_research_sat_NoOverlapConstraintProto_descriptor;
309 return com.google.ortools.sat.NoOverlapConstraintProto.getDefaultInstance();
316 throw newUninitializedMessageException(result);
324 if (bitField0_ != 0) { buildPartial0(result); }
329 private void buildPartial0(com.google.ortools.sat.NoOverlapConstraintProto result) {
330 int from_bitField0_ = bitField0_;
331 if (((from_bitField0_ & 0x00000001) != 0)) {
332 intervals_.makeImmutable();
333 result.intervals_ = intervals_;
339 return super.
clone();
343 com.google.protobuf.Descriptors.FieldDescriptor field,
344 java.lang.Object value) {
345 return super.
setField(field, value);
349 com.google.protobuf.Descriptors.FieldDescriptor field) {
354 com.google.protobuf.Descriptors.OneofDescriptor oneof) {
359 com.google.protobuf.Descriptors.FieldDescriptor field,
360 int index, java.lang.Object value) {
365 com.google.protobuf.Descriptors.FieldDescriptor field,
366 java.lang.Object value) {
371 if (other instanceof com.google.ortools.sat.NoOverlapConstraintProto) {
372 return mergeFrom((com.google.ortools.sat.NoOverlapConstraintProto)other);
374 super.mergeFrom(other);
380 if (other == com.google.ortools.sat.NoOverlapConstraintProto.getDefaultInstance())
return this;
381 if (!other.intervals_.isEmpty()) {
382 if (intervals_.isEmpty()) {
383 intervals_ = other.intervals_;
384 intervals_.makeImmutable();
385 bitField0_ |= 0x00000001;
387 ensureIntervalsIsMutable();
388 intervals_.addAll(other.intervals_);
404 com.google.protobuf.CodedInputStream input,
405 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
406 throws java.io.IOException {
407 if (extensionRegistry ==
null) {
408 throw new java.lang.NullPointerException();
411 boolean done =
false;
413 int tag = input.readTag();
419 int v = input.readInt32();
420 ensureIntervalsIsMutable();
421 intervals_.addInt(v);
425 int length = input.readRawVarint32();
426 int limit = input.pushLimit(length);
427 ensureIntervalsIsMutable();
428 while (input.getBytesUntilLimit() > 0) {
429 intervals_.addInt(input.readInt32());
431 input.popLimit(limit);
435 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
442 }
catch (com.google.protobuf.InvalidProtocolBufferException e) {
443 throw e.unwrapIOException();
449 private int bitField0_;
451 private com.google.protobuf.Internal.IntList intervals_ = emptyIntList();
452 private void ensureIntervalsIsMutable() {
453 if (!intervals_.isModifiable()) {
454 intervals_ = makeMutableCopy(intervals_);
456 bitField0_ |= 0x00000001;
462 public java.util.List<java.lang.Integer>
464 intervals_.makeImmutable();
472 return intervals_.size();
480 return intervals_.getInt(index);
489 int index,
int value) {
491 ensureIntervalsIsMutable();
492 intervals_.setInt(index, value);
493 bitField0_ |= 0x00000001;
504 ensureIntervalsIsMutable();
505 intervals_.addInt(value);
506 bitField0_ |= 0x00000001;
516 java.lang.Iterable<? extends java.lang.Integer> values) {
517 ensureIntervalsIsMutable();
518 com.google.protobuf.AbstractMessageLite.Builder.addAll(
520 bitField0_ |= 0x00000001;
529 intervals_ = emptyIntList();
530 bitField0_ = (bitField0_ & ~0x00000001);
536 final com.google.protobuf.UnknownFieldSet unknownFields) {
542 final com.google.protobuf.UnknownFieldSet unknownFields) {
553 DEFAULT_INSTANCE =
new com.google.ortools.sat.NoOverlapConstraintProto();
557 return DEFAULT_INSTANCE;
564 com.google.protobuf.CodedInputStream input,
565 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
566 throws com.google.protobuf.InvalidProtocolBufferException {
569 builder.mergeFrom(input, extensionRegistry);
570 }
catch (com.google.protobuf.InvalidProtocolBufferException e) {
571 throw e.setUnfinishedMessage(builder.buildPartial());
572 }
catch (com.google.protobuf.UninitializedMessageException e) {
573 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
574 }
catch (java.io.IOException e) {
575 throw new com.google.protobuf.InvalidProtocolBufferException(e)
576 .setUnfinishedMessage(builder.buildPartial());
578 return builder.buildPartial();
593 return DEFAULT_INSTANCE;