1 /* 2 * Copyright 2019 The Grafeas Authors. All rights reserved. 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * https://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package io.grafeas.v1; 18 19 import static io.grpc.MethodDescriptor.generateFullMethodName; 20 21 /** 22 * 23 * 24 * <pre> 25 * [Grafeas](https://grafeas.io) API. 26 * Retrieves analysis results of Cloud components such as Docker container 27 * images. 28 * Analysis results are stored as a series of occurrences. An `Occurrence` 29 * contains information about a specific analysis instance on a resource. An 30 * occurrence refers to a `Note`. A note contains details describing the 31 * analysis and is generally stored in a separate project, called a `Provider`. 32 * Multiple occurrences can refer to the same note. 33 * For example, an SSL vulnerability could affect multiple images. In this case, 34 * there would be one note for the vulnerability and an occurrence for each 35 * image with the vulnerability referring to that note. 36 * </pre> 37 */ 38 @javax.annotation.Generated( 39 value = "by gRPC proto compiler", 40 comments = "Source: grafeas/v1/grafeas.proto") 41 @io.grpc.stub.annotations.GrpcGenerated 42 public final class GrafeasGrpc { 43 GrafeasGrpc()44 private GrafeasGrpc() {} 45 46 public static final String SERVICE_NAME = "grafeas.v1.Grafeas"; 47 48 // Static method descriptors that strictly reflect the proto. 49 private static volatile io.grpc.MethodDescriptor< 50 io.grafeas.v1.GetOccurrenceRequest, io.grafeas.v1.Occurrence> 51 getGetOccurrenceMethod; 52 53 @io.grpc.stub.annotations.RpcMethod( 54 fullMethodName = SERVICE_NAME + '/' + "GetOccurrence", 55 requestType = io.grafeas.v1.GetOccurrenceRequest.class, 56 responseType = io.grafeas.v1.Occurrence.class, 57 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 58 public static io.grpc.MethodDescriptor< 59 io.grafeas.v1.GetOccurrenceRequest, io.grafeas.v1.Occurrence> getGetOccurrenceMethod()60 getGetOccurrenceMethod() { 61 io.grpc.MethodDescriptor<io.grafeas.v1.GetOccurrenceRequest, io.grafeas.v1.Occurrence> 62 getGetOccurrenceMethod; 63 if ((getGetOccurrenceMethod = GrafeasGrpc.getGetOccurrenceMethod) == null) { 64 synchronized (GrafeasGrpc.class) { 65 if ((getGetOccurrenceMethod = GrafeasGrpc.getGetOccurrenceMethod) == null) { 66 GrafeasGrpc.getGetOccurrenceMethod = 67 getGetOccurrenceMethod = 68 io.grpc.MethodDescriptor 69 .<io.grafeas.v1.GetOccurrenceRequest, io.grafeas.v1.Occurrence>newBuilder() 70 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 71 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetOccurrence")) 72 .setSampledToLocalTracing(true) 73 .setRequestMarshaller( 74 io.grpc.protobuf.ProtoUtils.marshaller( 75 io.grafeas.v1.GetOccurrenceRequest.getDefaultInstance())) 76 .setResponseMarshaller( 77 io.grpc.protobuf.ProtoUtils.marshaller( 78 io.grafeas.v1.Occurrence.getDefaultInstance())) 79 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("GetOccurrence")) 80 .build(); 81 } 82 } 83 } 84 return getGetOccurrenceMethod; 85 } 86 87 private static volatile io.grpc.MethodDescriptor< 88 io.grafeas.v1.ListOccurrencesRequest, io.grafeas.v1.ListOccurrencesResponse> 89 getListOccurrencesMethod; 90 91 @io.grpc.stub.annotations.RpcMethod( 92 fullMethodName = SERVICE_NAME + '/' + "ListOccurrences", 93 requestType = io.grafeas.v1.ListOccurrencesRequest.class, 94 responseType = io.grafeas.v1.ListOccurrencesResponse.class, 95 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 96 public static io.grpc.MethodDescriptor< 97 io.grafeas.v1.ListOccurrencesRequest, io.grafeas.v1.ListOccurrencesResponse> getListOccurrencesMethod()98 getListOccurrencesMethod() { 99 io.grpc.MethodDescriptor< 100 io.grafeas.v1.ListOccurrencesRequest, io.grafeas.v1.ListOccurrencesResponse> 101 getListOccurrencesMethod; 102 if ((getListOccurrencesMethod = GrafeasGrpc.getListOccurrencesMethod) == null) { 103 synchronized (GrafeasGrpc.class) { 104 if ((getListOccurrencesMethod = GrafeasGrpc.getListOccurrencesMethod) == null) { 105 GrafeasGrpc.getListOccurrencesMethod = 106 getListOccurrencesMethod = 107 io.grpc.MethodDescriptor 108 .<io.grafeas.v1.ListOccurrencesRequest, io.grafeas.v1.ListOccurrencesResponse> 109 newBuilder() 110 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 111 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListOccurrences")) 112 .setSampledToLocalTracing(true) 113 .setRequestMarshaller( 114 io.grpc.protobuf.ProtoUtils.marshaller( 115 io.grafeas.v1.ListOccurrencesRequest.getDefaultInstance())) 116 .setResponseMarshaller( 117 io.grpc.protobuf.ProtoUtils.marshaller( 118 io.grafeas.v1.ListOccurrencesResponse.getDefaultInstance())) 119 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("ListOccurrences")) 120 .build(); 121 } 122 } 123 } 124 return getListOccurrencesMethod; 125 } 126 127 private static volatile io.grpc.MethodDescriptor< 128 io.grafeas.v1.DeleteOccurrenceRequest, com.google.protobuf.Empty> 129 getDeleteOccurrenceMethod; 130 131 @io.grpc.stub.annotations.RpcMethod( 132 fullMethodName = SERVICE_NAME + '/' + "DeleteOccurrence", 133 requestType = io.grafeas.v1.DeleteOccurrenceRequest.class, 134 responseType = com.google.protobuf.Empty.class, 135 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 136 public static io.grpc.MethodDescriptor< 137 io.grafeas.v1.DeleteOccurrenceRequest, com.google.protobuf.Empty> getDeleteOccurrenceMethod()138 getDeleteOccurrenceMethod() { 139 io.grpc.MethodDescriptor<io.grafeas.v1.DeleteOccurrenceRequest, com.google.protobuf.Empty> 140 getDeleteOccurrenceMethod; 141 if ((getDeleteOccurrenceMethod = GrafeasGrpc.getDeleteOccurrenceMethod) == null) { 142 synchronized (GrafeasGrpc.class) { 143 if ((getDeleteOccurrenceMethod = GrafeasGrpc.getDeleteOccurrenceMethod) == null) { 144 GrafeasGrpc.getDeleteOccurrenceMethod = 145 getDeleteOccurrenceMethod = 146 io.grpc.MethodDescriptor 147 .<io.grafeas.v1.DeleteOccurrenceRequest, com.google.protobuf.Empty> 148 newBuilder() 149 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 150 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteOccurrence")) 151 .setSampledToLocalTracing(true) 152 .setRequestMarshaller( 153 io.grpc.protobuf.ProtoUtils.marshaller( 154 io.grafeas.v1.DeleteOccurrenceRequest.getDefaultInstance())) 155 .setResponseMarshaller( 156 io.grpc.protobuf.ProtoUtils.marshaller( 157 com.google.protobuf.Empty.getDefaultInstance())) 158 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("DeleteOccurrence")) 159 .build(); 160 } 161 } 162 } 163 return getDeleteOccurrenceMethod; 164 } 165 166 private static volatile io.grpc.MethodDescriptor< 167 io.grafeas.v1.CreateOccurrenceRequest, io.grafeas.v1.Occurrence> 168 getCreateOccurrenceMethod; 169 170 @io.grpc.stub.annotations.RpcMethod( 171 fullMethodName = SERVICE_NAME + '/' + "CreateOccurrence", 172 requestType = io.grafeas.v1.CreateOccurrenceRequest.class, 173 responseType = io.grafeas.v1.Occurrence.class, 174 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 175 public static io.grpc.MethodDescriptor< 176 io.grafeas.v1.CreateOccurrenceRequest, io.grafeas.v1.Occurrence> getCreateOccurrenceMethod()177 getCreateOccurrenceMethod() { 178 io.grpc.MethodDescriptor<io.grafeas.v1.CreateOccurrenceRequest, io.grafeas.v1.Occurrence> 179 getCreateOccurrenceMethod; 180 if ((getCreateOccurrenceMethod = GrafeasGrpc.getCreateOccurrenceMethod) == null) { 181 synchronized (GrafeasGrpc.class) { 182 if ((getCreateOccurrenceMethod = GrafeasGrpc.getCreateOccurrenceMethod) == null) { 183 GrafeasGrpc.getCreateOccurrenceMethod = 184 getCreateOccurrenceMethod = 185 io.grpc.MethodDescriptor 186 .<io.grafeas.v1.CreateOccurrenceRequest, io.grafeas.v1.Occurrence>newBuilder() 187 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 188 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateOccurrence")) 189 .setSampledToLocalTracing(true) 190 .setRequestMarshaller( 191 io.grpc.protobuf.ProtoUtils.marshaller( 192 io.grafeas.v1.CreateOccurrenceRequest.getDefaultInstance())) 193 .setResponseMarshaller( 194 io.grpc.protobuf.ProtoUtils.marshaller( 195 io.grafeas.v1.Occurrence.getDefaultInstance())) 196 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("CreateOccurrence")) 197 .build(); 198 } 199 } 200 } 201 return getCreateOccurrenceMethod; 202 } 203 204 private static volatile io.grpc.MethodDescriptor< 205 io.grafeas.v1.BatchCreateOccurrencesRequest, io.grafeas.v1.BatchCreateOccurrencesResponse> 206 getBatchCreateOccurrencesMethod; 207 208 @io.grpc.stub.annotations.RpcMethod( 209 fullMethodName = SERVICE_NAME + '/' + "BatchCreateOccurrences", 210 requestType = io.grafeas.v1.BatchCreateOccurrencesRequest.class, 211 responseType = io.grafeas.v1.BatchCreateOccurrencesResponse.class, 212 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 213 public static io.grpc.MethodDescriptor< 214 io.grafeas.v1.BatchCreateOccurrencesRequest, io.grafeas.v1.BatchCreateOccurrencesResponse> getBatchCreateOccurrencesMethod()215 getBatchCreateOccurrencesMethod() { 216 io.grpc.MethodDescriptor< 217 io.grafeas.v1.BatchCreateOccurrencesRequest, 218 io.grafeas.v1.BatchCreateOccurrencesResponse> 219 getBatchCreateOccurrencesMethod; 220 if ((getBatchCreateOccurrencesMethod = GrafeasGrpc.getBatchCreateOccurrencesMethod) == null) { 221 synchronized (GrafeasGrpc.class) { 222 if ((getBatchCreateOccurrencesMethod = GrafeasGrpc.getBatchCreateOccurrencesMethod) 223 == null) { 224 GrafeasGrpc.getBatchCreateOccurrencesMethod = 225 getBatchCreateOccurrencesMethod = 226 io.grpc.MethodDescriptor 227 .<io.grafeas.v1.BatchCreateOccurrencesRequest, 228 io.grafeas.v1.BatchCreateOccurrencesResponse> 229 newBuilder() 230 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 231 .setFullMethodName( 232 generateFullMethodName(SERVICE_NAME, "BatchCreateOccurrences")) 233 .setSampledToLocalTracing(true) 234 .setRequestMarshaller( 235 io.grpc.protobuf.ProtoUtils.marshaller( 236 io.grafeas.v1.BatchCreateOccurrencesRequest.getDefaultInstance())) 237 .setResponseMarshaller( 238 io.grpc.protobuf.ProtoUtils.marshaller( 239 io.grafeas.v1.BatchCreateOccurrencesResponse.getDefaultInstance())) 240 .setSchemaDescriptor( 241 new GrafeasMethodDescriptorSupplier("BatchCreateOccurrences")) 242 .build(); 243 } 244 } 245 } 246 return getBatchCreateOccurrencesMethod; 247 } 248 249 private static volatile io.grpc.MethodDescriptor< 250 io.grafeas.v1.UpdateOccurrenceRequest, io.grafeas.v1.Occurrence> 251 getUpdateOccurrenceMethod; 252 253 @io.grpc.stub.annotations.RpcMethod( 254 fullMethodName = SERVICE_NAME + '/' + "UpdateOccurrence", 255 requestType = io.grafeas.v1.UpdateOccurrenceRequest.class, 256 responseType = io.grafeas.v1.Occurrence.class, 257 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 258 public static io.grpc.MethodDescriptor< 259 io.grafeas.v1.UpdateOccurrenceRequest, io.grafeas.v1.Occurrence> getUpdateOccurrenceMethod()260 getUpdateOccurrenceMethod() { 261 io.grpc.MethodDescriptor<io.grafeas.v1.UpdateOccurrenceRequest, io.grafeas.v1.Occurrence> 262 getUpdateOccurrenceMethod; 263 if ((getUpdateOccurrenceMethod = GrafeasGrpc.getUpdateOccurrenceMethod) == null) { 264 synchronized (GrafeasGrpc.class) { 265 if ((getUpdateOccurrenceMethod = GrafeasGrpc.getUpdateOccurrenceMethod) == null) { 266 GrafeasGrpc.getUpdateOccurrenceMethod = 267 getUpdateOccurrenceMethod = 268 io.grpc.MethodDescriptor 269 .<io.grafeas.v1.UpdateOccurrenceRequest, io.grafeas.v1.Occurrence>newBuilder() 270 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 271 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateOccurrence")) 272 .setSampledToLocalTracing(true) 273 .setRequestMarshaller( 274 io.grpc.protobuf.ProtoUtils.marshaller( 275 io.grafeas.v1.UpdateOccurrenceRequest.getDefaultInstance())) 276 .setResponseMarshaller( 277 io.grpc.protobuf.ProtoUtils.marshaller( 278 io.grafeas.v1.Occurrence.getDefaultInstance())) 279 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("UpdateOccurrence")) 280 .build(); 281 } 282 } 283 } 284 return getUpdateOccurrenceMethod; 285 } 286 287 private static volatile io.grpc.MethodDescriptor< 288 io.grafeas.v1.GetOccurrenceNoteRequest, io.grafeas.v1.Note> 289 getGetOccurrenceNoteMethod; 290 291 @io.grpc.stub.annotations.RpcMethod( 292 fullMethodName = SERVICE_NAME + '/' + "GetOccurrenceNote", 293 requestType = io.grafeas.v1.GetOccurrenceNoteRequest.class, 294 responseType = io.grafeas.v1.Note.class, 295 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 296 public static io.grpc.MethodDescriptor<io.grafeas.v1.GetOccurrenceNoteRequest, io.grafeas.v1.Note> getGetOccurrenceNoteMethod()297 getGetOccurrenceNoteMethod() { 298 io.grpc.MethodDescriptor<io.grafeas.v1.GetOccurrenceNoteRequest, io.grafeas.v1.Note> 299 getGetOccurrenceNoteMethod; 300 if ((getGetOccurrenceNoteMethod = GrafeasGrpc.getGetOccurrenceNoteMethod) == null) { 301 synchronized (GrafeasGrpc.class) { 302 if ((getGetOccurrenceNoteMethod = GrafeasGrpc.getGetOccurrenceNoteMethod) == null) { 303 GrafeasGrpc.getGetOccurrenceNoteMethod = 304 getGetOccurrenceNoteMethod = 305 io.grpc.MethodDescriptor 306 .<io.grafeas.v1.GetOccurrenceNoteRequest, io.grafeas.v1.Note>newBuilder() 307 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 308 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetOccurrenceNote")) 309 .setSampledToLocalTracing(true) 310 .setRequestMarshaller( 311 io.grpc.protobuf.ProtoUtils.marshaller( 312 io.grafeas.v1.GetOccurrenceNoteRequest.getDefaultInstance())) 313 .setResponseMarshaller( 314 io.grpc.protobuf.ProtoUtils.marshaller( 315 io.grafeas.v1.Note.getDefaultInstance())) 316 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("GetOccurrenceNote")) 317 .build(); 318 } 319 } 320 } 321 return getGetOccurrenceNoteMethod; 322 } 323 324 private static volatile io.grpc.MethodDescriptor<io.grafeas.v1.GetNoteRequest, io.grafeas.v1.Note> 325 getGetNoteMethod; 326 327 @io.grpc.stub.annotations.RpcMethod( 328 fullMethodName = SERVICE_NAME + '/' + "GetNote", 329 requestType = io.grafeas.v1.GetNoteRequest.class, 330 responseType = io.grafeas.v1.Note.class, 331 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 332 public static io.grpc.MethodDescriptor<io.grafeas.v1.GetNoteRequest, io.grafeas.v1.Note> getGetNoteMethod()333 getGetNoteMethod() { 334 io.grpc.MethodDescriptor<io.grafeas.v1.GetNoteRequest, io.grafeas.v1.Note> getGetNoteMethod; 335 if ((getGetNoteMethod = GrafeasGrpc.getGetNoteMethod) == null) { 336 synchronized (GrafeasGrpc.class) { 337 if ((getGetNoteMethod = GrafeasGrpc.getGetNoteMethod) == null) { 338 GrafeasGrpc.getGetNoteMethod = 339 getGetNoteMethod = 340 io.grpc.MethodDescriptor 341 .<io.grafeas.v1.GetNoteRequest, io.grafeas.v1.Note>newBuilder() 342 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 343 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetNote")) 344 .setSampledToLocalTracing(true) 345 .setRequestMarshaller( 346 io.grpc.protobuf.ProtoUtils.marshaller( 347 io.grafeas.v1.GetNoteRequest.getDefaultInstance())) 348 .setResponseMarshaller( 349 io.grpc.protobuf.ProtoUtils.marshaller( 350 io.grafeas.v1.Note.getDefaultInstance())) 351 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("GetNote")) 352 .build(); 353 } 354 } 355 } 356 return getGetNoteMethod; 357 } 358 359 private static volatile io.grpc.MethodDescriptor< 360 io.grafeas.v1.ListNotesRequest, io.grafeas.v1.ListNotesResponse> 361 getListNotesMethod; 362 363 @io.grpc.stub.annotations.RpcMethod( 364 fullMethodName = SERVICE_NAME + '/' + "ListNotes", 365 requestType = io.grafeas.v1.ListNotesRequest.class, 366 responseType = io.grafeas.v1.ListNotesResponse.class, 367 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 368 public static io.grpc.MethodDescriptor< 369 io.grafeas.v1.ListNotesRequest, io.grafeas.v1.ListNotesResponse> getListNotesMethod()370 getListNotesMethod() { 371 io.grpc.MethodDescriptor<io.grafeas.v1.ListNotesRequest, io.grafeas.v1.ListNotesResponse> 372 getListNotesMethod; 373 if ((getListNotesMethod = GrafeasGrpc.getListNotesMethod) == null) { 374 synchronized (GrafeasGrpc.class) { 375 if ((getListNotesMethod = GrafeasGrpc.getListNotesMethod) == null) { 376 GrafeasGrpc.getListNotesMethod = 377 getListNotesMethod = 378 io.grpc.MethodDescriptor 379 .<io.grafeas.v1.ListNotesRequest, io.grafeas.v1.ListNotesResponse>newBuilder() 380 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 381 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListNotes")) 382 .setSampledToLocalTracing(true) 383 .setRequestMarshaller( 384 io.grpc.protobuf.ProtoUtils.marshaller( 385 io.grafeas.v1.ListNotesRequest.getDefaultInstance())) 386 .setResponseMarshaller( 387 io.grpc.protobuf.ProtoUtils.marshaller( 388 io.grafeas.v1.ListNotesResponse.getDefaultInstance())) 389 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("ListNotes")) 390 .build(); 391 } 392 } 393 } 394 return getListNotesMethod; 395 } 396 397 private static volatile io.grpc.MethodDescriptor< 398 io.grafeas.v1.DeleteNoteRequest, com.google.protobuf.Empty> 399 getDeleteNoteMethod; 400 401 @io.grpc.stub.annotations.RpcMethod( 402 fullMethodName = SERVICE_NAME + '/' + "DeleteNote", 403 requestType = io.grafeas.v1.DeleteNoteRequest.class, 404 responseType = com.google.protobuf.Empty.class, 405 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 406 public static io.grpc.MethodDescriptor<io.grafeas.v1.DeleteNoteRequest, com.google.protobuf.Empty> getDeleteNoteMethod()407 getDeleteNoteMethod() { 408 io.grpc.MethodDescriptor<io.grafeas.v1.DeleteNoteRequest, com.google.protobuf.Empty> 409 getDeleteNoteMethod; 410 if ((getDeleteNoteMethod = GrafeasGrpc.getDeleteNoteMethod) == null) { 411 synchronized (GrafeasGrpc.class) { 412 if ((getDeleteNoteMethod = GrafeasGrpc.getDeleteNoteMethod) == null) { 413 GrafeasGrpc.getDeleteNoteMethod = 414 getDeleteNoteMethod = 415 io.grpc.MethodDescriptor 416 .<io.grafeas.v1.DeleteNoteRequest, com.google.protobuf.Empty>newBuilder() 417 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 418 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteNote")) 419 .setSampledToLocalTracing(true) 420 .setRequestMarshaller( 421 io.grpc.protobuf.ProtoUtils.marshaller( 422 io.grafeas.v1.DeleteNoteRequest.getDefaultInstance())) 423 .setResponseMarshaller( 424 io.grpc.protobuf.ProtoUtils.marshaller( 425 com.google.protobuf.Empty.getDefaultInstance())) 426 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("DeleteNote")) 427 .build(); 428 } 429 } 430 } 431 return getDeleteNoteMethod; 432 } 433 434 private static volatile io.grpc.MethodDescriptor< 435 io.grafeas.v1.CreateNoteRequest, io.grafeas.v1.Note> 436 getCreateNoteMethod; 437 438 @io.grpc.stub.annotations.RpcMethod( 439 fullMethodName = SERVICE_NAME + '/' + "CreateNote", 440 requestType = io.grafeas.v1.CreateNoteRequest.class, 441 responseType = io.grafeas.v1.Note.class, 442 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 443 public static io.grpc.MethodDescriptor<io.grafeas.v1.CreateNoteRequest, io.grafeas.v1.Note> getCreateNoteMethod()444 getCreateNoteMethod() { 445 io.grpc.MethodDescriptor<io.grafeas.v1.CreateNoteRequest, io.grafeas.v1.Note> 446 getCreateNoteMethod; 447 if ((getCreateNoteMethod = GrafeasGrpc.getCreateNoteMethod) == null) { 448 synchronized (GrafeasGrpc.class) { 449 if ((getCreateNoteMethod = GrafeasGrpc.getCreateNoteMethod) == null) { 450 GrafeasGrpc.getCreateNoteMethod = 451 getCreateNoteMethod = 452 io.grpc.MethodDescriptor 453 .<io.grafeas.v1.CreateNoteRequest, io.grafeas.v1.Note>newBuilder() 454 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 455 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateNote")) 456 .setSampledToLocalTracing(true) 457 .setRequestMarshaller( 458 io.grpc.protobuf.ProtoUtils.marshaller( 459 io.grafeas.v1.CreateNoteRequest.getDefaultInstance())) 460 .setResponseMarshaller( 461 io.grpc.protobuf.ProtoUtils.marshaller( 462 io.grafeas.v1.Note.getDefaultInstance())) 463 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("CreateNote")) 464 .build(); 465 } 466 } 467 } 468 return getCreateNoteMethod; 469 } 470 471 private static volatile io.grpc.MethodDescriptor< 472 io.grafeas.v1.BatchCreateNotesRequest, io.grafeas.v1.BatchCreateNotesResponse> 473 getBatchCreateNotesMethod; 474 475 @io.grpc.stub.annotations.RpcMethod( 476 fullMethodName = SERVICE_NAME + '/' + "BatchCreateNotes", 477 requestType = io.grafeas.v1.BatchCreateNotesRequest.class, 478 responseType = io.grafeas.v1.BatchCreateNotesResponse.class, 479 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 480 public static io.grpc.MethodDescriptor< 481 io.grafeas.v1.BatchCreateNotesRequest, io.grafeas.v1.BatchCreateNotesResponse> getBatchCreateNotesMethod()482 getBatchCreateNotesMethod() { 483 io.grpc.MethodDescriptor< 484 io.grafeas.v1.BatchCreateNotesRequest, io.grafeas.v1.BatchCreateNotesResponse> 485 getBatchCreateNotesMethod; 486 if ((getBatchCreateNotesMethod = GrafeasGrpc.getBatchCreateNotesMethod) == null) { 487 synchronized (GrafeasGrpc.class) { 488 if ((getBatchCreateNotesMethod = GrafeasGrpc.getBatchCreateNotesMethod) == null) { 489 GrafeasGrpc.getBatchCreateNotesMethod = 490 getBatchCreateNotesMethod = 491 io.grpc.MethodDescriptor 492 .<io.grafeas.v1.BatchCreateNotesRequest, 493 io.grafeas.v1.BatchCreateNotesResponse> 494 newBuilder() 495 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 496 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "BatchCreateNotes")) 497 .setSampledToLocalTracing(true) 498 .setRequestMarshaller( 499 io.grpc.protobuf.ProtoUtils.marshaller( 500 io.grafeas.v1.BatchCreateNotesRequest.getDefaultInstance())) 501 .setResponseMarshaller( 502 io.grpc.protobuf.ProtoUtils.marshaller( 503 io.grafeas.v1.BatchCreateNotesResponse.getDefaultInstance())) 504 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("BatchCreateNotes")) 505 .build(); 506 } 507 } 508 } 509 return getBatchCreateNotesMethod; 510 } 511 512 private static volatile io.grpc.MethodDescriptor< 513 io.grafeas.v1.UpdateNoteRequest, io.grafeas.v1.Note> 514 getUpdateNoteMethod; 515 516 @io.grpc.stub.annotations.RpcMethod( 517 fullMethodName = SERVICE_NAME + '/' + "UpdateNote", 518 requestType = io.grafeas.v1.UpdateNoteRequest.class, 519 responseType = io.grafeas.v1.Note.class, 520 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 521 public static io.grpc.MethodDescriptor<io.grafeas.v1.UpdateNoteRequest, io.grafeas.v1.Note> getUpdateNoteMethod()522 getUpdateNoteMethod() { 523 io.grpc.MethodDescriptor<io.grafeas.v1.UpdateNoteRequest, io.grafeas.v1.Note> 524 getUpdateNoteMethod; 525 if ((getUpdateNoteMethod = GrafeasGrpc.getUpdateNoteMethod) == null) { 526 synchronized (GrafeasGrpc.class) { 527 if ((getUpdateNoteMethod = GrafeasGrpc.getUpdateNoteMethod) == null) { 528 GrafeasGrpc.getUpdateNoteMethod = 529 getUpdateNoteMethod = 530 io.grpc.MethodDescriptor 531 .<io.grafeas.v1.UpdateNoteRequest, io.grafeas.v1.Note>newBuilder() 532 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 533 .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateNote")) 534 .setSampledToLocalTracing(true) 535 .setRequestMarshaller( 536 io.grpc.protobuf.ProtoUtils.marshaller( 537 io.grafeas.v1.UpdateNoteRequest.getDefaultInstance())) 538 .setResponseMarshaller( 539 io.grpc.protobuf.ProtoUtils.marshaller( 540 io.grafeas.v1.Note.getDefaultInstance())) 541 .setSchemaDescriptor(new GrafeasMethodDescriptorSupplier("UpdateNote")) 542 .build(); 543 } 544 } 545 } 546 return getUpdateNoteMethod; 547 } 548 549 private static volatile io.grpc.MethodDescriptor< 550 io.grafeas.v1.ListNoteOccurrencesRequest, io.grafeas.v1.ListNoteOccurrencesResponse> 551 getListNoteOccurrencesMethod; 552 553 @io.grpc.stub.annotations.RpcMethod( 554 fullMethodName = SERVICE_NAME + '/' + "ListNoteOccurrences", 555 requestType = io.grafeas.v1.ListNoteOccurrencesRequest.class, 556 responseType = io.grafeas.v1.ListNoteOccurrencesResponse.class, 557 methodType = io.grpc.MethodDescriptor.MethodType.UNARY) 558 public static io.grpc.MethodDescriptor< 559 io.grafeas.v1.ListNoteOccurrencesRequest, io.grafeas.v1.ListNoteOccurrencesResponse> getListNoteOccurrencesMethod()560 getListNoteOccurrencesMethod() { 561 io.grpc.MethodDescriptor< 562 io.grafeas.v1.ListNoteOccurrencesRequest, io.grafeas.v1.ListNoteOccurrencesResponse> 563 getListNoteOccurrencesMethod; 564 if ((getListNoteOccurrencesMethod = GrafeasGrpc.getListNoteOccurrencesMethod) == null) { 565 synchronized (GrafeasGrpc.class) { 566 if ((getListNoteOccurrencesMethod = GrafeasGrpc.getListNoteOccurrencesMethod) == null) { 567 GrafeasGrpc.getListNoteOccurrencesMethod = 568 getListNoteOccurrencesMethod = 569 io.grpc.MethodDescriptor 570 .<io.grafeas.v1.ListNoteOccurrencesRequest, 571 io.grafeas.v1.ListNoteOccurrencesResponse> 572 newBuilder() 573 .setType(io.grpc.MethodDescriptor.MethodType.UNARY) 574 .setFullMethodName( 575 generateFullMethodName(SERVICE_NAME, "ListNoteOccurrences")) 576 .setSampledToLocalTracing(true) 577 .setRequestMarshaller( 578 io.grpc.protobuf.ProtoUtils.marshaller( 579 io.grafeas.v1.ListNoteOccurrencesRequest.getDefaultInstance())) 580 .setResponseMarshaller( 581 io.grpc.protobuf.ProtoUtils.marshaller( 582 io.grafeas.v1.ListNoteOccurrencesResponse.getDefaultInstance())) 583 .setSchemaDescriptor( 584 new GrafeasMethodDescriptorSupplier("ListNoteOccurrences")) 585 .build(); 586 } 587 } 588 } 589 return getListNoteOccurrencesMethod; 590 } 591 592 /** Creates a new async stub that supports all call types for the service */ newStub(io.grpc.Channel channel)593 public static GrafeasStub newStub(io.grpc.Channel channel) { 594 io.grpc.stub.AbstractStub.StubFactory<GrafeasStub> factory = 595 new io.grpc.stub.AbstractStub.StubFactory<GrafeasStub>() { 596 @java.lang.Override 597 public GrafeasStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 598 return new GrafeasStub(channel, callOptions); 599 } 600 }; 601 return GrafeasStub.newStub(factory, channel); 602 } 603 604 /** 605 * Creates a new blocking-style stub that supports unary and streaming output calls on the service 606 */ newBlockingStub(io.grpc.Channel channel)607 public static GrafeasBlockingStub newBlockingStub(io.grpc.Channel channel) { 608 io.grpc.stub.AbstractStub.StubFactory<GrafeasBlockingStub> factory = 609 new io.grpc.stub.AbstractStub.StubFactory<GrafeasBlockingStub>() { 610 @java.lang.Override 611 public GrafeasBlockingStub newStub( 612 io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 613 return new GrafeasBlockingStub(channel, callOptions); 614 } 615 }; 616 return GrafeasBlockingStub.newStub(factory, channel); 617 } 618 619 /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ newFutureStub(io.grpc.Channel channel)620 public static GrafeasFutureStub newFutureStub(io.grpc.Channel channel) { 621 io.grpc.stub.AbstractStub.StubFactory<GrafeasFutureStub> factory = 622 new io.grpc.stub.AbstractStub.StubFactory<GrafeasFutureStub>() { 623 @java.lang.Override 624 public GrafeasFutureStub newStub( 625 io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 626 return new GrafeasFutureStub(channel, callOptions); 627 } 628 }; 629 return GrafeasFutureStub.newStub(factory, channel); 630 } 631 632 /** 633 * 634 * 635 * <pre> 636 * [Grafeas](https://grafeas.io) API. 637 * Retrieves analysis results of Cloud components such as Docker container 638 * images. 639 * Analysis results are stored as a series of occurrences. An `Occurrence` 640 * contains information about a specific analysis instance on a resource. An 641 * occurrence refers to a `Note`. A note contains details describing the 642 * analysis and is generally stored in a separate project, called a `Provider`. 643 * Multiple occurrences can refer to the same note. 644 * For example, an SSL vulnerability could affect multiple images. In this case, 645 * there would be one note for the vulnerability and an occurrence for each 646 * image with the vulnerability referring to that note. 647 * </pre> 648 */ 649 public interface AsyncService { 650 651 /** 652 * 653 * 654 * <pre> 655 * Gets the specified occurrence. 656 * </pre> 657 */ getOccurrence( io.grafeas.v1.GetOccurrenceRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver)658 default void getOccurrence( 659 io.grafeas.v1.GetOccurrenceRequest request, 660 io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver) { 661 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 662 getGetOccurrenceMethod(), responseObserver); 663 } 664 665 /** 666 * 667 * 668 * <pre> 669 * Lists occurrences for the specified project. 670 * </pre> 671 */ listOccurrences( io.grafeas.v1.ListOccurrencesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.ListOccurrencesResponse> responseObserver)672 default void listOccurrences( 673 io.grafeas.v1.ListOccurrencesRequest request, 674 io.grpc.stub.StreamObserver<io.grafeas.v1.ListOccurrencesResponse> responseObserver) { 675 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 676 getListOccurrencesMethod(), responseObserver); 677 } 678 679 /** 680 * 681 * 682 * <pre> 683 * Deletes the specified occurrence. For example, use this method to delete an 684 * occurrence when the occurrence is no longer applicable for the given 685 * resource. 686 * </pre> 687 */ deleteOccurrence( io.grafeas.v1.DeleteOccurrenceRequest request, io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver)688 default void deleteOccurrence( 689 io.grafeas.v1.DeleteOccurrenceRequest request, 690 io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver) { 691 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 692 getDeleteOccurrenceMethod(), responseObserver); 693 } 694 695 /** 696 * 697 * 698 * <pre> 699 * Creates a new occurrence. 700 * </pre> 701 */ createOccurrence( io.grafeas.v1.CreateOccurrenceRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver)702 default void createOccurrence( 703 io.grafeas.v1.CreateOccurrenceRequest request, 704 io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver) { 705 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 706 getCreateOccurrenceMethod(), responseObserver); 707 } 708 709 /** 710 * 711 * 712 * <pre> 713 * Creates new occurrences in batch. 714 * </pre> 715 */ batchCreateOccurrences( io.grafeas.v1.BatchCreateOccurrencesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateOccurrencesResponse> responseObserver)716 default void batchCreateOccurrences( 717 io.grafeas.v1.BatchCreateOccurrencesRequest request, 718 io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateOccurrencesResponse> 719 responseObserver) { 720 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 721 getBatchCreateOccurrencesMethod(), responseObserver); 722 } 723 724 /** 725 * 726 * 727 * <pre> 728 * Updates the specified occurrence. 729 * </pre> 730 */ updateOccurrence( io.grafeas.v1.UpdateOccurrenceRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver)731 default void updateOccurrence( 732 io.grafeas.v1.UpdateOccurrenceRequest request, 733 io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver) { 734 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 735 getUpdateOccurrenceMethod(), responseObserver); 736 } 737 738 /** 739 * 740 * 741 * <pre> 742 * Gets the note attached to the specified occurrence. Consumer projects can 743 * use this method to get a note that belongs to a provider project. 744 * </pre> 745 */ getOccurrenceNote( io.grafeas.v1.GetOccurrenceNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)746 default void getOccurrenceNote( 747 io.grafeas.v1.GetOccurrenceNoteRequest request, 748 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 749 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 750 getGetOccurrenceNoteMethod(), responseObserver); 751 } 752 753 /** 754 * 755 * 756 * <pre> 757 * Gets the specified note. 758 * </pre> 759 */ getNote( io.grafeas.v1.GetNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)760 default void getNote( 761 io.grafeas.v1.GetNoteRequest request, 762 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 763 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetNoteMethod(), responseObserver); 764 } 765 766 /** 767 * 768 * 769 * <pre> 770 * Lists notes for the specified project. 771 * </pre> 772 */ listNotes( io.grafeas.v1.ListNotesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.ListNotesResponse> responseObserver)773 default void listNotes( 774 io.grafeas.v1.ListNotesRequest request, 775 io.grpc.stub.StreamObserver<io.grafeas.v1.ListNotesResponse> responseObserver) { 776 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListNotesMethod(), responseObserver); 777 } 778 779 /** 780 * 781 * 782 * <pre> 783 * Deletes the specified note. 784 * </pre> 785 */ deleteNote( io.grafeas.v1.DeleteNoteRequest request, io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver)786 default void deleteNote( 787 io.grafeas.v1.DeleteNoteRequest request, 788 io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver) { 789 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getDeleteNoteMethod(), responseObserver); 790 } 791 792 /** 793 * 794 * 795 * <pre> 796 * Creates a new note. 797 * </pre> 798 */ createNote( io.grafeas.v1.CreateNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)799 default void createNote( 800 io.grafeas.v1.CreateNoteRequest request, 801 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 802 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateNoteMethod(), responseObserver); 803 } 804 805 /** 806 * 807 * 808 * <pre> 809 * Creates new notes in batch. 810 * </pre> 811 */ batchCreateNotes( io.grafeas.v1.BatchCreateNotesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateNotesResponse> responseObserver)812 default void batchCreateNotes( 813 io.grafeas.v1.BatchCreateNotesRequest request, 814 io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateNotesResponse> responseObserver) { 815 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 816 getBatchCreateNotesMethod(), responseObserver); 817 } 818 819 /** 820 * 821 * 822 * <pre> 823 * Updates the specified note. 824 * </pre> 825 */ updateNote( io.grafeas.v1.UpdateNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)826 default void updateNote( 827 io.grafeas.v1.UpdateNoteRequest request, 828 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 829 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUpdateNoteMethod(), responseObserver); 830 } 831 832 /** 833 * 834 * 835 * <pre> 836 * Lists occurrences referencing the specified note. Provider projects can use 837 * this method to get all occurrences across consumer projects referencing the 838 * specified note. 839 * </pre> 840 */ listNoteOccurrences( io.grafeas.v1.ListNoteOccurrencesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.ListNoteOccurrencesResponse> responseObserver)841 default void listNoteOccurrences( 842 io.grafeas.v1.ListNoteOccurrencesRequest request, 843 io.grpc.stub.StreamObserver<io.grafeas.v1.ListNoteOccurrencesResponse> responseObserver) { 844 io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( 845 getListNoteOccurrencesMethod(), responseObserver); 846 } 847 } 848 849 /** 850 * Base class for the server implementation of the service Grafeas. 851 * 852 * <pre> 853 * [Grafeas](https://grafeas.io) API. 854 * Retrieves analysis results of Cloud components such as Docker container 855 * images. 856 * Analysis results are stored as a series of occurrences. An `Occurrence` 857 * contains information about a specific analysis instance on a resource. An 858 * occurrence refers to a `Note`. A note contains details describing the 859 * analysis and is generally stored in a separate project, called a `Provider`. 860 * Multiple occurrences can refer to the same note. 861 * For example, an SSL vulnerability could affect multiple images. In this case, 862 * there would be one note for the vulnerability and an occurrence for each 863 * image with the vulnerability referring to that note. 864 * </pre> 865 */ 866 public abstract static class GrafeasImplBase implements io.grpc.BindableService, AsyncService { 867 868 @java.lang.Override bindService()869 public final io.grpc.ServerServiceDefinition bindService() { 870 return GrafeasGrpc.bindService(this); 871 } 872 } 873 874 /** 875 * A stub to allow clients to do asynchronous rpc calls to service Grafeas. 876 * 877 * <pre> 878 * [Grafeas](https://grafeas.io) API. 879 * Retrieves analysis results of Cloud components such as Docker container 880 * images. 881 * Analysis results are stored as a series of occurrences. An `Occurrence` 882 * contains information about a specific analysis instance on a resource. An 883 * occurrence refers to a `Note`. A note contains details describing the 884 * analysis and is generally stored in a separate project, called a `Provider`. 885 * Multiple occurrences can refer to the same note. 886 * For example, an SSL vulnerability could affect multiple images. In this case, 887 * there would be one note for the vulnerability and an occurrence for each 888 * image with the vulnerability referring to that note. 889 * </pre> 890 */ 891 public static final class GrafeasStub extends io.grpc.stub.AbstractAsyncStub<GrafeasStub> { GrafeasStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions)892 private GrafeasStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 893 super(channel, callOptions); 894 } 895 896 @java.lang.Override build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)897 protected GrafeasStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 898 return new GrafeasStub(channel, callOptions); 899 } 900 901 /** 902 * 903 * 904 * <pre> 905 * Gets the specified occurrence. 906 * </pre> 907 */ getOccurrence( io.grafeas.v1.GetOccurrenceRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver)908 public void getOccurrence( 909 io.grafeas.v1.GetOccurrenceRequest request, 910 io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver) { 911 io.grpc.stub.ClientCalls.asyncUnaryCall( 912 getChannel().newCall(getGetOccurrenceMethod(), getCallOptions()), 913 request, 914 responseObserver); 915 } 916 917 /** 918 * 919 * 920 * <pre> 921 * Lists occurrences for the specified project. 922 * </pre> 923 */ listOccurrences( io.grafeas.v1.ListOccurrencesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.ListOccurrencesResponse> responseObserver)924 public void listOccurrences( 925 io.grafeas.v1.ListOccurrencesRequest request, 926 io.grpc.stub.StreamObserver<io.grafeas.v1.ListOccurrencesResponse> responseObserver) { 927 io.grpc.stub.ClientCalls.asyncUnaryCall( 928 getChannel().newCall(getListOccurrencesMethod(), getCallOptions()), 929 request, 930 responseObserver); 931 } 932 933 /** 934 * 935 * 936 * <pre> 937 * Deletes the specified occurrence. For example, use this method to delete an 938 * occurrence when the occurrence is no longer applicable for the given 939 * resource. 940 * </pre> 941 */ deleteOccurrence( io.grafeas.v1.DeleteOccurrenceRequest request, io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver)942 public void deleteOccurrence( 943 io.grafeas.v1.DeleteOccurrenceRequest request, 944 io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver) { 945 io.grpc.stub.ClientCalls.asyncUnaryCall( 946 getChannel().newCall(getDeleteOccurrenceMethod(), getCallOptions()), 947 request, 948 responseObserver); 949 } 950 951 /** 952 * 953 * 954 * <pre> 955 * Creates a new occurrence. 956 * </pre> 957 */ createOccurrence( io.grafeas.v1.CreateOccurrenceRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver)958 public void createOccurrence( 959 io.grafeas.v1.CreateOccurrenceRequest request, 960 io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver) { 961 io.grpc.stub.ClientCalls.asyncUnaryCall( 962 getChannel().newCall(getCreateOccurrenceMethod(), getCallOptions()), 963 request, 964 responseObserver); 965 } 966 967 /** 968 * 969 * 970 * <pre> 971 * Creates new occurrences in batch. 972 * </pre> 973 */ batchCreateOccurrences( io.grafeas.v1.BatchCreateOccurrencesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateOccurrencesResponse> responseObserver)974 public void batchCreateOccurrences( 975 io.grafeas.v1.BatchCreateOccurrencesRequest request, 976 io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateOccurrencesResponse> 977 responseObserver) { 978 io.grpc.stub.ClientCalls.asyncUnaryCall( 979 getChannel().newCall(getBatchCreateOccurrencesMethod(), getCallOptions()), 980 request, 981 responseObserver); 982 } 983 984 /** 985 * 986 * 987 * <pre> 988 * Updates the specified occurrence. 989 * </pre> 990 */ updateOccurrence( io.grafeas.v1.UpdateOccurrenceRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver)991 public void updateOccurrence( 992 io.grafeas.v1.UpdateOccurrenceRequest request, 993 io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence> responseObserver) { 994 io.grpc.stub.ClientCalls.asyncUnaryCall( 995 getChannel().newCall(getUpdateOccurrenceMethod(), getCallOptions()), 996 request, 997 responseObserver); 998 } 999 1000 /** 1001 * 1002 * 1003 * <pre> 1004 * Gets the note attached to the specified occurrence. Consumer projects can 1005 * use this method to get a note that belongs to a provider project. 1006 * </pre> 1007 */ getOccurrenceNote( io.grafeas.v1.GetOccurrenceNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)1008 public void getOccurrenceNote( 1009 io.grafeas.v1.GetOccurrenceNoteRequest request, 1010 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 1011 io.grpc.stub.ClientCalls.asyncUnaryCall( 1012 getChannel().newCall(getGetOccurrenceNoteMethod(), getCallOptions()), 1013 request, 1014 responseObserver); 1015 } 1016 1017 /** 1018 * 1019 * 1020 * <pre> 1021 * Gets the specified note. 1022 * </pre> 1023 */ getNote( io.grafeas.v1.GetNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)1024 public void getNote( 1025 io.grafeas.v1.GetNoteRequest request, 1026 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 1027 io.grpc.stub.ClientCalls.asyncUnaryCall( 1028 getChannel().newCall(getGetNoteMethod(), getCallOptions()), request, responseObserver); 1029 } 1030 1031 /** 1032 * 1033 * 1034 * <pre> 1035 * Lists notes for the specified project. 1036 * </pre> 1037 */ listNotes( io.grafeas.v1.ListNotesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.ListNotesResponse> responseObserver)1038 public void listNotes( 1039 io.grafeas.v1.ListNotesRequest request, 1040 io.grpc.stub.StreamObserver<io.grafeas.v1.ListNotesResponse> responseObserver) { 1041 io.grpc.stub.ClientCalls.asyncUnaryCall( 1042 getChannel().newCall(getListNotesMethod(), getCallOptions()), request, responseObserver); 1043 } 1044 1045 /** 1046 * 1047 * 1048 * <pre> 1049 * Deletes the specified note. 1050 * </pre> 1051 */ deleteNote( io.grafeas.v1.DeleteNoteRequest request, io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver)1052 public void deleteNote( 1053 io.grafeas.v1.DeleteNoteRequest request, 1054 io.grpc.stub.StreamObserver<com.google.protobuf.Empty> responseObserver) { 1055 io.grpc.stub.ClientCalls.asyncUnaryCall( 1056 getChannel().newCall(getDeleteNoteMethod(), getCallOptions()), request, responseObserver); 1057 } 1058 1059 /** 1060 * 1061 * 1062 * <pre> 1063 * Creates a new note. 1064 * </pre> 1065 */ createNote( io.grafeas.v1.CreateNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)1066 public void createNote( 1067 io.grafeas.v1.CreateNoteRequest request, 1068 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 1069 io.grpc.stub.ClientCalls.asyncUnaryCall( 1070 getChannel().newCall(getCreateNoteMethod(), getCallOptions()), request, responseObserver); 1071 } 1072 1073 /** 1074 * 1075 * 1076 * <pre> 1077 * Creates new notes in batch. 1078 * </pre> 1079 */ batchCreateNotes( io.grafeas.v1.BatchCreateNotesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateNotesResponse> responseObserver)1080 public void batchCreateNotes( 1081 io.grafeas.v1.BatchCreateNotesRequest request, 1082 io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateNotesResponse> responseObserver) { 1083 io.grpc.stub.ClientCalls.asyncUnaryCall( 1084 getChannel().newCall(getBatchCreateNotesMethod(), getCallOptions()), 1085 request, 1086 responseObserver); 1087 } 1088 1089 /** 1090 * 1091 * 1092 * <pre> 1093 * Updates the specified note. 1094 * </pre> 1095 */ updateNote( io.grafeas.v1.UpdateNoteRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver)1096 public void updateNote( 1097 io.grafeas.v1.UpdateNoteRequest request, 1098 io.grpc.stub.StreamObserver<io.grafeas.v1.Note> responseObserver) { 1099 io.grpc.stub.ClientCalls.asyncUnaryCall( 1100 getChannel().newCall(getUpdateNoteMethod(), getCallOptions()), request, responseObserver); 1101 } 1102 1103 /** 1104 * 1105 * 1106 * <pre> 1107 * Lists occurrences referencing the specified note. Provider projects can use 1108 * this method to get all occurrences across consumer projects referencing the 1109 * specified note. 1110 * </pre> 1111 */ listNoteOccurrences( io.grafeas.v1.ListNoteOccurrencesRequest request, io.grpc.stub.StreamObserver<io.grafeas.v1.ListNoteOccurrencesResponse> responseObserver)1112 public void listNoteOccurrences( 1113 io.grafeas.v1.ListNoteOccurrencesRequest request, 1114 io.grpc.stub.StreamObserver<io.grafeas.v1.ListNoteOccurrencesResponse> responseObserver) { 1115 io.grpc.stub.ClientCalls.asyncUnaryCall( 1116 getChannel().newCall(getListNoteOccurrencesMethod(), getCallOptions()), 1117 request, 1118 responseObserver); 1119 } 1120 } 1121 1122 /** 1123 * A stub to allow clients to do synchronous rpc calls to service Grafeas. 1124 * 1125 * <pre> 1126 * [Grafeas](https://grafeas.io) API. 1127 * Retrieves analysis results of Cloud components such as Docker container 1128 * images. 1129 * Analysis results are stored as a series of occurrences. An `Occurrence` 1130 * contains information about a specific analysis instance on a resource. An 1131 * occurrence refers to a `Note`. A note contains details describing the 1132 * analysis and is generally stored in a separate project, called a `Provider`. 1133 * Multiple occurrences can refer to the same note. 1134 * For example, an SSL vulnerability could affect multiple images. In this case, 1135 * there would be one note for the vulnerability and an occurrence for each 1136 * image with the vulnerability referring to that note. 1137 * </pre> 1138 */ 1139 public static final class GrafeasBlockingStub 1140 extends io.grpc.stub.AbstractBlockingStub<GrafeasBlockingStub> { GrafeasBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions)1141 private GrafeasBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 1142 super(channel, callOptions); 1143 } 1144 1145 @java.lang.Override build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)1146 protected GrafeasBlockingStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 1147 return new GrafeasBlockingStub(channel, callOptions); 1148 } 1149 1150 /** 1151 * 1152 * 1153 * <pre> 1154 * Gets the specified occurrence. 1155 * </pre> 1156 */ getOccurrence(io.grafeas.v1.GetOccurrenceRequest request)1157 public io.grafeas.v1.Occurrence getOccurrence(io.grafeas.v1.GetOccurrenceRequest request) { 1158 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1159 getChannel(), getGetOccurrenceMethod(), getCallOptions(), request); 1160 } 1161 1162 /** 1163 * 1164 * 1165 * <pre> 1166 * Lists occurrences for the specified project. 1167 * </pre> 1168 */ listOccurrences( io.grafeas.v1.ListOccurrencesRequest request)1169 public io.grafeas.v1.ListOccurrencesResponse listOccurrences( 1170 io.grafeas.v1.ListOccurrencesRequest request) { 1171 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1172 getChannel(), getListOccurrencesMethod(), getCallOptions(), request); 1173 } 1174 1175 /** 1176 * 1177 * 1178 * <pre> 1179 * Deletes the specified occurrence. For example, use this method to delete an 1180 * occurrence when the occurrence is no longer applicable for the given 1181 * resource. 1182 * </pre> 1183 */ deleteOccurrence( io.grafeas.v1.DeleteOccurrenceRequest request)1184 public com.google.protobuf.Empty deleteOccurrence( 1185 io.grafeas.v1.DeleteOccurrenceRequest request) { 1186 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1187 getChannel(), getDeleteOccurrenceMethod(), getCallOptions(), request); 1188 } 1189 1190 /** 1191 * 1192 * 1193 * <pre> 1194 * Creates a new occurrence. 1195 * </pre> 1196 */ createOccurrence( io.grafeas.v1.CreateOccurrenceRequest request)1197 public io.grafeas.v1.Occurrence createOccurrence( 1198 io.grafeas.v1.CreateOccurrenceRequest request) { 1199 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1200 getChannel(), getCreateOccurrenceMethod(), getCallOptions(), request); 1201 } 1202 1203 /** 1204 * 1205 * 1206 * <pre> 1207 * Creates new occurrences in batch. 1208 * </pre> 1209 */ batchCreateOccurrences( io.grafeas.v1.BatchCreateOccurrencesRequest request)1210 public io.grafeas.v1.BatchCreateOccurrencesResponse batchCreateOccurrences( 1211 io.grafeas.v1.BatchCreateOccurrencesRequest request) { 1212 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1213 getChannel(), getBatchCreateOccurrencesMethod(), getCallOptions(), request); 1214 } 1215 1216 /** 1217 * 1218 * 1219 * <pre> 1220 * Updates the specified occurrence. 1221 * </pre> 1222 */ updateOccurrence( io.grafeas.v1.UpdateOccurrenceRequest request)1223 public io.grafeas.v1.Occurrence updateOccurrence( 1224 io.grafeas.v1.UpdateOccurrenceRequest request) { 1225 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1226 getChannel(), getUpdateOccurrenceMethod(), getCallOptions(), request); 1227 } 1228 1229 /** 1230 * 1231 * 1232 * <pre> 1233 * Gets the note attached to the specified occurrence. Consumer projects can 1234 * use this method to get a note that belongs to a provider project. 1235 * </pre> 1236 */ getOccurrenceNote(io.grafeas.v1.GetOccurrenceNoteRequest request)1237 public io.grafeas.v1.Note getOccurrenceNote(io.grafeas.v1.GetOccurrenceNoteRequest request) { 1238 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1239 getChannel(), getGetOccurrenceNoteMethod(), getCallOptions(), request); 1240 } 1241 1242 /** 1243 * 1244 * 1245 * <pre> 1246 * Gets the specified note. 1247 * </pre> 1248 */ getNote(io.grafeas.v1.GetNoteRequest request)1249 public io.grafeas.v1.Note getNote(io.grafeas.v1.GetNoteRequest request) { 1250 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1251 getChannel(), getGetNoteMethod(), getCallOptions(), request); 1252 } 1253 1254 /** 1255 * 1256 * 1257 * <pre> 1258 * Lists notes for the specified project. 1259 * </pre> 1260 */ listNotes(io.grafeas.v1.ListNotesRequest request)1261 public io.grafeas.v1.ListNotesResponse listNotes(io.grafeas.v1.ListNotesRequest request) { 1262 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1263 getChannel(), getListNotesMethod(), getCallOptions(), request); 1264 } 1265 1266 /** 1267 * 1268 * 1269 * <pre> 1270 * Deletes the specified note. 1271 * </pre> 1272 */ deleteNote(io.grafeas.v1.DeleteNoteRequest request)1273 public com.google.protobuf.Empty deleteNote(io.grafeas.v1.DeleteNoteRequest request) { 1274 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1275 getChannel(), getDeleteNoteMethod(), getCallOptions(), request); 1276 } 1277 1278 /** 1279 * 1280 * 1281 * <pre> 1282 * Creates a new note. 1283 * </pre> 1284 */ createNote(io.grafeas.v1.CreateNoteRequest request)1285 public io.grafeas.v1.Note createNote(io.grafeas.v1.CreateNoteRequest request) { 1286 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1287 getChannel(), getCreateNoteMethod(), getCallOptions(), request); 1288 } 1289 1290 /** 1291 * 1292 * 1293 * <pre> 1294 * Creates new notes in batch. 1295 * </pre> 1296 */ batchCreateNotes( io.grafeas.v1.BatchCreateNotesRequest request)1297 public io.grafeas.v1.BatchCreateNotesResponse batchCreateNotes( 1298 io.grafeas.v1.BatchCreateNotesRequest request) { 1299 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1300 getChannel(), getBatchCreateNotesMethod(), getCallOptions(), request); 1301 } 1302 1303 /** 1304 * 1305 * 1306 * <pre> 1307 * Updates the specified note. 1308 * </pre> 1309 */ updateNote(io.grafeas.v1.UpdateNoteRequest request)1310 public io.grafeas.v1.Note updateNote(io.grafeas.v1.UpdateNoteRequest request) { 1311 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1312 getChannel(), getUpdateNoteMethod(), getCallOptions(), request); 1313 } 1314 1315 /** 1316 * 1317 * 1318 * <pre> 1319 * Lists occurrences referencing the specified note. Provider projects can use 1320 * this method to get all occurrences across consumer projects referencing the 1321 * specified note. 1322 * </pre> 1323 */ listNoteOccurrences( io.grafeas.v1.ListNoteOccurrencesRequest request)1324 public io.grafeas.v1.ListNoteOccurrencesResponse listNoteOccurrences( 1325 io.grafeas.v1.ListNoteOccurrencesRequest request) { 1326 return io.grpc.stub.ClientCalls.blockingUnaryCall( 1327 getChannel(), getListNoteOccurrencesMethod(), getCallOptions(), request); 1328 } 1329 } 1330 1331 /** 1332 * A stub to allow clients to do ListenableFuture-style rpc calls to service Grafeas. 1333 * 1334 * <pre> 1335 * [Grafeas](https://grafeas.io) API. 1336 * Retrieves analysis results of Cloud components such as Docker container 1337 * images. 1338 * Analysis results are stored as a series of occurrences. An `Occurrence` 1339 * contains information about a specific analysis instance on a resource. An 1340 * occurrence refers to a `Note`. A note contains details describing the 1341 * analysis and is generally stored in a separate project, called a `Provider`. 1342 * Multiple occurrences can refer to the same note. 1343 * For example, an SSL vulnerability could affect multiple images. In this case, 1344 * there would be one note for the vulnerability and an occurrence for each 1345 * image with the vulnerability referring to that note. 1346 * </pre> 1347 */ 1348 public static final class GrafeasFutureStub 1349 extends io.grpc.stub.AbstractFutureStub<GrafeasFutureStub> { GrafeasFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions)1350 private GrafeasFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 1351 super(channel, callOptions); 1352 } 1353 1354 @java.lang.Override build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)1355 protected GrafeasFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { 1356 return new GrafeasFutureStub(channel, callOptions); 1357 } 1358 1359 /** 1360 * 1361 * 1362 * <pre> 1363 * Gets the specified occurrence. 1364 * </pre> 1365 */ 1366 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Occurrence> getOccurrence(io.grafeas.v1.GetOccurrenceRequest request)1367 getOccurrence(io.grafeas.v1.GetOccurrenceRequest request) { 1368 return io.grpc.stub.ClientCalls.futureUnaryCall( 1369 getChannel().newCall(getGetOccurrenceMethod(), getCallOptions()), request); 1370 } 1371 1372 /** 1373 * 1374 * 1375 * <pre> 1376 * Lists occurrences for the specified project. 1377 * </pre> 1378 */ 1379 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.ListOccurrencesResponse> listOccurrences(io.grafeas.v1.ListOccurrencesRequest request)1380 listOccurrences(io.grafeas.v1.ListOccurrencesRequest request) { 1381 return io.grpc.stub.ClientCalls.futureUnaryCall( 1382 getChannel().newCall(getListOccurrencesMethod(), getCallOptions()), request); 1383 } 1384 1385 /** 1386 * 1387 * 1388 * <pre> 1389 * Deletes the specified occurrence. For example, use this method to delete an 1390 * occurrence when the occurrence is no longer applicable for the given 1391 * resource. 1392 * </pre> 1393 */ 1394 public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty> deleteOccurrence(io.grafeas.v1.DeleteOccurrenceRequest request)1395 deleteOccurrence(io.grafeas.v1.DeleteOccurrenceRequest request) { 1396 return io.grpc.stub.ClientCalls.futureUnaryCall( 1397 getChannel().newCall(getDeleteOccurrenceMethod(), getCallOptions()), request); 1398 } 1399 1400 /** 1401 * 1402 * 1403 * <pre> 1404 * Creates a new occurrence. 1405 * </pre> 1406 */ 1407 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Occurrence> createOccurrence(io.grafeas.v1.CreateOccurrenceRequest request)1408 createOccurrence(io.grafeas.v1.CreateOccurrenceRequest request) { 1409 return io.grpc.stub.ClientCalls.futureUnaryCall( 1410 getChannel().newCall(getCreateOccurrenceMethod(), getCallOptions()), request); 1411 } 1412 1413 /** 1414 * 1415 * 1416 * <pre> 1417 * Creates new occurrences in batch. 1418 * </pre> 1419 */ 1420 public com.google.common.util.concurrent.ListenableFuture< 1421 io.grafeas.v1.BatchCreateOccurrencesResponse> batchCreateOccurrences(io.grafeas.v1.BatchCreateOccurrencesRequest request)1422 batchCreateOccurrences(io.grafeas.v1.BatchCreateOccurrencesRequest request) { 1423 return io.grpc.stub.ClientCalls.futureUnaryCall( 1424 getChannel().newCall(getBatchCreateOccurrencesMethod(), getCallOptions()), request); 1425 } 1426 1427 /** 1428 * 1429 * 1430 * <pre> 1431 * Updates the specified occurrence. 1432 * </pre> 1433 */ 1434 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Occurrence> updateOccurrence(io.grafeas.v1.UpdateOccurrenceRequest request)1435 updateOccurrence(io.grafeas.v1.UpdateOccurrenceRequest request) { 1436 return io.grpc.stub.ClientCalls.futureUnaryCall( 1437 getChannel().newCall(getUpdateOccurrenceMethod(), getCallOptions()), request); 1438 } 1439 1440 /** 1441 * 1442 * 1443 * <pre> 1444 * Gets the note attached to the specified occurrence. Consumer projects can 1445 * use this method to get a note that belongs to a provider project. 1446 * </pre> 1447 */ getOccurrenceNote( io.grafeas.v1.GetOccurrenceNoteRequest request)1448 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Note> getOccurrenceNote( 1449 io.grafeas.v1.GetOccurrenceNoteRequest request) { 1450 return io.grpc.stub.ClientCalls.futureUnaryCall( 1451 getChannel().newCall(getGetOccurrenceNoteMethod(), getCallOptions()), request); 1452 } 1453 1454 /** 1455 * 1456 * 1457 * <pre> 1458 * Gets the specified note. 1459 * </pre> 1460 */ getNote( io.grafeas.v1.GetNoteRequest request)1461 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Note> getNote( 1462 io.grafeas.v1.GetNoteRequest request) { 1463 return io.grpc.stub.ClientCalls.futureUnaryCall( 1464 getChannel().newCall(getGetNoteMethod(), getCallOptions()), request); 1465 } 1466 1467 /** 1468 * 1469 * 1470 * <pre> 1471 * Lists notes for the specified project. 1472 * </pre> 1473 */ 1474 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.ListNotesResponse> listNotes(io.grafeas.v1.ListNotesRequest request)1475 listNotes(io.grafeas.v1.ListNotesRequest request) { 1476 return io.grpc.stub.ClientCalls.futureUnaryCall( 1477 getChannel().newCall(getListNotesMethod(), getCallOptions()), request); 1478 } 1479 1480 /** 1481 * 1482 * 1483 * <pre> 1484 * Deletes the specified note. 1485 * </pre> 1486 */ deleteNote( io.grafeas.v1.DeleteNoteRequest request)1487 public com.google.common.util.concurrent.ListenableFuture<com.google.protobuf.Empty> deleteNote( 1488 io.grafeas.v1.DeleteNoteRequest request) { 1489 return io.grpc.stub.ClientCalls.futureUnaryCall( 1490 getChannel().newCall(getDeleteNoteMethod(), getCallOptions()), request); 1491 } 1492 1493 /** 1494 * 1495 * 1496 * <pre> 1497 * Creates a new note. 1498 * </pre> 1499 */ createNote( io.grafeas.v1.CreateNoteRequest request)1500 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Note> createNote( 1501 io.grafeas.v1.CreateNoteRequest request) { 1502 return io.grpc.stub.ClientCalls.futureUnaryCall( 1503 getChannel().newCall(getCreateNoteMethod(), getCallOptions()), request); 1504 } 1505 1506 /** 1507 * 1508 * 1509 * <pre> 1510 * Creates new notes in batch. 1511 * </pre> 1512 */ 1513 public com.google.common.util.concurrent.ListenableFuture< 1514 io.grafeas.v1.BatchCreateNotesResponse> batchCreateNotes(io.grafeas.v1.BatchCreateNotesRequest request)1515 batchCreateNotes(io.grafeas.v1.BatchCreateNotesRequest request) { 1516 return io.grpc.stub.ClientCalls.futureUnaryCall( 1517 getChannel().newCall(getBatchCreateNotesMethod(), getCallOptions()), request); 1518 } 1519 1520 /** 1521 * 1522 * 1523 * <pre> 1524 * Updates the specified note. 1525 * </pre> 1526 */ updateNote( io.grafeas.v1.UpdateNoteRequest request)1527 public com.google.common.util.concurrent.ListenableFuture<io.grafeas.v1.Note> updateNote( 1528 io.grafeas.v1.UpdateNoteRequest request) { 1529 return io.grpc.stub.ClientCalls.futureUnaryCall( 1530 getChannel().newCall(getUpdateNoteMethod(), getCallOptions()), request); 1531 } 1532 1533 /** 1534 * 1535 * 1536 * <pre> 1537 * Lists occurrences referencing the specified note. Provider projects can use 1538 * this method to get all occurrences across consumer projects referencing the 1539 * specified note. 1540 * </pre> 1541 */ 1542 public com.google.common.util.concurrent.ListenableFuture< 1543 io.grafeas.v1.ListNoteOccurrencesResponse> listNoteOccurrences(io.grafeas.v1.ListNoteOccurrencesRequest request)1544 listNoteOccurrences(io.grafeas.v1.ListNoteOccurrencesRequest request) { 1545 return io.grpc.stub.ClientCalls.futureUnaryCall( 1546 getChannel().newCall(getListNoteOccurrencesMethod(), getCallOptions()), request); 1547 } 1548 } 1549 1550 private static final int METHODID_GET_OCCURRENCE = 0; 1551 private static final int METHODID_LIST_OCCURRENCES = 1; 1552 private static final int METHODID_DELETE_OCCURRENCE = 2; 1553 private static final int METHODID_CREATE_OCCURRENCE = 3; 1554 private static final int METHODID_BATCH_CREATE_OCCURRENCES = 4; 1555 private static final int METHODID_UPDATE_OCCURRENCE = 5; 1556 private static final int METHODID_GET_OCCURRENCE_NOTE = 6; 1557 private static final int METHODID_GET_NOTE = 7; 1558 private static final int METHODID_LIST_NOTES = 8; 1559 private static final int METHODID_DELETE_NOTE = 9; 1560 private static final int METHODID_CREATE_NOTE = 10; 1561 private static final int METHODID_BATCH_CREATE_NOTES = 11; 1562 private static final int METHODID_UPDATE_NOTE = 12; 1563 private static final int METHODID_LIST_NOTE_OCCURRENCES = 13; 1564 1565 private static final class MethodHandlers<Req, Resp> 1566 implements io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>, 1567 io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>, 1568 io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>, 1569 io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> { 1570 private final AsyncService serviceImpl; 1571 private final int methodId; 1572 MethodHandlers(AsyncService serviceImpl, int methodId)1573 MethodHandlers(AsyncService serviceImpl, int methodId) { 1574 this.serviceImpl = serviceImpl; 1575 this.methodId = methodId; 1576 } 1577 1578 @java.lang.Override 1579 @java.lang.SuppressWarnings("unchecked") invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserver)1580 public void invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserver) { 1581 switch (methodId) { 1582 case METHODID_GET_OCCURRENCE: 1583 serviceImpl.getOccurrence( 1584 (io.grafeas.v1.GetOccurrenceRequest) request, 1585 (io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence>) responseObserver); 1586 break; 1587 case METHODID_LIST_OCCURRENCES: 1588 serviceImpl.listOccurrences( 1589 (io.grafeas.v1.ListOccurrencesRequest) request, 1590 (io.grpc.stub.StreamObserver<io.grafeas.v1.ListOccurrencesResponse>) 1591 responseObserver); 1592 break; 1593 case METHODID_DELETE_OCCURRENCE: 1594 serviceImpl.deleteOccurrence( 1595 (io.grafeas.v1.DeleteOccurrenceRequest) request, 1596 (io.grpc.stub.StreamObserver<com.google.protobuf.Empty>) responseObserver); 1597 break; 1598 case METHODID_CREATE_OCCURRENCE: 1599 serviceImpl.createOccurrence( 1600 (io.grafeas.v1.CreateOccurrenceRequest) request, 1601 (io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence>) responseObserver); 1602 break; 1603 case METHODID_BATCH_CREATE_OCCURRENCES: 1604 serviceImpl.batchCreateOccurrences( 1605 (io.grafeas.v1.BatchCreateOccurrencesRequest) request, 1606 (io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateOccurrencesResponse>) 1607 responseObserver); 1608 break; 1609 case METHODID_UPDATE_OCCURRENCE: 1610 serviceImpl.updateOccurrence( 1611 (io.grafeas.v1.UpdateOccurrenceRequest) request, 1612 (io.grpc.stub.StreamObserver<io.grafeas.v1.Occurrence>) responseObserver); 1613 break; 1614 case METHODID_GET_OCCURRENCE_NOTE: 1615 serviceImpl.getOccurrenceNote( 1616 (io.grafeas.v1.GetOccurrenceNoteRequest) request, 1617 (io.grpc.stub.StreamObserver<io.grafeas.v1.Note>) responseObserver); 1618 break; 1619 case METHODID_GET_NOTE: 1620 serviceImpl.getNote( 1621 (io.grafeas.v1.GetNoteRequest) request, 1622 (io.grpc.stub.StreamObserver<io.grafeas.v1.Note>) responseObserver); 1623 break; 1624 case METHODID_LIST_NOTES: 1625 serviceImpl.listNotes( 1626 (io.grafeas.v1.ListNotesRequest) request, 1627 (io.grpc.stub.StreamObserver<io.grafeas.v1.ListNotesResponse>) responseObserver); 1628 break; 1629 case METHODID_DELETE_NOTE: 1630 serviceImpl.deleteNote( 1631 (io.grafeas.v1.DeleteNoteRequest) request, 1632 (io.grpc.stub.StreamObserver<com.google.protobuf.Empty>) responseObserver); 1633 break; 1634 case METHODID_CREATE_NOTE: 1635 serviceImpl.createNote( 1636 (io.grafeas.v1.CreateNoteRequest) request, 1637 (io.grpc.stub.StreamObserver<io.grafeas.v1.Note>) responseObserver); 1638 break; 1639 case METHODID_BATCH_CREATE_NOTES: 1640 serviceImpl.batchCreateNotes( 1641 (io.grafeas.v1.BatchCreateNotesRequest) request, 1642 (io.grpc.stub.StreamObserver<io.grafeas.v1.BatchCreateNotesResponse>) 1643 responseObserver); 1644 break; 1645 case METHODID_UPDATE_NOTE: 1646 serviceImpl.updateNote( 1647 (io.grafeas.v1.UpdateNoteRequest) request, 1648 (io.grpc.stub.StreamObserver<io.grafeas.v1.Note>) responseObserver); 1649 break; 1650 case METHODID_LIST_NOTE_OCCURRENCES: 1651 serviceImpl.listNoteOccurrences( 1652 (io.grafeas.v1.ListNoteOccurrencesRequest) request, 1653 (io.grpc.stub.StreamObserver<io.grafeas.v1.ListNoteOccurrencesResponse>) 1654 responseObserver); 1655 break; 1656 default: 1657 throw new AssertionError(); 1658 } 1659 } 1660 1661 @java.lang.Override 1662 @java.lang.SuppressWarnings("unchecked") invoke( io.grpc.stub.StreamObserver<Resp> responseObserver)1663 public io.grpc.stub.StreamObserver<Req> invoke( 1664 io.grpc.stub.StreamObserver<Resp> responseObserver) { 1665 switch (methodId) { 1666 default: 1667 throw new AssertionError(); 1668 } 1669 } 1670 } 1671 bindService(AsyncService service)1672 public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) { 1673 return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) 1674 .addMethod( 1675 getGetOccurrenceMethod(), 1676 io.grpc.stub.ServerCalls.asyncUnaryCall( 1677 new MethodHandlers<io.grafeas.v1.GetOccurrenceRequest, io.grafeas.v1.Occurrence>( 1678 service, METHODID_GET_OCCURRENCE))) 1679 .addMethod( 1680 getListOccurrencesMethod(), 1681 io.grpc.stub.ServerCalls.asyncUnaryCall( 1682 new MethodHandlers< 1683 io.grafeas.v1.ListOccurrencesRequest, io.grafeas.v1.ListOccurrencesResponse>( 1684 service, METHODID_LIST_OCCURRENCES))) 1685 .addMethod( 1686 getDeleteOccurrenceMethod(), 1687 io.grpc.stub.ServerCalls.asyncUnaryCall( 1688 new MethodHandlers< 1689 io.grafeas.v1.DeleteOccurrenceRequest, com.google.protobuf.Empty>( 1690 service, METHODID_DELETE_OCCURRENCE))) 1691 .addMethod( 1692 getCreateOccurrenceMethod(), 1693 io.grpc.stub.ServerCalls.asyncUnaryCall( 1694 new MethodHandlers<io.grafeas.v1.CreateOccurrenceRequest, io.grafeas.v1.Occurrence>( 1695 service, METHODID_CREATE_OCCURRENCE))) 1696 .addMethod( 1697 getBatchCreateOccurrencesMethod(), 1698 io.grpc.stub.ServerCalls.asyncUnaryCall( 1699 new MethodHandlers< 1700 io.grafeas.v1.BatchCreateOccurrencesRequest, 1701 io.grafeas.v1.BatchCreateOccurrencesResponse>( 1702 service, METHODID_BATCH_CREATE_OCCURRENCES))) 1703 .addMethod( 1704 getUpdateOccurrenceMethod(), 1705 io.grpc.stub.ServerCalls.asyncUnaryCall( 1706 new MethodHandlers<io.grafeas.v1.UpdateOccurrenceRequest, io.grafeas.v1.Occurrence>( 1707 service, METHODID_UPDATE_OCCURRENCE))) 1708 .addMethod( 1709 getGetOccurrenceNoteMethod(), 1710 io.grpc.stub.ServerCalls.asyncUnaryCall( 1711 new MethodHandlers<io.grafeas.v1.GetOccurrenceNoteRequest, io.grafeas.v1.Note>( 1712 service, METHODID_GET_OCCURRENCE_NOTE))) 1713 .addMethod( 1714 getGetNoteMethod(), 1715 io.grpc.stub.ServerCalls.asyncUnaryCall( 1716 new MethodHandlers<io.grafeas.v1.GetNoteRequest, io.grafeas.v1.Note>( 1717 service, METHODID_GET_NOTE))) 1718 .addMethod( 1719 getListNotesMethod(), 1720 io.grpc.stub.ServerCalls.asyncUnaryCall( 1721 new MethodHandlers<io.grafeas.v1.ListNotesRequest, io.grafeas.v1.ListNotesResponse>( 1722 service, METHODID_LIST_NOTES))) 1723 .addMethod( 1724 getDeleteNoteMethod(), 1725 io.grpc.stub.ServerCalls.asyncUnaryCall( 1726 new MethodHandlers<io.grafeas.v1.DeleteNoteRequest, com.google.protobuf.Empty>( 1727 service, METHODID_DELETE_NOTE))) 1728 .addMethod( 1729 getCreateNoteMethod(), 1730 io.grpc.stub.ServerCalls.asyncUnaryCall( 1731 new MethodHandlers<io.grafeas.v1.CreateNoteRequest, io.grafeas.v1.Note>( 1732 service, METHODID_CREATE_NOTE))) 1733 .addMethod( 1734 getBatchCreateNotesMethod(), 1735 io.grpc.stub.ServerCalls.asyncUnaryCall( 1736 new MethodHandlers< 1737 io.grafeas.v1.BatchCreateNotesRequest, io.grafeas.v1.BatchCreateNotesResponse>( 1738 service, METHODID_BATCH_CREATE_NOTES))) 1739 .addMethod( 1740 getUpdateNoteMethod(), 1741 io.grpc.stub.ServerCalls.asyncUnaryCall( 1742 new MethodHandlers<io.grafeas.v1.UpdateNoteRequest, io.grafeas.v1.Note>( 1743 service, METHODID_UPDATE_NOTE))) 1744 .addMethod( 1745 getListNoteOccurrencesMethod(), 1746 io.grpc.stub.ServerCalls.asyncUnaryCall( 1747 new MethodHandlers< 1748 io.grafeas.v1.ListNoteOccurrencesRequest, 1749 io.grafeas.v1.ListNoteOccurrencesResponse>( 1750 service, METHODID_LIST_NOTE_OCCURRENCES))) 1751 .build(); 1752 } 1753 1754 private abstract static class GrafeasBaseDescriptorSupplier 1755 implements io.grpc.protobuf.ProtoFileDescriptorSupplier, 1756 io.grpc.protobuf.ProtoServiceDescriptorSupplier { GrafeasBaseDescriptorSupplier()1757 GrafeasBaseDescriptorSupplier() {} 1758 1759 @java.lang.Override getFileDescriptor()1760 public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { 1761 return io.grafeas.v1.GrafeasOuterClass.getDescriptor(); 1762 } 1763 1764 @java.lang.Override getServiceDescriptor()1765 public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { 1766 return getFileDescriptor().findServiceByName("Grafeas"); 1767 } 1768 } 1769 1770 private static final class GrafeasFileDescriptorSupplier extends GrafeasBaseDescriptorSupplier { GrafeasFileDescriptorSupplier()1771 GrafeasFileDescriptorSupplier() {} 1772 } 1773 1774 private static final class GrafeasMethodDescriptorSupplier extends GrafeasBaseDescriptorSupplier 1775 implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { 1776 private final String methodName; 1777 GrafeasMethodDescriptorSupplier(String methodName)1778 GrafeasMethodDescriptorSupplier(String methodName) { 1779 this.methodName = methodName; 1780 } 1781 1782 @java.lang.Override getMethodDescriptor()1783 public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { 1784 return getServiceDescriptor().findMethodByName(methodName); 1785 } 1786 } 1787 1788 private static volatile io.grpc.ServiceDescriptor serviceDescriptor; 1789 getServiceDescriptor()1790 public static io.grpc.ServiceDescriptor getServiceDescriptor() { 1791 io.grpc.ServiceDescriptor result = serviceDescriptor; 1792 if (result == null) { 1793 synchronized (GrafeasGrpc.class) { 1794 result = serviceDescriptor; 1795 if (result == null) { 1796 serviceDescriptor = 1797 result = 1798 io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) 1799 .setSchemaDescriptor(new GrafeasFileDescriptorSupplier()) 1800 .addMethod(getGetOccurrenceMethod()) 1801 .addMethod(getListOccurrencesMethod()) 1802 .addMethod(getDeleteOccurrenceMethod()) 1803 .addMethod(getCreateOccurrenceMethod()) 1804 .addMethod(getBatchCreateOccurrencesMethod()) 1805 .addMethod(getUpdateOccurrenceMethod()) 1806 .addMethod(getGetOccurrenceNoteMethod()) 1807 .addMethod(getGetNoteMethod()) 1808 .addMethod(getListNotesMethod()) 1809 .addMethod(getDeleteNoteMethod()) 1810 .addMethod(getCreateNoteMethod()) 1811 .addMethod(getBatchCreateNotesMethod()) 1812 .addMethod(getUpdateNoteMethod()) 1813 .addMethod(getListNoteOccurrencesMethod()) 1814 .build(); 1815 } 1816 } 1817 } 1818 return result; 1819 } 1820 } 1821