5package com.google.ortools.sat.v1;
15 com.google.protobuf.GeneratedMessage implements
18private static final long serialVersionUID = 0L;
20 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
21 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
29 private CpSolverRequest(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
35 public static final com.google.protobuf.Descriptors.Descriptor
37 return com.google.ortools.sat.v1.CpModelServiceProto.internal_static_operations_research_sat_v1_CpSolverRequest_descriptor;
41 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
43 return com.google.ortools.sat.v1.CpModelServiceProto.internal_static_operations_research_sat_v1_CpSolverRequest_fieldAccessorTable
44 .ensureFieldAccessorsInitialized(
45 com.google.ortools.sat.v1.CpSolverRequest.class, com.google.ortools.sat.v1.CpSolverRequest.Builder.class);
48 private int bitField0_;
61 return ((bitField0_ & 0x00000001) != 0);
73 return model_ ==
null ? com.google.ortools.sat.CpModelProto.getDefaultInstance() : model_;
84 return model_ ==
null ? com.google.ortools.sat.CpModelProto.getDefaultInstance() : model_;
99 return ((bitField0_ & 0x00000002) != 0);
111 return parameters_ ==
null ? com.google.ortools.sat.SatParameters.getDefaultInstance() : parameters_;
122 return parameters_ ==
null ? com.google.ortools.sat.SatParameters.getDefaultInstance() : parameters_;
125 private byte memoizedIsInitialized = -1;
132 memoizedIsInitialized = 1;
137 public void writeTo(com.google.protobuf.CodedOutputStream output)
138 throws java.io.IOException {
139 if (((bitField0_ & 0x00000001) != 0)) {
142 if (((bitField0_ & 0x00000002) != 0)) {
145 getUnknownFields().writeTo(output);
150 int size = memoizedSize;
151 if (size != -1)
return size;
154 if (((bitField0_ & 0x00000001) != 0)) {
155 size += com.google.protobuf.CodedOutputStream
158 if (((bitField0_ & 0x00000002) != 0)) {
159 size += com.google.protobuf.CodedOutputStream
162 size += getUnknownFields().getSerializedSize();
168 public boolean equals(
final java.lang.Object obj) {
172 if (!(obj instanceof com.google.ortools.sat.v1.CpSolverRequest)) {
173 return super.equals(obj);
187 if (!getUnknownFields().
equals(other.getUnknownFields()))
return false;
193 if (memoizedHashCode != 0) {
194 return memoizedHashCode;
206 hash = (29 * hash) + getUnknownFields().hashCode();
207 memoizedHashCode = hash;
212 java.nio.ByteBuffer data)
213 throws com.google.protobuf.InvalidProtocolBufferException {
214 return PARSER.parseFrom(data);
217 java.nio.ByteBuffer data,
218 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
219 throws com.google.protobuf.InvalidProtocolBufferException {
220 return PARSER.parseFrom(data, extensionRegistry);
223 com.google.protobuf.ByteString data)
224 throws com.google.protobuf.InvalidProtocolBufferException {
225 return PARSER.parseFrom(data);
228 com.google.protobuf.ByteString data,
229 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
230 throws com.google.protobuf.InvalidProtocolBufferException {
231 return PARSER.parseFrom(data, extensionRegistry);
234 throws com.google.protobuf.InvalidProtocolBufferException {
235 return PARSER.parseFrom(data);
239 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
240 throws com.google.protobuf.InvalidProtocolBufferException {
241 return PARSER.parseFrom(data, extensionRegistry);
244 throws java.io.IOException {
245 return com.google.protobuf.GeneratedMessage
246 .parseWithIOException(PARSER, input);
249 java.io.InputStream input,
250 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
251 throws java.io.IOException {
252 return com.google.protobuf.GeneratedMessage
253 .parseWithIOException(PARSER, input, extensionRegistry);
257 throws java.io.IOException {
258 return com.google.protobuf.GeneratedMessage
259 .parseDelimitedWithIOException(PARSER, input);
263 java.io.InputStream input,
264 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
265 throws java.io.IOException {
266 return com.google.protobuf.GeneratedMessage
267 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
270 com.google.protobuf.CodedInputStream input)
271 throws java.io.IOException {
272 return com.google.protobuf.GeneratedMessage
273 .parseWithIOException(PARSER, input);
276 com.google.protobuf.CodedInputStream input,
277 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
278 throws java.io.IOException {
279 return com.google.protobuf.GeneratedMessage
280 .parseWithIOException(PARSER, input, extensionRegistry);
293 return this == DEFAULT_INSTANCE
299 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
311 com.google.protobuf.GeneratedMessage.
Builder<Builder> implements
314 public static final com.google.protobuf.Descriptors.Descriptor
316 return com.google.ortools.sat.v1.CpModelServiceProto.internal_static_operations_research_sat_v1_CpSolverRequest_descriptor;
320 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
322 return com.google.ortools.sat.v1.CpModelServiceProto.internal_static_operations_research_sat_v1_CpSolverRequest_fieldAccessorTable
323 .ensureFieldAccessorsInitialized(
324 com.google.ortools.sat.v1.CpSolverRequest.class, com.google.ortools.sat.v1.CpSolverRequest.Builder.class);
329 maybeForceBuilderInitialization();
333 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
335 maybeForceBuilderInitialization();
337 private void maybeForceBuilderInitialization() {
338 if (com.google.protobuf.GeneratedMessage
339 .alwaysUseFieldBuilders) {
340 getModelFieldBuilder();
341 getParametersFieldBuilder();
349 if (modelBuilder_ !=
null) {
350 modelBuilder_.dispose();
351 modelBuilder_ =
null;
354 if (parametersBuilder_ !=
null) {
355 parametersBuilder_.dispose();
356 parametersBuilder_ =
null;
362 public com.google.protobuf.Descriptors.Descriptor
364 return com.google.ortools.sat.v1.CpModelServiceProto.internal_static_operations_research_sat_v1_CpSolverRequest_descriptor;
369 return com.google.ortools.sat.v1.CpSolverRequest.getDefaultInstance();
376 throw newUninitializedMessageException(result);
384 if (bitField0_ != 0) { buildPartial0(result); }
389 private void buildPartial0(com.google.ortools.sat.v1.CpSolverRequest result) {
390 int from_bitField0_ = bitField0_;
391 int to_bitField0_ = 0;
392 if (((from_bitField0_ & 0x00000001) != 0)) {
393 result.model_ = modelBuilder_ ==
null
395 : modelBuilder_.build();
396 to_bitField0_ |= 0x00000001;
398 if (((from_bitField0_ & 0x00000002) != 0)) {
399 result.parameters_ = parametersBuilder_ ==
null
401 : parametersBuilder_.build();
402 to_bitField0_ |= 0x00000002;
404 result.bitField0_ |= to_bitField0_;
409 if (other instanceof com.google.ortools.sat.v1.CpSolverRequest) {
410 return mergeFrom((com.google.ortools.sat.v1.CpSolverRequest)other);
412 super.mergeFrom(other);
418 if (other == com.google.ortools.sat.v1.CpSolverRequest.getDefaultInstance())
return this;
419 if (other.hasModel()) {
422 if (other.hasParameters()) {
425 this.mergeUnknownFields(other.getUnknownFields());
437 com.google.protobuf.CodedInputStream input,
438 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
439 throws java.io.IOException {
440 if (extensionRegistry ==
null) {
441 throw new java.lang.NullPointerException();
444 boolean done =
false;
446 int tag = input.readTag();
453 getModelFieldBuilder().getBuilder(),
455 bitField0_ |= 0x00000001;
460 getParametersFieldBuilder().getBuilder(),
462 bitField0_ |= 0x00000002;
466 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
473 }
catch (com.google.protobuf.InvalidProtocolBufferException e) {
474 throw e.unwrapIOException();
480 private int bitField0_;
483 private com.google.protobuf.SingleFieldBuilder<
484 com.google.ortools.sat.CpModelProto, com.google.ortools.sat.CpModelProto.Builder, com.google.ortools.sat.CpModelProtoOrBuilder> modelBuilder_;
494 return ((bitField0_ & 0x00000001) != 0);
505 if (modelBuilder_ ==
null) {
506 return model_ ==
null ? com.google.ortools.sat.CpModelProto.getDefaultInstance() : model_;
508 return modelBuilder_.getMessage();
519 if (modelBuilder_ ==
null) {
521 throw new NullPointerException();
525 modelBuilder_.setMessage(value);
527 bitField0_ |= 0x00000001;
539 com.google.ortools.sat.CpModelProto.Builder builderForValue) {
540 if (modelBuilder_ ==
null) {
541 model_ = builderForValue.build();
543 modelBuilder_.setMessage(builderForValue.build());
545 bitField0_ |= 0x00000001;
557 if (modelBuilder_ ==
null) {
558 if (((bitField0_ & 0x00000001) != 0) &&
560 model_ != com.google.ortools.sat.CpModelProto.getDefaultInstance()) {
566 modelBuilder_.mergeFrom(value);
568 if (model_ !=
null) {
569 bitField0_ |= 0x00000001;
582 bitField0_ = (bitField0_ & ~0x00000001);
584 if (modelBuilder_ !=
null) {
585 modelBuilder_.dispose();
586 modelBuilder_ =
null;
599 bitField0_ |= 0x00000001;
601 return getModelFieldBuilder().getBuilder();
611 if (modelBuilder_ !=
null) {
612 return modelBuilder_.getMessageOrBuilder();
614 return model_ ==
null ?
615 com.google.ortools.sat.CpModelProto.getDefaultInstance() : model_;
625 private com.google.protobuf.SingleFieldBuilder<
626 com.google.ortools.sat.CpModelProto, com.google.ortools.sat.CpModelProto.Builder, com.google.ortools.sat.CpModelProtoOrBuilder>
627 getModelFieldBuilder() {
628 if (modelBuilder_ ==
null) {
629 modelBuilder_ =
new com.google.protobuf.SingleFieldBuilder<
630 com.google.ortools.sat.CpModelProto, com.google.ortools.sat.CpModelProto.Builder, com.google.ortools.sat.CpModelProtoOrBuilder>(
632 getParentForChildren(),
636 return modelBuilder_;
640 private com.google.protobuf.SingleFieldBuilder<
641 com.google.ortools.sat.SatParameters, com.google.ortools.sat.SatParameters.Builder, com.google.ortools.sat.SatParametersOrBuilder> parametersBuilder_;
651 return ((bitField0_ & 0x00000002) != 0);
662 if (parametersBuilder_ ==
null) {
663 return parameters_ ==
null ? com.google.ortools.sat.SatParameters.getDefaultInstance() : parameters_;
665 return parametersBuilder_.getMessage();
676 if (parametersBuilder_ ==
null) {
678 throw new NullPointerException();
682 parametersBuilder_.setMessage(value);
684 bitField0_ |= 0x00000002;
696 com.google.ortools.sat.SatParameters.Builder builderForValue) {
697 if (parametersBuilder_ ==
null) {
698 parameters_ = builderForValue.build();
700 parametersBuilder_.setMessage(builderForValue.build());
702 bitField0_ |= 0x00000002;
714 if (parametersBuilder_ ==
null) {
715 if (((bitField0_ & 0x00000002) != 0) &&
716 parameters_ !=
null &&
717 parameters_ != com.google.ortools.sat.SatParameters.getDefaultInstance()) {
723 parametersBuilder_.mergeFrom(value);
725 if (parameters_ !=
null) {
726 bitField0_ |= 0x00000002;
739 bitField0_ = (bitField0_ & ~0x00000002);
741 if (parametersBuilder_ !=
null) {
742 parametersBuilder_.dispose();
743 parametersBuilder_ =
null;
756 bitField0_ |= 0x00000002;
758 return getParametersFieldBuilder().getBuilder();
768 if (parametersBuilder_ !=
null) {
769 return parametersBuilder_.getMessageOrBuilder();
771 return parameters_ ==
null ?
772 com.google.ortools.sat.SatParameters.getDefaultInstance() : parameters_;
782 private com.google.protobuf.SingleFieldBuilder<
783 com.google.ortools.sat.SatParameters, com.google.ortools.sat.SatParameters.Builder, com.google.ortools.sat.SatParametersOrBuilder>
784 getParametersFieldBuilder() {
785 if (parametersBuilder_ ==
null) {
786 parametersBuilder_ =
new com.google.protobuf.SingleFieldBuilder<
787 com.google.ortools.sat.SatParameters, com.google.ortools.sat.SatParameters.Builder, com.google.ortools.sat.SatParametersOrBuilder>(
789 getParentForChildren(),
793 return parametersBuilder_;
802 DEFAULT_INSTANCE =
new com.google.ortools.sat.v1.CpSolverRequest();
806 return DEFAULT_INSTANCE;
813 com.google.protobuf.CodedInputStream input,
814 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
815 throws com.google.protobuf.InvalidProtocolBufferException {
818 builder.mergeFrom(input, extensionRegistry);
819 }
catch (com.google.protobuf.InvalidProtocolBufferException e) {
820 throw e.setUnfinishedMessage(builder.buildPartial());
821 }
catch (com.google.protobuf.UninitializedMessageException e) {
822 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
823 }
catch (java.io.IOException e) {
824 throw new com.google.protobuf.InvalidProtocolBufferException(e)
825 .setUnfinishedMessage(builder.buildPartial());
827 return builder.buildPartial();
842 return DEFAULT_INSTANCE;