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