Google OR-Tools v9.14
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
MPVariableProto.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/linear_solver/linear_solver.proto
4// Protobuf Java Version: 4.31.1
5
6package com.google.ortools.linearsolver;
7
27@com.google.protobuf.Generated
28public final class MPVariableProto extends
29 com.google.protobuf.GeneratedMessage implements
30 // @@protoc_insertion_point(message_implements:operations_research.MPVariableProto)
32private static final long serialVersionUID = 0L;
33 static {
34 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
35 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
36 /* major= */ 4,
37 /* minor= */ 31,
38 /* patch= */ 1,
39 /* suffix= */ "",
40 MPVariableProto.class.getName());
41 }
42 // Use MPVariableProto.newBuilder() to construct.
43 private MPVariableProto(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
44 super(builder);
45 }
46 private MPVariableProto() {
47 lowerBound_ = Double.NEGATIVE_INFINITY;
48 upperBound_ = Double.POSITIVE_INFINITY;
49 name_ = "";
50 }
51
52 public static final com.google.protobuf.Descriptors.Descriptor
54 return com.google.ortools.linearsolver.LinearSolver.internal_static_operations_research_MPVariableProto_descriptor;
55 }
56
57 @java.lang.Override
58 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
60 return com.google.ortools.linearsolver.LinearSolver.internal_static_operations_research_MPVariableProto_fieldAccessorTable
61 .ensureFieldAccessorsInitialized(
62 com.google.ortools.linearsolver.MPVariableProto.class, com.google.ortools.linearsolver.MPVariableProto.Builder.class);
63 }
64
65 private int bitField0_;
66 public static final int LOWER_BOUND_FIELD_NUMBER = 1;
67 private double lowerBound_ = Double.NEGATIVE_INFINITY;
76 @java.lang.Override
77 public boolean hasLowerBound() {
78 return ((bitField0_ & 0x00000001) != 0);
79 }
80
88 @java.lang.Override
89 public double getLowerBound() {
90 return lowerBound_;
91 }
92
93 public static final int UPPER_BOUND_FIELD_NUMBER = 2;
94 private double upperBound_ = Double.POSITIVE_INFINITY;
99 @java.lang.Override
100 public boolean hasUpperBound() {
101 return ((bitField0_ & 0x00000002) != 0);
102 }
103
107 @java.lang.Override
108 public double getUpperBound() {
109 return upperBound_;
110 }
111
112 public static final int OBJECTIVE_COEFFICIENT_FIELD_NUMBER = 3;
113 private double objectiveCoefficient_ = 0D;
122 @java.lang.Override
123 public boolean hasObjectiveCoefficient() {
124 return ((bitField0_ & 0x00000004) != 0);
125 }
126
134 @java.lang.Override
135 public double getObjectiveCoefficient() {
136 return objectiveCoefficient_;
137 }
138
139 public static final int IS_INTEGER_FIELD_NUMBER = 4;
140 private boolean isInteger_ = false;
150 @java.lang.Override
151 public boolean hasIsInteger() {
152 return ((bitField0_ & 0x00000008) != 0);
153 }
154
163 @java.lang.Override
164 public boolean getIsInteger() {
165 return isInteger_;
166 }
167
168 public static final int NAME_FIELD_NUMBER = 5;
169 @SuppressWarnings("serial")
170 private volatile java.lang.Object name_ = "";
179 @java.lang.Override
180 public boolean hasName() {
181 return ((bitField0_ & 0x00000010) != 0);
182 }
183
191 @java.lang.Override
192 public java.lang.String getName() {
193 java.lang.Object ref = name_;
194 if (ref instanceof java.lang.String) {
195 return (java.lang.String) ref;
196 } else {
197 com.google.protobuf.ByteString bs =
198 (com.google.protobuf.ByteString) ref;
199 java.lang.String s = bs.toStringUtf8();
200 if (bs.isValidUtf8()) {
201 name_ = s;
202 }
203 return s;
204 }
205 }
206
214 @java.lang.Override
215 public com.google.protobuf.ByteString
217 java.lang.Object ref = name_;
218 if (ref instanceof java.lang.String) {
219 com.google.protobuf.ByteString b =
220 com.google.protobuf.ByteString.copyFromUtf8(
221 (java.lang.String) ref);
222 name_ = b;
223 return b;
224 } else {
225 return (com.google.protobuf.ByteString) ref;
226 }
227 }
228
229 public static final int BRANCHING_PRIORITY_FIELD_NUMBER = 6;
230 private int branchingPriority_ = 0;
235 @java.lang.Override
236 public boolean hasBranchingPriority() {
237 return ((bitField0_ & 0x00000020) != 0);
238 }
239
243 @java.lang.Override
244 public int getBranchingPriority() {
245 return branchingPriority_;
246 }
247
248 private byte memoizedIsInitialized = -1;
249 @java.lang.Override
250 public final boolean isInitialized() {
251 byte isInitialized = memoizedIsInitialized;
252 if (isInitialized == 1) return true;
253 if (isInitialized == 0) return false;
254
255 memoizedIsInitialized = 1;
256 return true;
257 }
258
259 @java.lang.Override
260 public void writeTo(com.google.protobuf.CodedOutputStream output)
261 throws java.io.IOException {
262 if (((bitField0_ & 0x00000001) != 0)) {
263 output.writeDouble(1, lowerBound_);
264 }
265 if (((bitField0_ & 0x00000002) != 0)) {
266 output.writeDouble(2, upperBound_);
267 }
268 if (((bitField0_ & 0x00000004) != 0)) {
269 output.writeDouble(3, objectiveCoefficient_);
270 }
271 if (((bitField0_ & 0x00000008) != 0)) {
272 output.writeBool(4, isInteger_);
273 }
274 if (((bitField0_ & 0x00000010) != 0)) {
275 com.google.protobuf.GeneratedMessage.writeString(output, 5, name_);
276 }
277 if (((bitField0_ & 0x00000020) != 0)) {
278 output.writeInt32(6, branchingPriority_);
279 }
280 getUnknownFields().writeTo(output);
281 }
282
283 @java.lang.Override
284 public int getSerializedSize() {
285 int size = memoizedSize;
286 if (size != -1) return size;
287
288 size = 0;
289 if (((bitField0_ & 0x00000001) != 0)) {
290 size += com.google.protobuf.CodedOutputStream
291 .computeDoubleSize(1, lowerBound_);
292 }
293 if (((bitField0_ & 0x00000002) != 0)) {
294 size += com.google.protobuf.CodedOutputStream
295 .computeDoubleSize(2, upperBound_);
296 }
297 if (((bitField0_ & 0x00000004) != 0)) {
298 size += com.google.protobuf.CodedOutputStream
299 .computeDoubleSize(3, objectiveCoefficient_);
300 }
301 if (((bitField0_ & 0x00000008) != 0)) {
302 size += com.google.protobuf.CodedOutputStream
303 .computeBoolSize(4, isInteger_);
304 }
305 if (((bitField0_ & 0x00000010) != 0)) {
306 size += com.google.protobuf.GeneratedMessage.computeStringSize(5, name_);
307 }
308 if (((bitField0_ & 0x00000020) != 0)) {
309 size += com.google.protobuf.CodedOutputStream
310 .computeInt32Size(6, branchingPriority_);
311 }
312 size += getUnknownFields().getSerializedSize();
313 memoizedSize = size;
314 return size;
315 }
316
317 @java.lang.Override
318 public boolean equals(final java.lang.Object obj) {
319 if (obj == this) {
320 return true;
321 }
322 if (!(obj instanceof com.google.ortools.linearsolver.MPVariableProto)) {
323 return super.equals(obj);
324 }
325 com.google.ortools.linearsolver.MPVariableProto other = (com.google.ortools.linearsolver.MPVariableProto) obj;
326
327 if (hasLowerBound() != other.hasLowerBound()) return false;
328 if (hasLowerBound()) {
329 if (java.lang.Double.doubleToLongBits(getLowerBound())
330 != java.lang.Double.doubleToLongBits(
331 other.getLowerBound())) return false;
332 }
333 if (hasUpperBound() != other.hasUpperBound()) return false;
334 if (hasUpperBound()) {
335 if (java.lang.Double.doubleToLongBits(getUpperBound())
336 != java.lang.Double.doubleToLongBits(
337 other.getUpperBound())) return false;
338 }
339 if (hasObjectiveCoefficient() != other.hasObjectiveCoefficient()) return false;
341 if (java.lang.Double.doubleToLongBits(getObjectiveCoefficient())
342 != java.lang.Double.doubleToLongBits(
343 other.getObjectiveCoefficient())) return false;
344 }
345 if (hasIsInteger() != other.hasIsInteger()) return false;
346 if (hasIsInteger()) {
347 if (getIsInteger()
348 != other.getIsInteger()) return false;
349 }
350 if (hasName() != other.hasName()) return false;
351 if (hasName()) {
352 if (!getName()
353 .equals(other.getName())) return false;
354 }
355 if (hasBranchingPriority() != other.hasBranchingPriority()) return false;
356 if (hasBranchingPriority()) {
358 != other.getBranchingPriority()) return false;
359 }
360 if (!getUnknownFields().equals(other.getUnknownFields())) return false;
361 return true;
362 }
363
364 @java.lang.Override
365 public int hashCode() {
366 if (memoizedHashCode != 0) {
367 return memoizedHashCode;
368 }
369 int hash = 41;
370 hash = (19 * hash) + getDescriptor().hashCode();
371 if (hasLowerBound()) {
372 hash = (37 * hash) + LOWER_BOUND_FIELD_NUMBER;
373 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
374 java.lang.Double.doubleToLongBits(getLowerBound()));
375 }
376 if (hasUpperBound()) {
377 hash = (37 * hash) + UPPER_BOUND_FIELD_NUMBER;
378 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
379 java.lang.Double.doubleToLongBits(getUpperBound()));
380 }
382 hash = (37 * hash) + OBJECTIVE_COEFFICIENT_FIELD_NUMBER;
383 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
384 java.lang.Double.doubleToLongBits(getObjectiveCoefficient()));
385 }
386 if (hasIsInteger()) {
387 hash = (37 * hash) + IS_INTEGER_FIELD_NUMBER;
388 hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
389 getIsInteger());
390 }
391 if (hasName()) {
392 hash = (37 * hash) + NAME_FIELD_NUMBER;
393 hash = (53 * hash) + getName().hashCode();
394 }
395 if (hasBranchingPriority()) {
396 hash = (37 * hash) + BRANCHING_PRIORITY_FIELD_NUMBER;
397 hash = (53 * hash) + getBranchingPriority();
398 }
399 hash = (29 * hash) + getUnknownFields().hashCode();
400 memoizedHashCode = hash;
401 return hash;
402 }
403
405 java.nio.ByteBuffer data)
406 throws com.google.protobuf.InvalidProtocolBufferException {
407 return PARSER.parseFrom(data);
408 }
410 java.nio.ByteBuffer data,
411 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
412 throws com.google.protobuf.InvalidProtocolBufferException {
413 return PARSER.parseFrom(data, extensionRegistry);
414 }
416 com.google.protobuf.ByteString data)
417 throws com.google.protobuf.InvalidProtocolBufferException {
418 return PARSER.parseFrom(data);
419 }
421 com.google.protobuf.ByteString data,
422 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
423 throws com.google.protobuf.InvalidProtocolBufferException {
424 return PARSER.parseFrom(data, extensionRegistry);
425 }
427 throws com.google.protobuf.InvalidProtocolBufferException {
428 return PARSER.parseFrom(data);
429 }
431 byte[] data,
432 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
433 throws com.google.protobuf.InvalidProtocolBufferException {
434 return PARSER.parseFrom(data, extensionRegistry);
435 }
436 public static com.google.ortools.linearsolver.MPVariableProto parseFrom(java.io.InputStream input)
437 throws java.io.IOException {
438 return com.google.protobuf.GeneratedMessage
439 .parseWithIOException(PARSER, input);
440 }
442 java.io.InputStream input,
443 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
444 throws java.io.IOException {
445 return com.google.protobuf.GeneratedMessage
446 .parseWithIOException(PARSER, input, extensionRegistry);
447 }
448
450 throws java.io.IOException {
451 return com.google.protobuf.GeneratedMessage
452 .parseDelimitedWithIOException(PARSER, input);
453 }
454
456 java.io.InputStream input,
457 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
458 throws java.io.IOException {
459 return com.google.protobuf.GeneratedMessage
460 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
461 }
463 com.google.protobuf.CodedInputStream input)
464 throws java.io.IOException {
465 return com.google.protobuf.GeneratedMessage
466 .parseWithIOException(PARSER, input);
467 }
469 com.google.protobuf.CodedInputStream input,
470 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
471 throws java.io.IOException {
472 return com.google.protobuf.GeneratedMessage
473 .parseWithIOException(PARSER, input, extensionRegistry);
474 }
475
476 @java.lang.Override
477 public Builder newBuilderForType() { return newBuilder(); }
478 public static Builder newBuilder() {
479 return DEFAULT_INSTANCE.toBuilder();
480 }
481 public static Builder newBuilder(com.google.ortools.linearsolver.MPVariableProto prototype) {
482 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
483 }
484 @java.lang.Override
486 return this == DEFAULT_INSTANCE
487 ? new Builder() : new Builder().mergeFrom(this);
488 }
489
490 @java.lang.Override
492 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
493 Builder builder = new Builder(parent);
494 return builder;
495 }
496
515 public static final class Builder extends
516 com.google.protobuf.GeneratedMessage.Builder<Builder> implements
517 // @@protoc_insertion_point(builder_implements:operations_research.MPVariableProto)
519 public static final com.google.protobuf.Descriptors.Descriptor
521 return com.google.ortools.linearsolver.LinearSolver.internal_static_operations_research_MPVariableProto_descriptor;
522 }
523
524 @java.lang.Override
525 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
527 return com.google.ortools.linearsolver.LinearSolver.internal_static_operations_research_MPVariableProto_fieldAccessorTable
528 .ensureFieldAccessorsInitialized(
529 com.google.ortools.linearsolver.MPVariableProto.class, com.google.ortools.linearsolver.MPVariableProto.Builder.class);
530 }
531
532 // Construct using com.google.ortools.linearsolver.MPVariableProto.newBuilder()
533 private Builder() {
534
535 }
536
537 private Builder(
538 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
539 super(parent);
540
541 }
542 @java.lang.Override
543 public Builder clear() {
544 super.clear();
545 bitField0_ = 0;
546 lowerBound_ = Double.NEGATIVE_INFINITY;
547 upperBound_ = Double.POSITIVE_INFINITY;
548 objectiveCoefficient_ = 0D;
549 isInteger_ = false;
550 name_ = "";
551 branchingPriority_ = 0;
552 return this;
553 }
554
555 @java.lang.Override
556 public com.google.protobuf.Descriptors.Descriptor
558 return com.google.ortools.linearsolver.LinearSolver.internal_static_operations_research_MPVariableProto_descriptor;
559 }
560
561 @java.lang.Override
563 return com.google.ortools.linearsolver.MPVariableProto.getDefaultInstance();
564 }
565
566 @java.lang.Override
569 if (!result.isInitialized()) {
570 throw newUninitializedMessageException(result);
571 }
572 return result;
573 }
574
575 @java.lang.Override
577 com.google.ortools.linearsolver.MPVariableProto result = new com.google.ortools.linearsolver.MPVariableProto(this);
578 if (bitField0_ != 0) { buildPartial0(result); }
579 onBuilt();
580 return result;
581 }
582
583 private void buildPartial0(com.google.ortools.linearsolver.MPVariableProto result) {
584 int from_bitField0_ = bitField0_;
585 int to_bitField0_ = 0;
586 if (((from_bitField0_ & 0x00000001) != 0)) {
587 result.lowerBound_ = lowerBound_;
588 to_bitField0_ |= 0x00000001;
589 }
590 if (((from_bitField0_ & 0x00000002) != 0)) {
591 result.upperBound_ = upperBound_;
592 to_bitField0_ |= 0x00000002;
593 }
594 if (((from_bitField0_ & 0x00000004) != 0)) {
595 result.objectiveCoefficient_ = objectiveCoefficient_;
596 to_bitField0_ |= 0x00000004;
597 }
598 if (((from_bitField0_ & 0x00000008) != 0)) {
599 result.isInteger_ = isInteger_;
600 to_bitField0_ |= 0x00000008;
601 }
602 if (((from_bitField0_ & 0x00000010) != 0)) {
603 result.name_ = name_;
604 to_bitField0_ |= 0x00000010;
605 }
606 if (((from_bitField0_ & 0x00000020) != 0)) {
607 result.branchingPriority_ = branchingPriority_;
608 to_bitField0_ |= 0x00000020;
609 }
610 result.bitField0_ |= to_bitField0_;
611 }
612
613 @java.lang.Override
614 public Builder mergeFrom(com.google.protobuf.Message other) {
615 if (other instanceof com.google.ortools.linearsolver.MPVariableProto) {
616 return mergeFrom((com.google.ortools.linearsolver.MPVariableProto)other);
617 } else {
618 super.mergeFrom(other);
619 return this;
620 }
621 }
622
623 public Builder mergeFrom(com.google.ortools.linearsolver.MPVariableProto other) {
624 if (other == com.google.ortools.linearsolver.MPVariableProto.getDefaultInstance()) return this;
625 if (other.hasLowerBound()) {
626 setLowerBound(other.getLowerBound());
627 }
628 if (other.hasUpperBound()) {
629 setUpperBound(other.getUpperBound());
630 }
631 if (other.hasObjectiveCoefficient()) {
632 setObjectiveCoefficient(other.getObjectiveCoefficient());
633 }
634 if (other.hasIsInteger()) {
635 setIsInteger(other.getIsInteger());
636 }
637 if (other.hasName()) {
638 name_ = other.name_;
639 bitField0_ |= 0x00000010;
640 onChanged();
641 }
642 if (other.hasBranchingPriority()) {
643 setBranchingPriority(other.getBranchingPriority());
644 }
645 this.mergeUnknownFields(other.getUnknownFields());
646 onChanged();
647 return this;
648 }
649
650 @java.lang.Override
651 public final boolean isInitialized() {
652 return true;
653 }
654
655 @java.lang.Override
656 public Builder mergeFrom(
657 com.google.protobuf.CodedInputStream input,
658 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
659 throws java.io.IOException {
660 if (extensionRegistry == null) {
661 throw new java.lang.NullPointerException();
662 }
663 try {
664 boolean done = false;
665 while (!done) {
666 int tag = input.readTag();
667 switch (tag) {
668 case 0:
669 done = true;
670 break;
671 case 9: {
672 lowerBound_ = input.readDouble();
673 bitField0_ |= 0x00000001;
674 break;
675 } // case 9
676 case 17: {
677 upperBound_ = input.readDouble();
678 bitField0_ |= 0x00000002;
679 break;
680 } // case 17
681 case 25: {
682 objectiveCoefficient_ = input.readDouble();
683 bitField0_ |= 0x00000004;
684 break;
685 } // case 25
686 case 32: {
687 isInteger_ = input.readBool();
688 bitField0_ |= 0x00000008;
689 break;
690 } // case 32
691 case 42: {
692 name_ = input.readBytes();
693 bitField0_ |= 0x00000010;
694 break;
695 } // case 42
696 case 48: {
697 branchingPriority_ = input.readInt32();
698 bitField0_ |= 0x00000020;
699 break;
700 } // case 48
701 default: {
702 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
703 done = true; // was an endgroup tag
704 }
705 break;
706 } // default:
707 } // switch (tag)
708 } // while (!done)
709 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
710 throw e.unwrapIOException();
711 } finally {
712 onChanged();
713 } // finally
714 return this;
715 }
716 private int bitField0_;
717
718 private double lowerBound_ = Double.NEGATIVE_INFINITY;
727 @java.lang.Override
728 public boolean hasLowerBound() {
729 return ((bitField0_ & 0x00000001) != 0);
730 }
731
739 @java.lang.Override
740 public double getLowerBound() {
741 return lowerBound_;
742 }
743
752 public Builder setLowerBound(double value) {
753
754 lowerBound_ = value;
755 bitField0_ |= 0x00000001;
756 onChanged();
757 return this;
758 }
759
767 public Builder clearLowerBound() {
768 bitField0_ = (bitField0_ & ~0x00000001);
769 lowerBound_ = Double.NEGATIVE_INFINITY;
770 onChanged();
771 return this;
772 }
773
774 private double upperBound_ = Double.POSITIVE_INFINITY;
779 @java.lang.Override
780 public boolean hasUpperBound() {
781 return ((bitField0_ & 0x00000002) != 0);
782 }
783
787 @java.lang.Override
788 public double getUpperBound() {
789 return upperBound_;
790 }
791
796 public Builder setUpperBound(double value) {
797
798 upperBound_ = value;
799 bitField0_ |= 0x00000002;
800 onChanged();
801 return this;
802 }
803
807 public Builder clearUpperBound() {
808 bitField0_ = (bitField0_ & ~0x00000002);
809 upperBound_ = Double.POSITIVE_INFINITY;
810 onChanged();
811 return this;
812 }
813
814 private double objectiveCoefficient_ ;
823 @java.lang.Override
824 public boolean hasObjectiveCoefficient() {
825 return ((bitField0_ & 0x00000004) != 0);
826 }
827
835 @java.lang.Override
836 public double getObjectiveCoefficient() {
837 return objectiveCoefficient_;
838 }
839
848 public Builder setObjectiveCoefficient(double value) {
849
850 objectiveCoefficient_ = value;
851 bitField0_ |= 0x00000004;
852 onChanged();
853 return this;
854 }
855
863 public Builder clearObjectiveCoefficient() {
864 bitField0_ = (bitField0_ & ~0x00000004);
865 objectiveCoefficient_ = 0D;
866 onChanged();
867 return this;
868 }
869
870 private boolean isInteger_ ;
880 @java.lang.Override
881 public boolean hasIsInteger() {
882 return ((bitField0_ & 0x00000008) != 0);
883 }
884
893 @java.lang.Override
894 public boolean getIsInteger() {
895 return isInteger_;
896 }
897
907 public Builder setIsInteger(boolean value) {
908
909 isInteger_ = value;
910 bitField0_ |= 0x00000008;
911 onChanged();
912 return this;
913 }
914
923 public Builder clearIsInteger() {
924 bitField0_ = (bitField0_ & ~0x00000008);
925 isInteger_ = false;
926 onChanged();
927 return this;
928 }
929
930 private java.lang.Object name_ = "";
939 public boolean hasName() {
940 return ((bitField0_ & 0x00000010) != 0);
941 }
942
950 public java.lang.String getName() {
951 java.lang.Object ref = name_;
952 if (!(ref instanceof java.lang.String)) {
953 com.google.protobuf.ByteString bs =
954 (com.google.protobuf.ByteString) ref;
955 java.lang.String s = bs.toStringUtf8();
956 if (bs.isValidUtf8()) {
957 name_ = s;
958 }
959 return s;
960 } else {
961 return (java.lang.String) ref;
962 }
963 }
964
972 public com.google.protobuf.ByteString
974 java.lang.Object ref = name_;
975 if (ref instanceof String) {
976 com.google.protobuf.ByteString b =
977 com.google.protobuf.ByteString.copyFromUtf8(
978 (java.lang.String) ref);
979 name_ = b;
980 return b;
981 } else {
982 return (com.google.protobuf.ByteString) ref;
983 }
984 }
985
994 public Builder setName(
995 java.lang.String value) {
996 if (value == null) { throw new NullPointerException(); }
997 name_ = value;
998 bitField0_ |= 0x00000010;
999 onChanged();
1000 return this;
1001 }
1002
1010 public Builder clearName() {
1011 name_ = getDefaultInstance().getName();
1012 bitField0_ = (bitField0_ & ~0x00000010);
1013 onChanged();
1014 return this;
1015 }
1016
1025 public Builder setNameBytes(
1026 com.google.protobuf.ByteString value) {
1027 if (value == null) { throw new NullPointerException(); }
1028 name_ = value;
1029 bitField0_ |= 0x00000010;
1030 onChanged();
1031 return this;
1032 }
1033
1034 private int branchingPriority_ ;
1039 @java.lang.Override
1040 public boolean hasBranchingPriority() {
1041 return ((bitField0_ & 0x00000020) != 0);
1042 }
1043
1047 @java.lang.Override
1049 return branchingPriority_;
1050 }
1051
1056 public Builder setBranchingPriority(int value) {
1057
1058 branchingPriority_ = value;
1059 bitField0_ |= 0x00000020;
1060 onChanged();
1061 return this;
1062 }
1063
1067 public Builder clearBranchingPriority() {
1068 bitField0_ = (bitField0_ & ~0x00000020);
1069 branchingPriority_ = 0;
1070 onChanged();
1071 return this;
1072 }
1073
1074 // @@protoc_insertion_point(builder_scope:operations_research.MPVariableProto)
1075 }
1076
1077 // @@protoc_insertion_point(class_scope:operations_research.MPVariableProto)
1078 private static final com.google.ortools.linearsolver.MPVariableProto DEFAULT_INSTANCE;
1079 static {
1080 DEFAULT_INSTANCE = new com.google.ortools.linearsolver.MPVariableProto();
1081 }
1082
1084 return DEFAULT_INSTANCE;
1085 }
1086
1087 private static final com.google.protobuf.Parser<MPVariableProto>
1088 PARSER = new com.google.protobuf.AbstractParser<MPVariableProto>() {
1089 @java.lang.Override
1090 public MPVariableProto parsePartialFrom(
1091 com.google.protobuf.CodedInputStream input,
1092 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1093 throws com.google.protobuf.InvalidProtocolBufferException {
1094 Builder builder = newBuilder();
1095 try {
1096 builder.mergeFrom(input, extensionRegistry);
1097 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
1098 throw e.setUnfinishedMessage(builder.buildPartial());
1099 } catch (com.google.protobuf.UninitializedMessageException e) {
1100 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
1101 } catch (java.io.IOException e) {
1102 throw new com.google.protobuf.InvalidProtocolBufferException(e)
1103 .setUnfinishedMessage(builder.buildPartial());
1104 }
1105 return builder.buildPartial();
1106 }
1107 };
1108
1109 public static com.google.protobuf.Parser<MPVariableProto> parser() {
1110 return PARSER;
1111 }
1112
1113 @java.lang.Override
1114 public com.google.protobuf.Parser<MPVariableProto> getParserForType() {
1115 return PARSER;
1116 }
1117
1118 @java.lang.Override
1122
1123}
1124
com.google.ortools.linearsolver.MPVariableProto buildPartial()
com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
com.google.ortools.linearsolver.MPVariableProto getDefaultInstanceForType()
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
Builder setNameBytes(com.google.protobuf.ByteString value)
Builder mergeFrom(com.google.protobuf.Message other)
Builder mergeFrom(com.google.ortools.linearsolver.MPVariableProto other)
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
com.google.ortools.linearsolver.MPVariableProto build()
static com.google.ortools.linearsolver.MPVariableProto parseFrom(java.nio.ByteBuffer data)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(com.google.protobuf.ByteString data)
static com.google.ortools.linearsolver.MPVariableProto parseDelimitedFrom(java.io.InputStream input)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.protobuf.Parser< MPVariableProto > parser()
static com.google.ortools.linearsolver.MPVariableProto parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent)
void writeTo(com.google.protobuf.CodedOutputStream output)
static com.google.ortools.linearsolver.MPVariableProto parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.linearsolver.MPVariableProto getDefaultInstance()
static com.google.ortools.linearsolver.MPVariableProto parseFrom(byte[] data)
com.google.ortools.linearsolver.MPVariableProto getDefaultInstanceForType()
com.google.protobuf.ByteString getNameBytes()
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
static Builder newBuilder(com.google.ortools.linearsolver.MPVariableProto prototype)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.protobuf.Parser< MPVariableProto > getParserForType()
boolean equals(final java.lang.Object obj)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(java.io.InputStream input)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(com.google.protobuf.CodedInputStream input)
static com.google.ortools.linearsolver.MPVariableProto parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()