Google OR-Tools v9.14
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
SpatiallyCloseRoutesRuinStrategy.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.31.1
5
6package com.google.ortools.constraintsolver;
7
15@com.google.protobuf.Generated
16public final class SpatiallyCloseRoutesRuinStrategy extends
17 com.google.protobuf.GeneratedMessage implements
18 // @@protoc_insertion_point(message_implements:operations_research.SpatiallyCloseRoutesRuinStrategy)
20private static final long serialVersionUID = 0L;
21 static {
22 com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
23 com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
24 /* major= */ 4,
25 /* minor= */ 31,
26 /* patch= */ 1,
27 /* suffix= */ "",
28 SpatiallyCloseRoutesRuinStrategy.class.getName());
29 }
30 // Use SpatiallyCloseRoutesRuinStrategy.newBuilder() to construct.
31 private SpatiallyCloseRoutesRuinStrategy(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
32 super(builder);
33 }
34 private SpatiallyCloseRoutesRuinStrategy() {
35 }
36
37 public static final com.google.protobuf.Descriptors.Descriptor
39 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_SpatiallyCloseRoutesRuinStrategy_descriptor;
40 }
41
42 @java.lang.Override
43 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
45 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_SpatiallyCloseRoutesRuinStrategy_fieldAccessorTable
46 .ensureFieldAccessorsInitialized(
47 com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.class, com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.Builder.class);
48 }
49
50 private int bitField0_;
51 public static final int NUM_RUINED_ROUTES_FIELD_NUMBER = 3;
52 private int numRuinedRoutes_ = 0;
61 @java.lang.Override
62 public boolean hasNumRuinedRoutes() {
63 return ((bitField0_ & 0x00000001) != 0);
64 }
65
73 @java.lang.Override
74 public int getNumRuinedRoutes() {
75 return numRuinedRoutes_;
76 }
77
78 private byte memoizedIsInitialized = -1;
79 @java.lang.Override
80 public final boolean isInitialized() {
81 byte isInitialized = memoizedIsInitialized;
82 if (isInitialized == 1) return true;
83 if (isInitialized == 0) return false;
84
85 memoizedIsInitialized = 1;
86 return true;
87 }
88
89 @java.lang.Override
90 public void writeTo(com.google.protobuf.CodedOutputStream output)
91 throws java.io.IOException {
92 if (((bitField0_ & 0x00000001) != 0)) {
93 output.writeUInt32(3, numRuinedRoutes_);
94 }
95 getUnknownFields().writeTo(output);
96 }
97
98 @java.lang.Override
99 public int getSerializedSize() {
100 int size = memoizedSize;
101 if (size != -1) return size;
102
103 size = 0;
104 if (((bitField0_ & 0x00000001) != 0)) {
105 size += com.google.protobuf.CodedOutputStream
106 .computeUInt32Size(3, numRuinedRoutes_);
107 }
108 size += getUnknownFields().getSerializedSize();
109 memoizedSize = size;
110 return size;
111 }
112
113 @java.lang.Override
114 public boolean equals(final java.lang.Object obj) {
115 if (obj == this) {
116 return true;
117 }
118 if (!(obj instanceof com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy)) {
119 return super.equals(obj);
120 }
121 com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy other = (com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy) obj;
122
123 if (hasNumRuinedRoutes() != other.hasNumRuinedRoutes()) return false;
124 if (hasNumRuinedRoutes()) {
126 != other.getNumRuinedRoutes()) return false;
127 }
128 if (!getUnknownFields().equals(other.getUnknownFields())) return false;
129 return true;
130 }
131
132 @java.lang.Override
133 public int hashCode() {
134 if (memoizedHashCode != 0) {
135 return memoizedHashCode;
136 }
137 int hash = 41;
138 hash = (19 * hash) + getDescriptor().hashCode();
139 if (hasNumRuinedRoutes()) {
140 hash = (37 * hash) + NUM_RUINED_ROUTES_FIELD_NUMBER;
141 hash = (53 * hash) + getNumRuinedRoutes();
142 }
143 hash = (29 * hash) + getUnknownFields().hashCode();
144 memoizedHashCode = hash;
145 return hash;
146 }
147
149 java.nio.ByteBuffer data)
150 throws com.google.protobuf.InvalidProtocolBufferException {
151 return PARSER.parseFrom(data);
152 }
154 java.nio.ByteBuffer data,
155 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
156 throws com.google.protobuf.InvalidProtocolBufferException {
157 return PARSER.parseFrom(data, extensionRegistry);
158 }
160 com.google.protobuf.ByteString data)
161 throws com.google.protobuf.InvalidProtocolBufferException {
162 return PARSER.parseFrom(data);
163 }
165 com.google.protobuf.ByteString data,
166 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
167 throws com.google.protobuf.InvalidProtocolBufferException {
168 return PARSER.parseFrom(data, extensionRegistry);
169 }
171 throws com.google.protobuf.InvalidProtocolBufferException {
172 return PARSER.parseFrom(data);
173 }
175 byte[] data,
176 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
177 throws com.google.protobuf.InvalidProtocolBufferException {
178 return PARSER.parseFrom(data, extensionRegistry);
179 }
181 throws java.io.IOException {
182 return com.google.protobuf.GeneratedMessage
183 .parseWithIOException(PARSER, input);
184 }
186 java.io.InputStream input,
187 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
188 throws java.io.IOException {
189 return com.google.protobuf.GeneratedMessage
190 .parseWithIOException(PARSER, input, extensionRegistry);
191 }
192
194 throws java.io.IOException {
195 return com.google.protobuf.GeneratedMessage
196 .parseDelimitedWithIOException(PARSER, input);
197 }
198
200 java.io.InputStream input,
201 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
202 throws java.io.IOException {
203 return com.google.protobuf.GeneratedMessage
204 .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
205 }
207 com.google.protobuf.CodedInputStream input)
208 throws java.io.IOException {
209 return com.google.protobuf.GeneratedMessage
210 .parseWithIOException(PARSER, input);
211 }
213 com.google.protobuf.CodedInputStream input,
214 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
215 throws java.io.IOException {
216 return com.google.protobuf.GeneratedMessage
217 .parseWithIOException(PARSER, input, extensionRegistry);
218 }
219
220 @java.lang.Override
221 public Builder newBuilderForType() { return newBuilder(); }
222 public static Builder newBuilder() {
223 return DEFAULT_INSTANCE.toBuilder();
224 }
225 public static Builder newBuilder(com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy prototype) {
226 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
227 }
228 @java.lang.Override
230 return this == DEFAULT_INSTANCE
231 ? new Builder() : new Builder().mergeFrom(this);
232 }
233
234 @java.lang.Override
236 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
237 Builder builder = new Builder(parent);
238 return builder;
239 }
240
247 public static final class Builder extends
248 com.google.protobuf.GeneratedMessage.Builder<Builder> implements
249 // @@protoc_insertion_point(builder_implements:operations_research.SpatiallyCloseRoutesRuinStrategy)
251 public static final com.google.protobuf.Descriptors.Descriptor
253 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_SpatiallyCloseRoutesRuinStrategy_descriptor;
254 }
255
256 @java.lang.Override
257 protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
259 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_SpatiallyCloseRoutesRuinStrategy_fieldAccessorTable
260 .ensureFieldAccessorsInitialized(
261 com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.class, com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.Builder.class);
262 }
263
264 // Construct using com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.newBuilder()
265 private Builder() {
266
267 }
268
269 private Builder(
270 com.google.protobuf.GeneratedMessage.BuilderParent parent) {
271 super(parent);
272
273 }
274 @java.lang.Override
275 public Builder clear() {
276 super.clear();
277 bitField0_ = 0;
278 numRuinedRoutes_ = 0;
279 return this;
280 }
281
282 @java.lang.Override
283 public com.google.protobuf.Descriptors.Descriptor
285 return com.google.ortools.constraintsolver.RoutingIls.internal_static_operations_research_SpatiallyCloseRoutesRuinStrategy_descriptor;
286 }
287
288 @java.lang.Override
290 return com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.getDefaultInstance();
291 }
292
293 @java.lang.Override
296 if (!result.isInitialized()) {
297 throw newUninitializedMessageException(result);
298 }
299 return result;
300 }
301
302 @java.lang.Override
304 com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy result = new com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy(this);
305 if (bitField0_ != 0) { buildPartial0(result); }
306 onBuilt();
307 return result;
308 }
309
310 private void buildPartial0(com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy result) {
311 int from_bitField0_ = bitField0_;
312 int to_bitField0_ = 0;
313 if (((from_bitField0_ & 0x00000001) != 0)) {
314 result.numRuinedRoutes_ = numRuinedRoutes_;
315 to_bitField0_ |= 0x00000001;
316 }
317 result.bitField0_ |= to_bitField0_;
318 }
319
320 @java.lang.Override
321 public Builder mergeFrom(com.google.protobuf.Message other) {
322 if (other instanceof com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy) {
323 return mergeFrom((com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy)other);
324 } else {
325 super.mergeFrom(other);
326 return this;
327 }
328 }
329
330 public Builder mergeFrom(com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy other) {
331 if (other == com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy.getDefaultInstance()) return this;
332 if (other.hasNumRuinedRoutes()) {
333 setNumRuinedRoutes(other.getNumRuinedRoutes());
334 }
335 this.mergeUnknownFields(other.getUnknownFields());
336 onChanged();
337 return this;
338 }
339
340 @java.lang.Override
341 public final boolean isInitialized() {
342 return true;
343 }
344
345 @java.lang.Override
346 public Builder mergeFrom(
347 com.google.protobuf.CodedInputStream input,
348 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
349 throws java.io.IOException {
350 if (extensionRegistry == null) {
351 throw new java.lang.NullPointerException();
352 }
353 try {
354 boolean done = false;
355 while (!done) {
356 int tag = input.readTag();
357 switch (tag) {
358 case 0:
359 done = true;
360 break;
361 case 24: {
362 numRuinedRoutes_ = input.readUInt32();
363 bitField0_ |= 0x00000001;
364 break;
365 } // case 24
366 default: {
367 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
368 done = true; // was an endgroup tag
369 }
370 break;
371 } // default:
372 } // switch (tag)
373 } // while (!done)
374 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
375 throw e.unwrapIOException();
376 } finally {
377 onChanged();
378 } // finally
379 return this;
380 }
381 private int bitField0_;
382
383 private int numRuinedRoutes_ ;
392 @java.lang.Override
393 public boolean hasNumRuinedRoutes() {
394 return ((bitField0_ & 0x00000001) != 0);
395 }
396
404 @java.lang.Override
405 public int getNumRuinedRoutes() {
406 return numRuinedRoutes_;
407 }
408
417 public Builder setNumRuinedRoutes(int value) {
418
419 numRuinedRoutes_ = value;
420 bitField0_ |= 0x00000001;
421 onChanged();
422 return this;
423 }
424
432 public Builder clearNumRuinedRoutes() {
433 bitField0_ = (bitField0_ & ~0x00000001);
434 numRuinedRoutes_ = 0;
435 onChanged();
436 return this;
437 }
438
439 // @@protoc_insertion_point(builder_scope:operations_research.SpatiallyCloseRoutesRuinStrategy)
440 }
441
442 // @@protoc_insertion_point(class_scope:operations_research.SpatiallyCloseRoutesRuinStrategy)
444 static {
445 DEFAULT_INSTANCE = new com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy();
446 }
447
451
452 private static final com.google.protobuf.Parser<SpatiallyCloseRoutesRuinStrategy>
453 PARSER = new com.google.protobuf.AbstractParser<SpatiallyCloseRoutesRuinStrategy>() {
454 @java.lang.Override
455 public SpatiallyCloseRoutesRuinStrategy parsePartialFrom(
456 com.google.protobuf.CodedInputStream input,
457 com.google.protobuf.ExtensionRegistryLite extensionRegistry)
458 throws com.google.protobuf.InvalidProtocolBufferException {
459 Builder builder = newBuilder();
460 try {
461 builder.mergeFrom(input, extensionRegistry);
462 } catch (com.google.protobuf.InvalidProtocolBufferException e) {
463 throw e.setUnfinishedMessage(builder.buildPartial());
464 } catch (com.google.protobuf.UninitializedMessageException e) {
465 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
466 } catch (java.io.IOException e) {
467 throw new com.google.protobuf.InvalidProtocolBufferException(e)
468 .setUnfinishedMessage(builder.buildPartial());
469 }
470 return builder.buildPartial();
471 }
472 };
473
474 public static com.google.protobuf.Parser<SpatiallyCloseRoutesRuinStrategy> parser() {
475 return PARSER;
476 }
477
478 @java.lang.Override
479 public com.google.protobuf.Parser<SpatiallyCloseRoutesRuinStrategy> getParserForType() {
480 return PARSER;
481 }
482
483 @java.lang.Override
487
488}
489
com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy getDefaultInstanceForType()
Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy build()
Builder mergeFrom(com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy other)
com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy buildPartial()
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(com.google.protobuf.CodedInputStream input)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.protobuf.Parser< SpatiallyCloseRoutesRuinStrategy > parser()
com.google.protobuf.Parser< SpatiallyCloseRoutesRuinStrategy > getParserForType()
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy getDefaultInstance()
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(java.nio.ByteBuffer data)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(byte[] data)
com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy getDefaultInstanceForType()
static Builder newBuilder(com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy prototype)
com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseDelimitedFrom(java.io.InputStream input)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(com.google.protobuf.ByteString data)
Builder newBuilderForType(com.google.protobuf.GeneratedMessage.BuilderParent parent)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.ortools.constraintsolver.SpatiallyCloseRoutesRuinStrategy parseFrom(java.io.InputStream input)