Google OR-Tools v9.12
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
RuinRecreateParameters.java
Go to the documentation of this file.
1// Generated by the protocol buffer compiler. DO NOT EDIT!
2// NO CHECKED-IN PROTOBUF GENCODE
3// source: ortools/constraint_solver/routing_ils.proto
4// Protobuf Java Version: 4.29.3
5
6package com.google.ortools.constraintsolver;
7
15public final class RuinRecreateParameters extends
16 com.google.protobuf.GeneratedMessage implements
17 // @@protoc_insertion_point(message_implements:operations_research.RuinRecreateParameters)
19private static final long serialVersionUID = 0L;
20 static {
21 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
22 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
23 /* major= */ 4,
24 /* minor= */ 29,
25 /* patch= */ 3,
26 /* suffix= */ "",
27 RuinRecreateParameters.class.getName());
28 }
29 // Use RuinRecreateParameters.newBuilder() to construct.
30 private RuinRecreateParameters(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
31 super(builder);
32 }
33 private RuinRecreateParameters() {
34 ruinStrategies_ = java.util.Collections.emptyList();
35 ruinCompositionStrategy_ = 0;
36 recreateStrategy_ = 0;
37 }
38
39 public static final com.google.protobuf.Descriptors.Descriptor
41 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_RuinRecreateParameters_descriptor;
42 }
43
44 @java.lang.Override
45 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
47 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_RuinRecreateParameters_fieldAccessorTable
48 .ensureFieldAccessorsInitialized(
49 com.google.ortools.constraintsolver.RuinRecreateParameters.class, com.google.ortools.constraintsolver.RuinRecreateParameters.Builder.class);
50 }
51
52 private int bitField0_;
53 public static final int RUIN_STRATEGIES_FIELD_NUMBER = 1;
54 @SuppressWarnings("serial")
55 private java.util.List<com.google.ortools.constraintsolver.RuinStrategy> ruinStrategies_;
63 @java.lang.Override
65 return ruinStrategies_;
66 }
67
74 @java.lang.Override
75 public java.util.List<? extends com.google.ortools.constraintsolver.RuinStrategyOrBuilder>
77 return ruinStrategies_;
78 }
79
86 @java.lang.Override
88 return ruinStrategies_.size();
89 }
90
97 @java.lang.Override
99 return ruinStrategies_.get(index);
100 }
101
108 @java.lang.Override
110 int index) {
111 return ruinStrategies_.get(index);
112 }
113
114 public static final int RUIN_COMPOSITION_STRATEGY_FIELD_NUMBER = 2;
115 private int ruinCompositionStrategy_ = 0;
125 @java.lang.Override public int getRuinCompositionStrategyValue() {
126 return ruinCompositionStrategy_;
127 }
128
138 com.google.ortools.constraintsolver.RuinCompositionStrategy.Value result = com.google.ortools.constraintsolver.RuinCompositionStrategy.Value.forNumber(ruinCompositionStrategy_);
140 }
141
142 public static final int RECREATE_STRATEGY_FIELD_NUMBER = 3;
143 private int recreateStrategy_ = 0;
152 @java.lang.Override public int getRecreateStrategyValue() {
153 return recreateStrategy_;
154 }
155
164 com.google.ortools.constraintsolver.FirstSolutionStrategy.Value result = com.google.ortools.constraintsolver.FirstSolutionStrategy.Value.forNumber(recreateStrategy_);
166 }
167
169 private double routeSelectionNeighborsRatio_ = 0D;
193 @java.lang.Override
195 return ((bitField0_ & 0x00000001) != 0);
196 }
197
220 @java.lang.Override
222 return routeSelectionNeighborsRatio_;
223 }
224
226 private int routeSelectionMinNeighbors_ = 0;
231 @java.lang.Override
233 return ((bitField0_ & 0x00000002) != 0);
234 }
235
239 @java.lang.Override
241 return routeSelectionMinNeighbors_;
242 }
243
245 private int routeSelectionMaxNeighbors_ = 0;
250 @java.lang.Override
252 return ((bitField0_ & 0x00000004) != 0);
253 }
254
258 @java.lang.Override
260 return routeSelectionMaxNeighbors_;
261 }
262
263 private byte memoizedIsInitialized = -1;
264 @java.lang.Override
265 public final boolean isInitialized() {
266 byte isInitialized = memoizedIsInitialized;
267 if (isInitialized == 1) return true;
268 if (isInitialized == 0) return false;
269
270 memoizedIsInitialized = 1;
271 return true;
272 }
273
274 @java.lang.Override
275 public void writeTo(com.google.protobuf.CodedOutputStream output)
276 throws java.io.IOException {
277 for (int i = 0; i < ruinStrategies_.size(); i++) {
278 output.writeMessage(1, ruinStrategies_.get(i));
279 }
280 if (ruinCompositionStrategy_ != com.google.ortools.constraintsolver.RuinCompositionStrategy.Value.UNSET.getNumber()) {
281 output.writeEnum(2, ruinCompositionStrategy_);
282 }
283 if (recreateStrategy_ != com.google.ortools.constraintsolver.FirstSolutionStrategy.Value.UNSET.getNumber()) {
284 output.writeEnum(3, recreateStrategy_);
285 }
286 if (((bitField0_ & 0x00000001) != 0)) {
287 output.writeDouble(4, routeSelectionNeighborsRatio_);
288 }
289 if (((bitField0_ & 0x00000002) != 0)) {
290 output.writeUInt32(5, routeSelectionMinNeighbors_);
291 }
292 if (((bitField0_ & 0x00000004) != 0)) {
293 output.writeUInt32(6, routeSelectionMaxNeighbors_);
294 }
295 getUnknownFields().writeTo(output);
296 }
297
298 @java.lang.Override
299 public int getSerializedSize() {
300 int size = memoizedSize;
301 if (size != -1) return size;
302
303 size = 0;
304 for (int i = 0; i < ruinStrategies_.size(); i++) {
305 size += com.google.protobuf.CodedOutputStream
306 .computeMessageSize(1, ruinStrategies_.get(i));
307 }
308 if (ruinCompositionStrategy_ != com.google.ortools.constraintsolver.RuinCompositionStrategy.Value.UNSET.getNumber()) {
309 size += com.google.protobuf.CodedOutputStream
310 .computeEnumSize(2, ruinCompositionStrategy_);
311 }
312 if (recreateStrategy_ != com.google.ortools.constraintsolver.FirstSolutionStrategy.Value.UNSET.getNumber()) {
313 size += com.google.protobuf.CodedOutputStream
314 .computeEnumSize(3, recreateStrategy_);
315 }
316 if (((bitField0_ & 0x00000001) != 0)) {
317 size += com.google.protobuf.CodedOutputStream
318 .computeDoubleSize(4, routeSelectionNeighborsRatio_);
319 }
320 if (((bitField0_ & 0x00000002) != 0)) {
321 size += com.google.protobuf.CodedOutputStream
322 .computeUInt32Size(5, routeSelectionMinNeighbors_);
323 }
324 if (((bitField0_ & 0x00000004) != 0)) {
325 size += com.google.protobuf.CodedOutputStream
326 .computeUInt32Size(6, routeSelectionMaxNeighbors_);
327 }
328 size += getUnknownFields().getSerializedSize();
329 memoizedSize = size;
330 return size;
331 }
332
333 @java.lang.Override
334 public boolean equals(final java.lang.Object obj) {
335 if (obj == this) {
336 return true;
337 }
338 if (!(obj instanceof com.google.ortools.constraintsolver.RuinRecreateParameters)) {
339 return super.equals(obj);
340 }
341 com.google.ortools.constraintsolver.RuinRecreateParameters other = (com.google.ortools.constraintsolver.RuinRecreateParameters) obj;
342
344 .equals(other.getRuinStrategiesList())) return false;
345 if (ruinCompositionStrategy_ != other.ruinCompositionStrategy_) return false;
346 if (recreateStrategy_ != other.recreateStrategy_) return false;
349 if (java.lang.Double.doubleToLongBits(getRouteSelectionNeighborsRatio())
350 != java.lang.Double.doubleToLongBits(
351 other.getRouteSelectionNeighborsRatio())) return false;
352 }
356 != other.getRouteSelectionMinNeighbors()) return false;
357 }
361 != other.getRouteSelectionMaxNeighbors()) return false;
362 }
363 if (!getUnknownFields().equals(other.getUnknownFields())) return false;
364 return true;
365 }
366
367 @java.lang.Override
368 public int hashCode() {
369 if (memoizedHashCode != 0) {
370 return memoizedHashCode;
371 }
372 int hash = 41;
373 hash = (19 * hash) + getDescriptor().hashCode();
374 if (getRuinStrategiesCount() > 0) {
375 hash = (37 * hash) + RUIN_STRATEGIES_FIELD_NUMBER;
376 hash = (53 * hash) + getRuinStrategiesList().hashCode();
377 }
378 hash = (37 * hash) + RUIN_COMPOSITION_STRATEGY_FIELD_NUMBER;
379 hash = (53 * hash) + ruinCompositionStrategy_;
380 hash = (37 * hash) + RECREATE_STRATEGY_FIELD_NUMBER;
381 hash = (53 * hash) + recreateStrategy_;
384 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
385 java.lang.Double.doubleToLongBits(getRouteSelectionNeighborsRatio()));
386 }
389 hash = (53 * hash) + getRouteSelectionMinNeighbors();
390 }
393 hash = (53 * hash) + getRouteSelectionMaxNeighbors();
394 }
395 hash = (29 * hash) + getUnknownFields().hashCode();
396 memoizedHashCode = hash;
397 return hash;
398 }
399
401 java.nio.ByteBuffer data)
402 throws com.google.protobuf.InvalidProtocolBufferException {
403 return PARSER.parseFrom(data);
404 }
406 java.nio.ByteBuffer data,
407 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
408 throws com.google.protobuf.InvalidProtocolBufferException {
409 return PARSER.parseFrom(data, extensionRegistry);
410 }
412 com.google.protobuf.ByteString data)
413 throws com.google.protobuf.InvalidProtocolBufferException {
414 return PARSER.parseFrom(data);
415 }
417 com.google.protobuf.ByteString data,
418 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
419 throws com.google.protobuf.InvalidProtocolBufferException {
420 return PARSER.parseFrom(data, extensionRegistry);
421 }
423 throws com.google.protobuf.InvalidProtocolBufferException {
424 return PARSER.parseFrom(data);
425 }
427 byte[] data,
428 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
429 throws com.google.protobuf.InvalidProtocolBufferException {
430 return PARSER.parseFrom(data, extensionRegistry);
431 }
433 throws java.io.IOException {
434 return com.google.protobuf.GeneratedMessage
435 .parseWithIOException(PARSER, input);
436 }
438 java.io.InputStream input,
439 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
440 throws java.io.IOException {
441 return com.google.protobuf.GeneratedMessage
442 .parseWithIOException(PARSER, input, extensionRegistry);
443 }
444
446 throws java.io.IOException {
447 return com.google.protobuf.GeneratedMessage
448 .parseDelimitedWithIOException(PARSER, input);
449 }
450
452 java.io.InputStream input,
453 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
454 throws java.io.IOException {
455 return com.google.protobuf.GeneratedMessage
456 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
457 }
459 com.google.protobuf.CodedInputStream input)
460 throws java.io.IOException {
461 return com.google.protobuf.GeneratedMessage
462 .parseWithIOException(PARSER, input);
463 }
465 com.google.protobuf.CodedInputStream input,
466 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
467 throws java.io.IOException {
468 return com.google.protobuf.GeneratedMessage
469 .parseWithIOException(PARSER, input, extensionRegistry);
470 }
471
472 @java.lang.Override
473 public Builder newBuilderForType() { return newBuilder(); }
474 public static Builder newBuilder() {
475 return DEFAULT_INSTANCE.toBuilder();
476 }
477 public static Builder newBuilder(com.google.ortools.constraintsolver.RuinRecreateParameters prototype) {
478 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
479 }
480 @java.lang.Override
482 return this == DEFAULT_INSTANCE
483 ? new Builder() : new Builder().mergeFrom(this);
484 }
485
486 @java.lang.Override
488 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
489 Builder builder = new Builder(parent);
490 return builder;
491 }
492
499 public static final class Builder extends
500 com.google.protobuf.GeneratedMessage.Builder<Builder> implements
501 // @@protoc_insertion_point(builder_implements:operations_research.RuinRecreateParameters)
503 public static final com.google.protobuf.Descriptors.Descriptor
505 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_RuinRecreateParameters_descriptor;
506 }
507
508 @java.lang.Override
509 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
511 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_RuinRecreateParameters_fieldAccessorTable
512 .ensureFieldAccessorsInitialized(
513 com.google.ortools.constraintsolver.RuinRecreateParameters.class, com.google.ortools.constraintsolver.RuinRecreateParameters.Builder.class);
514 }
515
516 // Construct using com.google.ortools.constraintsolver.RuinRecreateParameters.newBuilder()
517 private Builder() {
518
519 }
520
521 private Builder(
522 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
523 super(parent);
524
525 }
526 @java.lang.Override
527 public Builder clear() {
528 super.clear();
529 bitField0_ = 0;
530 if (ruinStrategiesBuilder_ == null) {
531 ruinStrategies_ = java.util.Collections.emptyList();
532 } else {
533 ruinStrategies_ = null;
534 ruinStrategiesBuilder_.clear();
535 }
536 bitField0_ = (bitField0_ & ~0x00000001);
537 ruinCompositionStrategy_ = 0;
538 recreateStrategy_ = 0;
539 routeSelectionNeighborsRatio_ = 0D;
540 routeSelectionMinNeighbors_ = 0;
541 routeSelectionMaxNeighbors_ = 0;
542 return this;
543 }
544
545 @java.lang.Override
546 public com.google.protobuf.Descriptors.Descriptor
548 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_RuinRecreateParameters_descriptor;
549 }
550
551 @java.lang.Override
553 return com.google.ortools.constraintsolver.RuinRecreateParameters.getDefaultInstance();
554 }
555
556 @java.lang.Override
559 if (!result.isInitialized()) {
560 throw newUninitializedMessageException(result);
561 }
562 return result;
563 }
564
565 @java.lang.Override
567 com.google.ortools.constraintsolver.RuinRecreateParameters result = new com.google.ortools.constraintsolver.RuinRecreateParameters(this);
568 buildPartialRepeatedFields(result);
569 if (bitField0_ != 0) { buildPartial0(result); }
570 onBuilt();
571 return result;
572 }
573
574 private void buildPartialRepeatedFields(com.google.ortools.constraintsolver.RuinRecreateParameters result) {
575 if (ruinStrategiesBuilder_ == null) {
576 if (((bitField0_ & 0x00000001) != 0)) {
577 ruinStrategies_ = java.util.Collections.unmodifiableList(ruinStrategies_);
578 bitField0_ = (bitField0_ & ~0x00000001);
579 }
580 result.ruinStrategies_ = ruinStrategies_;
581 } else {
582 result.ruinStrategies_ = ruinStrategiesBuilder_.build();
583 }
584 }
585
586 private void buildPartial0(com.google.ortools.constraintsolver.RuinRecreateParameters result) {
587 int from_bitField0_ = bitField0_;
588 if (((from_bitField0_ & 0x00000002) != 0)) {
589 result.ruinCompositionStrategy_ = ruinCompositionStrategy_;
590 }
591 if (((from_bitField0_ & 0x00000004) != 0)) {
592 result.recreateStrategy_ = recreateStrategy_;
593 }
594 int to_bitField0_ = 0;
595 if (((from_bitField0_ & 0x00000008) != 0)) {
596 result.routeSelectionNeighborsRatio_ = routeSelectionNeighborsRatio_;
597 to_bitField0_ |= 0x00000001;
598 }
599 if (((from_bitField0_ & 0x00000010) != 0)) {
600 result.routeSelectionMinNeighbors_ = routeSelectionMinNeighbors_;
601 to_bitField0_ |= 0x00000002;
602 }
603 if (((from_bitField0_ & 0x00000020) != 0)) {
604 result.routeSelectionMaxNeighbors_ = routeSelectionMaxNeighbors_;
605 to_bitField0_ |= 0x00000004;
606 }
607 result.bitField0_ |= to_bitField0_;
608 }
609
610 @java.lang.Override
611 public Builder mergeFrom(com.google.protobuf.Message other) {
612 if (other instanceof com.google.ortools.constraintsolver.RuinRecreateParameters) {
613 return mergeFrom((com.google.ortools.constraintsolver.RuinRecreateParameters)other);
614 } else {
615 super.mergeFrom(other);
616 return this;
617 }
618 }
619
620 public Builder mergeFrom(com.google.ortools.constraintsolver.RuinRecreateParameters other) {
621 if (other == com.google.ortools.constraintsolver.RuinRecreateParameters.getDefaultInstance()) return this;
622 if (ruinStrategiesBuilder_ == null) {
623 if (!other.ruinStrategies_.isEmpty()) {
624 if (ruinStrategies_.isEmpty()) {
625 ruinStrategies_ = other.ruinStrategies_;
626 bitField0_ = (bitField0_ & ~0x00000001);
627 } else {
628 ensureRuinStrategiesIsMutable();
629 ruinStrategies_.addAll(other.ruinStrategies_);
630 }
631 onChanged();
632 }
633 } else {
634 if (!other.ruinStrategies_.isEmpty()) {
635 if (ruinStrategiesBuilder_.isEmpty()) {
636 ruinStrategiesBuilder_.dispose();
637 ruinStrategiesBuilder_ = null;
638 ruinStrategies_ = other.ruinStrategies_;
639 bitField0_ = (bitField0_ & ~0x00000001);
640 ruinStrategiesBuilder_ =
641 com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
642 getRuinStrategiesFieldBuilder() : null;
643 } else {
644 ruinStrategiesBuilder_.addAllMessages(other.ruinStrategies_);
645 }
646 }
647 }
648 if (other.ruinCompositionStrategy_ != 0) {
649 setRuinCompositionStrategyValue(other.getRuinCompositionStrategyValue());
650 }
651 if (other.recreateStrategy_ != 0) {
652 setRecreateStrategyValue(other.getRecreateStrategyValue());
653 }
654 if (other.hasRouteSelectionNeighborsRatio()) {
655 setRouteSelectionNeighborsRatio(other.getRouteSelectionNeighborsRatio());
656 }
657 if (other.hasRouteSelectionMinNeighbors()) {
658 setRouteSelectionMinNeighbors(other.getRouteSelectionMinNeighbors());
659 }
660 if (other.hasRouteSelectionMaxNeighbors()) {
661 setRouteSelectionMaxNeighbors(other.getRouteSelectionMaxNeighbors());
662 }
663 this.mergeUnknownFields(other.getUnknownFields());
664 onChanged();
665 return this;
666 }
667
668 @java.lang.Override
669 public final boolean isInitialized() {
670 return true;
671 }
672
673 @java.lang.Override
674 public Builder mergeFrom(
675 com.google.protobuf.CodedInputStream input,
676 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
677 throws java.io.IOException {
678 if (extensionRegistry == null) {
679 throw new java.lang.NullPointerException();
680 }
681 try {
682 boolean done = false;
683 while (!done) {
684 int tag = input.readTag();
685 switch (tag) {
686 case 0:
687 done = true;
688 break;
689 case 10: {
691 input.readMessage(
692 com.google.ortools.constraintsolver.RuinStrategy.parser(),
693 extensionRegistry);
694 if (ruinStrategiesBuilder_ == null) {
695 ensureRuinStrategiesIsMutable();
696 ruinStrategies_.add(m);
697 } else {
698 ruinStrategiesBuilder_.addMessage(m);
699 }
700 break;
701 } // case 10
702 case 16: {
703 ruinCompositionStrategy_ = input.readEnum();
704 bitField0_ |= 0x00000002;
705 break;
706 } // case 16
707 case 24: {
708 recreateStrategy_ = input.readEnum();
709 bitField0_ |= 0x00000004;
710 break;
711 } // case 24
712 case 33: {
713 routeSelectionNeighborsRatio_ = input.readDouble();
714 bitField0_ |= 0x00000008;
715 break;
716 } // case 33
717 case 40: {
718 routeSelectionMinNeighbors_ = input.readUInt32();
719 bitField0_ |= 0x00000010;
720 break;
721 } // case 40
722 case 48: {
723 routeSelectionMaxNeighbors_ = input.readUInt32();
724 bitField0_ |= 0x00000020;
725 break;
726 } // case 48
727 default: {
728 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
729 done = true; // was an endgroup tag
730 }
731 break;
732 } // default:
733 } // switch (tag)
734 } // while (!done)
735 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
736 throw e.unwrapIOException();
737 } finally {
738 onChanged();
739 } // finally
740 return this;
741 }
742 private int bitField0_;
743
744 private java.util.List<com.google.ortools.constraintsolver.RuinStrategy> ruinStrategies_ =
745 java.util.Collections.emptyList();
746 private void ensureRuinStrategiesIsMutable() {
747 if (!((bitField0_ & 0x00000001) != 0)) {
748 ruinStrategies_ = new java.util.ArrayList<com.google.ortools.constraintsolver.RuinStrategy>(ruinStrategies_);
749 bitField0_ |= 0x00000001;
750 }
751 }
752
753 private com.google.protobuf.RepeatedFieldBuilder<
754 com.google.ortools.constraintsolver.RuinStrategy, com.google.ortools.constraintsolver.RuinStrategy.Builder, com.google.ortools.constraintsolver.RuinStrategyOrBuilder> ruinStrategiesBuilder_;
755
763 public java.util.List<com.google.ortools.constraintsolver.RuinStrategy> getRuinStrategiesList() {
764 if (ruinStrategiesBuilder_ == null) {
765 return java.util.Collections.unmodifiableList(ruinStrategies_);
766 } else {
767 return ruinStrategiesBuilder_.getMessageList();
768 }
769 }
770
778 if (ruinStrategiesBuilder_ == null) {
779 return ruinStrategies_.size();
780 } else {
781 return ruinStrategiesBuilder_.getCount();
782 }
783 }
784
792 if (ruinStrategiesBuilder_ == null) {
793 return ruinStrategies_.get(index);
794 } else {
795 return ruinStrategiesBuilder_.getMessage(index);
796 }
797 }
798
805 public Builder setRuinStrategies(
806 int index, com.google.ortools.constraintsolver.RuinStrategy value) {
807 if (ruinStrategiesBuilder_ == null) {
808 if (value == null) {
809 throw new NullPointerException();
810 }
811 ensureRuinStrategiesIsMutable();
812 ruinStrategies_.set(index, value);
813 onChanged();
814 } else {
815 ruinStrategiesBuilder_.setMessage(index, value);
816 }
817 return this;
818 }
819
826 public Builder setRuinStrategies(
827 int index, com.google.ortools.constraintsolver.RuinStrategy.Builder builderForValue) {
828 if (ruinStrategiesBuilder_ == null) {
829 ensureRuinStrategiesIsMutable();
830 ruinStrategies_.set(index, builderForValue.build());
831 onChanged();
832 } else {
833 ruinStrategiesBuilder_.setMessage(index, builderForValue.build());
834 }
835 return this;
836 }
837
844 public Builder addRuinStrategies(com.google.ortools.constraintsolver.RuinStrategy value) {
845 if (ruinStrategiesBuilder_ == null) {
846 if (value == null) {
847 throw new NullPointerException();
848 }
849 ensureRuinStrategiesIsMutable();
850 ruinStrategies_.add(value);
851 onChanged();
852 } else {
853 ruinStrategiesBuilder_.addMessage(value);
854 }
855 return this;
856 }
857
864 public Builder addRuinStrategies(
865 int index, com.google.ortools.constraintsolver.RuinStrategy value) {
866 if (ruinStrategiesBuilder_ == null) {
867 if (value == null) {
868 throw new NullPointerException();
869 }
870 ensureRuinStrategiesIsMutable();
871 ruinStrategies_.add(index, value);
872 onChanged();
873 } else {
874 ruinStrategiesBuilder_.addMessage(index, value);
875 }
876 return this;
877 }
878
885 public Builder addRuinStrategies(
886 com.google.ortools.constraintsolver.RuinStrategy.Builder builderForValue) {
887 if (ruinStrategiesBuilder_ == null) {
888 ensureRuinStrategiesIsMutable();
889 ruinStrategies_.add(builderForValue.build());
890 onChanged();
891 } else {
892 ruinStrategiesBuilder_.addMessage(builderForValue.build());
893 }
894 return this;
895 }
896
903 public Builder addRuinStrategies(
904 int index, com.google.ortools.constraintsolver.RuinStrategy.Builder builderForValue) {
905 if (ruinStrategiesBuilder_ == null) {
906 ensureRuinStrategiesIsMutable();
907 ruinStrategies_.add(index, builderForValue.build());
908 onChanged();
909 } else {
910 ruinStrategiesBuilder_.addMessage(index, builderForValue.build());
911 }
912 return this;
913 }
914
921 public Builder addAllRuinStrategies(
922 java.lang.Iterable<? extends com.google.ortools.constraintsolver.RuinStrategy> values) {
923 if (ruinStrategiesBuilder_ == null) {
924 ensureRuinStrategiesIsMutable();
925 com.google.protobuf.AbstractMessageLite.Builder.addAll(
926 values, ruinStrategies_);
927 onChanged();
928 } else {
929 ruinStrategiesBuilder_.addAllMessages(values);
930 }
931 return this;
932 }
933
940 public Builder clearRuinStrategies() {
941 if (ruinStrategiesBuilder_ == null) {
942 ruinStrategies_ = java.util.Collections.emptyList();
943 bitField0_ = (bitField0_ & ~0x00000001);
944 onChanged();
945 } else {
946 ruinStrategiesBuilder_.clear();
947 }
948 return this;
949 }
950
957 public Builder removeRuinStrategies(int index) {
958 if (ruinStrategiesBuilder_ == null) {
959 ensureRuinStrategiesIsMutable();
960 ruinStrategies_.remove(index);
961 onChanged();
962 } else {
963 ruinStrategiesBuilder_.remove(index);
964 }
965 return this;
966 }
967
975 int index) {
976 return getRuinStrategiesFieldBuilder().getBuilder(index);
977 }
978
986 int index) {
987 if (ruinStrategiesBuilder_ == null) {
988 return ruinStrategies_.get(index); } else {
989 return ruinStrategiesBuilder_.getMessageOrBuilder(index);
990 }
991 }
992
999 public java.util.List<? extends com.google.ortools.constraintsolver.RuinStrategyOrBuilder>
1001 if (ruinStrategiesBuilder_ != null) {
1002 return ruinStrategiesBuilder_.getMessageOrBuilderList();
1003 } else {
1004 return java.util.Collections.unmodifiableList(ruinStrategies_);
1005 }
1006 }
1007
1015 return getRuinStrategiesFieldBuilder().addBuilder(
1016 com.google.ortools.constraintsolver.RuinStrategy.getDefaultInstance());
1017 }
1018
1026 int index) {
1027 return getRuinStrategiesFieldBuilder().addBuilder(
1028 index, com.google.ortools.constraintsolver.RuinStrategy.getDefaultInstance());
1029 }
1030
1037 public java.util.List<com.google.ortools.constraintsolver.RuinStrategy.Builder>
1039 return getRuinStrategiesFieldBuilder().getBuilderList();
1040 }
1041 private com.google.protobuf.RepeatedFieldBuilder<
1042 com.google.ortools.constraintsolver.RuinStrategy, com.google.ortools.constraintsolver.RuinStrategy.Builder, com.google.ortools.constraintsolver.RuinStrategyOrBuilder>
1043 getRuinStrategiesFieldBuilder() {
1044 if (ruinStrategiesBuilder_ == null) {
1045 ruinStrategiesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
1046 com.google.ortools.constraintsolver.RuinStrategy, com.google.ortools.constraintsolver.RuinStrategy.Builder, com.google.ortools.constraintsolver.RuinStrategyOrBuilder>(
1047 ruinStrategies_,
1048 ((bitField0_ & 0x00000001) != 0),
1049 getParentForChildren(),
1050 isClean());
1051 ruinStrategies_ = null;
1052 }
1053 return ruinStrategiesBuilder_;
1054 }
1055
1056 private int ruinCompositionStrategy_ = 0;
1066 @java.lang.Override public int getRuinCompositionStrategyValue() {
1067 return ruinCompositionStrategy_;
1068 }
1069
1079 public Builder setRuinCompositionStrategyValue(int value) {
1080 ruinCompositionStrategy_ = value;
1081 bitField0_ |= 0x00000002;
1082 onChanged();
1083 return this;
1084 }
1085
1094 @java.lang.Override
1096 com.google.ortools.constraintsolver.RuinCompositionStrategy.Value result = com.google.ortools.constraintsolver.RuinCompositionStrategy.Value.forNumber(ruinCompositionStrategy_);
1098 }
1099
1109 public Builder setRuinCompositionStrategy(com.google.ortools.constraintsolver.RuinCompositionStrategy.Value value) {
1110 if (value == null) {
1111 throw new NullPointerException();
1112 }
1113 bitField0_ |= 0x00000002;
1114 ruinCompositionStrategy_ = value.getNumber();
1115 onChanged();
1116 return this;
1117 }
1118
1128 bitField0_ = (bitField0_ & ~0x00000002);
1129 ruinCompositionStrategy_ = 0;
1130 onChanged();
1131 return this;
1132 }
1133
1134 private int recreateStrategy_ = 0;
1143 @java.lang.Override public int getRecreateStrategyValue() {
1144 return recreateStrategy_;
1145 }
1146
1155 public Builder setRecreateStrategyValue(int value) {
1156 recreateStrategy_ = value;
1157 bitField0_ |= 0x00000004;
1158 onChanged();
1159 return this;
1160 }
1161
1169 @java.lang.Override
1171 com.google.ortools.constraintsolver.FirstSolutionStrategy.Value result = com.google.ortools.constraintsolver.FirstSolutionStrategy.Value.forNumber(recreateStrategy_);
1173 }
1174
1183 public Builder setRecreateStrategy(com.google.ortools.constraintsolver.FirstSolutionStrategy.Value value) {
1184 if (value == null) {
1185 throw new NullPointerException();
1186 }
1187 bitField0_ |= 0x00000004;
1188 recreateStrategy_ = value.getNumber();
1189 onChanged();
1190 return this;
1191 }
1192
1200 public Builder clearRecreateStrategy() {
1201 bitField0_ = (bitField0_ & ~0x00000004);
1202 recreateStrategy_ = 0;
1203 onChanged();
1204 return this;
1205 }
1206
1207 private double routeSelectionNeighborsRatio_ ;
1231 @java.lang.Override
1233 return ((bitField0_ & 0x00000008) != 0);
1234 }
1235
1258 @java.lang.Override
1260 return routeSelectionNeighborsRatio_;
1261 }
1262
1286 public Builder setRouteSelectionNeighborsRatio(double value) {
1287
1288 routeSelectionNeighborsRatio_ = value;
1289 bitField0_ |= 0x00000008;
1290 onChanged();
1291 return this;
1292 }
1293
1317 bitField0_ = (bitField0_ & ~0x00000008);
1318 routeSelectionNeighborsRatio_ = 0D;
1319 onChanged();
1320 return this;
1321 }
1322
1323 private int routeSelectionMinNeighbors_ ;
1328 @java.lang.Override
1330 return ((bitField0_ & 0x00000010) != 0);
1331 }
1332
1336 @java.lang.Override
1338 return routeSelectionMinNeighbors_;
1339 }
1340
1345 public Builder setRouteSelectionMinNeighbors(int value) {
1346
1347 routeSelectionMinNeighbors_ = value;
1348 bitField0_ |= 0x00000010;
1349 onChanged();
1350 return this;
1351 }
1352
1357 bitField0_ = (bitField0_ & ~0x00000010);
1358 routeSelectionMinNeighbors_ = 0;
1359 onChanged();
1360 return this;
1361 }
1362
1363 private int routeSelectionMaxNeighbors_ ;
1368 @java.lang.Override
1370 return ((bitField0_ & 0x00000020) != 0);
1371 }
1372
1376 @java.lang.Override
1378 return routeSelectionMaxNeighbors_;
1379 }
1380
1385 public Builder setRouteSelectionMaxNeighbors(int value) {
1386
1387 routeSelectionMaxNeighbors_ = value;
1388 bitField0_ |= 0x00000020;
1389 onChanged();
1390 return this;
1391 }
1392
1397 bitField0_ = (bitField0_ & ~0x00000020);
1398 routeSelectionMaxNeighbors_ = 0;
1399 onChanged();
1400 return this;
1401 }
1402
1403 // @@protoc_insertion_point(builder_scope:operations_research.RuinRecreateParameters)
1404 }
1405
1406 // @@protoc_insertion_point(class_scope:operations_research.RuinRecreateParameters)
1407 private static final com.google.ortools.constraintsolver.RuinRecreateParameters DEFAULT_INSTANCE;
1408 static {
1409 DEFAULT_INSTANCE = new com.google.ortools.constraintsolver.RuinRecreateParameters();
1410 }
1411
1413 return DEFAULT_INSTANCE;
1414 }
1415
1416 private static final com.google.protobuf.Parser<RuinRecreateParameters>
1417 PARSER = new com.google.protobuf.AbstractParser<RuinRecreateParameters>() {
1418 @java.lang.Override
1419 public RuinRecreateParameters parsePartialFrom(
1420 com.google.protobuf.CodedInputStream input,
1421 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1422 throws com.google.protobuf.InvalidProtocolBufferException {
1423 Builder builder = newBuilder();
1424 try {
1425 builder.mergeFrom(input, extensionRegistry);
1426 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
1427 throw e.setUnfinishedMessage(builder.buildPartial());
1428 } catch (com.google.protobuf.UninitializedMessageException e) {
1429 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
1430 } catch (java.io.IOException e) {
1431 throw new com.google.protobuf.InvalidProtocolBufferException(e)
1432 .setUnfinishedMessage(builder.buildPartial());
1433 }
1434 return builder.buildPartial();
1435 }
1436 };
1437
1438 public static com.google.protobuf.Parser<RuinRecreateParameters> parser() {
1439 return PARSER;
1440 }
1441
1442 @java.lang.Override
1443 public com.google.protobuf.Parser<RuinRecreateParameters> getParserForType() {
1444 return PARSER;
1445 }
1446
1447 @java.lang.Override
1451
1452}
1453
Builder addAllRuinStrategies(java.lang.Iterable<? extends com.google.ortools.constraintsolver.RuinStrategy > values)
com.google.ortools.constraintsolver.RuinRecreateParameters build()
com.google.ortools.constraintsolver.RuinStrategy.Builder addRuinStrategiesBuilder(int index)
Builder setRuinStrategies(int index, com.google.ortools.constraintsolver.RuinStrategy.Builder builderForValue)
Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
java.util.List< com.google.ortools.constraintsolver.RuinStrategy > getRuinStrategiesList()
java.util.List<? extends com.google.ortools.constraintsolver.RuinStrategyOrBuilder > getRuinStrategiesOrBuilderList()
Builder addRuinStrategies(int index, com.google.ortools.constraintsolver.RuinStrategy.Builder builderForValue)
java.util.List< com.google.ortools.constraintsolver.RuinStrategy.Builder > getRuinStrategiesBuilderList()
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
com.google.ortools.constraintsolver.RuinStrategy.Builder addRuinStrategiesBuilder()
com.google.ortools.constraintsolver.RuinStrategy getRuinStrategies(int index)
Builder setRuinStrategies(int index, com.google.ortools.constraintsolver.RuinStrategy value)
com.google.ortools.constraintsolver.RuinStrategyOrBuilder getRuinStrategiesOrBuilder(int index)
com.google.ortools.constraintsolver.RuinRecreateParameters buildPartial()
Builder addRuinStrategies(com.google.ortools.constraintsolver.RuinStrategy.Builder builderForValue)
com.google.ortools.constraintsolver.RuinStrategy.Builder getRuinStrategiesBuilder(int index)
com.google.ortools.constraintsolver.RuinRecreateParameters getDefaultInstanceForType()
Builder setRecreateStrategy(com.google.ortools.constraintsolver.FirstSolutionStrategy.Value value)
Builder addRuinStrategies(int index, com.google.ortools.constraintsolver.RuinStrategy value)
com.google.ortools.constraintsolver.FirstSolutionStrategy.Value getRecreateStrategy()
Builder addRuinStrategies(com.google.ortools.constraintsolver.RuinStrategy value)
Builder mergeFrom(com.google.ortools.constraintsolver.RuinRecreateParameters other)
com.google.ortools.constraintsolver.RuinCompositionStrategy.Value getRuinCompositionStrategy()
Builder setRuinCompositionStrategy(com.google.ortools.constraintsolver.RuinCompositionStrategy.Value value)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(java.nio.ByteBuffer data)
void writeTo(com.google.protobuf.CodedOutputStream output)
java.util.List<? extends com.google.ortools.constraintsolver.RuinStrategyOrBuilder > getRuinStrategiesOrBuilderList()
com.google.ortools.constraintsolver.FirstSolutionStrategy.Value getRecreateStrategy()
com.google.ortools.constraintsolver.RuinRecreateParameters getDefaultInstanceForType()
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(java.io.InputStream input)
static com.google.protobuf.Parser< RuinRecreateParameters > parser()
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
com.google.ortools.constraintsolver.RuinCompositionStrategy.Value getRuinCompositionStrategy()
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
java.util.List< com.google.ortools.constraintsolver.RuinStrategy > getRuinStrategiesList()
static Builder newBuilder(com.google.ortools.constraintsolver.RuinRecreateParameters prototype)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(com.google.protobuf.ByteString data)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(byte[] data)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseDelimitedFrom(java.io.InputStream input)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.ortools.constraintsolver.RuinStrategyOrBuilder getRuinStrategiesOrBuilder(int index)
static com.google.ortools.constraintsolver.RuinRecreateParameters getDefaultInstance()
com.google.ortools.constraintsolver.RuinStrategy getRuinStrategies(int index)
Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(com.google.protobuf.CodedInputStream input)
static com.google.ortools.constraintsolver.RuinRecreateParameters parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.protobuf.Parser< RuinRecreateParameters > getParserForType()