From 9582175caef14e8d4be201b1492cccc52b8f8a3e Mon Sep 17 00:00:00 2001 From: Tomo Suzuki Date: Tue, 15 Nov 2022 21:27:49 +0000 Subject: [PATCH] chore: manual owlbot-java invocation --- .../google-cloud-eventarc-parent-bom/pom.xml | 94 + .../google-cloud-eventarc-parent/pom.xml | 139 + .../cloud/eventarc/v1/EventarcClient.java | 0 .../cloud/eventarc/v1/EventarcSettings.java | 1 - .../cloud/eventarc/v1/gapic_metadata.json | 0 .../cloud/eventarc/v1/package-info.java | 0 .../cloud/eventarc/v1/stub/EventarcStub.java | 0 .../v1/stub/EventarcStubSettings.java | 0 .../v1/stub/GrpcEventarcCallableFactory.java | 0 .../eventarc/v1/stub/GrpcEventarcStub.java | 1 - .../stub/HttpJsonEventarcCallableFactory.java | 0 .../v1/stub/HttpJsonEventarcStub.java | 1 - .../v1/EventarcClientHttpJsonTest.java | 0 .../cloud/eventarc/v1/EventarcClientTest.java | 0 .../cloud/eventarc/v1/MockEventarc.java | 0 .../cloud/eventarc/v1/MockEventarcImpl.java | 0 .../cloud/eventarc/v1/MockIAMPolicy.java | 0 .../cloud/eventarc/v1/MockIAMPolicyImpl.java | 0 .../cloud/eventarc/v1/MockLocations.java | 0 .../cloud/eventarc/v1/MockLocationsImpl.java | 0 .../cloud/eventarc/v1/EventarcGrpc.java | 2323 ++++++++++ .../com/google/cloud/eventarc/v1/Channel.java | 2680 ++++++++++++ .../cloud/eventarc/v1/ChannelConnection.java | 1778 ++++++++ .../eventarc/v1/ChannelConnectionName.java | 0 .../v1/ChannelConnectionOrBuilder.java | 217 + .../eventarc/v1/ChannelConnectionProto.java | 94 + .../google/cloud/eventarc/v1/ChannelName.java | 0 .../cloud/eventarc/v1/ChannelOrBuilder.java | 326 ++ .../cloud/eventarc/v1/ChannelProto.java | 106 + .../google/cloud/eventarc/v1/CloudRun.java | 1017 +++++ .../cloud/eventarc/v1/CloudRunOrBuilder.java | 114 + .../v1/CreateChannelConnectionRequest.java | 1102 +++++ ...eateChannelConnectionRequestOrBuilder.java | 120 + .../eventarc/v1/CreateChannelRequest.java | 1188 +++++ .../v1/CreateChannelRequestOrBuilder.java | 131 + .../eventarc/v1/CreateTriggerRequest.java | 1188 +++++ .../v1/CreateTriggerRequestOrBuilder.java | 131 + .../v1/DeleteChannelConnectionRequest.java | 631 +++ ...leteChannelConnectionRequestOrBuilder.java | 54 + .../eventarc/v1/DeleteChannelRequest.java | 724 +++ .../v1/DeleteChannelRequestOrBuilder.java | 68 + .../eventarc/v1/DeleteTriggerRequest.java | 1004 +++++ .../v1/DeleteTriggerRequestOrBuilder.java | 109 + .../google/cloud/eventarc/v1/Destination.java | 1641 +++++++ .../eventarc/v1/DestinationOrBuilder.java | 189 + .../cloud/eventarc/v1/DiscoveryProto.java | 114 + .../google/cloud/eventarc/v1/EventFilter.java | 1004 +++++ .../eventarc/v1/EventFilterOrBuilder.java | 110 + .../google/cloud/eventarc/v1/EventType.java | 1576 +++++++ .../cloud/eventarc/v1/EventTypeOrBuilder.java | 179 + .../cloud/eventarc/v1/EventarcProto.java | 560 +++ .../cloud/eventarc/v1/FilteringAttribute.java | 985 +++++ .../v1/FilteringAttributeOrBuilder.java | 103 + .../com/google/cloud/eventarc/v1/GKE.java | 1357 ++++++ .../cloud/eventarc/v1/GKEOrBuilder.java | 160 + .../v1/GetChannelConnectionRequest.java | 630 +++ .../GetChannelConnectionRequestOrBuilder.java | 54 + .../cloud/eventarc/v1/GetChannelRequest.java | 628 +++ .../v1/GetChannelRequestOrBuilder.java | 54 + .../v1/GetGoogleChannelConfigRequest.java | 630 +++ ...etGoogleChannelConfigRequestOrBuilder.java | 54 + .../cloud/eventarc/v1/GetProviderRequest.java | 629 +++ .../v1/GetProviderRequestOrBuilder.java | 54 + .../cloud/eventarc/v1/GetTriggerRequest.java | 628 +++ .../v1/GetTriggerRequestOrBuilder.java | 54 + .../eventarc/v1/GoogleChannelConfig.java | 1127 +++++ .../eventarc/v1/GoogleChannelConfigName.java | 0 .../v1/GoogleChannelConfigOrBuilder.java | 125 + .../eventarc/v1/GoogleChannelConfigProto.java | 95 + .../v1/ListChannelConnectionsRequest.java | 924 ++++ ...istChannelConnectionsRequestOrBuilder.java | 99 + .../v1/ListChannelConnectionsResponse.java | 1428 ++++++ ...stChannelConnectionsResponseOrBuilder.java | 162 + .../eventarc/v1/ListChannelsRequest.java | 1122 +++++ .../v1/ListChannelsRequestOrBuilder.java | 130 + .../eventarc/v1/ListChannelsResponse.java | 1380 ++++++ .../v1/ListChannelsResponseOrBuilder.java | 155 + .../eventarc/v1/ListProvidersRequest.java | 1296 ++++++ .../v1/ListProvidersRequestOrBuilder.java | 154 + .../eventarc/v1/ListProvidersResponse.java | 1380 ++++++ .../v1/ListProvidersResponseOrBuilder.java | 155 + .../eventarc/v1/ListTriggersRequest.java | 1314 ++++++ .../v1/ListTriggersRequestOrBuilder.java | 159 + .../eventarc/v1/ListTriggersResponse.java | 1380 ++++++ .../v1/ListTriggersResponseOrBuilder.java | 155 + .../cloud/eventarc/v1/LocationName.java | 0 .../cloud/eventarc/v1/OperationMetadata.java | 1806 ++++++++ .../v1/OperationMetadataOrBuilder.java | 217 + .../google/cloud/eventarc/v1/Provider.java | 1332 ++++++ .../cloud/eventarc/v1/ProviderName.java | 0 .../cloud/eventarc/v1/ProviderOrBuilder.java | 139 + .../com/google/cloud/eventarc/v1/Pubsub.java | 838 ++++ .../cloud/eventarc/v1/PubsubOrBuilder.java | 89 + .../cloud/eventarc/v1/StateCondition.java | 761 ++++ .../eventarc/v1/StateConditionOrBuilder.java | 75 + .../google/cloud/eventarc/v1/Transport.java | 820 ++++ .../cloud/eventarc/v1/TransportOrBuilder.java | 65 + .../com/google/cloud/eventarc/v1/Trigger.java | 3874 +++++++++++++++++ .../google/cloud/eventarc/v1/TriggerName.java | 0 .../cloud/eventarc/v1/TriggerOrBuilder.java | 552 +++ .../cloud/eventarc/v1/TriggerProto.java | 253 ++ .../eventarc/v1/UpdateChannelRequest.java | 1083 +++++ .../v1/UpdateChannelRequestOrBuilder.java | 115 + .../v1/UpdateGoogleChannelConfigRequest.java | 1025 +++++ ...teGoogleChannelConfigRequestOrBuilder.java | 107 + .../eventarc/v1/UpdateTriggerRequest.java | 1178 +++++ .../v1/UpdateTriggerRequestOrBuilder.java | 129 + .../google/cloud/eventarc/v1/channel.proto | 0 .../eventarc/v1/channel_connection.proto | 0 .../google/cloud/eventarc/v1/discovery.proto | 0 .../google/cloud/eventarc/v1/eventarc.proto | 0 .../eventarc/v1/google_channel_config.proto | 0 .../google/cloud/eventarc/v1/trigger.proto | 0 .../SyncCreateSetCredentialsProvider.java | 0 .../SyncCreateSetCredentialsProvider1.java | 0 .../create/SyncCreateSetEndpoint.java | 0 .../createchannel/AsyncCreateChannel.java | 0 .../createchannel/AsyncCreateChannelLRO.java | 0 .../createchannel/SyncCreateChannel.java | 0 ...reateChannelLocationnameChannelString.java | 0 .../SyncCreateChannelStringChannelString.java | 0 .../AsyncCreateChannelConnection.java | 0 .../AsyncCreateChannelConnectionLRO.java | 0 .../SyncCreateChannelConnection.java | 0 ...onLocationnameChannelconnectionString.java | 0 ...nnectionStringChannelconnectionString.java | 0 .../createtrigger/AsyncCreateTrigger.java | 0 .../createtrigger/AsyncCreateTriggerLRO.java | 0 .../createtrigger/SyncCreateTrigger.java | 0 ...reateTriggerLocationnameTriggerString.java | 0 .../SyncCreateTriggerStringTriggerString.java | 0 .../deletechannel/AsyncDeleteChannel.java | 0 .../deletechannel/AsyncDeleteChannelLRO.java | 0 .../deletechannel/SyncDeleteChannel.java | 0 .../SyncDeleteChannelChannelname.java | 0 .../SyncDeleteChannelString.java | 0 .../AsyncDeleteChannelConnection.java | 0 .../AsyncDeleteChannelConnectionLRO.java | 0 .../SyncDeleteChannelConnection.java | 0 ...hannelConnectionChannelconnectionname.java | 0 .../SyncDeleteChannelConnectionString.java | 0 .../deletetrigger/AsyncDeleteTrigger.java | 0 .../deletetrigger/AsyncDeleteTriggerLRO.java | 0 .../deletetrigger/SyncDeleteTrigger.java | 0 .../SyncDeleteTriggerStringBoolean.java | 0 .../SyncDeleteTriggerTriggernameBoolean.java | 0 .../eventarc/getchannel/AsyncGetChannel.java | 0 .../eventarc/getchannel/SyncGetChannel.java | 0 .../getchannel/SyncGetChannelChannelname.java | 0 .../getchannel/SyncGetChannelString.java | 0 .../AsyncGetChannelConnection.java | 0 .../SyncGetChannelConnection.java | 0 ...hannelConnectionChannelconnectionname.java | 0 .../SyncGetChannelConnectionString.java | 0 .../AsyncGetGoogleChannelConfig.java | 0 .../SyncGetGoogleChannelConfig.java | 0 ...eChannelConfigGooglechannelconfigname.java | 0 .../SyncGetGoogleChannelConfigString.java | 0 .../getiampolicy/AsyncGetIamPolicy.java | 0 .../getiampolicy/SyncGetIamPolicy.java | 0 .../getlocation/AsyncGetLocation.java | 0 .../eventarc/getlocation/SyncGetLocation.java | 0 .../getprovider/AsyncGetProvider.java | 0 .../eventarc/getprovider/SyncGetProvider.java | 0 .../SyncGetProviderProvidername.java | 0 .../getprovider/SyncGetProviderString.java | 0 .../eventarc/gettrigger/AsyncGetTrigger.java | 0 .../eventarc/gettrigger/SyncGetTrigger.java | 0 .../gettrigger/SyncGetTriggerString.java | 0 .../gettrigger/SyncGetTriggerTriggername.java | 0 .../AsyncListChannelConnections.java | 0 .../AsyncListChannelConnectionsPaged.java | 0 .../SyncListChannelConnections.java | 0 ...yncListChannelConnectionsLocationname.java | 0 .../SyncListChannelConnectionsString.java | 0 .../listchannels/AsyncListChannels.java | 0 .../listchannels/AsyncListChannelsPaged.java | 0 .../listchannels/SyncListChannels.java | 0 .../SyncListChannelsLocationname.java | 0 .../listchannels/SyncListChannelsString.java | 0 .../listlocations/AsyncListLocations.java | 0 .../AsyncListLocationsPaged.java | 0 .../listlocations/SyncListLocations.java | 0 .../listproviders/AsyncListProviders.java | 0 .../AsyncListProvidersPaged.java | 0 .../listproviders/SyncListProviders.java | 0 .../SyncListProvidersLocationname.java | 0 .../SyncListProvidersString.java | 0 .../listtriggers/AsyncListTriggers.java | 0 .../listtriggers/AsyncListTriggersPaged.java | 0 .../listtriggers/SyncListTriggers.java | 0 .../SyncListTriggersLocationname.java | 0 .../listtriggers/SyncListTriggersString.java | 0 .../setiampolicy/AsyncSetIamPolicy.java | 0 .../setiampolicy/SyncSetIamPolicy.java | 0 .../AsyncTestIamPermissions.java | 0 .../SyncTestIamPermissions.java | 0 .../updatechannel/AsyncUpdateChannel.java | 0 .../updatechannel/AsyncUpdateChannelLRO.java | 0 .../updatechannel/SyncUpdateChannel.java | 0 .../SyncUpdateChannelChannelFieldmask.java | 0 .../AsyncUpdateGoogleChannelConfig.java | 0 .../SyncUpdateGoogleChannelConfig.java | 0 ...nelConfigGooglechannelconfigFieldmask.java | 0 .../updatetrigger/AsyncUpdateTrigger.java | 0 .../updatetrigger/AsyncUpdateTriggerLRO.java | 0 .../updatetrigger/SyncUpdateTrigger.java | 0 ...cUpdateTriggerTriggerFieldmaskBoolean.java | 0 .../gettrigger/SyncGetTrigger.java | 0 .../gettrigger/SyncGetTrigger.java | 0 .../cloud/eventarc/v1/EventarcClient.java | 3509 +++++++++++++++ .../cloud/eventarc/v1/EventarcSettings.java | 568 +++ .../cloud/eventarc/v1/gapic_metadata.json | 87 + .../cloud/eventarc/v1/package-info.java | 44 + .../cloud/eventarc/v1/stub/EventarcStub.java | 253 ++ .../v1/stub/EventarcStubSettings.java | 1568 +++++++ .../v1/stub/GrpcEventarcCallableFactory.java | 113 + .../eventarc/v1/stub/GrpcEventarcStub.java | 1041 +++++ .../stub/HttpJsonEventarcCallableFactory.java | 105 + .../v1/stub/HttpJsonEventarcStub.java | 1614 +++++++ .../v1/EventarcClientHttpJsonTest.java | 2222 ++++++++++ .../cloud/eventarc/v1/EventarcClientTest.java | 2016 +++++++++ .../cloud/eventarc/v1/MockEventarc.java | 59 + .../cloud/eventarc/v1/MockEventarcImpl.java | 438 ++ .../cloud/eventarc/v1/MockIAMPolicy.java | 59 + .../cloud/eventarc/v1/MockIAMPolicyImpl.java | 127 + .../cloud/eventarc/v1/MockLocations.java | 59 + .../cloud/eventarc/v1/MockLocationsImpl.java | 105 + .../cloud/eventarc/v1/EventarcGrpc.java | 2308 ++++++++++ .../com/google/cloud/eventarc/v1/Channel.java | 1186 +++-- .../cloud/eventarc/v1/ChannelConnection.java | 826 ++-- .../eventarc/v1/ChannelConnectionName.java | 231 + .../v1/ChannelConnectionOrBuilder.java | 81 +- .../eventarc/v1/ChannelConnectionProto.java | 79 + .../google/cloud/eventarc/v1/ChannelName.java | 223 + .../cloud/eventarc/v1/ChannelOrBuilder.java | 116 +- .../cloud/eventarc/v1/ChannelProto.java | 91 + .../google/cloud/eventarc/v1/CloudRun.java | 487 ++- .../cloud/eventarc/v1/CloudRunOrBuilder.java | 38 +- .../v1/CreateChannelConnectionRequest.java | 554 ++- ...eateChannelConnectionRequestOrBuilder.java | 49 +- .../eventarc/v1/CreateChannelRequest.java | 579 ++- .../v1/CreateChannelRequestOrBuilder.java | 49 +- .../eventarc/v1/CreateTriggerRequest.java | 579 ++- .../v1/CreateTriggerRequestOrBuilder.java | 49 +- .../v1/DeleteChannelConnectionRequest.java | 346 +- ...leteChannelConnectionRequestOrBuilder.java | 20 +- .../eventarc/v1/DeleteChannelRequest.java | 378 +- .../v1/DeleteChannelRequestOrBuilder.java | 23 +- .../eventarc/v1/DeleteTriggerRequest.java | 495 ++- .../v1/DeleteTriggerRequestOrBuilder.java | 35 +- .../google/cloud/eventarc/v1/Destination.java | 662 +-- .../eventarc/v1/DestinationOrBuilder.java | 43 +- .../cloud/eventarc/v1/DiscoveryProto.java | 99 + .../google/cloud/eventarc/v1/EventFilter.java | 460 +- .../eventarc/v1/EventFilterOrBuilder.java | 30 +- .../google/cloud/eventarc/v1/EventType.java | 686 +-- .../cloud/eventarc/v1/EventTypeOrBuilder.java | 65 +- .../cloud/eventarc/v1/EventarcProto.java | 545 +++ .../cloud/eventarc/v1/FilteringAttribute.java | 463 +- .../v1/FilteringAttributeOrBuilder.java | 27 +- .../com/google/cloud/eventarc/v1/GKE.java | 601 +-- .../cloud/eventarc/v1/GKEOrBuilder.java | 48 +- .../v1/GetChannelConnectionRequest.java | 343 +- .../GetChannelConnectionRequestOrBuilder.java | 20 +- .../cloud/eventarc/v1/GetChannelRequest.java | 333 +- .../v1/GetChannelRequestOrBuilder.java | 20 +- .../v1/GetGoogleChannelConfigRequest.java | 343 +- ...etGoogleChannelConfigRequestOrBuilder.java | 20 +- .../cloud/eventarc/v1/GetProviderRequest.java | 336 +- .../v1/GetProviderRequestOrBuilder.java | 20 +- .../cloud/eventarc/v1/GetTriggerRequest.java | 333 +- .../v1/GetTriggerRequestOrBuilder.java | 20 +- .../eventarc/v1/GoogleChannelConfig.java | 541 ++- .../eventarc/v1/GoogleChannelConfigName.java | 193 + .../v1/GoogleChannelConfigOrBuilder.java | 46 +- .../eventarc/v1/GoogleChannelConfigProto.java | 80 + .../v1/ListChannelConnectionsRequest.java | 457 +- ...istChannelConnectionsRequestOrBuilder.java | 32 +- .../v1/ListChannelConnectionsResponse.java | 565 ++- ...stChannelConnectionsResponseOrBuilder.java | 48 +- .../eventarc/v1/ListChannelsRequest.java | 527 ++- .../v1/ListChannelsRequestOrBuilder.java | 41 +- .../eventarc/v1/ListChannelsResponse.java | 573 ++- .../v1/ListChannelsResponseOrBuilder.java | 48 +- .../eventarc/v1/ListProvidersRequest.java | 604 +-- .../v1/ListProvidersRequestOrBuilder.java | 50 +- .../eventarc/v1/ListProvidersResponse.java | 573 ++- .../v1/ListProvidersResponseOrBuilder.java | 48 +- .../eventarc/v1/ListTriggersRequest.java | 604 +-- .../v1/ListTriggersRequestOrBuilder.java | 50 +- .../eventarc/v1/ListTriggersResponse.java | 573 ++- .../v1/ListTriggersResponseOrBuilder.java | 48 +- .../cloud/eventarc/v1/LocationName.java | 192 + .../cloud/eventarc/v1/OperationMetadata.java | 823 ++-- .../v1/OperationMetadataOrBuilder.java | 76 +- .../google/cloud/eventarc/v1/Provider.java | 626 +-- .../cloud/eventarc/v1/ProviderName.java | 223 + .../cloud/eventarc/v1/ProviderOrBuilder.java | 59 +- .../com/google/cloud/eventarc/v1/Pubsub.java | 377 +- .../cloud/eventarc/v1/PubsubOrBuilder.java | 21 +- .../cloud/eventarc/v1/StateCondition.java | 355 +- .../eventarc/v1/StateConditionOrBuilder.java | 18 +- .../google/cloud/eventarc/v1/Transport.java | 354 +- .../cloud/eventarc/v1/TransportOrBuilder.java | 11 +- .../com/google/cloud/eventarc/v1/Trigger.java | 1957 +++++---- .../google/cloud/eventarc/v1/TriggerName.java | 223 + .../cloud/eventarc/v1/TriggerOrBuilder.java | 250 +- .../cloud/eventarc/v1/TriggerProto.java | 238 + .../eventarc/v1/UpdateChannelRequest.java | 436 +- .../v1/UpdateChannelRequestOrBuilder.java | 22 +- .../v1/UpdateGoogleChannelConfigRequest.java | 479 +- ...teGoogleChannelConfigRequestOrBuilder.java | 31 +- .../eventarc/v1/UpdateTriggerRequest.java | 472 +- .../v1/UpdateTriggerRequestOrBuilder.java | 25 +- .../google/cloud/eventarc/v1/channel.proto | 120 + .../eventarc/v1/channel_connection.proto | 71 + .../google/cloud/eventarc/v1/discovery.proto | 86 + .../google/cloud/eventarc/v1/eventarc.proto | 632 +++ .../eventarc/v1/google_channel_config.proto | 65 + .../google/cloud/eventarc/v1/trigger.proto | 251 ++ .../SyncCreateSetCredentialsProvider.java | 44 + .../SyncCreateSetCredentialsProvider1.java | 39 + .../create/SyncCreateSetEndpoint.java | 41 + .../createchannel/AsyncCreateChannel.java | 53 + .../createchannel/AsyncCreateChannelLRO.java | 54 + .../createchannel/SyncCreateChannel.java | 49 + ...reateChannelLocationnameChannelString.java | 44 + .../SyncCreateChannelStringChannelString.java | 44 + .../AsyncCreateChannelConnection.java | 53 + .../AsyncCreateChannelConnectionLRO.java | 53 + .../SyncCreateChannelConnection.java | 48 + ...onLocationnameChannelconnectionString.java | 48 + ...nnectionStringChannelconnectionString.java | 47 + .../createtrigger/AsyncCreateTrigger.java | 53 + .../createtrigger/AsyncCreateTriggerLRO.java | 54 + .../createtrigger/SyncCreateTrigger.java | 49 + ...reateTriggerLocationnameTriggerString.java | 44 + .../SyncCreateTriggerStringTriggerString.java | 44 + .../deletechannel/AsyncDeleteChannel.java | 50 + .../deletechannel/AsyncDeleteChannelLRO.java | 52 + .../deletechannel/SyncDeleteChannel.java | 47 + .../SyncDeleteChannelChannelname.java | 42 + .../SyncDeleteChannelString.java | 42 + .../AsyncDeleteChannelConnection.java | 52 + .../AsyncDeleteChannelConnectionLRO.java | 53 + .../SyncDeleteChannelConnection.java | 48 + ...hannelConnectionChannelconnectionname.java | 43 + .../SyncDeleteChannelConnectionString.java | 43 + .../deletetrigger/AsyncDeleteTrigger.java | 52 + .../deletetrigger/AsyncDeleteTriggerLRO.java | 54 + .../deletetrigger/SyncDeleteTrigger.java | 49 + .../SyncDeleteTriggerStringBoolean.java | 43 + .../SyncDeleteTriggerTriggernameBoolean.java | 43 + .../eventarc/getchannel/AsyncGetChannel.java | 49 + .../eventarc/getchannel/SyncGetChannel.java | 46 + .../getchannel/SyncGetChannelChannelname.java | 42 + .../getchannel/SyncGetChannelString.java | 42 + .../AsyncGetChannelConnection.java | 52 + .../SyncGetChannelConnection.java | 48 + ...hannelConnectionChannelconnectionname.java | 43 + .../SyncGetChannelConnectionString.java | 43 + .../AsyncGetGoogleChannelConfig.java | 50 + .../SyncGetGoogleChannelConfig.java | 46 + ...eChannelConfigGooglechannelconfigname.java | 42 + .../SyncGetGoogleChannelConfigString.java | 42 + .../getiampolicy/AsyncGetIamPolicy.java | 51 + .../getiampolicy/SyncGetIamPolicy.java | 48 + .../getlocation/AsyncGetLocation.java | 45 + .../eventarc/getlocation/SyncGetLocation.java | 42 + .../getprovider/AsyncGetProvider.java | 49 + .../eventarc/getprovider/SyncGetProvider.java | 46 + .../SyncGetProviderProvidername.java | 42 + .../getprovider/SyncGetProviderString.java | 42 + .../eventarc/gettrigger/AsyncGetTrigger.java | 49 + .../eventarc/gettrigger/SyncGetTrigger.java | 46 + .../gettrigger/SyncGetTriggerString.java | 42 + .../gettrigger/SyncGetTriggerTriggername.java | 42 + .../AsyncListChannelConnections.java | 54 + .../AsyncListChannelConnectionsPaged.java | 62 + .../SyncListChannelConnections.java | 51 + ...yncListChannelConnectionsLocationname.java | 44 + .../SyncListChannelConnectionsString.java | 44 + .../listchannels/AsyncListChannels.java | 54 + .../listchannels/AsyncListChannelsPaged.java | 62 + .../listchannels/SyncListChannels.java | 51 + .../SyncListChannelsLocationname.java | 44 + .../listchannels/SyncListChannelsString.java | 44 + .../listlocations/AsyncListLocations.java | 53 + .../AsyncListLocationsPaged.java | 61 + .../listlocations/SyncListLocations.java | 50 + .../listproviders/AsyncListProviders.java | 55 + .../AsyncListProvidersPaged.java | 63 + .../listproviders/SyncListProviders.java | 52 + .../SyncListProvidersLocationname.java | 44 + .../SyncListProvidersString.java | 44 + .../listtriggers/AsyncListTriggers.java | 55 + .../listtriggers/AsyncListTriggersPaged.java | 63 + .../listtriggers/SyncListTriggers.java | 52 + .../SyncListTriggersLocationname.java | 44 + .../listtriggers/SyncListTriggersString.java | 44 + .../setiampolicy/AsyncSetIamPolicy.java | 52 + .../setiampolicy/SyncSetIamPolicy.java | 49 + .../AsyncTestIamPermissions.java | 52 + .../SyncTestIamPermissions.java | 48 + .../updatechannel/AsyncUpdateChannel.java | 52 + .../updatechannel/AsyncUpdateChannelLRO.java | 53 + .../updatechannel/SyncUpdateChannel.java | 48 + .../SyncUpdateChannelChannelFieldmask.java | 43 + .../AsyncUpdateGoogleChannelConfig.java | 51 + .../SyncUpdateGoogleChannelConfig.java | 47 + ...nelConfigGooglechannelconfigFieldmask.java | 44 + .../updatetrigger/AsyncUpdateTrigger.java | 53 + .../updatetrigger/AsyncUpdateTriggerLRO.java | 54 + .../updatetrigger/SyncUpdateTrigger.java | 49 + ...cUpdateTriggerTriggerFieldmaskBoolean.java | 44 + .../gettrigger/SyncGetTrigger.java | 45 + .../gettrigger/SyncGetTrigger.java | 45 + .../cloud/eventarc/v1/EventarcGrpc.java | 1770 -------- .../eventarc/v1/ChannelConnectionProto.java | 79 - .../cloud/eventarc/v1/ChannelProto.java | 82 - .../cloud/eventarc/v1/DiscoveryProto.java | 97 - .../cloud/eventarc/v1/EventarcProto.java | 517 --- .../eventarc/v1/GoogleChannelConfigProto.java | 80 - .../cloud/eventarc/v1/TriggerProto.java | 218 - versions.txt | 1 + 426 files changed, 92207 insertions(+), 11771 deletions(-) create mode 100644 java-eventarc/google-cloud-eventarc-parent-bom/pom.xml create mode 100644 java-eventarc/google-cloud-eventarc-parent/pom.xml rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java (99%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java (99%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java (99%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java (100%) create mode 100644 java-eventarc/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java (100%) create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java (100%) create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilter.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java (100%) create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java (100%) create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java (100%) create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java (100%) create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java create mode 100644 java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java (100%) rename {owl-bot-staging/java-eventarc/v1 => java-eventarc}/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java (100%) create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java create mode 100644 java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java create mode 100644 java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java (72%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java (69%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java (79%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java (81%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java (70%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java (79%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java (64%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java (64%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java (66%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java (66%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java (62%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java (59%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java (65%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java (67%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java (68%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java (75%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java (93%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilter.java (72%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java (88%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java (70%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java (75%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java (72%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java (88%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java (88%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java (63%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java (58%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java (63%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java (58%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java (63%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java (57%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java (63%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java (58%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java (63%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java (58%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java (68%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java (76%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java (68%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java (76%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java (75%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java (87%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java (70%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java (80%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java (85%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java (71%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java (80%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java (85%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java (72%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java (82%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java (74%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java (85%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java (71%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java (84%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java (66%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java (65%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java (73%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java (90%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java (69%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java (85%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java (70%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java (92%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java (65%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java (71%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequest.java (72%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java (93%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java (65%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java (77%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java (73%) rename {owl-bot-staging/java-eventarc => java-eventarc}/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java (94%) create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto create mode 100644 java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java create mode 100644 java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java delete mode 100644 owl-bot-staging/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java delete mode 100644 owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java delete mode 100644 owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java delete mode 100644 owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java delete mode 100644 owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java delete mode 100644 owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java delete mode 100644 owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java diff --git a/java-eventarc/google-cloud-eventarc-parent-bom/pom.xml b/java-eventarc/google-cloud-eventarc-parent-bom/pom.xml new file mode 100644 index 000000000000..267193cf008d --- /dev/null +++ b/java-eventarc/google-cloud-eventarc-parent-bom/pom.xml @@ -0,0 +1,94 @@ + + + 4.0.0 + com.google.cloud + google-cloud-eventarc-bom + 0.0.1-SNAPSHOT + pom + + com.google.cloud + google-cloud-shared-config + 1.5.3 + + + Google Eventarc BOM + https://github.com/googleapis/java-eventarc + + BOM for Eventarc + + + + Google LLC + + + + + chingor13 + Jeff Ching + chingor@google.com + Google LLC + + Developer + + + + neenushaji + Neenu Shaji + neenushaji@google.com + Google LLC + + Developer + + + + + + scm:git:https://github.com/googleapis/java-eventarc.git + scm:git:git@github.com:googleapis/java-eventarc.git + https://github.com/googleapis/java-eventarc + + + + true + + + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + + + + com.google.cloud + google-cloud-eventarc + 1.5.1-SNAPSHOT + + + com.google.api.grpc + grpc-google-cloud-eventarc-v1 + 1.5.1-SNAPSHOT + + + com.google.api.grpc + proto-google-cloud-eventarc-v1 + 1.5.1-SNAPSHOT + + + + + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + true + + + + + diff --git a/java-eventarc/google-cloud-eventarc-parent/pom.xml b/java-eventarc/google-cloud-eventarc-parent/pom.xml new file mode 100644 index 000000000000..5caede8ffbc5 --- /dev/null +++ b/java-eventarc/google-cloud-eventarc-parent/pom.xml @@ -0,0 +1,139 @@ + + + 4.0.0 + com.google.cloud + google-cloud-eventarc + 0.0.1-SNAPSHOT + jar + Google Eventarc + https://github.com/googleapis/java-eventarc + Eventarc lets you asynchronously deliver events from Google services, SaaS, and your own apps using loosely coupled services that react to state changes. Eventarc requires no infrastructure management, you can optimize productivity and costs while building a modern, event-driven solution. + + com.google.cloud + google-cloud-eventarc-parent + 0.0.1-SNAPSHOT + + + google-cloud-eventarc + + + + io.grpc + grpc-api + + + io.grpc + grpc-stub + + + io.grpc + grpc-protobuf + + + com.google.api + api-common + + + com.google.protobuf + protobuf-java + + + com.google.api.grpc + proto-google-common-protos + + + + com.google.api.grpc + proto-google-cloud-eventarc-v1 + + + com.google.guava + guava + + + com.google.api + gax + + + com.google.api + gax-grpc + + + com.google.api + gax-httpjson + + + com.google.api.grpc + grpc-google-common-protos + + + com.google.api.grpc + proto-google-iam-v1 + + + com.google.api.grpc + grpc-google-iam-v1 + + + org.threeten + threetenbp + + + + + junit + junit + test + 4.13.2 + + + + com.google.api.grpc + grpc-google-cloud-eventarc-v1 + test + + + + com.google.api + gax + testlib + test + + + com.google.api + gax-grpc + testlib + test + + + com.google.api + gax-httpjson + testlib + test + + + + + + java9 + + [9,) + + + + javax.annotation + javax.annotation-api + + + + + + + + + org.codehaus.mojo + flatten-maven-plugin + + + + diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java similarity index 99% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java index 2974693444a0..a50feecfd4d8 100644 --- a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java +++ b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java @@ -33,7 +33,6 @@ import com.google.api.gax.rpc.ClientSettings; import com.google.api.gax.rpc.OperationCallSettings; import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.StubSettings; import com.google.api.gax.rpc.TransportChannelProvider; import com.google.api.gax.rpc.UnaryCallSettings; import com.google.cloud.eventarc.v1.stub.EventarcStubSettings; diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java similarity index 99% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java index 12aa6756e1bd..907248b7ea27 100644 --- a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java +++ b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java @@ -72,7 +72,6 @@ import io.grpc.MethodDescriptor; import io.grpc.protobuf.ProtoUtils; import java.io.IOException; -import java.util.Map; import java.util.concurrent.TimeUnit; import javax.annotation.Generated; diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java similarity index 99% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java rename to java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java index c613ed25c691..c268fc5b7b07 100644 --- a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java +++ b/java-eventarc/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java @@ -34,7 +34,6 @@ import com.google.api.gax.httpjson.ProtoMessageResponseParser; import com.google.api.gax.httpjson.ProtoRestSerializer; import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub; -import com.google.api.gax.longrunning.OperationSnapshot; import com.google.api.gax.rpc.ClientContext; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java diff --git a/owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java b/java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java rename to java-eventarc/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java diff --git a/java-eventarc/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java b/java-eventarc/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java new file mode 100644 index 000000000000..664adcf0d5ec --- /dev/null +++ b/java-eventarc/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java @@ -0,0 +1,2323 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.eventarc.v1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; + +/** + * + * + *
+ * Eventarc allows users to subscribe to various events that are provided by
+ * Google Cloud services and forward them to supported destinations.
+ * 
+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/cloud/eventarc/v1/eventarc.proto") +@io.grpc.stub.annotations.GrpcGenerated +public final class EventarcGrpc { + + private EventarcGrpc() {} + + public static final String SERVICE_NAME = "google.cloud.eventarc.v1.Eventarc"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetTriggerRequest, com.google.cloud.eventarc.v1.Trigger> + getGetTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetTrigger", + requestType = com.google.cloud.eventarc.v1.GetTriggerRequest.class, + responseType = com.google.cloud.eventarc.v1.Trigger.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetTriggerRequest, com.google.cloud.eventarc.v1.Trigger> + getGetTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetTriggerRequest, com.google.cloud.eventarc.v1.Trigger> + getGetTriggerMethod; + if ((getGetTriggerMethod = EventarcGrpc.getGetTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetTriggerMethod = EventarcGrpc.getGetTriggerMethod) == null) { + EventarcGrpc.getGetTriggerMethod = + getGetTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetTriggerRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.Trigger.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetTrigger")) + .build(); + } + } + } + return getGetTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse> + getListTriggersMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListTriggers", + requestType = com.google.cloud.eventarc.v1.ListTriggersRequest.class, + responseType = com.google.cloud.eventarc.v1.ListTriggersResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse> + getListTriggersMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse> + getListTriggersMethod; + if ((getListTriggersMethod = EventarcGrpc.getListTriggersMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListTriggersMethod = EventarcGrpc.getListTriggersMethod) == null) { + EventarcGrpc.getListTriggersMethod = + getListTriggersMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListTriggers")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListTriggersRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListTriggersResponse + .getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListTriggers")) + .build(); + } + } + } + return getListTriggersMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateTriggerRequest, com.google.longrunning.Operation> + getCreateTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateTrigger", + requestType = com.google.cloud.eventarc.v1.CreateTriggerRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateTriggerRequest, com.google.longrunning.Operation> + getCreateTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateTriggerRequest, com.google.longrunning.Operation> + getCreateTriggerMethod; + if ((getCreateTriggerMethod = EventarcGrpc.getCreateTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getCreateTriggerMethod = EventarcGrpc.getCreateTriggerMethod) == null) { + EventarcGrpc.getCreateTriggerMethod = + getCreateTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.CreateTriggerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateTrigger")) + .build(); + } + } + } + return getCreateTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, com.google.longrunning.Operation> + getUpdateTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateTrigger", + requestType = com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, com.google.longrunning.Operation> + getUpdateTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, com.google.longrunning.Operation> + getUpdateTriggerMethod; + if ((getUpdateTriggerMethod = EventarcGrpc.getUpdateTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getUpdateTriggerMethod = EventarcGrpc.getUpdateTriggerMethod) == null) { + EventarcGrpc.getUpdateTriggerMethod = + getUpdateTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.UpdateTriggerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateTrigger")) + .build(); + } + } + } + return getUpdateTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, com.google.longrunning.Operation> + getDeleteTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteTrigger", + requestType = com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, com.google.longrunning.Operation> + getDeleteTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, com.google.longrunning.Operation> + getDeleteTriggerMethod; + if ((getDeleteTriggerMethod = EventarcGrpc.getDeleteTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getDeleteTriggerMethod = EventarcGrpc.getDeleteTriggerMethod) == null) { + EventarcGrpc.getDeleteTriggerMethod = + getDeleteTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.DeleteTriggerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteTrigger")) + .build(); + } + } + } + return getDeleteTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelRequest, com.google.cloud.eventarc.v1.Channel> + getGetChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetChannel", + requestType = com.google.cloud.eventarc.v1.GetChannelRequest.class, + responseType = com.google.cloud.eventarc.v1.Channel.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelRequest, com.google.cloud.eventarc.v1.Channel> + getGetChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelRequest, com.google.cloud.eventarc.v1.Channel> + getGetChannelMethod; + if ((getGetChannelMethod = EventarcGrpc.getGetChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetChannelMethod = EventarcGrpc.getGetChannelMethod) == null) { + EventarcGrpc.getGetChannelMethod = + getGetChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetChannelRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.Channel.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetChannel")) + .build(); + } + } + } + return getGetChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse> + getListChannelsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListChannels", + requestType = com.google.cloud.eventarc.v1.ListChannelsRequest.class, + responseType = com.google.cloud.eventarc.v1.ListChannelsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse> + getListChannelsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse> + getListChannelsMethod; + if ((getListChannelsMethod = EventarcGrpc.getListChannelsMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListChannelsMethod = EventarcGrpc.getListChannelsMethod) == null) { + EventarcGrpc.getListChannelsMethod = + getListChannelsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListChannels")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelsResponse + .getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListChannels")) + .build(); + } + } + } + return getListChannelsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelRequest, com.google.longrunning.Operation> + getCreateChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateChannel", + requestType = com.google.cloud.eventarc.v1.CreateChannelRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelRequest, com.google.longrunning.Operation> + getCreateChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelRequest, com.google.longrunning.Operation> + getCreateChannelMethod; + if ((getCreateChannelMethod = EventarcGrpc.getCreateChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getCreateChannelMethod = EventarcGrpc.getCreateChannelMethod) == null) { + EventarcGrpc.getCreateChannelMethod = + getCreateChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.CreateChannelRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateChannel")) + .build(); + } + } + } + return getCreateChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateChannelRequest, com.google.longrunning.Operation> + getUpdateChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateChannel", + requestType = com.google.cloud.eventarc.v1.UpdateChannelRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateChannelRequest, com.google.longrunning.Operation> + getUpdateChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateChannelRequest, com.google.longrunning.Operation> + getUpdateChannelMethod; + if ((getUpdateChannelMethod = EventarcGrpc.getUpdateChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getUpdateChannelMethod = EventarcGrpc.getUpdateChannelMethod) == null) { + EventarcGrpc.getUpdateChannelMethod = + getUpdateChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.UpdateChannelRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateChannel")) + .build(); + } + } + } + return getUpdateChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelRequest, com.google.longrunning.Operation> + getDeleteChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteChannel", + requestType = com.google.cloud.eventarc.v1.DeleteChannelRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelRequest, com.google.longrunning.Operation> + getDeleteChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelRequest, com.google.longrunning.Operation> + getDeleteChannelMethod; + if ((getDeleteChannelMethod = EventarcGrpc.getDeleteChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getDeleteChannelMethod = EventarcGrpc.getDeleteChannelMethod) == null) { + EventarcGrpc.getDeleteChannelMethod = + getDeleteChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.DeleteChannelRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteChannel")) + .build(); + } + } + } + return getDeleteChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetProviderRequest, com.google.cloud.eventarc.v1.Provider> + getGetProviderMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetProvider", + requestType = com.google.cloud.eventarc.v1.GetProviderRequest.class, + responseType = com.google.cloud.eventarc.v1.Provider.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetProviderRequest, com.google.cloud.eventarc.v1.Provider> + getGetProviderMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetProviderRequest, com.google.cloud.eventarc.v1.Provider> + getGetProviderMethod; + if ((getGetProviderMethod = EventarcGrpc.getGetProviderMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetProviderMethod = EventarcGrpc.getGetProviderMethod) == null) { + EventarcGrpc.getGetProviderMethod = + getGetProviderMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetProvider")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.Provider.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetProvider")) + .build(); + } + } + } + return getGetProviderMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse> + getListProvidersMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListProviders", + requestType = com.google.cloud.eventarc.v1.ListProvidersRequest.class, + responseType = com.google.cloud.eventarc.v1.ListProvidersResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse> + getListProvidersMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse> + getListProvidersMethod; + if ((getListProvidersMethod = EventarcGrpc.getListProvidersMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListProvidersMethod = EventarcGrpc.getListProvidersMethod) == null) { + EventarcGrpc.getListProvidersMethod = + getListProvidersMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListProviders")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListProvidersRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListProvidersResponse + .getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListProviders")) + .build(); + } + } + } + return getListProvidersMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection> + getGetChannelConnectionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetChannelConnection", + requestType = com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, + responseType = com.google.cloud.eventarc.v1.ChannelConnection.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection> + getGetChannelConnectionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection> + getGetChannelConnectionMethod; + if ((getGetChannelConnectionMethod = EventarcGrpc.getGetChannelConnectionMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetChannelConnectionMethod = EventarcGrpc.getGetChannelConnectionMethod) == null) { + EventarcGrpc.getGetChannelConnectionMethod = + getGetChannelConnectionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetChannelConnection")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("GetChannelConnection")) + .build(); + } + } + } + return getGetChannelConnectionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + getListChannelConnectionsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListChannelConnections", + requestType = com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, + responseType = com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + getListChannelConnectionsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + getListChannelConnectionsMethod; + if ((getListChannelConnectionsMethod = EventarcGrpc.getListChannelConnectionsMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListChannelConnectionsMethod = EventarcGrpc.getListChannelConnectionsMethod) + == null) { + EventarcGrpc.getListChannelConnectionsMethod = + getListChannelConnectionsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListChannelConnections")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("ListChannelConnections")) + .build(); + } + } + } + return getListChannelConnectionsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation> + getCreateChannelConnectionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateChannelConnection", + requestType = com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation> + getCreateChannelConnectionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation> + getCreateChannelConnectionMethod; + if ((getCreateChannelConnectionMethod = EventarcGrpc.getCreateChannelConnectionMethod) + == null) { + synchronized (EventarcGrpc.class) { + if ((getCreateChannelConnectionMethod = EventarcGrpc.getCreateChannelConnectionMethod) + == null) { + EventarcGrpc.getCreateChannelConnectionMethod = + getCreateChannelConnectionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateChannelConnection")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("CreateChannelConnection")) + .build(); + } + } + } + return getCreateChannelConnectionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation> + getDeleteChannelConnectionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteChannelConnection", + requestType = com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation> + getDeleteChannelConnectionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation> + getDeleteChannelConnectionMethod; + if ((getDeleteChannelConnectionMethod = EventarcGrpc.getDeleteChannelConnectionMethod) + == null) { + synchronized (EventarcGrpc.class) { + if ((getDeleteChannelConnectionMethod = EventarcGrpc.getDeleteChannelConnectionMethod) + == null) { + EventarcGrpc.getDeleteChannelConnectionMethod = + getDeleteChannelConnectionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteChannelConnection")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("DeleteChannelConnection")) + .build(); + } + } + } + return getDeleteChannelConnectionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGetGoogleChannelConfigMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetGoogleChannelConfig", + requestType = com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, + responseType = com.google.cloud.eventarc.v1.GoogleChannelConfig.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGetGoogleChannelConfigMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGetGoogleChannelConfigMethod; + if ((getGetGoogleChannelConfigMethod = EventarcGrpc.getGetGoogleChannelConfigMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetGoogleChannelConfigMethod = EventarcGrpc.getGetGoogleChannelConfigMethod) + == null) { + EventarcGrpc.getGetGoogleChannelConfigMethod = + getGetGoogleChannelConfigMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetGoogleChannelConfig")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GoogleChannelConfig + .getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("GetGoogleChannelConfig")) + .build(); + } + } + } + return getGetGoogleChannelConfigMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getUpdateGoogleChannelConfigMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateGoogleChannelConfig", + requestType = com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, + responseType = com.google.cloud.eventarc.v1.GoogleChannelConfig.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getUpdateGoogleChannelConfigMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getUpdateGoogleChannelConfigMethod; + if ((getUpdateGoogleChannelConfigMethod = EventarcGrpc.getUpdateGoogleChannelConfigMethod) + == null) { + synchronized (EventarcGrpc.class) { + if ((getUpdateGoogleChannelConfigMethod = EventarcGrpc.getUpdateGoogleChannelConfigMethod) + == null) { + EventarcGrpc.getUpdateGoogleChannelConfigMethod = + getUpdateGoogleChannelConfigMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateGoogleChannelConfig")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GoogleChannelConfig + .getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("UpdateGoogleChannelConfig")) + .build(); + } + } + } + return getUpdateGoogleChannelConfigMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static EventarcStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public EventarcStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcStub(channel, callOptions); + } + }; + return EventarcStub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static EventarcBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public EventarcBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcBlockingStub(channel, callOptions); + } + }; + return EventarcBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static EventarcFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public EventarcFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcFutureStub(channel, callOptions); + } + }; + return EventarcFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public abstract static class EventarcImplBase implements io.grpc.BindableService { + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public void getTrigger( + com.google.cloud.eventarc.v1.GetTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public void listTriggers( + com.google.cloud.eventarc.v1.ListTriggersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListTriggersMethod(), responseObserver); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public void createTrigger( + com.google.cloud.eventarc.v1.CreateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public void updateTrigger( + com.google.cloud.eventarc.v1.UpdateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public void deleteTrigger( + com.google.cloud.eventarc.v1.DeleteTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public void getChannel( + com.google.cloud.eventarc.v1.GetChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public void listChannels( + com.google.cloud.eventarc.v1.ListChannelsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListChannelsMethod(), responseObserver); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public void createChannel( + com.google.cloud.eventarc.v1.CreateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public void updateChannel( + com.google.cloud.eventarc.v1.UpdateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public void deleteChannel( + com.google.cloud.eventarc.v1.DeleteChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public void getProvider( + com.google.cloud.eventarc.v1.GetProviderRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetProviderMethod(), responseObserver); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public void listProviders( + com.google.cloud.eventarc.v1.ListProvidersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListProvidersMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public void getChannelConnection( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetChannelConnectionMethod(), responseObserver); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public void listChannelConnections( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListChannelConnectionsMethod(), responseObserver); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public void createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateChannelConnectionMethod(), responseObserver); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public void deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteChannelConnectionMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public void getGoogleChannelConfig( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetGoogleChannelConfigMethod(), responseObserver); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public void updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateGoogleChannelConfigMethod(), responseObserver); + } + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getGetTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetTriggerRequest, + com.google.cloud.eventarc.v1.Trigger>(this, METHODID_GET_TRIGGER))) + .addMethod( + getListTriggersMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse>( + this, METHODID_LIST_TRIGGERS))) + .addMethod( + getCreateTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.CreateTriggerRequest, + com.google.longrunning.Operation>(this, METHODID_CREATE_TRIGGER))) + .addMethod( + getUpdateTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, + com.google.longrunning.Operation>(this, METHODID_UPDATE_TRIGGER))) + .addMethod( + getDeleteTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, + com.google.longrunning.Operation>(this, METHODID_DELETE_TRIGGER))) + .addMethod( + getGetChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetChannelRequest, + com.google.cloud.eventarc.v1.Channel>(this, METHODID_GET_CHANNEL))) + .addMethod( + getListChannelsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse>( + this, METHODID_LIST_CHANNELS))) + .addMethod( + getCreateChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.CreateChannelRequest, + com.google.longrunning.Operation>(this, METHODID_CREATE_CHANNEL))) + .addMethod( + getUpdateChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.UpdateChannelRequest, + com.google.longrunning.Operation>(this, METHODID_UPDATE_CHANNEL))) + .addMethod( + getDeleteChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.DeleteChannelRequest, + com.google.longrunning.Operation>(this, METHODID_DELETE_CHANNEL))) + .addMethod( + getGetProviderMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetProviderRequest, + com.google.cloud.eventarc.v1.Provider>(this, METHODID_GET_PROVIDER))) + .addMethod( + getListProvidersMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse>( + this, METHODID_LIST_PROVIDERS))) + .addMethod( + getGetChannelConnectionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection>( + this, METHODID_GET_CHANNEL_CONNECTION))) + .addMethod( + getListChannelConnectionsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse>( + this, METHODID_LIST_CHANNEL_CONNECTIONS))) + .addMethod( + getCreateChannelConnectionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation>(this, METHODID_CREATE_CHANNEL_CONNECTION))) + .addMethod( + getDeleteChannelConnectionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation>(this, METHODID_DELETE_CHANNEL_CONNECTION))) + .addMethod( + getGetGoogleChannelConfigMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig>( + this, METHODID_GET_GOOGLE_CHANNEL_CONFIG))) + .addMethod( + getUpdateGoogleChannelConfigMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig>( + this, METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG))) + .build(); + } + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public static final class EventarcStub extends io.grpc.stub.AbstractAsyncStub { + private EventarcStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected EventarcStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcStub(channel, callOptions); + } + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public void getTrigger( + com.google.cloud.eventarc.v1.GetTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetTriggerMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public void listTriggers( + com.google.cloud.eventarc.v1.ListTriggersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListTriggersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public void createTrigger( + com.google.cloud.eventarc.v1.CreateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateTriggerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public void updateTrigger( + com.google.cloud.eventarc.v1.UpdateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateTriggerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public void deleteTrigger( + com.google.cloud.eventarc.v1.DeleteTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteTriggerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public void getChannel( + com.google.cloud.eventarc.v1.GetChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetChannelMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public void listChannels( + com.google.cloud.eventarc.v1.ListChannelsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListChannelsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public void createChannel( + com.google.cloud.eventarc.v1.CreateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateChannelMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public void updateChannel( + com.google.cloud.eventarc.v1.UpdateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateChannelMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public void deleteChannel( + com.google.cloud.eventarc.v1.DeleteChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteChannelMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public void getProvider( + com.google.cloud.eventarc.v1.GetProviderRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetProviderMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public void listProviders( + com.google.cloud.eventarc.v1.ListProvidersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListProvidersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public void getChannelConnection( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetChannelConnectionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public void listChannelConnections( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListChannelConnectionsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public void createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateChannelConnectionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public void deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteChannelConnectionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public void getGoogleChannelConfig( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetGoogleChannelConfigMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public void updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateGoogleChannelConfigMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public static final class EventarcBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private EventarcBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected EventarcBlockingStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public com.google.cloud.eventarc.v1.Trigger getTrigger( + com.google.cloud.eventarc.v1.GetTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListTriggersResponse listTriggers( + com.google.cloud.eventarc.v1.ListTriggersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListTriggersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public com.google.longrunning.Operation createTrigger( + com.google.cloud.eventarc.v1.CreateTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public com.google.longrunning.Operation updateTrigger( + com.google.cloud.eventarc.v1.UpdateTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public com.google.longrunning.Operation deleteTrigger( + com.google.cloud.eventarc.v1.DeleteTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public com.google.cloud.eventarc.v1.Channel getChannel( + com.google.cloud.eventarc.v1.GetChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListChannelsResponse listChannels( + com.google.cloud.eventarc.v1.ListChannelsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListChannelsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public com.google.longrunning.Operation createChannel( + com.google.cloud.eventarc.v1.CreateChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public com.google.longrunning.Operation updateChannel( + com.google.cloud.eventarc.v1.UpdateChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public com.google.longrunning.Operation deleteChannel( + com.google.cloud.eventarc.v1.DeleteChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public com.google.cloud.eventarc.v1.Provider getProvider( + com.google.cloud.eventarc.v1.GetProviderRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetProviderMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListProvidersResponse listProviders( + com.google.cloud.eventarc.v1.ListProvidersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListProvidersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetChannelConnectionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse listChannelConnections( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListChannelConnectionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public com.google.longrunning.Operation createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateChannelConnectionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public com.google.longrunning.Operation deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteChannelConnectionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGoogleChannelConfigMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public com.google.cloud.eventarc.v1.GoogleChannelConfig updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGoogleChannelConfigMethod(), getCallOptions(), request); + } + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public static final class EventarcFutureStub + extends io.grpc.stub.AbstractFutureStub { + private EventarcFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected EventarcFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + getTrigger(com.google.cloud.eventarc.v1.GetTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListTriggersResponse> + listTriggers(com.google.cloud.eventarc.v1.ListTriggersRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListTriggersMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createTrigger(com.google.cloud.eventarc.v1.CreateTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + updateTrigger(com.google.cloud.eventarc.v1.UpdateTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteTrigger(com.google.cloud.eventarc.v1.DeleteTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + getChannel(com.google.cloud.eventarc.v1.GetChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListChannelsResponse> + listChannels(com.google.cloud.eventarc.v1.ListChannelsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListChannelsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createChannel(com.google.cloud.eventarc.v1.CreateChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + updateChannel(com.google.cloud.eventarc.v1.UpdateChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteChannel(com.google.cloud.eventarc.v1.DeleteChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + getProvider(com.google.cloud.eventarc.v1.GetProviderRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetProviderMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListProvidersResponse> + listProviders(com.google.cloud.eventarc.v1.ListProvidersRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListProvidersMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ChannelConnection> + getChannelConnection(com.google.cloud.eventarc.v1.GetChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetChannelConnectionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + listChannelConnections(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListChannelConnectionsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateChannelConnectionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteChannelConnectionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGoogleChannelConfig(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetGoogleChannelConfigMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.GoogleChannelConfig> + updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateGoogleChannelConfigMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_GET_TRIGGER = 0; + private static final int METHODID_LIST_TRIGGERS = 1; + private static final int METHODID_CREATE_TRIGGER = 2; + private static final int METHODID_UPDATE_TRIGGER = 3; + private static final int METHODID_DELETE_TRIGGER = 4; + private static final int METHODID_GET_CHANNEL = 5; + private static final int METHODID_LIST_CHANNELS = 6; + private static final int METHODID_CREATE_CHANNEL = 7; + private static final int METHODID_UPDATE_CHANNEL = 8; + private static final int METHODID_DELETE_CHANNEL = 9; + private static final int METHODID_GET_PROVIDER = 10; + private static final int METHODID_LIST_PROVIDERS = 11; + private static final int METHODID_GET_CHANNEL_CONNECTION = 12; + private static final int METHODID_LIST_CHANNEL_CONNECTIONS = 13; + private static final int METHODID_CREATE_CHANNEL_CONNECTION = 14; + private static final int METHODID_DELETE_CHANNEL_CONNECTION = 15; + private static final int METHODID_GET_GOOGLE_CHANNEL_CONFIG = 16; + private static final int METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG = 17; + + private static final class MethodHandlers + implements io.grpc.stub.ServerCalls.UnaryMethod, + io.grpc.stub.ServerCalls.ServerStreamingMethod, + io.grpc.stub.ServerCalls.ClientStreamingMethod, + io.grpc.stub.ServerCalls.BidiStreamingMethod { + private final EventarcImplBase serviceImpl; + private final int methodId; + + MethodHandlers(EventarcImplBase serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_GET_TRIGGER: + serviceImpl.getTrigger( + (com.google.cloud.eventarc.v1.GetTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_TRIGGERS: + serviceImpl.listTriggers( + (com.google.cloud.eventarc.v1.ListTriggersRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_TRIGGER: + serviceImpl.createTrigger( + (com.google.cloud.eventarc.v1.CreateTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_UPDATE_TRIGGER: + serviceImpl.updateTrigger( + (com.google.cloud.eventarc.v1.UpdateTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_TRIGGER: + serviceImpl.deleteTrigger( + (com.google.cloud.eventarc.v1.DeleteTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_CHANNEL: + serviceImpl.getChannel( + (com.google.cloud.eventarc.v1.GetChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_CHANNELS: + serviceImpl.listChannels( + (com.google.cloud.eventarc.v1.ListChannelsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_CHANNEL: + serviceImpl.createChannel( + (com.google.cloud.eventarc.v1.CreateChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_UPDATE_CHANNEL: + serviceImpl.updateChannel( + (com.google.cloud.eventarc.v1.UpdateChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_CHANNEL: + serviceImpl.deleteChannel( + (com.google.cloud.eventarc.v1.DeleteChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_PROVIDER: + serviceImpl.getProvider( + (com.google.cloud.eventarc.v1.GetProviderRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_PROVIDERS: + serviceImpl.listProviders( + (com.google.cloud.eventarc.v1.ListProvidersRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_GET_CHANNEL_CONNECTION: + serviceImpl.getChannelConnection( + (com.google.cloud.eventarc.v1.GetChannelConnectionRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_CHANNEL_CONNECTIONS: + serviceImpl.listChannelConnections( + (com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse>) + responseObserver); + break; + case METHODID_CREATE_CHANNEL_CONNECTION: + serviceImpl.createChannelConnection( + (com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_CHANNEL_CONNECTION: + serviceImpl.deleteChannelConnection( + (com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_GOOGLE_CHANNEL_CONFIG: + serviceImpl.getGoogleChannelConfig( + (com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG: + serviceImpl.updateGoogleChannelConfig( + (com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + default: + throw new AssertionError(); + } + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public io.grpc.stub.StreamObserver invoke( + io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + default: + throw new AssertionError(); + } + } + } + + private abstract static class EventarcBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + EventarcBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("Eventarc"); + } + } + + private static final class EventarcFileDescriptorSupplier extends EventarcBaseDescriptorSupplier { + EventarcFileDescriptorSupplier() {} + } + + private static final class EventarcMethodDescriptorSupplier extends EventarcBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final String methodName; + + EventarcMethodDescriptorSupplier(String methodName) { + this.methodName = methodName; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { + return getServiceDescriptor().findMethodByName(methodName); + } + } + + private static volatile io.grpc.ServiceDescriptor serviceDescriptor; + + public static io.grpc.ServiceDescriptor getServiceDescriptor() { + io.grpc.ServiceDescriptor result = serviceDescriptor; + if (result == null) { + synchronized (EventarcGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new EventarcFileDescriptorSupplier()) + .addMethod(getGetTriggerMethod()) + .addMethod(getListTriggersMethod()) + .addMethod(getCreateTriggerMethod()) + .addMethod(getUpdateTriggerMethod()) + .addMethod(getDeleteTriggerMethod()) + .addMethod(getGetChannelMethod()) + .addMethod(getListChannelsMethod()) + .addMethod(getCreateChannelMethod()) + .addMethod(getUpdateChannelMethod()) + .addMethod(getDeleteChannelMethod()) + .addMethod(getGetProviderMethod()) + .addMethod(getListProvidersMethod()) + .addMethod(getGetChannelConnectionMethod()) + .addMethod(getListChannelConnectionsMethod()) + .addMethod(getCreateChannelConnectionMethod()) + .addMethod(getDeleteChannelConnectionMethod()) + .addMethod(getGetGoogleChannelConfigMethod()) + .addMethod(getUpdateGoogleChannelConfigMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java new file mode 100644 index 000000000000..db7c96a8d331 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java @@ -0,0 +1,2680 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A representation of the Channel resource.
+ * A Channel is a resource on which event providers publish their events.
+ * The published events are delivered through the transport associated with the
+ * channel. Note that a channel is associated with exactly one event provider.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Channel} + */ +public final class Channel extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Channel) + ChannelOrBuilder { + private static final long serialVersionUID = 0L; + // Use Channel.newBuilder() to construct. + private Channel(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Channel() { + name_ = ""; + uid_ = ""; + provider_ = ""; + state_ = 0; + activationToken_ = ""; + cryptoKeyName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Channel(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.ChannelProto + .internal_static_google_cloud_eventarc_v1_Channel_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.ChannelProto + .internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Channel.class, + com.google.cloud.eventarc.v1.Channel.Builder.class); + } + + /** + * + * + *
+   * State lists all the possible states of a Channel
+   * 
+ * + * Protobuf enum {@code google.cloud.eventarc.v1.Channel.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The PENDING state indicates that a Channel has been created successfully
+     * and there is a new activation token available for the subscriber to use
+     * to convey the Channel to the provider in order to create a Connection.
+     * 
+ * + * PENDING = 1; + */ + PENDING(1), + /** + * + * + *
+     * The ACTIVE state indicates that a Channel has been successfully
+     * connected with the event provider.
+     * An ACTIVE Channel is ready to receive and route events from the
+     * event provider.
+     * 
+ * + * ACTIVE = 2; + */ + ACTIVE(2), + /** + * + * + *
+     * The INACTIVE state indicates that the Channel cannot receive events
+     * permanently. There are two possible cases this state can happen:
+     * 1. The SaaS provider disconnected from this Channel.
+     * 2. The Channel activation token has expired but the SaaS provider
+     *    wasn't connected.
+     * To re-establish a Connection with a provider, the subscriber
+     * should create a new Channel and give it to the provider.
+     * 
+ * + * INACTIVE = 3; + */ + INACTIVE(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Default value. This value is unused.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * The PENDING state indicates that a Channel has been created successfully
+     * and there is a new activation token available for the subscriber to use
+     * to convey the Channel to the provider in order to create a Connection.
+     * 
+ * + * PENDING = 1; + */ + public static final int PENDING_VALUE = 1; + /** + * + * + *
+     * The ACTIVE state indicates that a Channel has been successfully
+     * connected with the event provider.
+     * An ACTIVE Channel is ready to receive and route events from the
+     * event provider.
+     * 
+ * + * ACTIVE = 2; + */ + public static final int ACTIVE_VALUE = 2; + /** + * + * + *
+     * The INACTIVE state indicates that the Channel cannot receive events
+     * permanently. There are two possible cases this state can happen:
+     * 1. The SaaS provider disconnected from this Channel.
+     * 2. The Channel activation token has expired but the SaaS provider
+     *    wasn't connected.
+     * To re-establish a Connection with a provider, the subscriber
+     * should create a new Channel and give it to the provider.
+     * 
+ * + * INACTIVE = 3; + */ + public static final int INACTIVE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return PENDING; + case 2: + return ACTIVE; + case 3: + return INACTIVE; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public State findValueByNumber(int number) { + return State.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.eventarc.v1.Channel.getDescriptor().getEnumTypes().get(0); + } + + private static final State[] VALUES = values(); + + public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private State(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.eventarc.v1.Channel.State) + } + + private int transportCase_ = 0; + private java.lang.Object transport_; + + public enum TransportCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + PUBSUB_TOPIC(8), + TRANSPORT_NOT_SET(0); + private final int value; + + private TransportCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static TransportCase valueOf(int value) { + return forNumber(value); + } + + public static TransportCase forNumber(int value) { + switch (value) { + case 8: + return PUBSUB_TOPIC; + case 0: + return TRANSPORT_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public TransportCase getTransportCase() { + return TransportCase.forNumber(transportCase_); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The resource name of the channel. Must be unique within the
+   * location on the project and must be in
+   * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The resource name of the channel. Must be unique within the
+   * location on the project and must be in
+   * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UID_FIELD_NUMBER = 2; + private volatile java.lang.Object uid_; + /** + * + * + *
+   * Output only. Server assigned unique identifier for the channel. The value
+   * is a UUID4 string and guaranteed to remain unchanged until the resource is
+   * deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Server assigned unique identifier for the channel. The value
+   * is a UUID4 string and guaranteed to remain unchanged until the resource is
+   * deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int PROVIDER_FIELD_NUMBER = 7; + private volatile java.lang.Object provider_; + /** + * + * + *
+   * The name of the event provider (e.g. Eventarc SaaS partner) associated
+   * with the channel. This provider will be granted permissions to publish
+   * events to the channel. Format:
+   * `projects/{project}/locations/{location}/providers/{provider_id}`.
+   * 
+ * + * string provider = 7; + * + * @return The provider. + */ + @java.lang.Override + public java.lang.String getProvider() { + java.lang.Object ref = provider_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + provider_ = s; + return s; + } + } + /** + * + * + *
+   * The name of the event provider (e.g. Eventarc SaaS partner) associated
+   * with the channel. This provider will be granted permissions to publish
+   * events to the channel. Format:
+   * `projects/{project}/locations/{location}/providers/{provider_id}`.
+   * 
+ * + * string provider = 7; + * + * @return The bytes for provider. + */ + @java.lang.Override + public com.google.protobuf.ByteString getProviderBytes() { + java.lang.Object ref = provider_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + provider_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PUBSUB_TOPIC_FIELD_NUMBER = 8; + /** + * + * + *
+   * Output only. The name of the Pub/Sub topic created and managed by
+   * Eventarc system as a transport for the event delivery. Format:
+   * `projects/{project}/topics/{topic_id}`.
+   * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return Whether the pubsubTopic field is set. + */ + public boolean hasPubsubTopic() { + return transportCase_ == 8; + } + /** + * + * + *
+   * Output only. The name of the Pub/Sub topic created and managed by
+   * Eventarc system as a transport for the event delivery. Format:
+   * `projects/{project}/topics/{topic_id}`.
+   * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The pubsubTopic. + */ + public java.lang.String getPubsubTopic() { + java.lang.Object ref = ""; + if (transportCase_ == 8) { + ref = transport_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (transportCase_ == 8) { + transport_ = s; + } + return s; + } + } + /** + * + * + *
+   * Output only. The name of the Pub/Sub topic created and managed by
+   * Eventarc system as a transport for the event delivery. Format:
+   * `projects/{project}/topics/{topic_id}`.
+   * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for pubsubTopic. + */ + public com.google.protobuf.ByteString getPubsubTopicBytes() { + java.lang.Object ref = ""; + if (transportCase_ == 8) { + ref = transport_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (transportCase_ == 8) { + transport_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 9; + private int state_; + /** + * + * + *
+   * Output only. The state of a Channel.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + /** + * + * + *
+   * Output only. The state of a Channel.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel.State getState() { + @SuppressWarnings("deprecation") + com.google.cloud.eventarc.v1.Channel.State result = + com.google.cloud.eventarc.v1.Channel.State.valueOf(state_); + return result == null ? com.google.cloud.eventarc.v1.Channel.State.UNRECOGNIZED : result; + } + + public static final int ACTIVATION_TOKEN_FIELD_NUMBER = 10; + private volatile java.lang.Object activationToken_; + /** + * + * + *
+   * Output only. The activation token for the channel. The token must be used
+   * by the provider to register the channel for publishing.
+   * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The activationToken. + */ + @java.lang.Override + public java.lang.String getActivationToken() { + java.lang.Object ref = activationToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + activationToken_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. The activation token for the channel. The token must be used
+   * by the provider to register the channel for publishing.
+   * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for activationToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getActivationTokenBytes() { + java.lang.Object ref = activationToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + activationToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CRYPTO_KEY_NAME_FIELD_NUMBER = 11; + private volatile java.lang.Object cryptoKeyName_; + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + @java.lang.Override + public java.lang.String getCryptoKeyName() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cryptoKeyName_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cryptoKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uid_); + } + if (createTime_ != null) { + output.writeMessage(5, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(6, getUpdateTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(provider_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 7, provider_); + } + if (transportCase_ == 8) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 8, transport_); + } + if (state_ != com.google.cloud.eventarc.v1.Channel.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(9, state_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(activationToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 10, activationToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cryptoKeyName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 11, cryptoKeyName_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(provider_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, provider_); + } + if (transportCase_ == 8) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, transport_); + } + if (state_ != com.google.cloud.eventarc.v1.Channel.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, state_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(activationToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, activationToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cryptoKeyName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, cryptoKeyName_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.Channel)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.Channel other = (com.google.cloud.eventarc.v1.Channel) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getProvider().equals(other.getProvider())) return false; + if (state_ != other.state_) return false; + if (!getActivationToken().equals(other.getActivationToken())) return false; + if (!getCryptoKeyName().equals(other.getCryptoKeyName())) return false; + if (!getTransportCase().equals(other.getTransportCase())) return false; + switch (transportCase_) { + case 8: + if (!getPubsubTopic().equals(other.getPubsubTopic())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (37 * hash) + PROVIDER_FIELD_NUMBER; + hash = (53 * hash) + getProvider().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (37 * hash) + ACTIVATION_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getActivationToken().hashCode(); + hash = (37 * hash) + CRYPTO_KEY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getCryptoKeyName().hashCode(); + switch (transportCase_) { + case 8: + hash = (37 * hash) + PUBSUB_TOPIC_FIELD_NUMBER; + hash = (53 * hash) + getPubsubTopic().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Channel parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Channel parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Channel parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.Channel prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A representation of the Channel resource.
+   * A Channel is a resource on which event providers publish their events.
+   * The published events are delivered through the transport associated with the
+   * channel. Note that a channel is associated with exactly one event provider.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Channel} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Channel) + com.google.cloud.eventarc.v1.ChannelOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.ChannelProto + .internal_static_google_cloud_eventarc_v1_Channel_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.ChannelProto + .internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Channel.class, + com.google.cloud.eventarc.v1.Channel.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.Channel.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + uid_ = ""; + + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + provider_ = ""; + + state_ = 0; + + activationToken_ = ""; + + cryptoKeyName_ = ""; + + transportCase_ = 0; + transport_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.ChannelProto + .internal_static_google_cloud_eventarc_v1_Channel_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.Channel.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel build() { + com.google.cloud.eventarc.v1.Channel result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel buildPartial() { + com.google.cloud.eventarc.v1.Channel result = new com.google.cloud.eventarc.v1.Channel(this); + result.name_ = name_; + result.uid_ = uid_; + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + result.provider_ = provider_; + if (transportCase_ == 8) { + result.transport_ = transport_; + } + result.state_ = state_; + result.activationToken_ = activationToken_; + result.cryptoKeyName_ = cryptoKeyName_; + result.transportCase_ = transportCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.Channel) { + return mergeFrom((com.google.cloud.eventarc.v1.Channel) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.Channel other) { + if (other == com.google.cloud.eventarc.v1.Channel.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (!other.getProvider().isEmpty()) { + provider_ = other.provider_; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (!other.getActivationToken().isEmpty()) { + activationToken_ = other.activationToken_; + onChanged(); + } + if (!other.getCryptoKeyName().isEmpty()) { + cryptoKeyName_ = other.cryptoKeyName_; + onChanged(); + } + switch (other.getTransportCase()) { + case PUBSUB_TOPIC: + { + transportCase_ = 8; + transport_ = other.transport_; + onChanged(); + break; + } + case TRANSPORT_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + uid_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + provider_ = input.readStringRequireUtf8(); + + break; + } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + transportCase_ = 8; + transport_ = s; + break; + } // case 66 + case 72: + { + state_ = input.readEnum(); + + break; + } // case 72 + case 82: + { + activationToken_ = input.readStringRequireUtf8(); + + break; + } // case 82 + case 90: + { + cryptoKeyName_ = input.readStringRequireUtf8(); + + break; + } // case 90 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int transportCase_ = 0; + private java.lang.Object transport_; + + public TransportCase getTransportCase() { + return TransportCase.forNumber(transportCase_); + } + + public Builder clearTransport() { + transportCase_ = 0; + transport_ = null; + onChanged(); + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The resource name of the channel. Must be unique within the
+     * location on the project and must be in
+     * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The resource name of the channel. Must be unique within the
+     * location on the project and must be in
+     * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The resource name of the channel. Must be unique within the
+     * location on the project and must be in
+     * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The resource name of the channel. Must be unique within the
+     * location on the project and must be in
+     * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The resource name of the channel. Must be unique within the
+     * location on the project and must be in
+     * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + /** + * + * + *
+     * Output only. Server assigned unique identifier for the channel. The value
+     * is a UUID4 string and guaranteed to remain unchanged until the resource is
+     * deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Server assigned unique identifier for the channel. The value
+     * is a UUID4 string and guaranteed to remain unchanged until the resource is
+     * deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Server assigned unique identifier for the channel. The value
+     * is a UUID4 string and guaranteed to remain unchanged until the resource is
+     * deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + uid_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server assigned unique identifier for the channel. The value
+     * is a UUID4 string and guaranteed to remain unchanged until the resource is
+     * deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearUid() { + + uid_ = getDefaultInstance().getUid(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server assigned unique identifier for the channel. The value
+     * is a UUID4 string and guaranteed to remain unchanged until the resource is
+     * deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + uid_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private java.lang.Object provider_ = ""; + /** + * + * + *
+     * The name of the event provider (e.g. Eventarc SaaS partner) associated
+     * with the channel. This provider will be granted permissions to publish
+     * events to the channel. Format:
+     * `projects/{project}/locations/{location}/providers/{provider_id}`.
+     * 
+ * + * string provider = 7; + * + * @return The provider. + */ + public java.lang.String getProvider() { + java.lang.Object ref = provider_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + provider_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The name of the event provider (e.g. Eventarc SaaS partner) associated
+     * with the channel. This provider will be granted permissions to publish
+     * events to the channel. Format:
+     * `projects/{project}/locations/{location}/providers/{provider_id}`.
+     * 
+ * + * string provider = 7; + * + * @return The bytes for provider. + */ + public com.google.protobuf.ByteString getProviderBytes() { + java.lang.Object ref = provider_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + provider_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The name of the event provider (e.g. Eventarc SaaS partner) associated
+     * with the channel. This provider will be granted permissions to publish
+     * events to the channel. Format:
+     * `projects/{project}/locations/{location}/providers/{provider_id}`.
+     * 
+ * + * string provider = 7; + * + * @param value The provider to set. + * @return This builder for chaining. + */ + public Builder setProvider(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + provider_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the event provider (e.g. Eventarc SaaS partner) associated
+     * with the channel. This provider will be granted permissions to publish
+     * events to the channel. Format:
+     * `projects/{project}/locations/{location}/providers/{provider_id}`.
+     * 
+ * + * string provider = 7; + * + * @return This builder for chaining. + */ + public Builder clearProvider() { + + provider_ = getDefaultInstance().getProvider(); + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the event provider (e.g. Eventarc SaaS partner) associated
+     * with the channel. This provider will be granted permissions to publish
+     * events to the channel. Format:
+     * `projects/{project}/locations/{location}/providers/{provider_id}`.
+     * 
+ * + * string provider = 7; + * + * @param value The bytes for provider to set. + * @return This builder for chaining. + */ + public Builder setProviderBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + provider_ = value; + onChanged(); + return this; + } + + /** + * + * + *
+     * Output only. The name of the Pub/Sub topic created and managed by
+     * Eventarc system as a transport for the event delivery. Format:
+     * `projects/{project}/topics/{topic_id}`.
+     * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return Whether the pubsubTopic field is set. + */ + @java.lang.Override + public boolean hasPubsubTopic() { + return transportCase_ == 8; + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub topic created and managed by
+     * Eventarc system as a transport for the event delivery. Format:
+     * `projects/{project}/topics/{topic_id}`.
+     * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The pubsubTopic. + */ + @java.lang.Override + public java.lang.String getPubsubTopic() { + java.lang.Object ref = ""; + if (transportCase_ == 8) { + ref = transport_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (transportCase_ == 8) { + transport_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub topic created and managed by
+     * Eventarc system as a transport for the event delivery. Format:
+     * `projects/{project}/topics/{topic_id}`.
+     * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for pubsubTopic. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPubsubTopicBytes() { + java.lang.Object ref = ""; + if (transportCase_ == 8) { + ref = transport_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (transportCase_ == 8) { + transport_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub topic created and managed by
+     * Eventarc system as a transport for the event delivery. Format:
+     * `projects/{project}/topics/{topic_id}`.
+     * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The pubsubTopic to set. + * @return This builder for chaining. + */ + public Builder setPubsubTopic(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + transportCase_ = 8; + transport_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub topic created and managed by
+     * Eventarc system as a transport for the event delivery. Format:
+     * `projects/{project}/topics/{topic_id}`.
+     * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearPubsubTopic() { + if (transportCase_ == 8) { + transportCase_ = 0; + transport_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub topic created and managed by
+     * Eventarc system as a transport for the event delivery. Format:
+     * `projects/{project}/topics/{topic_id}`.
+     * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for pubsubTopic to set. + * @return This builder for chaining. + */ + public Builder setPubsubTopicBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + transportCase_ = 8; + transport_ = value; + onChanged(); + return this; + } + + private int state_ = 0; + /** + * + * + *
+     * Output only. The state of a Channel.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + /** + * + * + *
+     * Output only. The state of a Channel.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The enum numeric value on the wire for state to set. + * @return This builder for chaining. + */ + public Builder setStateValue(int value) { + + state_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The state of a Channel.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel.State getState() { + @SuppressWarnings("deprecation") + com.google.cloud.eventarc.v1.Channel.State result = + com.google.cloud.eventarc.v1.Channel.State.valueOf(state_); + return result == null ? com.google.cloud.eventarc.v1.Channel.State.UNRECOGNIZED : result; + } + /** + * + * + *
+     * Output only. The state of a Channel.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.eventarc.v1.Channel.State value) { + if (value == null) { + throw new NullPointerException(); + } + + state_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The state of a Channel.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + + state_ = 0; + onChanged(); + return this; + } + + private java.lang.Object activationToken_ = ""; + /** + * + * + *
+     * Output only. The activation token for the channel. The token must be used
+     * by the provider to register the channel for publishing.
+     * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The activationToken. + */ + public java.lang.String getActivationToken() { + java.lang.Object ref = activationToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + activationToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. The activation token for the channel. The token must be used
+     * by the provider to register the channel for publishing.
+     * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for activationToken. + */ + public com.google.protobuf.ByteString getActivationTokenBytes() { + java.lang.Object ref = activationToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + activationToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. The activation token for the channel. The token must be used
+     * by the provider to register the channel for publishing.
+     * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The activationToken to set. + * @return This builder for chaining. + */ + public Builder setActivationToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + activationToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The activation token for the channel. The token must be used
+     * by the provider to register the channel for publishing.
+     * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearActivationToken() { + + activationToken_ = getDefaultInstance().getActivationToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The activation token for the channel. The token must be used
+     * by the provider to register the channel for publishing.
+     * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for activationToken to set. + * @return This builder for chaining. + */ + public Builder setActivationTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + activationToken_ = value; + onChanged(); + return this; + } + + private java.lang.Object cryptoKeyName_ = ""; + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + public java.lang.String getCryptoKeyName() { + java.lang.Object ref = cryptoKeyName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cryptoKeyName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cryptoKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The cryptoKeyName to set. + * @return This builder for chaining. + */ + public Builder setCryptoKeyName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + cryptoKeyName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearCryptoKeyName() { + + cryptoKeyName_ = getDefaultInstance().getCryptoKeyName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for cryptoKeyName to set. + * @return This builder for chaining. + */ + public Builder setCryptoKeyNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + cryptoKeyName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Channel) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Channel) + private static final com.google.cloud.eventarc.v1.Channel DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Channel(); + } + + public static com.google.cloud.eventarc.v1.Channel getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Channel parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java new file mode 100644 index 000000000000..283a2179aba8 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java @@ -0,0 +1,1778 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel_connection.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A representation of the ChannelConnection resource.
+ * A ChannelConnection is a resource which event providers create during the
+ * activation process to establish a connection between the provider and the
+ * subscriber channel.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ChannelConnection} + */ +public final class ChannelConnection extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ChannelConnection) + ChannelConnectionOrBuilder { + private static final long serialVersionUID = 0L; + // Use ChannelConnection.newBuilder() to construct. + private ChannelConnection(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ChannelConnection() { + name_ = ""; + uid_ = ""; + channel_ = ""; + activationToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ChannelConnection(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.ChannelConnectionProto + .internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.ChannelConnectionProto + .internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ChannelConnection.class, + com.google.cloud.eventarc.v1.ChannelConnection.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the connection.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the connection.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UID_FIELD_NUMBER = 2; + private volatile java.lang.Object uid_; + /** + * + * + *
+   * Output only. Server assigned ID of the resource.
+   * The server guarantees uniqueness and immutability until deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Server assigned ID of the resource.
+   * The server guarantees uniqueness and immutability until deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CHANNEL_FIELD_NUMBER = 5; + private volatile java.lang.Object channel_; + /** + * + * + *
+   * Required. The name of the connected subscriber Channel.
+   * This is a weak reference to avoid cross project and cross accounts
+   * references. This must be in
+   * `projects/{project}/location/{location}/channels/{channel_id}` format.
+   * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The channel. + */ + @java.lang.Override + public java.lang.String getChannel() { + java.lang.Object ref = channel_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channel_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the connected subscriber Channel.
+   * This is a weak reference to avoid cross project and cross accounts
+   * references. This must be in
+   * `projects/{project}/location/{location}/channels/{channel_id}` format.
+   * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for channel. + */ + @java.lang.Override + public com.google.protobuf.ByteString getChannelBytes() { + java.lang.Object ref = channel_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channel_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 7; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int ACTIVATION_TOKEN_FIELD_NUMBER = 8; + private volatile java.lang.Object activationToken_; + /** + * + * + *
+   * Input only. Activation token for the channel. The token will be used
+   * during the creation of ChannelConnection to bind the channel with the
+   * provider project. This field will not be stored in the provider resource.
+   * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return The activationToken. + */ + @java.lang.Override + public java.lang.String getActivationToken() { + java.lang.Object ref = activationToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + activationToken_ = s; + return s; + } + } + /** + * + * + *
+   * Input only. Activation token for the channel. The token will be used
+   * during the creation of ChannelConnection to bind the channel with the
+   * provider project. This field will not be stored in the provider resource.
+   * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return The bytes for activationToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getActivationTokenBytes() { + java.lang.Object ref = activationToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + activationToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channel_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, channel_); + } + if (createTime_ != null) { + output.writeMessage(6, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(7, getUpdateTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(activationToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 8, activationToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channel_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, channel_); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(activationToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, activationToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ChannelConnection)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ChannelConnection other = + (com.google.cloud.eventarc.v1.ChannelConnection) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; + if (!getChannel().equals(other.getChannel())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getActivationToken().equals(other.getActivationToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + hash = (37 * hash) + CHANNEL_FIELD_NUMBER; + hash = (53 * hash) + getChannel().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (37 * hash) + ACTIVATION_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getActivationToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ChannelConnection prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A representation of the ChannelConnection resource.
+   * A ChannelConnection is a resource which event providers create during the
+   * activation process to establish a connection between the provider and the
+   * subscriber channel.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ChannelConnection} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ChannelConnection) + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.ChannelConnectionProto + .internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.ChannelConnectionProto + .internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ChannelConnection.class, + com.google.cloud.eventarc.v1.ChannelConnection.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ChannelConnection.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + uid_ = ""; + + channel_ = ""; + + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + activationToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.ChannelConnectionProto + .internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnection getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnection build() { + com.google.cloud.eventarc.v1.ChannelConnection result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnection buildPartial() { + com.google.cloud.eventarc.v1.ChannelConnection result = + new com.google.cloud.eventarc.v1.ChannelConnection(this); + result.name_ = name_; + result.uid_ = uid_; + result.channel_ = channel_; + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + result.activationToken_ = activationToken_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ChannelConnection) { + return mergeFrom((com.google.cloud.eventarc.v1.ChannelConnection) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ChannelConnection other) { + if (other == com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + onChanged(); + } + if (!other.getChannel().isEmpty()) { + channel_ = other.channel_; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (!other.getActivationToken().isEmpty()) { + activationToken_ = other.activationToken_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + uid_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 42: + { + channel_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 50: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 58 + case 66: + { + activationToken_ = input.readStringRequireUtf8(); + + break; + } // case 66 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the connection.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the connection.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the connection.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the connection.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the connection.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + /** + * + * + *
+     * Output only. Server assigned ID of the resource.
+     * The server guarantees uniqueness and immutability until deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Server assigned ID of the resource.
+     * The server guarantees uniqueness and immutability until deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Server assigned ID of the resource.
+     * The server guarantees uniqueness and immutability until deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + uid_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server assigned ID of the resource.
+     * The server guarantees uniqueness and immutability until deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearUid() { + + uid_ = getDefaultInstance().getUid(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server assigned ID of the resource.
+     * The server guarantees uniqueness and immutability until deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + uid_ = value; + onChanged(); + return this; + } + + private java.lang.Object channel_ = ""; + /** + * + * + *
+     * Required. The name of the connected subscriber Channel.
+     * This is a weak reference to avoid cross project and cross accounts
+     * references. This must be in
+     * `projects/{project}/location/{location}/channels/{channel_id}` format.
+     * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The channel. + */ + public java.lang.String getChannel() { + java.lang.Object ref = channel_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channel_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the connected subscriber Channel.
+     * This is a weak reference to avoid cross project and cross accounts
+     * references. This must be in
+     * `projects/{project}/location/{location}/channels/{channel_id}` format.
+     * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for channel. + */ + public com.google.protobuf.ByteString getChannelBytes() { + java.lang.Object ref = channel_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channel_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the connected subscriber Channel.
+     * This is a weak reference to avoid cross project and cross accounts
+     * references. This must be in
+     * `projects/{project}/location/{location}/channels/{channel_id}` format.
+     * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The channel to set. + * @return This builder for chaining. + */ + public Builder setChannel(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + channel_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the connected subscriber Channel.
+     * This is a weak reference to avoid cross project and cross accounts
+     * references. This must be in
+     * `projects/{project}/location/{location}/channels/{channel_id}` format.
+     * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearChannel() { + + channel_ = getDefaultInstance().getChannel(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the connected subscriber Channel.
+     * This is a weak reference to avoid cross project and cross accounts
+     * references. This must be in
+     * `projects/{project}/location/{location}/channels/{channel_id}` format.
+     * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for channel to set. + * @return This builder for chaining. + */ + public Builder setChannelBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + channel_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private java.lang.Object activationToken_ = ""; + /** + * + * + *
+     * Input only. Activation token for the channel. The token will be used
+     * during the creation of ChannelConnection to bind the channel with the
+     * provider project. This field will not be stored in the provider resource.
+     * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return The activationToken. + */ + public java.lang.String getActivationToken() { + java.lang.Object ref = activationToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + activationToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Input only. Activation token for the channel. The token will be used
+     * during the creation of ChannelConnection to bind the channel with the
+     * provider project. This field will not be stored in the provider resource.
+     * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return The bytes for activationToken. + */ + public com.google.protobuf.ByteString getActivationTokenBytes() { + java.lang.Object ref = activationToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + activationToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Input only. Activation token for the channel. The token will be used
+     * during the creation of ChannelConnection to bind the channel with the
+     * provider project. This field will not be stored in the provider resource.
+     * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @param value The activationToken to set. + * @return This builder for chaining. + */ + public Builder setActivationToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + activationToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Input only. Activation token for the channel. The token will be used
+     * during the creation of ChannelConnection to bind the channel with the
+     * provider project. This field will not be stored in the provider resource.
+     * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearActivationToken() { + + activationToken_ = getDefaultInstance().getActivationToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * Input only. Activation token for the channel. The token will be used
+     * during the creation of ChannelConnection to bind the channel with the
+     * provider project. This field will not be stored in the provider resource.
+     * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @param value The bytes for activationToken to set. + * @return This builder for chaining. + */ + public Builder setActivationTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + activationToken_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ChannelConnection) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ChannelConnection) + private static final com.google.cloud.eventarc.v1.ChannelConnection DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ChannelConnection(); + } + + public static com.google.cloud.eventarc.v1.ChannelConnection getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ChannelConnection parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnection getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java new file mode 100644 index 000000000000..88e2a1eed2ee --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java @@ -0,0 +1,217 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel_connection.proto + +package com.google.cloud.eventarc.v1; + +public interface ChannelConnectionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ChannelConnection) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the connection.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the connection.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. Server assigned ID of the resource.
+   * The server guarantees uniqueness and immutability until deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + java.lang.String getUid(); + /** + * + * + *
+   * Output only. Server assigned ID of the resource.
+   * The server guarantees uniqueness and immutability until deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Required. The name of the connected subscriber Channel.
+   * This is a weak reference to avoid cross project and cross accounts
+   * references. This must be in
+   * `projects/{project}/location/{location}/channels/{channel_id}` format.
+   * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The channel. + */ + java.lang.String getChannel(); + /** + * + * + *
+   * Required. The name of the connected subscriber Channel.
+   * This is a weak reference to avoid cross project and cross accounts
+   * references. This must be in
+   * `projects/{project}/location/{location}/channels/{channel_id}` format.
+   * 
+ * + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for channel. + */ + com.google.protobuf.ByteString getChannelBytes(); + + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Input only. Activation token for the channel. The token will be used
+   * during the creation of ChannelConnection to bind the channel with the
+   * provider project. This field will not be stored in the provider resource.
+   * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return The activationToken. + */ + java.lang.String getActivationToken(); + /** + * + * + *
+   * Input only. Activation token for the channel. The token will be used
+   * during the creation of ChannelConnection to bind the channel with the
+   * provider project. This field will not be stored in the provider resource.
+   * 
+ * + * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * + * @return The bytes for activationToken. + */ + com.google.protobuf.ByteString getActivationTokenBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java new file mode 100644 index 000000000000..d0f7280e6b56 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java @@ -0,0 +1,94 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel_connection.proto + +package com.google.cloud.eventarc.v1; + +public final class ChannelConnectionProto { + private ChannelConnectionProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n1google/cloud/eventarc/v1/channel_conne" + + "ction.proto\022\030google.cloud.eventarc.v1\032\037g" + + "oogle/api/field_behavior.proto\032\031google/a" + + "pi/resource.proto\032\037google/protobuf/times" + + "tamp.proto\"\247\003\n\021ChannelConnection\022\021\n\004name" + + "\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 \001(\tB\003\340A\003\0228\n\007channel" + + "\030\005 \001(\tB\'\340A\002\372A!\n\037eventarc.googleapis.com/" + + "Channel\0224\n\013create_time\030\006 \001(\0132\032.google.pr" + + "otobuf.TimestampB\003\340A\003\0224\n\013update_time\030\007 \001" + + "(\0132\032.google.protobuf.TimestampB\003\340A\003\022\035\n\020a" + + "ctivation_token\030\010 \001(\tB\003\340A\004:\247\001\352A\243\001\n)event" + + "arc.googleapis.com/ChannelConnection\022Opr" + + "ojects/{project}/locations/{location}/ch" + + "annelConnections/{channel_connection}*\022c" + + "hannelConnections2\021channelConnectionB\316\001\n" + + "\034com.google.cloud.eventarc.v1B\026ChannelCo" + + "nnectionProtoP\001Z@google.golang.org/genpr" + + "oto/googleapis/cloud/eventarc/v1;eventar" + + "c\252\002\030Google.Cloud.Eventarc.V1\312\002\030Google\\Cl" + + "oud\\Eventarc\\V1\352\002\033Google::Cloud::Eventar" + + "c::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor, + new java.lang.String[] { + "Name", "Uid", "Channel", "CreateTime", "UpdateTime", "ActivationToken", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java new file mode 100644 index 000000000000..615711d54aca --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java @@ -0,0 +1,326 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel.proto + +package com.google.cloud.eventarc.v1; + +public interface ChannelOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Channel) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The resource name of the channel. Must be unique within the
+   * location on the project and must be in
+   * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The resource name of the channel. Must be unique within the
+   * location on the project and must be in
+   * `projects/{project}/locations/{location}/channels/{channel_id}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. Server assigned unique identifier for the channel. The value
+   * is a UUID4 string and guaranteed to remain unchanged until the resource is
+   * deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + java.lang.String getUid(); + /** + * + * + *
+   * Output only. Server assigned unique identifier for the channel. The value
+   * is a UUID4 string and guaranteed to remain unchanged until the resource is
+   * deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * The name of the event provider (e.g. Eventarc SaaS partner) associated
+   * with the channel. This provider will be granted permissions to publish
+   * events to the channel. Format:
+   * `projects/{project}/locations/{location}/providers/{provider_id}`.
+   * 
+ * + * string provider = 7; + * + * @return The provider. + */ + java.lang.String getProvider(); + /** + * + * + *
+   * The name of the event provider (e.g. Eventarc SaaS partner) associated
+   * with the channel. This provider will be granted permissions to publish
+   * events to the channel. Format:
+   * `projects/{project}/locations/{location}/providers/{provider_id}`.
+   * 
+ * + * string provider = 7; + * + * @return The bytes for provider. + */ + com.google.protobuf.ByteString getProviderBytes(); + + /** + * + * + *
+   * Output only. The name of the Pub/Sub topic created and managed by
+   * Eventarc system as a transport for the event delivery. Format:
+   * `projects/{project}/topics/{topic_id}`.
+   * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return Whether the pubsubTopic field is set. + */ + boolean hasPubsubTopic(); + /** + * + * + *
+   * Output only. The name of the Pub/Sub topic created and managed by
+   * Eventarc system as a transport for the event delivery. Format:
+   * `projects/{project}/topics/{topic_id}`.
+   * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The pubsubTopic. + */ + java.lang.String getPubsubTopic(); + /** + * + * + *
+   * Output only. The name of the Pub/Sub topic created and managed by
+   * Eventarc system as a transport for the event delivery. Format:
+   * `projects/{project}/topics/{topic_id}`.
+   * 
+ * + * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for pubsubTopic. + */ + com.google.protobuf.ByteString getPubsubTopicBytes(); + + /** + * + * + *
+   * Output only. The state of a Channel.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + /** + * + * + *
+   * Output only. The state of a Channel.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.eventarc.v1.Channel.State getState(); + + /** + * + * + *
+   * Output only. The activation token for the channel. The token must be used
+   * by the provider to register the channel for publishing.
+   * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The activationToken. + */ + java.lang.String getActivationToken(); + /** + * + * + *
+   * Output only. The activation token for the channel. The token must be used
+   * by the provider to register the channel for publishing.
+   * 
+ * + * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for activationToken. + */ + com.google.protobuf.ByteString getActivationTokenBytes(); + + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + java.lang.String getCryptoKeyName(); + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + com.google.protobuf.ByteString getCryptoKeyNameBytes(); + + public com.google.cloud.eventarc.v1.Channel.TransportCase getTransportCase(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java new file mode 100644 index 000000000000..0ef41cd84d78 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java @@ -0,0 +1,106 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel.proto + +package com.google.cloud.eventarc.v1; + +public final class ChannelProto { + private ChannelProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Channel_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n&google/cloud/eventarc/v1/channel.proto" + + "\022\030google.cloud.eventarc.v1\032\037google/api/f" + + "ield_behavior.proto\032\031google/api/resource" + + ".proto\032\037google/protobuf/timestamp.proto\"" + + "\262\004\n\007Channel\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 " + + "\001(\tB\003\340A\003\0224\n\013create_time\030\005 \001(\0132\032.google.p" + + "rotobuf.TimestampB\003\340A\003\0224\n\013update_time\030\006 " + + "\001(\0132\032.google.protobuf.TimestampB\003\340A\003\022\020\n\010" + + "provider\030\007 \001(\t\022\033\n\014pubsub_topic\030\010 \001(\tB\003\340A" + + "\003H\000\022;\n\005state\030\t \001(\0162\'.google.cloud.eventa" + + "rc.v1.Channel.StateB\003\340A\003\022\035\n\020activation_t" + + "oken\030\n \001(\tB\003\340A\003\022B\n\017crypto_key_name\030\013 \001(\t" + + "B)\340A\001\372A#\n!cloudkms.googleapis.com/Crypto" + + "Key\"E\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n\007P" + + "ENDING\020\001\022\n\n\006ACTIVE\020\002\022\014\n\010INACTIVE\020\003:s\352Ap\n" + + "\037eventarc.googleapis.com/Channel\022:projec" + + "ts/{project}/locations/{location}/channe" + + "ls/{channel}*\010channels2\007channelB\013\n\ttrans" + + "portB\304\001\n\034com.google.cloud.eventarc.v1B\014C" + + "hannelProtoP\001Z@google.golang.org/genprot" + + "o/googleapis/cloud/eventarc/v1;eventarc\252" + + "\002\030Google.Cloud.Eventarc.V1\312\002\030Google\\Clou" + + "d\\Eventarc\\V1\352\002\033Google::Cloud::Eventarc:" + + ":V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_Channel_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_Channel_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "CreateTime", + "UpdateTime", + "Provider", + "PubsubTopic", + "State", + "ActivationToken", + "CryptoKeyName", + "Transport", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java new file mode 100644 index 000000000000..db8b4453b6a7 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java @@ -0,0 +1,1017 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * Represents a Cloud Run destination.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CloudRun} + */ +public final class CloudRun extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CloudRun) + CloudRunOrBuilder { + private static final long serialVersionUID = 0L; + // Use CloudRun.newBuilder() to construct. + private CloudRun(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CloudRun() { + service_ = ""; + path_ = ""; + region_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CloudRun(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CloudRun.class, + com.google.cloud.eventarc.v1.CloudRun.Builder.class); + } + + public static final int SERVICE_FIELD_NUMBER = 1; + private volatile java.lang.Object service_; + /** + * + * + *
+   * Required. The name of the Cloud Run service being addressed. See
+   * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+   * Only services located in the same project as the trigger object
+   * can be addressed.
+   * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The service. + */ + @java.lang.Override + public java.lang.String getService() { + java.lang.Object ref = service_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + service_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the Cloud Run service being addressed. See
+   * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+   * Only services located in the same project as the trigger object
+   * can be addressed.
+   * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for service. + */ + @java.lang.Override + public com.google.protobuf.ByteString getServiceBytes() { + java.lang.Object ref = service_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + service_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PATH_FIELD_NUMBER = 2; + private volatile java.lang.Object path_; + /** + * + * + *
+   * Optional. The relative path on the Cloud Run service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + @java.lang.Override + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. The relative path on the Cloud Run service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REGION_FIELD_NUMBER = 3; + private volatile java.lang.Object region_; + /** + * + * + *
+   * Required. The region the Cloud Run service is deployed in.
+   * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The region. + */ + @java.lang.Override + public java.lang.String getRegion() { + java.lang.Object ref = region_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + region_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The region the Cloud Run service is deployed in.
+   * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for region. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRegionBytes() { + java.lang.Object ref = region_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + region_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, service_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(region_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, region_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, service_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(region_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, region_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.CloudRun)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.CloudRun other = (com.google.cloud.eventarc.v1.CloudRun) obj; + + if (!getService().equals(other.getService())) return false; + if (!getPath().equals(other.getPath())) return false; + if (!getRegion().equals(other.getRegion())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + SERVICE_FIELD_NUMBER; + hash = (53 * hash) + getService().hashCode(); + hash = (37 * hash) + PATH_FIELD_NUMBER; + hash = (53 * hash) + getPath().hashCode(); + hash = (37 * hash) + REGION_FIELD_NUMBER; + hash = (53 * hash) + getRegion().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.CloudRun prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Represents a Cloud Run destination.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CloudRun} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CloudRun) + com.google.cloud.eventarc.v1.CloudRunOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CloudRun.class, + com.google.cloud.eventarc.v1.CloudRun.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.CloudRun.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + service_ = ""; + + path_ = ""; + + region_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRun getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRun build() { + com.google.cloud.eventarc.v1.CloudRun result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRun buildPartial() { + com.google.cloud.eventarc.v1.CloudRun result = + new com.google.cloud.eventarc.v1.CloudRun(this); + result.service_ = service_; + result.path_ = path_; + result.region_ = region_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.CloudRun) { + return mergeFrom((com.google.cloud.eventarc.v1.CloudRun) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.CloudRun other) { + if (other == com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance()) return this; + if (!other.getService().isEmpty()) { + service_ = other.service_; + onChanged(); + } + if (!other.getPath().isEmpty()) { + path_ = other.path_; + onChanged(); + } + if (!other.getRegion().isEmpty()) { + region_ = other.region_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + service_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + path_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + region_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object service_ = ""; + /** + * + * + *
+     * Required. The name of the Cloud Run service being addressed. See
+     * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+     * Only services located in the same project as the trigger object
+     * can be addressed.
+     * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The service. + */ + public java.lang.String getService() { + java.lang.Object ref = service_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + service_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the Cloud Run service being addressed. See
+     * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+     * Only services located in the same project as the trigger object
+     * can be addressed.
+     * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for service. + */ + public com.google.protobuf.ByteString getServiceBytes() { + java.lang.Object ref = service_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + service_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the Cloud Run service being addressed. See
+     * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+     * Only services located in the same project as the trigger object
+     * can be addressed.
+     * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The service to set. + * @return This builder for chaining. + */ + public Builder setService(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + service_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the Cloud Run service being addressed. See
+     * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+     * Only services located in the same project as the trigger object
+     * can be addressed.
+     * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearService() { + + service_ = getDefaultInstance().getService(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the Cloud Run service being addressed. See
+     * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+     * Only services located in the same project as the trigger object
+     * can be addressed.
+     * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for service to set. + * @return This builder for chaining. + */ + public Builder setServiceBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + service_ = value; + onChanged(); + return this; + } + + private java.lang.Object path_ = ""; + /** + * + * + *
+     * Optional. The relative path on the Cloud Run service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. The relative path on the Cloud Run service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. The relative path on the Cloud Run service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The path to set. + * @return This builder for chaining. + */ + public Builder setPath(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + path_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The relative path on the Cloud Run service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPath() { + + path_ = getDefaultInstance().getPath(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The relative path on the Cloud Run service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for path to set. + * @return This builder for chaining. + */ + public Builder setPathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + path_ = value; + onChanged(); + return this; + } + + private java.lang.Object region_ = ""; + /** + * + * + *
+     * Required. The region the Cloud Run service is deployed in.
+     * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The region. + */ + public java.lang.String getRegion() { + java.lang.Object ref = region_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + region_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The region the Cloud Run service is deployed in.
+     * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for region. + */ + public com.google.protobuf.ByteString getRegionBytes() { + java.lang.Object ref = region_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + region_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The region the Cloud Run service is deployed in.
+     * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The region to set. + * @return This builder for chaining. + */ + public Builder setRegion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + region_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The region the Cloud Run service is deployed in.
+     * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearRegion() { + + region_ = getDefaultInstance().getRegion(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The region the Cloud Run service is deployed in.
+     * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for region to set. + * @return This builder for chaining. + */ + public Builder setRegionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + region_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CloudRun) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CloudRun) + private static final com.google.cloud.eventarc.v1.CloudRun DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CloudRun(); + } + + public static com.google.cloud.eventarc.v1.CloudRun getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CloudRun parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRun getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java new file mode 100644 index 000000000000..fc4c9a5b3d98 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java @@ -0,0 +1,114 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface CloudRunOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CloudRun) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the Cloud Run service being addressed. See
+   * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+   * Only services located in the same project as the trigger object
+   * can be addressed.
+   * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The service. + */ + java.lang.String getService(); + /** + * + * + *
+   * Required. The name of the Cloud Run service being addressed. See
+   * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
+   * Only services located in the same project as the trigger object
+   * can be addressed.
+   * 
+ * + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for service. + */ + com.google.protobuf.ByteString getServiceBytes(); + + /** + * + * + *
+   * Optional. The relative path on the Cloud Run service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + java.lang.String getPath(); + /** + * + * + *
+   * Optional. The relative path on the Cloud Run service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + com.google.protobuf.ByteString getPathBytes(); + + /** + * + * + *
+   * Required. The region the Cloud Run service is deployed in.
+   * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The region. + */ + java.lang.String getRegion(); + /** + * + * + *
+   * Required. The region the Cloud Run service is deployed in.
+   * 
+ * + * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for region. + */ + com.google.protobuf.ByteString getRegionBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java new file mode 100644 index 000000000000..7c3830077879 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java @@ -0,0 +1,1102 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the CreateChannelConnection method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelConnectionRequest} + */ +public final class CreateChannelConnectionRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CreateChannelConnectionRequest) + CreateChannelConnectionRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use CreateChannelConnectionRequest.newBuilder() to construct. + private CreateChannelConnectionRequest( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateChannelConnectionRequest() { + parent_ = ""; + channelConnectionId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateChannelConnectionRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent collection in which to add this channel connection.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent collection in which to add this channel connection.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CHANNEL_CONNECTION_FIELD_NUMBER = 2; + private com.google.cloud.eventarc.v1.ChannelConnection channelConnection_; + /** + * + * + *
+   * Required. Channel connection to create.
+   * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the channelConnection field is set. + */ + @java.lang.Override + public boolean hasChannelConnection() { + return channelConnection_ != null; + } + /** + * + * + *
+   * Required. Channel connection to create.
+   * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The channelConnection. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection() { + return channelConnection_ == null + ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() + : channelConnection_; + } + /** + * + * + *
+   * Required. Channel connection to create.
+   * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionOrBuilder() { + return getChannelConnection(); + } + + public static final int CHANNEL_CONNECTION_ID_FIELD_NUMBER = 3; + private volatile java.lang.Object channelConnectionId_; + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel connection.
+   * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The channelConnectionId. + */ + @java.lang.Override + public java.lang.String getChannelConnectionId() { + java.lang.Object ref = channelConnectionId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channelConnectionId_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel connection.
+   * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for channelConnectionId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getChannelConnectionIdBytes() { + java.lang.Object ref = channelConnectionId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channelConnectionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (channelConnection_ != null) { + output.writeMessage(2, getChannelConnection()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channelConnectionId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, channelConnectionId_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (channelConnection_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getChannelConnection()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channelConnectionId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, channelConnectionId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.CreateChannelConnectionRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest other = + (com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasChannelConnection() != other.hasChannelConnection()) return false; + if (hasChannelConnection()) { + if (!getChannelConnection().equals(other.getChannelConnection())) return false; + } + if (!getChannelConnectionId().equals(other.getChannelConnectionId())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasChannelConnection()) { + hash = (37 * hash) + CHANNEL_CONNECTION_FIELD_NUMBER; + hash = (53 * hash) + getChannelConnection().hashCode(); + } + hash = (37 * hash) + CHANNEL_CONNECTION_ID_FIELD_NUMBER; + hash = (53 * hash) + getChannelConnectionId().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the CreateChannelConnection method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelConnectionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CreateChannelConnectionRequest) + com.google.cloud.eventarc.v1.CreateChannelConnectionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + if (channelConnectionBuilder_ == null) { + channelConnection_ = null; + } else { + channelConnection_ = null; + channelConnectionBuilder_ = null; + } + channelConnectionId_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest build() { + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest buildPartial() { + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest result = + new com.google.cloud.eventarc.v1.CreateChannelConnectionRequest(this); + result.parent_ = parent_; + if (channelConnectionBuilder_ == null) { + result.channelConnection_ = channelConnection_; + } else { + result.channelConnection_ = channelConnectionBuilder_.build(); + } + result.channelConnectionId_ = channelConnectionId_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.CreateChannelConnectionRequest other) { + if (other == com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.hasChannelConnection()) { + mergeChannelConnection(other.getChannelConnection()); + } + if (!other.getChannelConnectionId().isEmpty()) { + channelConnectionId_ = other.channelConnectionId_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage( + getChannelConnectionFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + channelConnectionId_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent collection in which to add this channel connection.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel connection.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel connection.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel connection.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel connection.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private com.google.cloud.eventarc.v1.ChannelConnection channelConnection_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + channelConnectionBuilder_; + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the channelConnection field is set. + */ + public boolean hasChannelConnection() { + return channelConnectionBuilder_ != null || channelConnection_ != null; + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The channelConnection. + */ + public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection() { + if (channelConnectionBuilder_ == null) { + return channelConnection_ == null + ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() + : channelConnection_; + } else { + return channelConnectionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setChannelConnection(com.google.cloud.eventarc.v1.ChannelConnection value) { + if (channelConnectionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + channelConnection_ = value; + onChanged(); + } else { + channelConnectionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setChannelConnection( + com.google.cloud.eventarc.v1.ChannelConnection.Builder builderForValue) { + if (channelConnectionBuilder_ == null) { + channelConnection_ = builderForValue.build(); + onChanged(); + } else { + channelConnectionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeChannelConnection(com.google.cloud.eventarc.v1.ChannelConnection value) { + if (channelConnectionBuilder_ == null) { + if (channelConnection_ != null) { + channelConnection_ = + com.google.cloud.eventarc.v1.ChannelConnection.newBuilder(channelConnection_) + .mergeFrom(value) + .buildPartial(); + } else { + channelConnection_ = value; + } + onChanged(); + } else { + channelConnectionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearChannelConnection() { + if (channelConnectionBuilder_ == null) { + channelConnection_ = null; + onChanged(); + } else { + channelConnection_ = null; + channelConnectionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.ChannelConnection.Builder getChannelConnectionBuilder() { + + onChanged(); + return getChannelConnectionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionOrBuilder() { + if (channelConnectionBuilder_ != null) { + return channelConnectionBuilder_.getMessageOrBuilder(); + } else { + return channelConnection_ == null + ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() + : channelConnection_; + } + } + /** + * + * + *
+     * Required. Channel connection to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + getChannelConnectionFieldBuilder() { + if (channelConnectionBuilder_ == null) { + channelConnectionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>( + getChannelConnection(), getParentForChildren(), isClean()); + channelConnection_ = null; + } + return channelConnectionBuilder_; + } + + private java.lang.Object channelConnectionId_ = ""; + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel connection.
+     * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The channelConnectionId. + */ + public java.lang.String getChannelConnectionId() { + java.lang.Object ref = channelConnectionId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channelConnectionId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel connection.
+     * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for channelConnectionId. + */ + public com.google.protobuf.ByteString getChannelConnectionIdBytes() { + java.lang.Object ref = channelConnectionId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channelConnectionId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel connection.
+     * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The channelConnectionId to set. + * @return This builder for chaining. + */ + public Builder setChannelConnectionId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + channelConnectionId_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel connection.
+     * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearChannelConnectionId() { + + channelConnectionId_ = getDefaultInstance().getChannelConnectionId(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel connection.
+     * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for channelConnectionId to set. + * @return This builder for chaining. + */ + public Builder setChannelConnectionIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + channelConnectionId_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CreateChannelConnectionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CreateChannelConnectionRequest) + private static final com.google.cloud.eventarc.v1.CreateChannelConnectionRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CreateChannelConnectionRequest(); + } + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateChannelConnectionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java new file mode 100644 index 000000000000..bb40917c6d63 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java @@ -0,0 +1,120 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface CreateChannelConnectionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CreateChannelConnectionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent collection in which to add this channel connection.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent collection in which to add this channel connection.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. Channel connection to create.
+   * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the channelConnection field is set. + */ + boolean hasChannelConnection(); + /** + * + * + *
+   * Required. Channel connection to create.
+   * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The channelConnection. + */ + com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection(); + /** + * + * + *
+   * Required. Channel connection to create.
+   * 
+ * + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionOrBuilder(); + + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel connection.
+   * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The channelConnectionId. + */ + java.lang.String getChannelConnectionId(); + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel connection.
+   * 
+ * + * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for channelConnectionId. + */ + com.google.protobuf.ByteString getChannelConnectionIdBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java new file mode 100644 index 000000000000..50c6deeb8429 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java @@ -0,0 +1,1188 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the CreateChannel method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelRequest} + */ +public final class CreateChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CreateChannelRequest) + CreateChannelRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use CreateChannelRequest.newBuilder() to construct. + private CreateChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateChannelRequest() { + parent_ = ""; + channelId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateChannelRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CreateChannelRequest.class, + com.google.cloud.eventarc.v1.CreateChannelRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent collection in which to add this channel.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent collection in which to add this channel.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CHANNEL_FIELD_NUMBER = 2; + private com.google.cloud.eventarc.v1.Channel channel_; + /** + * + * + *
+   * Required. The channel to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the channel field is set. + */ + @java.lang.Override + public boolean hasChannel() { + return channel_ != null; + } + /** + * + * + *
+   * Required. The channel to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The channel. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel getChannel() { + return channel_ == null ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; + } + /** + * + * + *
+   * Required. The channel to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { + return getChannel(); + } + + public static final int CHANNEL_ID_FIELD_NUMBER = 3; + private volatile java.lang.Object channelId_; + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel.
+   * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The channelId. + */ + @java.lang.Override + public java.lang.String getChannelId() { + java.lang.Object ref = channelId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channelId_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel.
+   * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for channelId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getChannelIdBytes() { + java.lang.Object ref = channelId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channelId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; + private boolean validateOnly_; + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (channel_ != null) { + output.writeMessage(2, getChannel()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channelId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, channelId_); + } + if (validateOnly_ != false) { + output.writeBool(4, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (channel_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getChannel()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channelId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, channelId_); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.CreateChannelRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.CreateChannelRequest other = + (com.google.cloud.eventarc.v1.CreateChannelRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasChannel() != other.hasChannel()) return false; + if (hasChannel()) { + if (!getChannel().equals(other.getChannel())) return false; + } + if (!getChannelId().equals(other.getChannelId())) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasChannel()) { + hash = (37 * hash) + CHANNEL_FIELD_NUMBER; + hash = (53 * hash) + getChannel().hashCode(); + } + hash = (37 * hash) + CHANNEL_ID_FIELD_NUMBER; + hash = (53 * hash) + getChannelId().hashCode(); + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.CreateChannelRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the CreateChannel method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CreateChannelRequest) + com.google.cloud.eventarc.v1.CreateChannelRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CreateChannelRequest.class, + com.google.cloud.eventarc.v1.CreateChannelRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.CreateChannelRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + if (channelBuilder_ == null) { + channel_ = null; + } else { + channel_ = null; + channelBuilder_ = null; + } + channelId_ = ""; + + validateOnly_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.CreateChannelRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelRequest build() { + com.google.cloud.eventarc.v1.CreateChannelRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelRequest buildPartial() { + com.google.cloud.eventarc.v1.CreateChannelRequest result = + new com.google.cloud.eventarc.v1.CreateChannelRequest(this); + result.parent_ = parent_; + if (channelBuilder_ == null) { + result.channel_ = channel_; + } else { + result.channel_ = channelBuilder_.build(); + } + result.channelId_ = channelId_; + result.validateOnly_ = validateOnly_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.CreateChannelRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.CreateChannelRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.CreateChannelRequest other) { + if (other == com.google.cloud.eventarc.v1.CreateChannelRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.hasChannel()) { + mergeChannel(other.getChannel()); + } + if (!other.getChannelId().isEmpty()) { + channelId_ = other.channelId_; + onChanged(); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getChannelFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + channelId_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent collection in which to add this channel.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection in which to add this channel.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private com.google.cloud.eventarc.v1.Channel channel_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + channelBuilder_; + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the channel field is set. + */ + public boolean hasChannel() { + return channelBuilder_ != null || channel_ != null; + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The channel. + */ + public com.google.cloud.eventarc.v1.Channel getChannel() { + if (channelBuilder_ == null) { + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; + } else { + return channelBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setChannel(com.google.cloud.eventarc.v1.Channel value) { + if (channelBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + channel_ = value; + onChanged(); + } else { + channelBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setChannel(com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + if (channelBuilder_ == null) { + channel_ = builderForValue.build(); + onChanged(); + } else { + channelBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeChannel(com.google.cloud.eventarc.v1.Channel value) { + if (channelBuilder_ == null) { + if (channel_ != null) { + channel_ = + com.google.cloud.eventarc.v1.Channel.newBuilder(channel_) + .mergeFrom(value) + .buildPartial(); + } else { + channel_ = value; + } + onChanged(); + } else { + channelBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearChannel() { + if (channelBuilder_ == null) { + channel_ = null; + onChanged(); + } else { + channel_ = null; + channelBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.Channel.Builder getChannelBuilder() { + + onChanged(); + return getChannelFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { + if (channelBuilder_ != null) { + return channelBuilder_.getMessageOrBuilder(); + } else { + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; + } + } + /** + * + * + *
+     * Required. The channel to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + getChannelFieldBuilder() { + if (channelBuilder_ == null) { + channelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder>( + getChannel(), getParentForChildren(), isClean()); + channel_ = null; + } + return channelBuilder_; + } + + private java.lang.Object channelId_ = ""; + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel.
+     * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The channelId. + */ + public java.lang.String getChannelId() { + java.lang.Object ref = channelId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channelId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel.
+     * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for channelId. + */ + public com.google.protobuf.ByteString getChannelIdBytes() { + java.lang.Object ref = channelId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channelId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel.
+     * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The channelId to set. + * @return This builder for chaining. + */ + public Builder setChannelId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + channelId_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel.
+     * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearChannelId() { + + channelId_ = getDefaultInstance().getChannelId(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the channel.
+     * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for channelId to set. + * @return This builder for chaining. + */ + public Builder setChannelIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + channelId_ = value; + onChanged(); + return this; + } + + private boolean validateOnly_; + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CreateChannelRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CreateChannelRequest) + private static final com.google.cloud.eventarc.v1.CreateChannelRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CreateChannelRequest(); + } + + public static com.google.cloud.eventarc.v1.CreateChannelRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateChannelRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java new file mode 100644 index 000000000000..bb561aaf7ceb --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java @@ -0,0 +1,131 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface CreateChannelRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CreateChannelRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent collection in which to add this channel.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent collection in which to add this channel.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. The channel to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the channel field is set. + */ + boolean hasChannel(); + /** + * + * + *
+   * Required. The channel to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The channel. + */ + com.google.cloud.eventarc.v1.Channel getChannel(); + /** + * + * + *
+   * Required. The channel to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder(); + + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel.
+   * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The channelId. + */ + java.lang.String getChannelId(); + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the channel.
+   * 
+ * + * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for channelId. + */ + com.google.protobuf.ByteString getChannelIdBytes(); + + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java new file mode 100644 index 000000000000..36bc7fe5554f --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java @@ -0,0 +1,1188 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the CreateTrigger method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CreateTriggerRequest} + */ +public final class CreateTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CreateTriggerRequest) + CreateTriggerRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use CreateTriggerRequest.newBuilder() to construct. + private CreateTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateTriggerRequest() { + parent_ = ""; + triggerId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateTriggerRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CreateTriggerRequest.class, + com.google.cloud.eventarc.v1.CreateTriggerRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent collection in which to add this trigger.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent collection in which to add this trigger.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TRIGGER_FIELD_NUMBER = 2; + private com.google.cloud.eventarc.v1.Trigger trigger_; + /** + * + * + *
+   * Required. The trigger to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the trigger field is set. + */ + @java.lang.Override + public boolean hasTrigger() { + return trigger_ != null; + } + /** + * + * + *
+   * Required. The trigger to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The trigger. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger getTrigger() { + return trigger_ == null ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; + } + /** + * + * + *
+   * Required. The trigger to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { + return getTrigger(); + } + + public static final int TRIGGER_ID_FIELD_NUMBER = 3; + private volatile java.lang.Object triggerId_; + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the trigger.
+   * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The triggerId. + */ + @java.lang.Override + public java.lang.String getTriggerId() { + java.lang.Object ref = triggerId_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + triggerId_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the trigger.
+   * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for triggerId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTriggerIdBytes() { + java.lang.Object ref = triggerId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + triggerId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; + private boolean validateOnly_; + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (trigger_ != null) { + output.writeMessage(2, getTrigger()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, triggerId_); + } + if (validateOnly_ != false) { + output.writeBool(4, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (trigger_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getTrigger()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, triggerId_); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.CreateTriggerRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.CreateTriggerRequest other = + (com.google.cloud.eventarc.v1.CreateTriggerRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasTrigger() != other.hasTrigger()) return false; + if (hasTrigger()) { + if (!getTrigger().equals(other.getTrigger())) return false; + } + if (!getTriggerId().equals(other.getTriggerId())) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasTrigger()) { + hash = (37 * hash) + TRIGGER_FIELD_NUMBER; + hash = (53 * hash) + getTrigger().hashCode(); + } + hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; + hash = (53 * hash) + getTriggerId().hashCode(); + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.CreateTriggerRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the CreateTrigger method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.CreateTriggerRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CreateTriggerRequest) + com.google.cloud.eventarc.v1.CreateTriggerRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.CreateTriggerRequest.class, + com.google.cloud.eventarc.v1.CreateTriggerRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.CreateTriggerRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + if (triggerBuilder_ == null) { + trigger_ = null; + } else { + trigger_ = null; + triggerBuilder_ = null; + } + triggerId_ = ""; + + validateOnly_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateTriggerRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.CreateTriggerRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateTriggerRequest build() { + com.google.cloud.eventarc.v1.CreateTriggerRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateTriggerRequest buildPartial() { + com.google.cloud.eventarc.v1.CreateTriggerRequest result = + new com.google.cloud.eventarc.v1.CreateTriggerRequest(this); + result.parent_ = parent_; + if (triggerBuilder_ == null) { + result.trigger_ = trigger_; + } else { + result.trigger_ = triggerBuilder_.build(); + } + result.triggerId_ = triggerId_; + result.validateOnly_ = validateOnly_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.CreateTriggerRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.CreateTriggerRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.CreateTriggerRequest other) { + if (other == com.google.cloud.eventarc.v1.CreateTriggerRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.hasTrigger()) { + mergeTrigger(other.getTrigger()); + } + if (!other.getTriggerId().isEmpty()) { + triggerId_ = other.triggerId_; + onChanged(); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + triggerId_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent collection in which to add this trigger.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent collection in which to add this trigger.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent collection in which to add this trigger.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection in which to add this trigger.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection in which to add this trigger.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private com.google.cloud.eventarc.v1.Trigger trigger_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + triggerBuilder_; + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the trigger field is set. + */ + public boolean hasTrigger() { + return triggerBuilder_ != null || trigger_ != null; + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The trigger. + */ + public com.google.cloud.eventarc.v1.Trigger getTrigger() { + if (triggerBuilder_ == null) { + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; + } else { + return triggerBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger value) { + if (triggerBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + trigger_ = value; + onChanged(); + } else { + triggerBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + if (triggerBuilder_ == null) { + trigger_ = builderForValue.build(); + onChanged(); + } else { + triggerBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeTrigger(com.google.cloud.eventarc.v1.Trigger value) { + if (triggerBuilder_ == null) { + if (trigger_ != null) { + trigger_ = + com.google.cloud.eventarc.v1.Trigger.newBuilder(trigger_) + .mergeFrom(value) + .buildPartial(); + } else { + trigger_ = value; + } + onChanged(); + } else { + triggerBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearTrigger() { + if (triggerBuilder_ == null) { + trigger_ = null; + onChanged(); + } else { + trigger_ = null; + triggerBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.Trigger.Builder getTriggerBuilder() { + + onChanged(); + return getTriggerFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { + if (triggerBuilder_ != null) { + return triggerBuilder_.getMessageOrBuilder(); + } else { + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; + } + } + /** + * + * + *
+     * Required. The trigger to create.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + getTriggerFieldBuilder() { + if (triggerBuilder_ == null) { + triggerBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder>( + getTrigger(), getParentForChildren(), isClean()); + trigger_ = null; + } + return triggerBuilder_; + } + + private java.lang.Object triggerId_ = ""; + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the trigger.
+     * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The triggerId. + */ + public java.lang.String getTriggerId() { + java.lang.Object ref = triggerId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + triggerId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the trigger.
+     * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for triggerId. + */ + public com.google.protobuf.ByteString getTriggerIdBytes() { + java.lang.Object ref = triggerId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + triggerId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the trigger.
+     * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The triggerId to set. + * @return This builder for chaining. + */ + public Builder setTriggerId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + triggerId_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the trigger.
+     * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearTriggerId() { + + triggerId_ = getDefaultInstance().getTriggerId(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The user-provided ID to be assigned to the trigger.
+     * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for triggerId to set. + * @return This builder for chaining. + */ + public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + triggerId_ = value; + onChanged(); + return this; + } + + private boolean validateOnly_; + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CreateTriggerRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CreateTriggerRequest) + private static final com.google.cloud.eventarc.v1.CreateTriggerRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CreateTriggerRequest(); + } + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.CreateTriggerRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java new file mode 100644 index 000000000000..9ec5691ca69d --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java @@ -0,0 +1,131 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface CreateTriggerRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CreateTriggerRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent collection in which to add this trigger.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent collection in which to add this trigger.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. The trigger to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the trigger field is set. + */ + boolean hasTrigger(); + /** + * + * + *
+   * Required. The trigger to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The trigger. + */ + com.google.cloud.eventarc.v1.Trigger getTrigger(); + /** + * + * + *
+   * Required. The trigger to create.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder(); + + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the trigger.
+   * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The triggerId. + */ + java.lang.String getTriggerId(); + /** + * + * + *
+   * Required. The user-provided ID to be assigned to the trigger.
+   * 
+ * + * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for triggerId. + */ + com.google.protobuf.ByteString getTriggerIdBytes(); + + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java new file mode 100644 index 000000000000..f8706de019c5 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java @@ -0,0 +1,631 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the DeleteChannelConnection method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelConnectionRequest} + */ +public final class DeleteChannelConnectionRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) + DeleteChannelConnectionRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use DeleteChannelConnectionRequest.newBuilder() to construct. + private DeleteChannelConnectionRequest( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteChannelConnectionRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteChannelConnectionRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the channel connection to delete.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the channel connection to delete.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest other = + (com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the DeleteChannelConnection method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelConnectionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest build() { + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest buildPartial() { + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest result = + new com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest other) { + if (other == com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the channel connection to delete.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel connection to delete.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel connection to delete.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel connection to delete.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel connection to delete.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) + private static final com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest(); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteChannelConnectionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java new file mode 100644 index 000000000000..a2894e026e79 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java @@ -0,0 +1,54 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface DeleteChannelConnectionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the channel connection to delete.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the channel connection to delete.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java new file mode 100644 index 000000000000..051c29c49eb4 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java @@ -0,0 +1,724 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the DeleteChannel method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelRequest} + */ +public final class DeleteChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.DeleteChannelRequest) + DeleteChannelRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use DeleteChannelRequest.newBuilder() to construct. + private DeleteChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteChannelRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteChannelRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.DeleteChannelRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the channel to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the channel to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 2; + private boolean validateOnly_; + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (validateOnly_ != false) { + output.writeBool(2, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, validateOnly_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.DeleteChannelRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.DeleteChannelRequest other = + (com.google.cloud.eventarc.v1.DeleteChannelRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.DeleteChannelRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the DeleteChannel method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.DeleteChannelRequest) + com.google.cloud.eventarc.v1.DeleteChannelRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.DeleteChannelRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.DeleteChannelRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + validateOnly_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.DeleteChannelRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelRequest build() { + com.google.cloud.eventarc.v1.DeleteChannelRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelRequest buildPartial() { + com.google.cloud.eventarc.v1.DeleteChannelRequest result = + new com.google.cloud.eventarc.v1.DeleteChannelRequest(this); + result.name_ = name_; + result.validateOnly_ = validateOnly_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.DeleteChannelRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.DeleteChannelRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.DeleteChannelRequest other) { + if (other == com.google.cloud.eventarc.v1.DeleteChannelRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + validateOnly_ = input.readBool(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the channel to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private boolean validateOnly_; + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.DeleteChannelRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.DeleteChannelRequest) + private static final com.google.cloud.eventarc.v1.DeleteChannelRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.DeleteChannelRequest(); + } + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteChannelRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java new file mode 100644 index 000000000000..0db07aec819e --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java @@ -0,0 +1,68 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface DeleteChannelRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.DeleteChannelRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the channel to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the channel to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java new file mode 100644 index 000000000000..9931e7575335 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java @@ -0,0 +1,1004 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the DeleteTrigger method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.DeleteTriggerRequest} + */ +public final class DeleteTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.DeleteTriggerRequest) + DeleteTriggerRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use DeleteTriggerRequest.newBuilder() to construct. + private DeleteTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteTriggerRequest() { + name_ = ""; + etag_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteTriggerRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, + com.google.cloud.eventarc.v1.DeleteTriggerRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the trigger to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the trigger to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ETAG_FIELD_NUMBER = 2; + private volatile java.lang.Object etag_; + /** + * + * + *
+   * If provided, the trigger will only be deleted if the etag matches the
+   * current etag on the resource.
+   * 
+ * + * string etag = 2; + * + * @return The etag. + */ + @java.lang.Override + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } + } + /** + * + * + *
+   * If provided, the trigger will only be deleted if the etag matches the
+   * current etag on the resource.
+   * 
+ * + * string etag = 2; + * + * @return The bytes for etag. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ALLOW_MISSING_FIELD_NUMBER = 3; + private boolean allowMissing_; + /** + * + * + *
+   * If set to true, and the trigger is not found, the request will succeed
+   * but no action will be taken on the server.
+   * 
+ * + * bool allow_missing = 3; + * + * @return The allowMissing. + */ + @java.lang.Override + public boolean getAllowMissing() { + return allowMissing_; + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; + private boolean validateOnly_; + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, etag_); + } + if (allowMissing_ != false) { + output.writeBool(3, allowMissing_); + } + if (validateOnly_ != false) { + output.writeBool(4, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, etag_); + } + if (allowMissing_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowMissing_); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.DeleteTriggerRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.DeleteTriggerRequest other = + (com.google.cloud.eventarc.v1.DeleteTriggerRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getEtag().equals(other.getEtag())) return false; + if (getAllowMissing() != other.getAllowMissing()) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + ETAG_FIELD_NUMBER; + hash = (53 * hash) + getEtag().hashCode(); + hash = (37 * hash) + ALLOW_MISSING_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowMissing()); + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.DeleteTriggerRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the DeleteTrigger method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.DeleteTriggerRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.DeleteTriggerRequest) + com.google.cloud.eventarc.v1.DeleteTriggerRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, + com.google.cloud.eventarc.v1.DeleteTriggerRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.DeleteTriggerRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + etag_ = ""; + + allowMissing_ = false; + + validateOnly_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteTriggerRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.DeleteTriggerRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteTriggerRequest build() { + com.google.cloud.eventarc.v1.DeleteTriggerRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteTriggerRequest buildPartial() { + com.google.cloud.eventarc.v1.DeleteTriggerRequest result = + new com.google.cloud.eventarc.v1.DeleteTriggerRequest(this); + result.name_ = name_; + result.etag_ = etag_; + result.allowMissing_ = allowMissing_; + result.validateOnly_ = validateOnly_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.DeleteTriggerRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.DeleteTriggerRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.DeleteTriggerRequest other) { + if (other == com.google.cloud.eventarc.v1.DeleteTriggerRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getEtag().isEmpty()) { + etag_ = other.etag_; + onChanged(); + } + if (other.getAllowMissing() != false) { + setAllowMissing(other.getAllowMissing()); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + allowMissing_ = input.readBool(); + + break; + } // case 24 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the trigger to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the trigger to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the trigger to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the trigger to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the trigger to be deleted.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private java.lang.Object etag_ = ""; + /** + * + * + *
+     * If provided, the trigger will only be deleted if the etag matches the
+     * current etag on the resource.
+     * 
+ * + * string etag = 2; + * + * @return The etag. + */ + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * If provided, the trigger will only be deleted if the etag matches the
+     * current etag on the resource.
+     * 
+ * + * string etag = 2; + * + * @return The bytes for etag. + */ + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * If provided, the trigger will only be deleted if the etag matches the
+     * current etag on the resource.
+     * 
+ * + * string etag = 2; + * + * @param value The etag to set. + * @return This builder for chaining. + */ + public Builder setEtag(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + etag_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If provided, the trigger will only be deleted if the etag matches the
+     * current etag on the resource.
+     * 
+ * + * string etag = 2; + * + * @return This builder for chaining. + */ + public Builder clearEtag() { + + etag_ = getDefaultInstance().getEtag(); + onChanged(); + return this; + } + /** + * + * + *
+     * If provided, the trigger will only be deleted if the etag matches the
+     * current etag on the resource.
+     * 
+ * + * string etag = 2; + * + * @param value The bytes for etag to set. + * @return This builder for chaining. + */ + public Builder setEtagBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + etag_ = value; + onChanged(); + return this; + } + + private boolean allowMissing_; + /** + * + * + *
+     * If set to true, and the trigger is not found, the request will succeed
+     * but no action will be taken on the server.
+     * 
+ * + * bool allow_missing = 3; + * + * @return The allowMissing. + */ + @java.lang.Override + public boolean getAllowMissing() { + return allowMissing_; + } + /** + * + * + *
+     * If set to true, and the trigger is not found, the request will succeed
+     * but no action will be taken on the server.
+     * 
+ * + * bool allow_missing = 3; + * + * @param value The allowMissing to set. + * @return This builder for chaining. + */ + public Builder setAllowMissing(boolean value) { + + allowMissing_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If set to true, and the trigger is not found, the request will succeed
+     * but no action will be taken on the server.
+     * 
+ * + * bool allow_missing = 3; + * + * @return This builder for chaining. + */ + public Builder clearAllowMissing() { + + allowMissing_ = false; + onChanged(); + return this; + } + + private boolean validateOnly_; + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.DeleteTriggerRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.DeleteTriggerRequest) + private static final com.google.cloud.eventarc.v1.DeleteTriggerRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.DeleteTriggerRequest(); + } + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.DeleteTriggerRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java new file mode 100644 index 000000000000..5584bffa0fdb --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java @@ -0,0 +1,109 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface DeleteTriggerRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.DeleteTriggerRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the trigger to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the trigger to be deleted.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * If provided, the trigger will only be deleted if the etag matches the
+   * current etag on the resource.
+   * 
+ * + * string etag = 2; + * + * @return The etag. + */ + java.lang.String getEtag(); + /** + * + * + *
+   * If provided, the trigger will only be deleted if the etag matches the
+   * current etag on the resource.
+   * 
+ * + * string etag = 2; + * + * @return The bytes for etag. + */ + com.google.protobuf.ByteString getEtagBytes(); + + /** + * + * + *
+   * If set to true, and the trigger is not found, the request will succeed
+   * but no action will be taken on the server.
+   * 
+ * + * bool allow_missing = 3; + * + * @return The allowMissing. + */ + boolean getAllowMissing(); + + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java new file mode 100644 index 000000000000..bb9df3dc1e7a --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java @@ -0,0 +1,1641 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * Represents a target of an invocation over HTTP.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Destination} + */ +public final class Destination extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Destination) + DestinationOrBuilder { + private static final long serialVersionUID = 0L; + // Use Destination.newBuilder() to construct. + private Destination(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Destination() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Destination(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Destination.class, + com.google.cloud.eventarc.v1.Destination.Builder.class); + } + + private int descriptorCase_ = 0; + private java.lang.Object descriptor_; + + public enum DescriptorCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + CLOUD_RUN(1), + CLOUD_FUNCTION(2), + GKE(3), + WORKFLOW(4), + DESCRIPTOR_NOT_SET(0); + private final int value; + + private DescriptorCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DescriptorCase valueOf(int value) { + return forNumber(value); + } + + public static DescriptorCase forNumber(int value) { + switch (value) { + case 1: + return CLOUD_RUN; + case 2: + return CLOUD_FUNCTION; + case 3: + return GKE; + case 4: + return WORKFLOW; + case 0: + return DESCRIPTOR_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public DescriptorCase getDescriptorCase() { + return DescriptorCase.forNumber(descriptorCase_); + } + + public static final int CLOUD_RUN_FIELD_NUMBER = 1; + /** + * + * + *
+   * Cloud Run fully-managed resource that receives the events. The resource
+   * should be in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * + * @return Whether the cloudRun field is set. + */ + @java.lang.Override + public boolean hasCloudRun() { + return descriptorCase_ == 1; + } + /** + * + * + *
+   * Cloud Run fully-managed resource that receives the events. The resource
+   * should be in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * + * @return The cloudRun. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRun getCloudRun() { + if (descriptorCase_ == 1) { + return (com.google.cloud.eventarc.v1.CloudRun) descriptor_; + } + return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } + /** + * + * + *
+   * Cloud Run fully-managed resource that receives the events. The resource
+   * should be in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder() { + if (descriptorCase_ == 1) { + return (com.google.cloud.eventarc.v1.CloudRun) descriptor_; + } + return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } + + public static final int CLOUD_FUNCTION_FIELD_NUMBER = 2; + /** + * + * + *
+   * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+   * Format: `projects/{project}/locations/{location}/functions/{function}`
+   * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return Whether the cloudFunction field is set. + */ + public boolean hasCloudFunction() { + return descriptorCase_ == 2; + } + /** + * + * + *
+   * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+   * Format: `projects/{project}/locations/{location}/functions/{function}`
+   * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return The cloudFunction. + */ + public java.lang.String getCloudFunction() { + java.lang.Object ref = ""; + if (descriptorCase_ == 2) { + ref = descriptor_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (descriptorCase_ == 2) { + descriptor_ = s; + } + return s; + } + } + /** + * + * + *
+   * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+   * Format: `projects/{project}/locations/{location}/functions/{function}`
+   * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for cloudFunction. + */ + public com.google.protobuf.ByteString getCloudFunctionBytes() { + java.lang.Object ref = ""; + if (descriptorCase_ == 2) { + ref = descriptor_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (descriptorCase_ == 2) { + descriptor_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int GKE_FIELD_NUMBER = 3; + /** + * + * + *
+   * A GKE service capable of receiving events. The service should be running
+   * in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + * + * @return Whether the gke field is set. + */ + @java.lang.Override + public boolean hasGke() { + return descriptorCase_ == 3; + } + /** + * + * + *
+   * A GKE service capable of receiving events. The service should be running
+   * in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + * + * @return The gke. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.GKE getGke() { + if (descriptorCase_ == 3) { + return (com.google.cloud.eventarc.v1.GKE) descriptor_; + } + return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } + /** + * + * + *
+   * A GKE service capable of receiving events. The service should be running
+   * in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() { + if (descriptorCase_ == 3) { + return (com.google.cloud.eventarc.v1.GKE) descriptor_; + } + return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } + + public static final int WORKFLOW_FIELD_NUMBER = 4; + /** + * + * + *
+   * The resource name of the Workflow whose Executions are triggered by
+   * the events. The Workflow resource should be deployed in the same project
+   * as the trigger.
+   * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+   * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return Whether the workflow field is set. + */ + public boolean hasWorkflow() { + return descriptorCase_ == 4; + } + /** + * + * + *
+   * The resource name of the Workflow whose Executions are triggered by
+   * the events. The Workflow resource should be deployed in the same project
+   * as the trigger.
+   * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+   * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return The workflow. + */ + public java.lang.String getWorkflow() { + java.lang.Object ref = ""; + if (descriptorCase_ == 4) { + ref = descriptor_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (descriptorCase_ == 4) { + descriptor_ = s; + } + return s; + } + } + /** + * + * + *
+   * The resource name of the Workflow whose Executions are triggered by
+   * the events. The Workflow resource should be deployed in the same project
+   * as the trigger.
+   * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+   * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for workflow. + */ + public com.google.protobuf.ByteString getWorkflowBytes() { + java.lang.Object ref = ""; + if (descriptorCase_ == 4) { + ref = descriptor_; + } + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (descriptorCase_ == 4) { + descriptor_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (descriptorCase_ == 1) { + output.writeMessage(1, (com.google.cloud.eventarc.v1.CloudRun) descriptor_); + } + if (descriptorCase_ == 2) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, descriptor_); + } + if (descriptorCase_ == 3) { + output.writeMessage(3, (com.google.cloud.eventarc.v1.GKE) descriptor_); + } + if (descriptorCase_ == 4) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, descriptor_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (descriptorCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.eventarc.v1.CloudRun) descriptor_); + } + if (descriptorCase_ == 2) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, descriptor_); + } + if (descriptorCase_ == 3) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.cloud.eventarc.v1.GKE) descriptor_); + } + if (descriptorCase_ == 4) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, descriptor_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.Destination)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.Destination other = (com.google.cloud.eventarc.v1.Destination) obj; + + if (!getDescriptorCase().equals(other.getDescriptorCase())) return false; + switch (descriptorCase_) { + case 1: + if (!getCloudRun().equals(other.getCloudRun())) return false; + break; + case 2: + if (!getCloudFunction().equals(other.getCloudFunction())) return false; + break; + case 3: + if (!getGke().equals(other.getGke())) return false; + break; + case 4: + if (!getWorkflow().equals(other.getWorkflow())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (descriptorCase_) { + case 1: + hash = (37 * hash) + CLOUD_RUN_FIELD_NUMBER; + hash = (53 * hash) + getCloudRun().hashCode(); + break; + case 2: + hash = (37 * hash) + CLOUD_FUNCTION_FIELD_NUMBER; + hash = (53 * hash) + getCloudFunction().hashCode(); + break; + case 3: + hash = (37 * hash) + GKE_FIELD_NUMBER; + hash = (53 * hash) + getGke().hashCode(); + break; + case 4: + hash = (37 * hash) + WORKFLOW_FIELD_NUMBER; + hash = (53 * hash) + getWorkflow().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Destination parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Destination parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Destination parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.Destination prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Represents a target of an invocation over HTTP.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Destination} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Destination) + com.google.cloud.eventarc.v1.DestinationOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Destination.class, + com.google.cloud.eventarc.v1.Destination.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.Destination.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (cloudRunBuilder_ != null) { + cloudRunBuilder_.clear(); + } + if (gkeBuilder_ != null) { + gkeBuilder_.clear(); + } + descriptorCase_ = 0; + descriptor_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Destination getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.Destination.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Destination build() { + com.google.cloud.eventarc.v1.Destination result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Destination buildPartial() { + com.google.cloud.eventarc.v1.Destination result = + new com.google.cloud.eventarc.v1.Destination(this); + if (descriptorCase_ == 1) { + if (cloudRunBuilder_ == null) { + result.descriptor_ = descriptor_; + } else { + result.descriptor_ = cloudRunBuilder_.build(); + } + } + if (descriptorCase_ == 2) { + result.descriptor_ = descriptor_; + } + if (descriptorCase_ == 3) { + if (gkeBuilder_ == null) { + result.descriptor_ = descriptor_; + } else { + result.descriptor_ = gkeBuilder_.build(); + } + } + if (descriptorCase_ == 4) { + result.descriptor_ = descriptor_; + } + result.descriptorCase_ = descriptorCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.Destination) { + return mergeFrom((com.google.cloud.eventarc.v1.Destination) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.Destination other) { + if (other == com.google.cloud.eventarc.v1.Destination.getDefaultInstance()) return this; + switch (other.getDescriptorCase()) { + case CLOUD_RUN: + { + mergeCloudRun(other.getCloudRun()); + break; + } + case CLOUD_FUNCTION: + { + descriptorCase_ = 2; + descriptor_ = other.descriptor_; + onChanged(); + break; + } + case GKE: + { + mergeGke(other.getGke()); + break; + } + case WORKFLOW: + { + descriptorCase_ = 4; + descriptor_ = other.descriptor_; + onChanged(); + break; + } + case DESCRIPTOR_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getCloudRunFieldBuilder().getBuilder(), extensionRegistry); + descriptorCase_ = 1; + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + descriptorCase_ = 2; + descriptor_ = s; + break; + } // case 18 + case 26: + { + input.readMessage(getGkeFieldBuilder().getBuilder(), extensionRegistry); + descriptorCase_ = 3; + break; + } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + descriptorCase_ = 4; + descriptor_ = s; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int descriptorCase_ = 0; + private java.lang.Object descriptor_; + + public DescriptorCase getDescriptorCase() { + return DescriptorCase.forNumber(descriptorCase_); + } + + public Builder clearDescriptor() { + descriptorCase_ = 0; + descriptor_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.CloudRun, + com.google.cloud.eventarc.v1.CloudRun.Builder, + com.google.cloud.eventarc.v1.CloudRunOrBuilder> + cloudRunBuilder_; + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * + * @return Whether the cloudRun field is set. + */ + @java.lang.Override + public boolean hasCloudRun() { + return descriptorCase_ == 1; + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * + * @return The cloudRun. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRun getCloudRun() { + if (cloudRunBuilder_ == null) { + if (descriptorCase_ == 1) { + return (com.google.cloud.eventarc.v1.CloudRun) descriptor_; + } + return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } else { + if (descriptorCase_ == 1) { + return cloudRunBuilder_.getMessage(); + } + return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + public Builder setCloudRun(com.google.cloud.eventarc.v1.CloudRun value) { + if (cloudRunBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + descriptor_ = value; + onChanged(); + } else { + cloudRunBuilder_.setMessage(value); + } + descriptorCase_ = 1; + return this; + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + public Builder setCloudRun(com.google.cloud.eventarc.v1.CloudRun.Builder builderForValue) { + if (cloudRunBuilder_ == null) { + descriptor_ = builderForValue.build(); + onChanged(); + } else { + cloudRunBuilder_.setMessage(builderForValue.build()); + } + descriptorCase_ = 1; + return this; + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + public Builder mergeCloudRun(com.google.cloud.eventarc.v1.CloudRun value) { + if (cloudRunBuilder_ == null) { + if (descriptorCase_ == 1 + && descriptor_ != com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance()) { + descriptor_ = + com.google.cloud.eventarc.v1.CloudRun.newBuilder( + (com.google.cloud.eventarc.v1.CloudRun) descriptor_) + .mergeFrom(value) + .buildPartial(); + } else { + descriptor_ = value; + } + onChanged(); + } else { + if (descriptorCase_ == 1) { + cloudRunBuilder_.mergeFrom(value); + } else { + cloudRunBuilder_.setMessage(value); + } + } + descriptorCase_ = 1; + return this; + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + public Builder clearCloudRun() { + if (cloudRunBuilder_ == null) { + if (descriptorCase_ == 1) { + descriptorCase_ = 0; + descriptor_ = null; + onChanged(); + } + } else { + if (descriptorCase_ == 1) { + descriptorCase_ = 0; + descriptor_ = null; + } + cloudRunBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + public com.google.cloud.eventarc.v1.CloudRun.Builder getCloudRunBuilder() { + return getCloudRunFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder() { + if ((descriptorCase_ == 1) && (cloudRunBuilder_ != null)) { + return cloudRunBuilder_.getMessageOrBuilder(); + } else { + if (descriptorCase_ == 1) { + return (com.google.cloud.eventarc.v1.CloudRun) descriptor_; + } + return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } + } + /** + * + * + *
+     * Cloud Run fully-managed resource that receives the events. The resource
+     * should be in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.CloudRun, + com.google.cloud.eventarc.v1.CloudRun.Builder, + com.google.cloud.eventarc.v1.CloudRunOrBuilder> + getCloudRunFieldBuilder() { + if (cloudRunBuilder_ == null) { + if (!(descriptorCase_ == 1)) { + descriptor_ = com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); + } + cloudRunBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.CloudRun, + com.google.cloud.eventarc.v1.CloudRun.Builder, + com.google.cloud.eventarc.v1.CloudRunOrBuilder>( + (com.google.cloud.eventarc.v1.CloudRun) descriptor_, + getParentForChildren(), + isClean()); + descriptor_ = null; + } + descriptorCase_ = 1; + onChanged(); + ; + return cloudRunBuilder_; + } + + /** + * + * + *
+     * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+     * Format: `projects/{project}/locations/{location}/functions/{function}`
+     * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return Whether the cloudFunction field is set. + */ + @java.lang.Override + public boolean hasCloudFunction() { + return descriptorCase_ == 2; + } + /** + * + * + *
+     * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+     * Format: `projects/{project}/locations/{location}/functions/{function}`
+     * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return The cloudFunction. + */ + @java.lang.Override + public java.lang.String getCloudFunction() { + java.lang.Object ref = ""; + if (descriptorCase_ == 2) { + ref = descriptor_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (descriptorCase_ == 2) { + descriptor_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+     * Format: `projects/{project}/locations/{location}/functions/{function}`
+     * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for cloudFunction. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCloudFunctionBytes() { + java.lang.Object ref = ""; + if (descriptorCase_ == 2) { + ref = descriptor_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (descriptorCase_ == 2) { + descriptor_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+     * Format: `projects/{project}/locations/{location}/functions/{function}`
+     * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @param value The cloudFunction to set. + * @return This builder for chaining. + */ + public Builder setCloudFunction(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + descriptorCase_ = 2; + descriptor_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+     * Format: `projects/{project}/locations/{location}/functions/{function}`
+     * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearCloudFunction() { + if (descriptorCase_ == 2) { + descriptorCase_ = 0; + descriptor_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+     * Format: `projects/{project}/locations/{location}/functions/{function}`
+     * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for cloudFunction to set. + * @return This builder for chaining. + */ + public Builder setCloudFunctionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + descriptorCase_ = 2; + descriptor_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GKE, + com.google.cloud.eventarc.v1.GKE.Builder, + com.google.cloud.eventarc.v1.GKEOrBuilder> + gkeBuilder_; + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + * + * @return Whether the gke field is set. + */ + @java.lang.Override + public boolean hasGke() { + return descriptorCase_ == 3; + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + * + * @return The gke. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.GKE getGke() { + if (gkeBuilder_ == null) { + if (descriptorCase_ == 3) { + return (com.google.cloud.eventarc.v1.GKE) descriptor_; + } + return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } else { + if (descriptorCase_ == 3) { + return gkeBuilder_.getMessage(); + } + return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + public Builder setGke(com.google.cloud.eventarc.v1.GKE value) { + if (gkeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + descriptor_ = value; + onChanged(); + } else { + gkeBuilder_.setMessage(value); + } + descriptorCase_ = 3; + return this; + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + public Builder setGke(com.google.cloud.eventarc.v1.GKE.Builder builderForValue) { + if (gkeBuilder_ == null) { + descriptor_ = builderForValue.build(); + onChanged(); + } else { + gkeBuilder_.setMessage(builderForValue.build()); + } + descriptorCase_ = 3; + return this; + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + public Builder mergeGke(com.google.cloud.eventarc.v1.GKE value) { + if (gkeBuilder_ == null) { + if (descriptorCase_ == 3 + && descriptor_ != com.google.cloud.eventarc.v1.GKE.getDefaultInstance()) { + descriptor_ = + com.google + .cloud + .eventarc + .v1 + .GKE + .newBuilder((com.google.cloud.eventarc.v1.GKE) descriptor_) + .mergeFrom(value) + .buildPartial(); + } else { + descriptor_ = value; + } + onChanged(); + } else { + if (descriptorCase_ == 3) { + gkeBuilder_.mergeFrom(value); + } else { + gkeBuilder_.setMessage(value); + } + } + descriptorCase_ = 3; + return this; + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + public Builder clearGke() { + if (gkeBuilder_ == null) { + if (descriptorCase_ == 3) { + descriptorCase_ = 0; + descriptor_ = null; + onChanged(); + } + } else { + if (descriptorCase_ == 3) { + descriptorCase_ = 0; + descriptor_ = null; + } + gkeBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + public com.google.cloud.eventarc.v1.GKE.Builder getGkeBuilder() { + return getGkeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() { + if ((descriptorCase_ == 3) && (gkeBuilder_ != null)) { + return gkeBuilder_.getMessageOrBuilder(); + } else { + if (descriptorCase_ == 3) { + return (com.google.cloud.eventarc.v1.GKE) descriptor_; + } + return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } + } + /** + * + * + *
+     * A GKE service capable of receiving events. The service should be running
+     * in the same project as the trigger.
+     * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GKE, + com.google.cloud.eventarc.v1.GKE.Builder, + com.google.cloud.eventarc.v1.GKEOrBuilder> + getGkeFieldBuilder() { + if (gkeBuilder_ == null) { + if (!(descriptorCase_ == 3)) { + descriptor_ = com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } + gkeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GKE, + com.google.cloud.eventarc.v1.GKE.Builder, + com.google.cloud.eventarc.v1.GKEOrBuilder>( + (com.google.cloud.eventarc.v1.GKE) descriptor_, getParentForChildren(), isClean()); + descriptor_ = null; + } + descriptorCase_ = 3; + onChanged(); + ; + return gkeBuilder_; + } + + /** + * + * + *
+     * The resource name of the Workflow whose Executions are triggered by
+     * the events. The Workflow resource should be deployed in the same project
+     * as the trigger.
+     * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+     * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return Whether the workflow field is set. + */ + @java.lang.Override + public boolean hasWorkflow() { + return descriptorCase_ == 4; + } + /** + * + * + *
+     * The resource name of the Workflow whose Executions are triggered by
+     * the events. The Workflow resource should be deployed in the same project
+     * as the trigger.
+     * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+     * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return The workflow. + */ + @java.lang.Override + public java.lang.String getWorkflow() { + java.lang.Object ref = ""; + if (descriptorCase_ == 4) { + ref = descriptor_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (descriptorCase_ == 4) { + descriptor_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The resource name of the Workflow whose Executions are triggered by
+     * the events. The Workflow resource should be deployed in the same project
+     * as the trigger.
+     * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+     * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for workflow. + */ + @java.lang.Override + public com.google.protobuf.ByteString getWorkflowBytes() { + java.lang.Object ref = ""; + if (descriptorCase_ == 4) { + ref = descriptor_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (descriptorCase_ == 4) { + descriptor_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The resource name of the Workflow whose Executions are triggered by
+     * the events. The Workflow resource should be deployed in the same project
+     * as the trigger.
+     * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+     * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @param value The workflow to set. + * @return This builder for chaining. + */ + public Builder setWorkflow(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + descriptorCase_ = 4; + descriptor_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The resource name of the Workflow whose Executions are triggered by
+     * the events. The Workflow resource should be deployed in the same project
+     * as the trigger.
+     * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+     * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearWorkflow() { + if (descriptorCase_ == 4) { + descriptorCase_ = 0; + descriptor_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+     * The resource name of the Workflow whose Executions are triggered by
+     * the events. The Workflow resource should be deployed in the same project
+     * as the trigger.
+     * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+     * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for workflow to set. + * @return This builder for chaining. + */ + public Builder setWorkflowBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + descriptorCase_ = 4; + descriptor_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Destination) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Destination) + private static final com.google.cloud.eventarc.v1.Destination DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Destination(); + } + + public static com.google.cloud.eventarc.v1.Destination getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Destination parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Destination getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java new file mode 100644 index 000000000000..11f694fbc1bc --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java @@ -0,0 +1,189 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface DestinationOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Destination) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Cloud Run fully-managed resource that receives the events. The resource
+   * should be in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * + * @return Whether the cloudRun field is set. + */ + boolean hasCloudRun(); + /** + * + * + *
+   * Cloud Run fully-managed resource that receives the events. The resource
+   * should be in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * + * @return The cloudRun. + */ + com.google.cloud.eventarc.v1.CloudRun getCloudRun(); + /** + * + * + *
+   * Cloud Run fully-managed resource that receives the events. The resource
+   * should be in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + */ + com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder(); + + /** + * + * + *
+   * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+   * Format: `projects/{project}/locations/{location}/functions/{function}`
+   * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return Whether the cloudFunction field is set. + */ + boolean hasCloudFunction(); + /** + * + * + *
+   * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+   * Format: `projects/{project}/locations/{location}/functions/{function}`
+   * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return The cloudFunction. + */ + java.lang.String getCloudFunction(); + /** + * + * + *
+   * The Cloud Function resource name. Only Cloud Functions V2 is supported.
+   * Format: `projects/{project}/locations/{location}/functions/{function}`
+   * 
+ * + * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for cloudFunction. + */ + com.google.protobuf.ByteString getCloudFunctionBytes(); + + /** + * + * + *
+   * A GKE service capable of receiving events. The service should be running
+   * in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + * + * @return Whether the gke field is set. + */ + boolean hasGke(); + /** + * + * + *
+   * A GKE service capable of receiving events. The service should be running
+   * in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + * + * @return The gke. + */ + com.google.cloud.eventarc.v1.GKE getGke(); + /** + * + * + *
+   * A GKE service capable of receiving events. The service should be running
+   * in the same project as the trigger.
+   * 
+ * + * .google.cloud.eventarc.v1.GKE gke = 3; + */ + com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder(); + + /** + * + * + *
+   * The resource name of the Workflow whose Executions are triggered by
+   * the events. The Workflow resource should be deployed in the same project
+   * as the trigger.
+   * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+   * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return Whether the workflow field is set. + */ + boolean hasWorkflow(); + /** + * + * + *
+   * The resource name of the Workflow whose Executions are triggered by
+   * the events. The Workflow resource should be deployed in the same project
+   * as the trigger.
+   * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+   * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return The workflow. + */ + java.lang.String getWorkflow(); + /** + * + * + *
+   * The resource name of the Workflow whose Executions are triggered by
+   * the events. The Workflow resource should be deployed in the same project
+   * as the trigger.
+   * Format: `projects/{project}/locations/{location}/workflows/{workflow}`
+   * 
+ * + * string workflow = 4 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for workflow. + */ + com.google.protobuf.ByteString getWorkflowBytes(); + + public com.google.cloud.eventarc.v1.Destination.DescriptorCase getDescriptorCase(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java new file mode 100644 index 000000000000..88db7970fdb1 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java @@ -0,0 +1,114 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +public final class DiscoveryProto { + private DiscoveryProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Provider_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_EventType_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n(google/cloud/eventarc/v1/discovery.pro" + + "to\022\030google.cloud.eventarc.v1\032\037google/api" + + "/field_behavior.proto\032\031google/api/resour" + + "ce.proto\"\361\001\n\010Provider\022\021\n\004name\030\001 \001(\tB\003\340A\003" + + "\022\031\n\014display_name\030\002 \001(\tB\003\340A\003\022=\n\013event_typ" + + "es\030\003 \003(\0132#.google.cloud.eventarc.v1.Even" + + "tTypeB\003\340A\003:x\352Au\n eventarc.googleapis.com" + + "/Provider\022 + * Filters events based on exact matches on the CloudEvents attributes. + * + * + * Protobuf type {@code google.cloud.eventarc.v1.EventFilter} + */ +public final class EventFilter extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.EventFilter) + EventFilterOrBuilder { + private static final long serialVersionUID = 0L; + // Use EventFilter.newBuilder() to construct. + private EventFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EventFilter() { + attribute_ = ""; + value_ = ""; + operator_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EventFilter(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.EventFilter.class, + com.google.cloud.eventarc.v1.EventFilter.Builder.class); + } + + public static final int ATTRIBUTE_FIELD_NUMBER = 1; + private volatile java.lang.Object attribute_; + /** + * + * + *
+   * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+   * are supported for filtering.
+   * All triggers MUST provide a filter for the 'type' attribute.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The attribute. + */ + @java.lang.Override + public java.lang.String getAttribute() { + java.lang.Object ref = attribute_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + attribute_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+   * are supported for filtering.
+   * All triggers MUST provide a filter for the 'type' attribute.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for attribute. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAttributeBytes() { + java.lang.Object ref = attribute_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + attribute_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VALUE_FIELD_NUMBER = 2; + private volatile java.lang.Object value_; + /** + * + * + *
+   * Required. The value for the attribute.
+   * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The value. + */ + @java.lang.Override + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The value for the attribute.
+   * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for value. + */ + @java.lang.Override + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int OPERATOR_FIELD_NUMBER = 3; + private volatile java.lang.Object operator_; + /** + * + * + *
+   * Optional. The operator used for matching the events with the value of the
+   * filter. If not specified, only events that have an exact key-value pair
+   * specified in the filter are matched. The only allowed value is
+   * `match-path-pattern`.
+   * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The operator. + */ + @java.lang.Override + public java.lang.String getOperator() { + java.lang.Object ref = operator_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + operator_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. The operator used for matching the events with the value of the
+   * filter. If not specified, only events that have an exact key-value pair
+   * specified in the filter are matched. The only allowed value is
+   * `match-path-pattern`.
+   * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for operator. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOperatorBytes() { + java.lang.Object ref = operator_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + operator_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(attribute_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, attribute_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(value_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, value_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(operator_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, operator_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(attribute_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, attribute_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(value_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, value_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(operator_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, operator_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.EventFilter)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.EventFilter other = (com.google.cloud.eventarc.v1.EventFilter) obj; + + if (!getAttribute().equals(other.getAttribute())) return false; + if (!getValue().equals(other.getValue())) return false; + if (!getOperator().equals(other.getOperator())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ATTRIBUTE_FIELD_NUMBER; + hash = (53 * hash) + getAttribute().hashCode(); + hash = (37 * hash) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + getValue().hashCode(); + hash = (37 * hash) + OPERATOR_FIELD_NUMBER; + hash = (53 * hash) + getOperator().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.EventFilter prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Filters events based on exact matches on the CloudEvents attributes.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.EventFilter} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.EventFilter) + com.google.cloud.eventarc.v1.EventFilterOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.EventFilter.class, + com.google.cloud.eventarc.v1.EventFilter.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.EventFilter.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + attribute_ = ""; + + value_ = ""; + + operator_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventFilter getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventFilter build() { + com.google.cloud.eventarc.v1.EventFilter result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventFilter buildPartial() { + com.google.cloud.eventarc.v1.EventFilter result = + new com.google.cloud.eventarc.v1.EventFilter(this); + result.attribute_ = attribute_; + result.value_ = value_; + result.operator_ = operator_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.EventFilter) { + return mergeFrom((com.google.cloud.eventarc.v1.EventFilter) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.EventFilter other) { + if (other == com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()) return this; + if (!other.getAttribute().isEmpty()) { + attribute_ = other.attribute_; + onChanged(); + } + if (!other.getValue().isEmpty()) { + value_ = other.value_; + onChanged(); + } + if (!other.getOperator().isEmpty()) { + operator_ = other.operator_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + attribute_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + value_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + operator_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object attribute_ = ""; + /** + * + * + *
+     * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+     * are supported for filtering.
+     * All triggers MUST provide a filter for the 'type' attribute.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The attribute. + */ + public java.lang.String getAttribute() { + java.lang.Object ref = attribute_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + attribute_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+     * are supported for filtering.
+     * All triggers MUST provide a filter for the 'type' attribute.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for attribute. + */ + public com.google.protobuf.ByteString getAttributeBytes() { + java.lang.Object ref = attribute_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + attribute_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+     * are supported for filtering.
+     * All triggers MUST provide a filter for the 'type' attribute.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The attribute to set. + * @return This builder for chaining. + */ + public Builder setAttribute(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + attribute_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+     * are supported for filtering.
+     * All triggers MUST provide a filter for the 'type' attribute.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearAttribute() { + + attribute_ = getDefaultInstance().getAttribute(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+     * are supported for filtering.
+     * All triggers MUST provide a filter for the 'type' attribute.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for attribute to set. + * @return This builder for chaining. + */ + public Builder setAttributeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + attribute_ = value; + onChanged(); + return this; + } + + private java.lang.Object value_ = ""; + /** + * + * + *
+     * Required. The value for the attribute.
+     * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The value. + */ + public java.lang.String getValue() { + java.lang.Object ref = value_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + value_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The value for the attribute.
+     * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for value. + */ + public com.google.protobuf.ByteString getValueBytes() { + java.lang.Object ref = value_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + value_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The value for the attribute.
+     * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + value_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The value for the attribute.
+     * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + + value_ = getDefaultInstance().getValue(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The value for the attribute.
+     * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for value to set. + * @return This builder for chaining. + */ + public Builder setValueBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + value_ = value; + onChanged(); + return this; + } + + private java.lang.Object operator_ = ""; + /** + * + * + *
+     * Optional. The operator used for matching the events with the value of the
+     * filter. If not specified, only events that have an exact key-value pair
+     * specified in the filter are matched. The only allowed value is
+     * `match-path-pattern`.
+     * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The operator. + */ + public java.lang.String getOperator() { + java.lang.Object ref = operator_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + operator_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. The operator used for matching the events with the value of the
+     * filter. If not specified, only events that have an exact key-value pair
+     * specified in the filter are matched. The only allowed value is
+     * `match-path-pattern`.
+     * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for operator. + */ + public com.google.protobuf.ByteString getOperatorBytes() { + java.lang.Object ref = operator_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + operator_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. The operator used for matching the events with the value of the
+     * filter. If not specified, only events that have an exact key-value pair
+     * specified in the filter are matched. The only allowed value is
+     * `match-path-pattern`.
+     * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The operator to set. + * @return This builder for chaining. + */ + public Builder setOperator(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + operator_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The operator used for matching the events with the value of the
+     * filter. If not specified, only events that have an exact key-value pair
+     * specified in the filter are matched. The only allowed value is
+     * `match-path-pattern`.
+     * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearOperator() { + + operator_ = getDefaultInstance().getOperator(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The operator used for matching the events with the value of the
+     * filter. If not specified, only events that have an exact key-value pair
+     * specified in the filter are matched. The only allowed value is
+     * `match-path-pattern`.
+     * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for operator to set. + * @return This builder for chaining. + */ + public Builder setOperatorBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + operator_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.EventFilter) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.EventFilter) + private static final com.google.cloud.eventarc.v1.EventFilter DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.EventFilter(); + } + + public static com.google.cloud.eventarc.v1.EventFilter getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventFilter getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java new file mode 100644 index 000000000000..f121b1cc122a --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface EventFilterOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.EventFilter) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+   * are supported for filtering.
+   * All triggers MUST provide a filter for the 'type' attribute.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The attribute. + */ + java.lang.String getAttribute(); + /** + * + * + *
+   * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
+   * are supported for filtering.
+   * All triggers MUST provide a filter for the 'type' attribute.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for attribute. + */ + com.google.protobuf.ByteString getAttributeBytes(); + + /** + * + * + *
+   * Required. The value for the attribute.
+   * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The value. + */ + java.lang.String getValue(); + /** + * + * + *
+   * Required. The value for the attribute.
+   * 
+ * + * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for value. + */ + com.google.protobuf.ByteString getValueBytes(); + + /** + * + * + *
+   * Optional. The operator used for matching the events with the value of the
+   * filter. If not specified, only events that have an exact key-value pair
+   * specified in the filter are matched. The only allowed value is
+   * `match-path-pattern`.
+   * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The operator. + */ + java.lang.String getOperator(); + /** + * + * + *
+   * Optional. The operator used for matching the events with the value of the
+   * filter. If not specified, only events that have an exact key-value pair
+   * specified in the filter are matched. The only allowed value is
+   * `match-path-pattern`.
+   * 
+ * + * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for operator. + */ + com.google.protobuf.ByteString getOperatorBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java new file mode 100644 index 000000000000..5e559a906acf --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java @@ -0,0 +1,1576 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A representation of the event type resource.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.EventType} + */ +public final class EventType extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.EventType) + EventTypeOrBuilder { + private static final long serialVersionUID = 0L; + // Use EventType.newBuilder() to construct. + private EventType(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EventType() { + type_ = ""; + description_ = ""; + filteringAttributes_ = java.util.Collections.emptyList(); + eventSchemaUri_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EventType(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.EventType.class, + com.google.cloud.eventarc.v1.EventType.Builder.class); + } + + public static final int TYPE_FIELD_NUMBER = 1; + private volatile java.lang.Object type_; + /** + * + * + *
+   * Output only. The full name of the event type (for example,
+   * "google.cloud.storage.object.v1.finalized"). In the form of
+   * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+   * versioned and event schemas are guaranteed to remain backward compatible
+   * within one version. Note that event type versions and API versions do not
+   * need to match.
+   * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The type. + */ + @java.lang.Override + public java.lang.String getType() { + java.lang.Object ref = type_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + type_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. The full name of the event type (for example,
+   * "google.cloud.storage.object.v1.finalized"). In the form of
+   * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+   * versioned and event schemas are guaranteed to remain backward compatible
+   * within one version. Note that event type versions and API versions do not
+   * need to match.
+   * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for type. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTypeBytes() { + java.lang.Object ref = type_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + type_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 2; + private volatile java.lang.Object description_; + /** + * + * + *
+   * Output only. Human friendly description of what the event type is about.
+   * For example "Bucket created in Cloud Storage".
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Human friendly description of what the event type is about.
+   * For example "Bucket created in Cloud Storage".
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTERING_ATTRIBUTES_FIELD_NUMBER = 3; + private java.util.List filteringAttributes_; + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getFilteringAttributesList() { + return filteringAttributes_; + } + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getFilteringAttributesOrBuilderList() { + return filteringAttributes_; + } + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public int getFilteringAttributesCount() { + return filteringAttributes_.size(); + } + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(int index) { + return filteringAttributes_.get(index); + } + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesOrBuilder( + int index) { + return filteringAttributes_.get(index); + } + + public static final int EVENT_SCHEMA_URI_FIELD_NUMBER = 4; + private volatile java.lang.Object eventSchemaUri_; + /** + * + * + *
+   * Output only. URI for the event schema.
+   * For example
+   * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+   * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The eventSchemaUri. + */ + @java.lang.Override + public java.lang.String getEventSchemaUri() { + java.lang.Object ref = eventSchemaUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + eventSchemaUri_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. URI for the event schema.
+   * For example
+   * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+   * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for eventSchemaUri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEventSchemaUriBytes() { + java.lang.Object ref = eventSchemaUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + eventSchemaUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); + } + for (int i = 0; i < filteringAttributes_.size(); i++) { + output.writeMessage(3, filteringAttributes_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(eventSchemaUri_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, eventSchemaUri_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, type_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); + } + for (int i = 0; i < filteringAttributes_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, filteringAttributes_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(eventSchemaUri_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, eventSchemaUri_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.EventType)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.EventType other = (com.google.cloud.eventarc.v1.EventType) obj; + + if (!getType().equals(other.getType())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!getFilteringAttributesList().equals(other.getFilteringAttributesList())) return false; + if (!getEventSchemaUri().equals(other.getEventSchemaUri())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + getType().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + if (getFilteringAttributesCount() > 0) { + hash = (37 * hash) + FILTERING_ATTRIBUTES_FIELD_NUMBER; + hash = (53 * hash) + getFilteringAttributesList().hashCode(); + } + hash = (37 * hash) + EVENT_SCHEMA_URI_FIELD_NUMBER; + hash = (53 * hash) + getEventSchemaUri().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventType parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.EventType parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.EventType parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.EventType prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A representation of the event type resource.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.EventType} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.EventType) + com.google.cloud.eventarc.v1.EventTypeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.EventType.class, + com.google.cloud.eventarc.v1.EventType.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.EventType.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + type_ = ""; + + description_ = ""; + + if (filteringAttributesBuilder_ == null) { + filteringAttributes_ = java.util.Collections.emptyList(); + } else { + filteringAttributes_ = null; + filteringAttributesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + eventSchemaUri_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventType getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.EventType.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventType build() { + com.google.cloud.eventarc.v1.EventType result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventType buildPartial() { + com.google.cloud.eventarc.v1.EventType result = + new com.google.cloud.eventarc.v1.EventType(this); + int from_bitField0_ = bitField0_; + result.type_ = type_; + result.description_ = description_; + if (filteringAttributesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + filteringAttributes_ = java.util.Collections.unmodifiableList(filteringAttributes_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.filteringAttributes_ = filteringAttributes_; + } else { + result.filteringAttributes_ = filteringAttributesBuilder_.build(); + } + result.eventSchemaUri_ = eventSchemaUri_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.EventType) { + return mergeFrom((com.google.cloud.eventarc.v1.EventType) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.EventType other) { + if (other == com.google.cloud.eventarc.v1.EventType.getDefaultInstance()) return this; + if (!other.getType().isEmpty()) { + type_ = other.type_; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + onChanged(); + } + if (filteringAttributesBuilder_ == null) { + if (!other.filteringAttributes_.isEmpty()) { + if (filteringAttributes_.isEmpty()) { + filteringAttributes_ = other.filteringAttributes_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.addAll(other.filteringAttributes_); + } + onChanged(); + } + } else { + if (!other.filteringAttributes_.isEmpty()) { + if (filteringAttributesBuilder_.isEmpty()) { + filteringAttributesBuilder_.dispose(); + filteringAttributesBuilder_ = null; + filteringAttributes_ = other.filteringAttributes_; + bitField0_ = (bitField0_ & ~0x00000001); + filteringAttributesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getFilteringAttributesFieldBuilder() + : null; + } else { + filteringAttributesBuilder_.addAllMessages(other.filteringAttributes_); + } + } + } + if (!other.getEventSchemaUri().isEmpty()) { + eventSchemaUri_ = other.eventSchemaUri_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + type_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + description_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + com.google.cloud.eventarc.v1.FilteringAttribute m = + input.readMessage( + com.google.cloud.eventarc.v1.FilteringAttribute.parser(), + extensionRegistry); + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.add(m); + } else { + filteringAttributesBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + eventSchemaUri_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object type_ = ""; + /** + * + * + *
+     * Output only. The full name of the event type (for example,
+     * "google.cloud.storage.object.v1.finalized"). In the form of
+     * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+     * versioned and event schemas are guaranteed to remain backward compatible
+     * within one version. Note that event type versions and API versions do not
+     * need to match.
+     * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The type. + */ + public java.lang.String getType() { + java.lang.Object ref = type_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + type_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. The full name of the event type (for example,
+     * "google.cloud.storage.object.v1.finalized"). In the form of
+     * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+     * versioned and event schemas are guaranteed to remain backward compatible
+     * within one version. Note that event type versions and API versions do not
+     * need to match.
+     * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for type. + */ + public com.google.protobuf.ByteString getTypeBytes() { + java.lang.Object ref = type_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + type_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. The full name of the event type (for example,
+     * "google.cloud.storage.object.v1.finalized"). In the form of
+     * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+     * versioned and event schemas are guaranteed to remain backward compatible
+     * within one version. Note that event type versions and API versions do not
+     * need to match.
+     * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + type_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The full name of the event type (for example,
+     * "google.cloud.storage.object.v1.finalized"). In the form of
+     * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+     * versioned and event schemas are guaranteed to remain backward compatible
+     * within one version. Note that event type versions and API versions do not
+     * need to match.
+     * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearType() { + + type_ = getDefaultInstance().getType(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The full name of the event type (for example,
+     * "google.cloud.storage.object.v1.finalized"). In the form of
+     * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+     * versioned and event schemas are guaranteed to remain backward compatible
+     * within one version. Note that event type versions and API versions do not
+     * need to match.
+     * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for type to set. + * @return This builder for chaining. + */ + public Builder setTypeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + type_ = value; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + /** + * + * + *
+     * Output only. Human friendly description of what the event type is about.
+     * For example "Bucket created in Cloud Storage".
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Human friendly description of what the event type is about.
+     * For example "Bucket created in Cloud Storage".
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Human friendly description of what the event type is about.
+     * For example "Bucket created in Cloud Storage".
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + description_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Human friendly description of what the event type is about.
+     * For example "Bucket created in Cloud Storage".
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + + description_ = getDefaultInstance().getDescription(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Human friendly description of what the event type is about.
+     * For example "Bucket created in Cloud Storage".
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + description_ = value; + onChanged(); + return this; + } + + private java.util.List filteringAttributes_ = + java.util.Collections.emptyList(); + + private void ensureFilteringAttributesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + filteringAttributes_ = + new java.util.ArrayList( + filteringAttributes_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.FilteringAttribute, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder, + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder> + filteringAttributesBuilder_; + + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getFilteringAttributesList() { + if (filteringAttributesBuilder_ == null) { + return java.util.Collections.unmodifiableList(filteringAttributes_); + } else { + return filteringAttributesBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public int getFilteringAttributesCount() { + if (filteringAttributesBuilder_ == null) { + return filteringAttributes_.size(); + } else { + return filteringAttributesBuilder_.getCount(); + } + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(int index) { + if (filteringAttributesBuilder_ == null) { + return filteringAttributes_.get(index); + } else { + return filteringAttributesBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFilteringAttributes( + int index, com.google.cloud.eventarc.v1.FilteringAttribute value) { + if (filteringAttributesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFilteringAttributesIsMutable(); + filteringAttributes_.set(index, value); + onChanged(); + } else { + filteringAttributesBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setFilteringAttributes( + int index, com.google.cloud.eventarc.v1.FilteringAttribute.Builder builderForValue) { + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.set(index, builderForValue.build()); + onChanged(); + } else { + filteringAttributesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addFilteringAttributes(com.google.cloud.eventarc.v1.FilteringAttribute value) { + if (filteringAttributesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFilteringAttributesIsMutable(); + filteringAttributes_.add(value); + onChanged(); + } else { + filteringAttributesBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addFilteringAttributes( + int index, com.google.cloud.eventarc.v1.FilteringAttribute value) { + if (filteringAttributesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureFilteringAttributesIsMutable(); + filteringAttributes_.add(index, value); + onChanged(); + } else { + filteringAttributesBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addFilteringAttributes( + com.google.cloud.eventarc.v1.FilteringAttribute.Builder builderForValue) { + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.add(builderForValue.build()); + onChanged(); + } else { + filteringAttributesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addFilteringAttributes( + int index, com.google.cloud.eventarc.v1.FilteringAttribute.Builder builderForValue) { + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.add(index, builderForValue.build()); + onChanged(); + } else { + filteringAttributesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAllFilteringAttributes( + java.lang.Iterable values) { + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, filteringAttributes_); + onChanged(); + } else { + filteringAttributesBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearFilteringAttributes() { + if (filteringAttributesBuilder_ == null) { + filteringAttributes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + filteringAttributesBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeFilteringAttributes(int index) { + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.remove(index); + onChanged(); + } else { + filteringAttributesBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.FilteringAttribute.Builder getFilteringAttributesBuilder( + int index) { + return getFilteringAttributesFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesOrBuilder( + int index) { + if (filteringAttributesBuilder_ == null) { + return filteringAttributes_.get(index); + } else { + return filteringAttributesBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getFilteringAttributesOrBuilderList() { + if (filteringAttributesBuilder_ != null) { + return filteringAttributesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(filteringAttributes_); + } + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.FilteringAttribute.Builder addFilteringAttributesBuilder() { + return getFilteringAttributesFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()); + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.FilteringAttribute.Builder addFilteringAttributesBuilder( + int index) { + return getFilteringAttributesFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()); + } + /** + * + * + *
+     * Output only. Filtering attributes for the event type.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getFilteringAttributesBuilderList() { + return getFilteringAttributesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.FilteringAttribute, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder, + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder> + getFilteringAttributesFieldBuilder() { + if (filteringAttributesBuilder_ == null) { + filteringAttributesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.FilteringAttribute, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder, + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder>( + filteringAttributes_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + filteringAttributes_ = null; + } + return filteringAttributesBuilder_; + } + + private java.lang.Object eventSchemaUri_ = ""; + /** + * + * + *
+     * Output only. URI for the event schema.
+     * For example
+     * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+     * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The eventSchemaUri. + */ + public java.lang.String getEventSchemaUri() { + java.lang.Object ref = eventSchemaUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + eventSchemaUri_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. URI for the event schema.
+     * For example
+     * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+     * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for eventSchemaUri. + */ + public com.google.protobuf.ByteString getEventSchemaUriBytes() { + java.lang.Object ref = eventSchemaUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + eventSchemaUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. URI for the event schema.
+     * For example
+     * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+     * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The eventSchemaUri to set. + * @return This builder for chaining. + */ + public Builder setEventSchemaUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + eventSchemaUri_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. URI for the event schema.
+     * For example
+     * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+     * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearEventSchemaUri() { + + eventSchemaUri_ = getDefaultInstance().getEventSchemaUri(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. URI for the event schema.
+     * For example
+     * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+     * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for eventSchemaUri to set. + * @return This builder for chaining. + */ + public Builder setEventSchemaUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + eventSchemaUri_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.EventType) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.EventType) + private static final com.google.cloud.eventarc.v1.EventType DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.EventType(); + } + + public static com.google.cloud.eventarc.v1.EventType getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventType parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.EventType getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java new file mode 100644 index 000000000000..95f54d959b02 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java @@ -0,0 +1,179 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +public interface EventTypeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.EventType) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Output only. The full name of the event type (for example,
+   * "google.cloud.storage.object.v1.finalized"). In the form of
+   * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+   * versioned and event schemas are guaranteed to remain backward compatible
+   * within one version. Note that event type versions and API versions do not
+   * need to match.
+   * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The type. + */ + java.lang.String getType(); + /** + * + * + *
+   * Output only. The full name of the event type (for example,
+   * "google.cloud.storage.object.v1.finalized"). In the form of
+   * {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be
+   * versioned and event schemas are guaranteed to remain backward compatible
+   * within one version. Note that event type versions and API versions do not
+   * need to match.
+   * 
+ * + * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for type. + */ + com.google.protobuf.ByteString getTypeBytes(); + + /** + * + * + *
+   * Output only. Human friendly description of what the event type is about.
+   * For example "Bucket created in Cloud Storage".
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The description. + */ + java.lang.String getDescription(); + /** + * + * + *
+   * Output only. Human friendly description of what the event type is about.
+   * For example "Bucket created in Cloud Storage".
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List getFilteringAttributesList(); + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(int index); + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getFilteringAttributesCount(); + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List + getFilteringAttributesOrBuilderList(); + /** + * + * + *
+   * Output only. Filtering attributes for the event type.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesOrBuilder( + int index); + + /** + * + * + *
+   * Output only. URI for the event schema.
+   * For example
+   * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+   * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The eventSchemaUri. + */ + java.lang.String getEventSchemaUri(); + /** + * + * + *
+   * Output only. URI for the event schema.
+   * For example
+   * "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto"
+   * 
+ * + * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for eventSchemaUri. + */ + com.google.protobuf.ByteString getEventSchemaUriBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java new file mode 100644 index 000000000000..bdd9b88dd361 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java @@ -0,0 +1,560 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public final class EventarcProto { + private EventarcProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n\'google/cloud/eventarc/v1/eventarc.prot" + + "o\022\030google.cloud.eventarc.v1\032\034google/api/" + + "annotations.proto\032\027google/api/client.pro" + + "to\032\037google/api/field_behavior.proto\032\031goo" + + "gle/api/resource.proto\032&google/cloud/eve" + + "ntarc/v1/channel.proto\0321google/cloud/eve" + + "ntarc/v1/channel_connection.proto\032(googl" + + "e/cloud/eventarc/v1/discovery.proto\0324goo" + + "gle/cloud/eventarc/v1/google_channel_con" + + "fig.proto\032&google/cloud/eventarc/v1/trig" + + "ger.proto\032#google/longrunning/operations" + + ".proto\032 google/protobuf/field_mask.proto" + + "\032\037google/protobuf/timestamp.proto\"J\n\021Get" + + "TriggerRequest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037ev" + + "entarc.googleapis.com/Trigger\"\227\001\n\023ListTr" + + "iggersRequest\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037e" + + "ventarc.googleapis.com/Trigger\022\021\n\tpage_s" + + "ize\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\022\020\n\010order_b" + + "y\030\004 \001(\t\022\016\n\006filter\030\005 \001(\t\"y\n\024ListTriggersR" + + "esponse\0223\n\010triggers\030\001 \003(\0132!.google.cloud" + + ".eventarc.v1.Trigger\022\027\n\017next_page_token\030" + + "\002 \001(\t\022\023\n\013unreachable\030\003 \003(\t\"\275\001\n\024CreateTri" + + "ggerRequest\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037eve" + + "ntarc.googleapis.com/Trigger\0227\n\007trigger\030" + + "\002 \001(\0132!.google.cloud.eventarc.v1.Trigger" + + "B\003\340A\002\022\027\n\ntrigger_id\030\003 \001(\tB\003\340A\002\022\032\n\rvalida" + + "te_only\030\004 \001(\010B\003\340A\002\"\256\001\n\024UpdateTriggerRequ" + + "est\0222\n\007trigger\030\001 \001(\0132!.google.cloud.even" + + "tarc.v1.Trigger\022/\n\013update_mask\030\002 \001(\0132\032.g" + + "oogle.protobuf.FieldMask\022\025\n\rallow_missin" + + "g\030\003 \001(\010\022\032\n\rvalidate_only\030\004 \001(\010B\003\340A\002\"\216\001\n\024" + + "DeleteTriggerRequest\0225\n\004name\030\001 \001(\tB\'\340A\002\372" + + "A!\n\037eventarc.googleapis.com/Trigger\022\014\n\004e" + + "tag\030\002 \001(\t\022\025\n\rallow_missing\030\003 \001(\010\022\032\n\rvali" + + "date_only\030\004 \001(\010B\003\340A\002\"J\n\021GetChannelReques" + + "t\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037eventarc.google" + + "apis.com/Channel\"\207\001\n\023ListChannelsRequest" + + "\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037eventarc.googl" + + "eapis.com/Channel\022\021\n\tpage_size\030\002 \001(\005\022\022\n\n" + + "page_token\030\003 \001(\t\022\020\n\010order_by\030\004 \001(\t\"y\n\024Li" + + "stChannelsResponse\0223\n\010channels\030\001 \003(\0132!.g" + + "oogle.cloud.eventarc.v1.Channel\022\027\n\017next_" + + "page_token\030\002 \001(\t\022\023\n\013unreachable\030\003 \003(\t\"\275\001" + + "\n\024CreateChannelRequest\0227\n\006parent\030\001 \001(\tB\'" + + "\340A\002\372A!\022\037eventarc.googleapis.com/Channel\022" + + "7\n\007channel\030\002 \001(\0132!.google.cloud.eventarc" + + ".v1.ChannelB\003\340A\002\022\027\n\nchannel_id\030\003 \001(\tB\003\340A" + + "\002\022\032\n\rvalidate_only\030\004 \001(\010B\003\340A\002\"\227\001\n\024Update" + + "ChannelRequest\0222\n\007channel\030\001 \001(\0132!.google" + + ".cloud.eventarc.v1.Channel\022/\n\013update_mas" + + "k\030\002 \001(\0132\032.google.protobuf.FieldMask\022\032\n\rv" + + "alidate_only\030\003 \001(\010B\003\340A\002\"i\n\024DeleteChannel" + + "Request\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037eventarc." + + "googleapis.com/Channel\022\032\n\rvalidate_only\030" + + "\002 \001(\010B\003\340A\002\"L\n\022GetProviderRequest\0226\n\004name" + + "\030\001 \001(\tB(\340A\002\372A\"\n eventarc.googleapis.com/" + + "Provider\"\231\001\n\024ListProvidersRequest\0228\n\006par" + + "ent\030\001 \001(\tB(\340A\002\372A\"\022 eventarc.googleapis.c" + + "om/Provider\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_t" + + "oken\030\003 \001(\t\022\020\n\010order_by\030\004 \001(\t\022\016\n\006filter\030\005" + + " \001(\t\"|\n\025ListProvidersResponse\0225\n\tprovide" + + "rs\030\001 \003(\0132\".google.cloud.eventarc.v1.Prov" + + "ider\022\027\n\017next_page_token\030\002 \001(\t\022\023\n\013unreach" + + "able\030\003 \003(\t\"^\n\033GetChannelConnectionReques" + + "t\022?\n\004name\030\001 \001(\tB1\340A\002\372A+\n)eventarc.google" + + "apis.com/ChannelConnection\"\211\001\n\035ListChann" + + "elConnectionsRequest\022A\n\006parent\030\001 \001(\tB1\340A" + + "\002\372A+\022)eventarc.googleapis.com/ChannelCon" + + "nection\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_token" + + "\030\003 \001(\t\"\230\001\n\036ListChannelConnectionsRespons" + + "e\022H\n\023channel_connections\030\001 \003(\0132+.google." + + "cloud.eventarc.v1.ChannelConnection\022\027\n\017n" + + "ext_page_token\030\002 \001(\t\022\023\n\013unreachable\030\003 \003(" + + "\t\"\325\001\n\036CreateChannelConnectionRequest\022A\n\006" + + "parent\030\001 \001(\tB1\340A\002\372A+\022)eventarc.googleapi" + + "s.com/ChannelConnection\022L\n\022channel_conne" + + "ction\030\002 \001(\0132+.google.cloud.eventarc.v1.C" + + "hannelConnectionB\003\340A\002\022\"\n\025channel_connect" + + "ion_id\030\003 \001(\tB\003\340A\002\"a\n\036DeleteChannelConnec" + + "tionRequest\022?\n\004name\030\001 \001(\tB1\340A\002\372A+\n)event" + + "arc.googleapis.com/ChannelConnection\"\246\001\n" + + " UpdateGoogleChannelConfigRequest\022Q\n\025goo" + + "gle_channel_config\030\001 \001(\0132-.google.cloud." + + "eventarc.v1.GoogleChannelConfigB\003\340A\002\022/\n\013" + + "update_mask\030\002 \001(\0132\032.google.protobuf.Fiel" + + "dMask\"b\n\035GetGoogleChannelConfigRequest\022A" + + "\n\004name\030\001 \001(\tB3\340A\002\372A-\n+eventarc.googleapi" + + "s.com/GoogleChannelConfig\"\200\002\n\021OperationM" + + "etadata\0224\n\013create_time\030\001 \001(\0132\032.google.pr" + + "otobuf.TimestampB\003\340A\003\0221\n\010end_time\030\002 \001(\0132" + + "\032.google.protobuf.TimestampB\003\340A\003\022\023\n\006targ" + + "et\030\003 \001(\tB\003\340A\003\022\021\n\004verb\030\004 \001(\tB\003\340A\003\022\033\n\016stat" + + "us_message\030\005 \001(\tB\003\340A\003\022#\n\026requested_cance" + + "llation\030\006 \001(\010B\003\340A\003\022\030\n\013api_version\030\007 \001(\tB" + + "\003\340A\0032\317\035\n\010Eventarc\022\231\001\n\nGetTrigger\022+.googl" + + "e.cloud.eventarc.v1.GetTriggerRequest\032!." + + "google.cloud.eventarc.v1.Trigger\";\202\323\344\223\002." + + "\022,/v1/{name=projects/*/locations/*/trigg" + + "ers/*}\332A\004name\022\254\001\n\014ListTriggers\022-.google." + + "cloud.eventarc.v1.ListTriggersRequest\032.." + + "google.cloud.eventarc.v1.ListTriggersRes" + + "ponse\"=\202\323\344\223\002.\022,/v1/{parent=projects/*/lo" + + "cations/*}/triggers\332A\006parent\022\330\001\n\rCreateT" + + "rigger\022..google.cloud.eventarc.v1.Create" + + "TriggerRequest\032\035.google.longrunning.Oper" + + "ation\"x\202\323\344\223\0027\",/v1/{parent=projects/*/lo" + + "cations/*}/triggers:\007trigger\332A\031parent,tr" + + "igger,trigger_id\312A\034\n\007Trigger\022\021OperationM" + + "etadata\022\351\001\n\rUpdateTrigger\022..google.cloud" + + ".eventarc.v1.UpdateTriggerRequest\032\035.goog" + + "le.longrunning.Operation\"\210\001\202\323\344\223\002?24/v1/{" + + "trigger.name=projects/*/locations/*/trig" + + "gers/*}:\007trigger\332A!trigger,update_mask,a" + + "llow_missing\312A\034\n\007Trigger\022\021OperationMetad" + + "ata\022\310\001\n\rDeleteTrigger\022..google.cloud.eve" + + "ntarc.v1.DeleteTriggerRequest\032\035.google.l" + + "ongrunning.Operation\"h\202\323\344\223\002.*,/v1/{name=" + + "projects/*/locations/*/triggers/*}\332A\022nam" + + "e,allow_missing\312A\034\n\007Trigger\022\021OperationMe" + + "tadata\022\231\001\n\nGetChannel\022+.google.cloud.eve" + + "ntarc.v1.GetChannelRequest\032!.google.clou" + + "d.eventarc.v1.Channel\";\202\323\344\223\002.\022,/v1/{name" + + "=projects/*/locations/*/channels/*}\332A\004na" + + "me\022\254\001\n\014ListChannels\022-.google.cloud.event" + + "arc.v1.ListChannelsRequest\032..google.clou" + + "d.eventarc.v1.ListChannelsResponse\"=\202\323\344\223" + + "\002.\022,/v1/{parent=projects/*/locations/*}/" + + "channels\332A\006parent\022\330\001\n\rCreateChannel\022..go" + + "ogle.cloud.eventarc.v1.CreateChannelRequ" + + "est\032\035.google.longrunning.Operation\"x\202\323\344\223" + + "\0027\",/v1/{parent=projects/*/locations/*}/" + + "channels:\007channel\332A\031parent,channel,chann" + + "el_id\312A\034\n\007Channel\022\021OperationMetadata\022\332\001\n" + + "\rUpdateChannel\022..google.cloud.eventarc.v" + + "1.UpdateChannelRequest\032\035.google.longrunn" + + "ing.Operation\"z\202\323\344\223\002?24/v1/{channel.name" + + "=projects/*/locations/*/channels/*}:\007cha" + + "nnel\332A\023channel,update_mask\312A\034\n\007Channel\022\021" + + "OperationMetadata\022\272\001\n\rDeleteChannel\022..go" + + "ogle.cloud.eventarc.v1.DeleteChannelRequ" + + "est\032\035.google.longrunning.Operation\"Z\202\323\344\223" + + "\002.*,/v1/{name=projects/*/locations/*/cha" + + "nnels/*}\332A\004name\312A\034\n\007Channel\022\021OperationMe" + + "tadata\022\235\001\n\013GetProvider\022,.google.cloud.ev" + + "entarc.v1.GetProviderRequest\032\".google.cl" + + "oud.eventarc.v1.Provider\"<\202\323\344\223\002/\022-/v1/{n" + + "ame=projects/*/locations/*/providers/*}\332" + + "A\004name\022\260\001\n\rListProviders\022..google.cloud." + + "eventarc.v1.ListProvidersRequest\032/.googl" + + "e.cloud.eventarc.v1.ListProvidersRespons" + + "e\">\202\323\344\223\002/\022-/v1/{parent=projects/*/locati" + + "ons/*}/providers\332A\006parent\022\301\001\n\024GetChannel" + + "Connection\0225.google.cloud.eventarc.v1.Ge" + + "tChannelConnectionRequest\032+.google.cloud" + + ".eventarc.v1.ChannelConnection\"E\202\323\344\223\0028\0226" + + "/v1/{name=projects/*/locations/*/channel" + + "Connections/*}\332A\004name\022\324\001\n\026ListChannelCon" + + "nections\0227.google.cloud.eventarc.v1.List" + + "ChannelConnectionsRequest\0328.google.cloud" + + ".eventarc.v1.ListChannelConnectionsRespo" + + "nse\"G\202\323\344\223\0028\0226/v1/{parent=projects/*/loca" + + "tions/*}/channelConnections\332A\006parent\022\242\002\n" + + "\027CreateChannelConnection\0228.google.cloud." + + "eventarc.v1.CreateChannelConnectionReque" + + "st\032\035.google.longrunning.Operation\"\255\001\202\323\344\223" + + "\002L\"6/v1/{parent=projects/*/locations/*}/" + + "channelConnections:\022channel_connection\332A" + + "/parent,channel_connection,channel_conne" + + "ction_id\312A&\n\021ChannelConnection\022\021Operatio" + + "nMetadata\022\342\001\n\027DeleteChannelConnection\0228." + + "google.cloud.eventarc.v1.DeleteChannelCo" + + "nnectionRequest\032\035.google.longrunning.Ope" + + "ration\"n\202\323\344\223\0028*6/v1/{name=projects/*/loc" + + "ations/*/channelConnections/*}\332A\004name\312A&" + + "\n\021ChannelConnection\022\021OperationMetadata\022\306" + + "\001\n\026GetGoogleChannelConfig\0227.google.cloud" + + ".eventarc.v1.GetGoogleChannelConfigReque" + + "st\032-.google.cloud.eventarc.v1.GoogleChan" + + "nelConfig\"D\202\323\344\223\0027\0225/v1/{name=projects/*/" + + "locations/*/googleChannelConfig}\332A\004name\022" + + "\227\002\n\031UpdateGoogleChannelConfig\022:.google.c" + + "loud.eventarc.v1.UpdateGoogleChannelConf" + + "igRequest\032-.google.cloud.eventarc.v1.Goo" + + "gleChannelConfig\"\216\001\202\323\344\223\002d2K/v1/{google_c" + + "hannel_config.name=projects/*/locations/" + + "*/googleChannelConfig}:\025google_channel_c" + + "onfig\332A!google_channel_config,update_mas" + + "k\032K\312A\027eventarc.googleapis.com\322A.https://" + + "www.googleapis.com/auth/cloud-platformB\305" + + "\001\n\034com.google.cloud.eventarc.v1B\rEventar" + + "cProtoP\001Z@google.golang.org/genproto/goo" + + "gleapis/cloud/eventarc/v1;eventarc\252\002\030Goo" + + "gle.Cloud.Eventarc.V1\312\002\030Google\\Cloud\\Eve" + + "ntarc\\V1\352\002\033Google::Cloud::Eventarc::V1b\006" + + "proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.eventarc.v1.ChannelProto.getDescriptor(), + com.google.cloud.eventarc.v1.ChannelConnectionProto.getDescriptor(), + com.google.cloud.eventarc.v1.DiscoveryProto.getDescriptor(), + com.google.cloud.eventarc.v1.GoogleChannelConfigProto.getDescriptor(), + com.google.cloud.eventarc.v1.TriggerProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "OrderBy", "Filter", + }); + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor, + new java.lang.String[] { + "Triggers", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor, + new java.lang.String[] { + "Parent", "Trigger", "TriggerId", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor, + new java.lang.String[] { + "Trigger", "UpdateMask", "AllowMissing", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor, + new java.lang.String[] { + "Name", "Etag", "AllowMissing", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor = + getDescriptor().getMessageTypes().get(7); + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "OrderBy", + }); + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor = + getDescriptor().getMessageTypes().get(8); + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor, + new java.lang.String[] { + "Channels", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(9); + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor, + new java.lang.String[] { + "Parent", "Channel", "ChannelId", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor, + new java.lang.String[] { + "Channel", "UpdateMask", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(11); + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor, + new java.lang.String[] { + "Name", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor = + getDescriptor().getMessageTypes().get(12); + internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor = + getDescriptor().getMessageTypes().get(13); + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "OrderBy", "Filter", + }); + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor = + getDescriptor().getMessageTypes().get(14); + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor, + new java.lang.String[] { + "Providers", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor = + getDescriptor().getMessageTypes().get(15); + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor = + getDescriptor().getMessageTypes().get(16); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor = + getDescriptor().getMessageTypes().get(17); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor, + new java.lang.String[] { + "ChannelConnections", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor = + getDescriptor().getMessageTypes().get(18); + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor, + new java.lang.String[] { + "Parent", "ChannelConnection", "ChannelConnectionId", + }); + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor = + getDescriptor().getMessageTypes().get(19); + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor = + getDescriptor().getMessageTypes().get(20); + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor, + new java.lang.String[] { + "GoogleChannelConfig", "UpdateMask", + }); + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor = + getDescriptor().getMessageTypes().get(21); + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor = + getDescriptor().getMessageTypes().get(22); + internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor, + new java.lang.String[] { + "CreateTime", + "EndTime", + "Target", + "Verb", + "StatusMessage", + "RequestedCancellation", + "ApiVersion", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resourceReference); + registry.add(com.google.longrunning.OperationsProto.operationInfo); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.eventarc.v1.ChannelProto.getDescriptor(); + com.google.cloud.eventarc.v1.ChannelConnectionProto.getDescriptor(); + com.google.cloud.eventarc.v1.DiscoveryProto.getDescriptor(); + com.google.cloud.eventarc.v1.GoogleChannelConfigProto.getDescriptor(); + com.google.cloud.eventarc.v1.TriggerProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java new file mode 100644 index 000000000000..cbc1cfad9ae3 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java @@ -0,0 +1,985 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A representation of the FilteringAttribute resource.
+ * Filtering attributes are per event type.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.FilteringAttribute} + */ +public final class FilteringAttribute extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.FilteringAttribute) + FilteringAttributeOrBuilder { + private static final long serialVersionUID = 0L; + // Use FilteringAttribute.newBuilder() to construct. + private FilteringAttribute(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FilteringAttribute() { + attribute_ = ""; + description_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FilteringAttribute(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.FilteringAttribute.class, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder.class); + } + + public static final int ATTRIBUTE_FIELD_NUMBER = 1; + private volatile java.lang.Object attribute_; + /** + * + * + *
+   * Output only. Attribute used for filtering the event type.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The attribute. + */ + @java.lang.Override + public java.lang.String getAttribute() { + java.lang.Object ref = attribute_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + attribute_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Attribute used for filtering the event type.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for attribute. + */ + @java.lang.Override + public com.google.protobuf.ByteString getAttributeBytes() { + java.lang.Object ref = attribute_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + attribute_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 2; + private volatile java.lang.Object description_; + /** + * + * + *
+   * Output only. Description of the purpose of the attribute.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The description. + */ + @java.lang.Override + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Description of the purpose of the attribute.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUIRED_FIELD_NUMBER = 3; + private boolean required_; + /** + * + * + *
+   * Output only. If true, the triggers for this provider should always specify a filter
+   * on these attributes. Trigger creation will fail otherwise.
+   * 
+ * + * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The required. + */ + @java.lang.Override + public boolean getRequired() { + return required_; + } + + public static final int PATH_PATTERN_SUPPORTED_FIELD_NUMBER = 4; + private boolean pathPatternSupported_; + /** + * + * + *
+   * Output only. If true, the attribute accepts matching expressions in the Eventarc
+   * PathPattern format.
+   * 
+ * + * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The pathPatternSupported. + */ + @java.lang.Override + public boolean getPathPatternSupported() { + return pathPatternSupported_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(attribute_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, attribute_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); + } + if (required_ != false) { + output.writeBool(3, required_); + } + if (pathPatternSupported_ != false) { + output.writeBool(4, pathPatternSupported_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(attribute_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, attribute_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); + } + if (required_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, required_); + } + if (pathPatternSupported_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, pathPatternSupported_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.FilteringAttribute)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.FilteringAttribute other = + (com.google.cloud.eventarc.v1.FilteringAttribute) obj; + + if (!getAttribute().equals(other.getAttribute())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (getRequired() != other.getRequired()) return false; + if (getPathPatternSupported() != other.getPathPatternSupported()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ATTRIBUTE_FIELD_NUMBER; + hash = (53 * hash) + getAttribute().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + REQUIRED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getRequired()); + hash = (37 * hash) + PATH_PATTERN_SUPPORTED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPathPatternSupported()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.FilteringAttribute prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A representation of the FilteringAttribute resource.
+   * Filtering attributes are per event type.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.FilteringAttribute} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.FilteringAttribute) + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.FilteringAttribute.class, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.FilteringAttribute.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + attribute_ = ""; + + description_ = ""; + + required_ = false; + + pathPatternSupported_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.FilteringAttribute getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.FilteringAttribute build() { + com.google.cloud.eventarc.v1.FilteringAttribute result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.FilteringAttribute buildPartial() { + com.google.cloud.eventarc.v1.FilteringAttribute result = + new com.google.cloud.eventarc.v1.FilteringAttribute(this); + result.attribute_ = attribute_; + result.description_ = description_; + result.required_ = required_; + result.pathPatternSupported_ = pathPatternSupported_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.FilteringAttribute) { + return mergeFrom((com.google.cloud.eventarc.v1.FilteringAttribute) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.FilteringAttribute other) { + if (other == com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()) + return this; + if (!other.getAttribute().isEmpty()) { + attribute_ = other.attribute_; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + onChanged(); + } + if (other.getRequired() != false) { + setRequired(other.getRequired()); + } + if (other.getPathPatternSupported() != false) { + setPathPatternSupported(other.getPathPatternSupported()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + attribute_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + description_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + required_ = input.readBool(); + + break; + } // case 24 + case 32: + { + pathPatternSupported_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object attribute_ = ""; + /** + * + * + *
+     * Output only. Attribute used for filtering the event type.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The attribute. + */ + public java.lang.String getAttribute() { + java.lang.Object ref = attribute_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + attribute_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Attribute used for filtering the event type.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for attribute. + */ + public com.google.protobuf.ByteString getAttributeBytes() { + java.lang.Object ref = attribute_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + attribute_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Attribute used for filtering the event type.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The attribute to set. + * @return This builder for chaining. + */ + public Builder setAttribute(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + attribute_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Attribute used for filtering the event type.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearAttribute() { + + attribute_ = getDefaultInstance().getAttribute(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Attribute used for filtering the event type.
+     * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for attribute to set. + * @return This builder for chaining. + */ + public Builder setAttributeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + attribute_ = value; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + /** + * + * + *
+     * Output only. Description of the purpose of the attribute.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The description. + */ + public java.lang.String getDescription() { + java.lang.Object ref = description_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + description_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Description of the purpose of the attribute.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for description. + */ + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Description of the purpose of the attribute.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The description to set. + * @return This builder for chaining. + */ + public Builder setDescription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + description_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Description of the purpose of the attribute.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + + description_ = getDefaultInstance().getDescription(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Description of the purpose of the attribute.
+     * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for description to set. + * @return This builder for chaining. + */ + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + description_ = value; + onChanged(); + return this; + } + + private boolean required_; + /** + * + * + *
+     * Output only. If true, the triggers for this provider should always specify a filter
+     * on these attributes. Trigger creation will fail otherwise.
+     * 
+ * + * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The required. + */ + @java.lang.Override + public boolean getRequired() { + return required_; + } + /** + * + * + *
+     * Output only. If true, the triggers for this provider should always specify a filter
+     * on these attributes. Trigger creation will fail otherwise.
+     * 
+ * + * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The required to set. + * @return This builder for chaining. + */ + public Builder setRequired(boolean value) { + + required_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. If true, the triggers for this provider should always specify a filter
+     * on these attributes. Trigger creation will fail otherwise.
+     * 
+ * + * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearRequired() { + + required_ = false; + onChanged(); + return this; + } + + private boolean pathPatternSupported_; + /** + * + * + *
+     * Output only. If true, the attribute accepts matching expressions in the Eventarc
+     * PathPattern format.
+     * 
+ * + * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The pathPatternSupported. + */ + @java.lang.Override + public boolean getPathPatternSupported() { + return pathPatternSupported_; + } + /** + * + * + *
+     * Output only. If true, the attribute accepts matching expressions in the Eventarc
+     * PathPattern format.
+     * 
+ * + * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The pathPatternSupported to set. + * @return This builder for chaining. + */ + public Builder setPathPatternSupported(boolean value) { + + pathPatternSupported_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. If true, the attribute accepts matching expressions in the Eventarc
+     * PathPattern format.
+     * 
+ * + * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearPathPatternSupported() { + + pathPatternSupported_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.FilteringAttribute) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.FilteringAttribute) + private static final com.google.cloud.eventarc.v1.FilteringAttribute DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.FilteringAttribute(); + } + + public static com.google.cloud.eventarc.v1.FilteringAttribute getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FilteringAttribute parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.FilteringAttribute getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java new file mode 100644 index 000000000000..4de607b4cabc --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java @@ -0,0 +1,103 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +public interface FilteringAttributeOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.FilteringAttribute) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Output only. Attribute used for filtering the event type.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The attribute. + */ + java.lang.String getAttribute(); + /** + * + * + *
+   * Output only. Attribute used for filtering the event type.
+   * 
+ * + * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for attribute. + */ + com.google.protobuf.ByteString getAttributeBytes(); + + /** + * + * + *
+   * Output only. Description of the purpose of the attribute.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The description. + */ + java.lang.String getDescription(); + /** + * + * + *
+   * Output only. Description of the purpose of the attribute.
+   * 
+ * + * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * Output only. If true, the triggers for this provider should always specify a filter
+   * on these attributes. Trigger creation will fail otherwise.
+   * 
+ * + * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The required. + */ + boolean getRequired(); + + /** + * + * + *
+   * Output only. If true, the attribute accepts matching expressions in the Eventarc
+   * PathPattern format.
+   * 
+ * + * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The pathPatternSupported. + */ + boolean getPathPatternSupported(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java new file mode 100644 index 000000000000..c71eed0dc4d0 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java @@ -0,0 +1,1357 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * Represents a GKE destination.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GKE} + */ +public final class GKE extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GKE) + GKEOrBuilder { + private static final long serialVersionUID = 0L; + // Use GKE.newBuilder() to construct. + private GKE(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GKE() { + cluster_ = ""; + location_ = ""; + namespace_ = ""; + service_ = ""; + path_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GKE(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GKE.class, com.google.cloud.eventarc.v1.GKE.Builder.class); + } + + public static final int CLUSTER_FIELD_NUMBER = 1; + private volatile java.lang.Object cluster_; + /** + * + * + *
+   * Required. The name of the cluster the GKE service is running in. The cluster must be
+   * running in the same project as the trigger being created.
+   * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The cluster. + */ + @java.lang.Override + public java.lang.String getCluster() { + java.lang.Object ref = cluster_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cluster_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the cluster the GKE service is running in. The cluster must be
+   * running in the same project as the trigger being created.
+   * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for cluster. + */ + @java.lang.Override + public com.google.protobuf.ByteString getClusterBytes() { + java.lang.Object ref = cluster_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cluster_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int LOCATION_FIELD_NUMBER = 2; + private volatile java.lang.Object location_; + /** + * + * + *
+   * Required. The name of the Google Compute Engine in which the cluster resides, which
+   * can either be compute zone (for example, us-central1-a) for the zonal
+   * clusters or region (for example, us-central1) for regional clusters.
+   * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The location. + */ + @java.lang.Override + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the Google Compute Engine in which the cluster resides, which
+   * can either be compute zone (for example, us-central1-a) for the zonal
+   * clusters or region (for example, us-central1) for regional clusters.
+   * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for location. + */ + @java.lang.Override + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int NAMESPACE_FIELD_NUMBER = 3; + private volatile java.lang.Object namespace_; + /** + * + * + *
+   * Required. The namespace the GKE service is running in.
+   * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The namespace. + */ + @java.lang.Override + public java.lang.String getNamespace() { + java.lang.Object ref = namespace_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + namespace_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The namespace the GKE service is running in.
+   * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for namespace. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNamespaceBytes() { + java.lang.Object ref = namespace_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + namespace_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SERVICE_FIELD_NUMBER = 4; + private volatile java.lang.Object service_; + /** + * + * + *
+   * Required. Name of the GKE service.
+   * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The service. + */ + @java.lang.Override + public java.lang.String getService() { + java.lang.Object ref = service_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + service_ = s; + return s; + } + } + /** + * + * + *
+   * Required. Name of the GKE service.
+   * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for service. + */ + @java.lang.Override + public com.google.protobuf.ByteString getServiceBytes() { + java.lang.Object ref = service_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + service_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PATH_FIELD_NUMBER = 5; + private volatile java.lang.Object path_; + /** + * + * + *
+   * Optional. The relative path on the GKE service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + @java.lang.Override + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. The relative path on the GKE service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cluster_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, cluster_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, location_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(namespace_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, namespace_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, service_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, path_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cluster_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, cluster_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, location_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(namespace_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, namespace_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, service_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, path_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GKE)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GKE other = (com.google.cloud.eventarc.v1.GKE) obj; + + if (!getCluster().equals(other.getCluster())) return false; + if (!getLocation().equals(other.getLocation())) return false; + if (!getNamespace().equals(other.getNamespace())) return false; + if (!getService().equals(other.getService())) return false; + if (!getPath().equals(other.getPath())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + CLUSTER_FIELD_NUMBER; + hash = (53 * hash) + getCluster().hashCode(); + hash = (37 * hash) + LOCATION_FIELD_NUMBER; + hash = (53 * hash) + getLocation().hashCode(); + hash = (37 * hash) + NAMESPACE_FIELD_NUMBER; + hash = (53 * hash) + getNamespace().hashCode(); + hash = (37 * hash) + SERVICE_FIELD_NUMBER; + hash = (53 * hash) + getService().hashCode(); + hash = (37 * hash) + PATH_FIELD_NUMBER; + hash = (53 * hash) + getPath().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GKE parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GKE parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GKE parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.GKE prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Represents a GKE destination.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GKE} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GKE) + com.google.cloud.eventarc.v1.GKEOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GKE.class, + com.google.cloud.eventarc.v1.GKE.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GKE.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + cluster_ = ""; + + location_ = ""; + + namespace_ = ""; + + service_ = ""; + + path_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GKE getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GKE build() { + com.google.cloud.eventarc.v1.GKE result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GKE buildPartial() { + com.google.cloud.eventarc.v1.GKE result = new com.google.cloud.eventarc.v1.GKE(this); + result.cluster_ = cluster_; + result.location_ = location_; + result.namespace_ = namespace_; + result.service_ = service_; + result.path_ = path_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GKE) { + return mergeFrom((com.google.cloud.eventarc.v1.GKE) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GKE other) { + if (other == com.google.cloud.eventarc.v1.GKE.getDefaultInstance()) return this; + if (!other.getCluster().isEmpty()) { + cluster_ = other.cluster_; + onChanged(); + } + if (!other.getLocation().isEmpty()) { + location_ = other.location_; + onChanged(); + } + if (!other.getNamespace().isEmpty()) { + namespace_ = other.namespace_; + onChanged(); + } + if (!other.getService().isEmpty()) { + service_ = other.service_; + onChanged(); + } + if (!other.getPath().isEmpty()) { + path_ = other.path_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + cluster_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + location_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + namespace_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + service_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + path_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object cluster_ = ""; + /** + * + * + *
+     * Required. The name of the cluster the GKE service is running in. The cluster must be
+     * running in the same project as the trigger being created.
+     * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The cluster. + */ + public java.lang.String getCluster() { + java.lang.Object ref = cluster_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cluster_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the cluster the GKE service is running in. The cluster must be
+     * running in the same project as the trigger being created.
+     * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for cluster. + */ + public com.google.protobuf.ByteString getClusterBytes() { + java.lang.Object ref = cluster_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cluster_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the cluster the GKE service is running in. The cluster must be
+     * running in the same project as the trigger being created.
+     * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The cluster to set. + * @return This builder for chaining. + */ + public Builder setCluster(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + cluster_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the cluster the GKE service is running in. The cluster must be
+     * running in the same project as the trigger being created.
+     * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearCluster() { + + cluster_ = getDefaultInstance().getCluster(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the cluster the GKE service is running in. The cluster must be
+     * running in the same project as the trigger being created.
+     * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for cluster to set. + * @return This builder for chaining. + */ + public Builder setClusterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + cluster_ = value; + onChanged(); + return this; + } + + private java.lang.Object location_ = ""; + /** + * + * + *
+     * Required. The name of the Google Compute Engine in which the cluster resides, which
+     * can either be compute zone (for example, us-central1-a) for the zonal
+     * clusters or region (for example, us-central1) for regional clusters.
+     * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The location. + */ + public java.lang.String getLocation() { + java.lang.Object ref = location_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + location_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the Google Compute Engine in which the cluster resides, which
+     * can either be compute zone (for example, us-central1-a) for the zonal
+     * clusters or region (for example, us-central1) for regional clusters.
+     * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for location. + */ + public com.google.protobuf.ByteString getLocationBytes() { + java.lang.Object ref = location_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + location_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the Google Compute Engine in which the cluster resides, which
+     * can either be compute zone (for example, us-central1-a) for the zonal
+     * clusters or region (for example, us-central1) for regional clusters.
+     * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The location to set. + * @return This builder for chaining. + */ + public Builder setLocation(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + location_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the Google Compute Engine in which the cluster resides, which
+     * can either be compute zone (for example, us-central1-a) for the zonal
+     * clusters or region (for example, us-central1) for regional clusters.
+     * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearLocation() { + + location_ = getDefaultInstance().getLocation(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the Google Compute Engine in which the cluster resides, which
+     * can either be compute zone (for example, us-central1-a) for the zonal
+     * clusters or region (for example, us-central1) for regional clusters.
+     * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for location to set. + * @return This builder for chaining. + */ + public Builder setLocationBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + location_ = value; + onChanged(); + return this; + } + + private java.lang.Object namespace_ = ""; + /** + * + * + *
+     * Required. The namespace the GKE service is running in.
+     * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The namespace. + */ + public java.lang.String getNamespace() { + java.lang.Object ref = namespace_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + namespace_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The namespace the GKE service is running in.
+     * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for namespace. + */ + public com.google.protobuf.ByteString getNamespaceBytes() { + java.lang.Object ref = namespace_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + namespace_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The namespace the GKE service is running in.
+     * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The namespace to set. + * @return This builder for chaining. + */ + public Builder setNamespace(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + namespace_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The namespace the GKE service is running in.
+     * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearNamespace() { + + namespace_ = getDefaultInstance().getNamespace(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The namespace the GKE service is running in.
+     * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for namespace to set. + * @return This builder for chaining. + */ + public Builder setNamespaceBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + namespace_ = value; + onChanged(); + return this; + } + + private java.lang.Object service_ = ""; + /** + * + * + *
+     * Required. Name of the GKE service.
+     * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The service. + */ + public java.lang.String getService() { + java.lang.Object ref = service_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + service_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. Name of the GKE service.
+     * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for service. + */ + public com.google.protobuf.ByteString getServiceBytes() { + java.lang.Object ref = service_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + service_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. Name of the GKE service.
+     * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The service to set. + * @return This builder for chaining. + */ + public Builder setService(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + service_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the GKE service.
+     * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearService() { + + service_ = getDefaultInstance().getService(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Name of the GKE service.
+     * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for service to set. + * @return This builder for chaining. + */ + public Builder setServiceBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + service_ = value; + onChanged(); + return this; + } + + private java.lang.Object path_ = ""; + /** + * + * + *
+     * Optional. The relative path on the GKE service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + public java.lang.String getPath() { + java.lang.Object ref = path_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + path_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. The relative path on the GKE service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + public com.google.protobuf.ByteString getPathBytes() { + java.lang.Object ref = path_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + path_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. The relative path on the GKE service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The path to set. + * @return This builder for chaining. + */ + public Builder setPath(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + path_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The relative path on the GKE service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPath() { + + path_ = getDefaultInstance().getPath(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The relative path on the GKE service the events should be sent to.
+     * The value must conform to the definition of a URI path segment (section 3.3
+     * of RFC2396). Examples: "/route", "route", "route/subroute".
+     * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for path to set. + * @return This builder for chaining. + */ + public Builder setPathBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + path_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GKE) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GKE) + private static final com.google.cloud.eventarc.v1.GKE DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GKE(); + } + + public static com.google.cloud.eventarc.v1.GKE getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GKE parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GKE getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java new file mode 100644 index 000000000000..bf65375b8c93 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java @@ -0,0 +1,160 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface GKEOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GKE) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the cluster the GKE service is running in. The cluster must be
+   * running in the same project as the trigger being created.
+   * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The cluster. + */ + java.lang.String getCluster(); + /** + * + * + *
+   * Required. The name of the cluster the GKE service is running in. The cluster must be
+   * running in the same project as the trigger being created.
+   * 
+ * + * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for cluster. + */ + com.google.protobuf.ByteString getClusterBytes(); + + /** + * + * + *
+   * Required. The name of the Google Compute Engine in which the cluster resides, which
+   * can either be compute zone (for example, us-central1-a) for the zonal
+   * clusters or region (for example, us-central1) for regional clusters.
+   * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The location. + */ + java.lang.String getLocation(); + /** + * + * + *
+   * Required. The name of the Google Compute Engine in which the cluster resides, which
+   * can either be compute zone (for example, us-central1-a) for the zonal
+   * clusters or region (for example, us-central1) for regional clusters.
+   * 
+ * + * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for location. + */ + com.google.protobuf.ByteString getLocationBytes(); + + /** + * + * + *
+   * Required. The namespace the GKE service is running in.
+   * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The namespace. + */ + java.lang.String getNamespace(); + /** + * + * + *
+   * Required. The namespace the GKE service is running in.
+   * 
+ * + * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for namespace. + */ + com.google.protobuf.ByteString getNamespaceBytes(); + + /** + * + * + *
+   * Required. Name of the GKE service.
+   * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The service. + */ + java.lang.String getService(); + /** + * + * + *
+   * Required. Name of the GKE service.
+   * 
+ * + * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for service. + */ + com.google.protobuf.ByteString getServiceBytes(); + + /** + * + * + *
+   * Optional. The relative path on the GKE service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The path. + */ + java.lang.String getPath(); + /** + * + * + *
+   * Optional. The relative path on the GKE service the events should be sent to.
+   * The value must conform to the definition of a URI path segment (section 3.3
+   * of RFC2396). Examples: "/route", "route", "route/subroute".
+   * 
+ * + * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for path. + */ + com.google.protobuf.ByteString getPathBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java new file mode 100644 index 000000000000..c026805cc0f9 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java @@ -0,0 +1,630 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the GetChannelConnection method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetChannelConnectionRequest} + */ +public final class GetChannelConnectionRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetChannelConnectionRequest) + GetChannelConnectionRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetChannelConnectionRequest.newBuilder() to construct. + private GetChannelConnectionRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetChannelConnectionRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetChannelConnectionRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the channel connection to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the channel connection to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GetChannelConnectionRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GetChannelConnectionRequest other = + (com.google.cloud.eventarc.v1.GetChannelConnectionRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the GetChannelConnection method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetChannelConnectionRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetChannelConnectionRequest) + com.google.cloud.eventarc.v1.GetChannelConnectionRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GetChannelConnectionRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelConnectionRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GetChannelConnectionRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelConnectionRequest build() { + com.google.cloud.eventarc.v1.GetChannelConnectionRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelConnectionRequest buildPartial() { + com.google.cloud.eventarc.v1.GetChannelConnectionRequest result = + new com.google.cloud.eventarc.v1.GetChannelConnectionRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GetChannelConnectionRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.GetChannelConnectionRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GetChannelConnectionRequest other) { + if (other == com.google.cloud.eventarc.v1.GetChannelConnectionRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the channel connection to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel connection to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel connection to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel connection to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel connection to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetChannelConnectionRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetChannelConnectionRequest) + private static final com.google.cloud.eventarc.v1.GetChannelConnectionRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetChannelConnectionRequest(); + } + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetChannelConnectionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelConnectionRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java new file mode 100644 index 000000000000..4740326d3526 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java @@ -0,0 +1,54 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface GetChannelConnectionRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetChannelConnectionRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the channel connection to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the channel connection to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java new file mode 100644 index 000000000000..50909a208005 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java @@ -0,0 +1,628 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the GetChannel method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetChannelRequest} + */ +public final class GetChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetChannelRequest) + GetChannelRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetChannelRequest.newBuilder() to construct. + private GetChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetChannelRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetChannelRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetChannelRequest.class, + com.google.cloud.eventarc.v1.GetChannelRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the channel to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the channel to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GetChannelRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GetChannelRequest other = + (com.google.cloud.eventarc.v1.GetChannelRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.GetChannelRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the GetChannel method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetChannelRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetChannelRequest) + com.google.cloud.eventarc.v1.GetChannelRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetChannelRequest.class, + com.google.cloud.eventarc.v1.GetChannelRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GetChannelRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GetChannelRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelRequest build() { + com.google.cloud.eventarc.v1.GetChannelRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelRequest buildPartial() { + com.google.cloud.eventarc.v1.GetChannelRequest result = + new com.google.cloud.eventarc.v1.GetChannelRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GetChannelRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.GetChannelRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GetChannelRequest other) { + if (other == com.google.cloud.eventarc.v1.GetChannelRequest.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the channel to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the channel to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the channel to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetChannelRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetChannelRequest) + private static final com.google.cloud.eventarc.v1.GetChannelRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetChannelRequest(); + } + + public static com.google.cloud.eventarc.v1.GetChannelRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetChannelRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java new file mode 100644 index 000000000000..90fbf98bdc3a --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java @@ -0,0 +1,54 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface GetChannelRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetChannelRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the channel to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the channel to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java new file mode 100644 index 000000000000..d72e3f2c9429 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java @@ -0,0 +1,630 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the GetGoogleChannelConfig method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetGoogleChannelConfigRequest} + */ +public final class GetGoogleChannelConfigRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) + GetGoogleChannelConfigRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetGoogleChannelConfigRequest.newBuilder() to construct. + private GetGoogleChannelConfigRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetGoogleChannelConfigRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetGoogleChannelConfigRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the config to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the config to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest other = + (com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the GetGoogleChannelConfig method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetGoogleChannelConfigRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest build() { + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest buildPartial() { + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest result = + new com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest other) { + if (other == com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the config to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the config to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the config to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the config to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the config to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) + private static final com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest(); + } + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetGoogleChannelConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java new file mode 100644 index 000000000000..537002ba14d6 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java @@ -0,0 +1,54 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface GetGoogleChannelConfigRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the config to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the config to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java new file mode 100644 index 000000000000..297e337f6af1 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java @@ -0,0 +1,629 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the GetProvider method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetProviderRequest} + */ +public final class GetProviderRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetProviderRequest) + GetProviderRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetProviderRequest.newBuilder() to construct. + private GetProviderRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetProviderRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetProviderRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetProviderRequest.class, + com.google.cloud.eventarc.v1.GetProviderRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the provider to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the provider to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GetProviderRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GetProviderRequest other = + (com.google.cloud.eventarc.v1.GetProviderRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.GetProviderRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the GetProvider method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetProviderRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetProviderRequest) + com.google.cloud.eventarc.v1.GetProviderRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetProviderRequest.class, + com.google.cloud.eventarc.v1.GetProviderRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GetProviderRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetProviderRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetProviderRequest build() { + com.google.cloud.eventarc.v1.GetProviderRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetProviderRequest buildPartial() { + com.google.cloud.eventarc.v1.GetProviderRequest result = + new com.google.cloud.eventarc.v1.GetProviderRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GetProviderRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.GetProviderRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GetProviderRequest other) { + if (other == com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the provider to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the provider to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the provider to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the provider to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the provider to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetProviderRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetProviderRequest) + private static final com.google.cloud.eventarc.v1.GetProviderRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetProviderRequest(); + } + + public static com.google.cloud.eventarc.v1.GetProviderRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetProviderRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetProviderRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java new file mode 100644 index 000000000000..c5079d476f49 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java @@ -0,0 +1,54 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface GetProviderRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetProviderRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the provider to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the provider to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java new file mode 100644 index 000000000000..2544e39e03c7 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java @@ -0,0 +1,628 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the GetTrigger method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetTriggerRequest} + */ +public final class GetTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetTriggerRequest) + GetTriggerRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetTriggerRequest.newBuilder() to construct. + private GetTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetTriggerRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetTriggerRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetTriggerRequest.class, + com.google.cloud.eventarc.v1.GetTriggerRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the trigger to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The name of the trigger to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GetTriggerRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GetTriggerRequest other = + (com.google.cloud.eventarc.v1.GetTriggerRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.GetTriggerRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the GetTrigger method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GetTriggerRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetTriggerRequest) + com.google.cloud.eventarc.v1.GetTriggerRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GetTriggerRequest.class, + com.google.cloud.eventarc.v1.GetTriggerRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GetTriggerRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetTriggerRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GetTriggerRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetTriggerRequest build() { + com.google.cloud.eventarc.v1.GetTriggerRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetTriggerRequest buildPartial() { + com.google.cloud.eventarc.v1.GetTriggerRequest result = + new com.google.cloud.eventarc.v1.GetTriggerRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GetTriggerRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.GetTriggerRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GetTriggerRequest other) { + if (other == com.google.cloud.eventarc.v1.GetTriggerRequest.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the trigger to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The name of the trigger to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The name of the trigger to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the trigger to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the trigger to get.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetTriggerRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetTriggerRequest) + private static final com.google.cloud.eventarc.v1.GetTriggerRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetTriggerRequest(); + } + + public static com.google.cloud.eventarc.v1.GetTriggerRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GetTriggerRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java new file mode 100644 index 000000000000..e9a5a9ebc3d5 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java @@ -0,0 +1,54 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface GetTriggerRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetTriggerRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the trigger to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The name of the trigger to get.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java new file mode 100644 index 000000000000..445f59681dca --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java @@ -0,0 +1,1127 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/google_channel_config.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A GoogleChannelConfig is a resource that stores the custom settings
+ * respected by Eventarc first-party triggers in the matching region.
+ * Once configured, first-party event data will be protected
+ * using the specified custom managed encryption key instead of Google-managed
+ * encryption keys.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GoogleChannelConfig} + */ +public final class GoogleChannelConfig extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GoogleChannelConfig) + GoogleChannelConfigOrBuilder { + private static final long serialVersionUID = 0L; + // Use GoogleChannelConfig.newBuilder() to construct. + private GoogleChannelConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GoogleChannelConfig() { + name_ = ""; + cryptoKeyName_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GoogleChannelConfig(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.GoogleChannelConfigProto + .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.GoogleChannelConfigProto + .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GoogleChannelConfig.class, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The resource name of the config. Must be in the format of,
+   * `projects/{project}/locations/{location}/googleChannelConfig`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The resource name of the config. Must be in the format of,
+   * `projects/{project}/locations/{location}/googleChannelConfig`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int CRYPTO_KEY_NAME_FIELD_NUMBER = 7; + private volatile java.lang.Object cryptoKeyName_; + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + @java.lang.Override + public java.lang.String getCryptoKeyName() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cryptoKeyName_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cryptoKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (updateTime_ != null) { + output.writeMessage(6, getUpdateTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cryptoKeyName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 7, cryptoKeyName_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cryptoKeyName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, cryptoKeyName_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.GoogleChannelConfig)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.GoogleChannelConfig other = + (com.google.cloud.eventarc.v1.GoogleChannelConfig) obj; + + if (!getName().equals(other.getName())) return false; + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getCryptoKeyName().equals(other.getCryptoKeyName())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + hash = (37 * hash) + CRYPTO_KEY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getCryptoKeyName().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.GoogleChannelConfig prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A GoogleChannelConfig is a resource that stores the custom settings
+   * respected by Eventarc first-party triggers in the matching region.
+   * Once configured, first-party event data will be protected
+   * using the specified custom managed encryption key instead of Google-managed
+   * encryption keys.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.GoogleChannelConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GoogleChannelConfig) + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.GoogleChannelConfigProto + .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.GoogleChannelConfigProto + .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.GoogleChannelConfig.class, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.GoogleChannelConfig.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + cryptoKeyName_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.GoogleChannelConfigProto + .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GoogleChannelConfig getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GoogleChannelConfig build() { + com.google.cloud.eventarc.v1.GoogleChannelConfig result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GoogleChannelConfig buildPartial() { + com.google.cloud.eventarc.v1.GoogleChannelConfig result = + new com.google.cloud.eventarc.v1.GoogleChannelConfig(this); + result.name_ = name_; + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + result.cryptoKeyName_ = cryptoKeyName_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.GoogleChannelConfig) { + return mergeFrom((com.google.cloud.eventarc.v1.GoogleChannelConfig) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.GoogleChannelConfig other) { + if (other == com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (!other.getCryptoKeyName().isEmpty()) { + cryptoKeyName_ = other.cryptoKeyName_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + cryptoKeyName_ = input.readStringRequireUtf8(); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The resource name of the config. Must be in the format of,
+     * `projects/{project}/locations/{location}/googleChannelConfig`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The resource name of the config. Must be in the format of,
+     * `projects/{project}/locations/{location}/googleChannelConfig`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The resource name of the config. Must be in the format of,
+     * `projects/{project}/locations/{location}/googleChannelConfig`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The resource name of the config. Must be in the format of,
+     * `projects/{project}/locations/{location}/googleChannelConfig`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The resource name of the config. Must be in the format of,
+     * `projects/{project}/locations/{location}/googleChannelConfig`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private java.lang.Object cryptoKeyName_ = ""; + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + public java.lang.String getCryptoKeyName() { + java.lang.Object ref = cryptoKeyName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + cryptoKeyName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { + java.lang.Object ref = cryptoKeyName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + cryptoKeyName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The cryptoKeyName to set. + * @return This builder for chaining. + */ + public Builder setCryptoKeyName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + cryptoKeyName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearCryptoKeyName() { + + cryptoKeyName_ = getDefaultInstance().getCryptoKeyName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. Resource name of a KMS crypto key (managed by the user) used to
+     * encrypt/decrypt their event data.
+     * It must match the pattern
+     * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+     * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for cryptoKeyName to set. + * @return This builder for chaining. + */ + public Builder setCryptoKeyNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + cryptoKeyName_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GoogleChannelConfig) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GoogleChannelConfig) + private static final com.google.cloud.eventarc.v1.GoogleChannelConfig DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GoogleChannelConfig(); + } + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GoogleChannelConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.GoogleChannelConfig getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java new file mode 100644 index 000000000000..fec57b0b7aec --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java @@ -0,0 +1,125 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/google_channel_config.proto + +package com.google.cloud.eventarc.v1; + +public interface GoogleChannelConfigOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GoogleChannelConfig) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The resource name of the config. Must be in the format of,
+   * `projects/{project}/locations/{location}/googleChannelConfig`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The resource name of the config. Must be in the format of,
+   * `projects/{project}/locations/{location}/googleChannelConfig`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The cryptoKeyName. + */ + java.lang.String getCryptoKeyName(); + /** + * + * + *
+   * Optional. Resource name of a KMS crypto key (managed by the user) used to
+   * encrypt/decrypt their event data.
+   * It must match the pattern
+   * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
+   * 
+ * + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for cryptoKeyName. + */ + com.google.protobuf.ByteString getCryptoKeyNameBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java new file mode 100644 index 000000000000..60528967f07c --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java @@ -0,0 +1,95 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/google_channel_config.proto + +package com.google.cloud.eventarc.v1; + +public final class GoogleChannelConfigProto { + private GoogleChannelConfigProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n4google/cloud/eventarc/v1/google_channe" + + "l_config.proto\022\030google.cloud.eventarc.v1" + + "\032\037google/api/field_behavior.proto\032\031googl" + + "e/api/resource.proto\032\037google/protobuf/ti" + + "mestamp.proto\"\247\002\n\023GoogleChannelConfig\022\021\n" + + "\004name\030\001 \001(\tB\003\340A\002\0224\n\013update_time\030\006 \001(\0132\032." + + "google.protobuf.TimestampB\003\340A\003\022B\n\017crypto" + + "_key_name\030\007 \001(\tB)\340A\001\372A#\n!cloudkms.google" + + "apis.com/CryptoKey:\202\001\352A\177\n+eventarc.googl" + + "eapis.com/GoogleChannelConfig\022;projects/" + + "{project}/locations/{location}/googleCha" + + "nnelConfig2\023googleChannelConfigB\313\002\n\034com." + + "google.cloud.eventarc.v1B\030GoogleChannelC" + + "onfigProtoP\001Z@google.golang.org/genproto" + + "/googleapis/cloud/eventarc/v1;eventarc\252\002" + + "\030Google.Cloud.Eventarc.V1\312\002\030Google\\Cloud" + + "\\Eventarc\\V1\352\002\033Google::Cloud::Eventarc::" + + "V1\352Ax\n!cloudkms.googleapis.com/CryptoKey" + + "\022Sprojects/{project}/locations/{location" + + "}/keyRings/{key_ring}/cryptoKeys/{crypto" + + "_key}b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor, + new java.lang.String[] { + "Name", "UpdateTime", "CryptoKeyName", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceDefinition); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java new file mode 100644 index 000000000000..558b1e654bfe --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java @@ -0,0 +1,924 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the ListChannelConnections method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsRequest} + */ +public final class ListChannelConnectionsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelConnectionsRequest) + ListChannelConnectionsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListChannelConnectionsRequest.newBuilder() to construct. + private ListChannelConnectionsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListChannelConnectionsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListChannelConnectionsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent collection from which to list channel connections.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent collection from which to list channel connections.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of channel connections to return on each page.
+   * Note: The service may send fewer responses.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannelConnections` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannelConnetions`
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannelConnections` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannelConnetions`
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest other = + (com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the ListChannelConnections method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelConnectionsRequest) + com.google.cloud.eventarc.v1.ListChannelConnectionsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest build() { + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest buildPartial() { + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest result = + new com.google.cloud.eventarc.v1.ListChannelConnectionsRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest other) { + if (other == com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent collection from which to list channel connections.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent collection from which to list channel connections.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent collection from which to list channel connections.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection from which to list channel connections.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection from which to list channel connections.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of channel connections to return on each page.
+     * Note: The service may send fewer responses.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of channel connections to return on each page.
+     * Note: The service may send fewer responses.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of channel connections to return on each page.
+     * Note: The service may send fewer responses.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannelConnections` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannelConnetions`
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannelConnections` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannelConnetions`
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannelConnections` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannelConnetions`
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + pageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannelConnections` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannelConnetions`
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannelConnections` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannelConnetions`
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + pageToken_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelConnectionsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelConnectionsRequest) + private static final com.google.cloud.eventarc.v1.ListChannelConnectionsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelConnectionsRequest(); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelConnectionsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java new file mode 100644 index 000000000000..bb5c61d244db --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java @@ -0,0 +1,99 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListChannelConnectionsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelConnectionsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent collection from which to list channel connections.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent collection from which to list channel connections.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of channel connections to return on each page.
+   * Note: The service may send fewer responses.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannelConnections` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannelConnetions`
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannelConnections` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannelConnetions`
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java new file mode 100644 index 000000000000..9d8a5317ed11 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java @@ -0,0 +1,1428 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The response message for the `ListChannelConnections` method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsResponse} + */ +public final class ListChannelConnectionsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelConnectionsResponse) + ListChannelConnectionsResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListChannelConnectionsResponse.newBuilder() to construct. + private ListChannelConnectionsResponse( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListChannelConnectionsResponse() { + channelConnections_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListChannelConnectionsResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.Builder.class); + } + + public static final int CHANNEL_CONNECTIONS_FIELD_NUMBER = 1; + private java.util.List channelConnections_; + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + @java.lang.Override + public java.util.List + getChannelConnectionsList() { + return channelConnections_; + } + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + @java.lang.Override + public java.util.List + getChannelConnectionsOrBuilderList() { + return channelConnections_; + } + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + @java.lang.Override + public int getChannelConnectionsCount() { + return channelConnections_.size(); + } + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnections(int index) { + return channelConnections_.get(index); + } + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrBuilder( + int index) { + return channelConnections_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * A page token that can be sent to `ListChannelConnections` to request the
+   * next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * A page token that can be sent to `ListChannelConnections` to request the
+   * next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + private com.google.protobuf.LazyStringList unreachable_; + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < channelConnections_.size(); i++) { + output.writeMessage(1, channelConnections_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < channelConnections_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, channelConnections_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsResponse)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse other = + (com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) obj; + + if (!getChannelConnectionsList().equals(other.getChannelConnectionsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getChannelConnectionsCount() > 0) { + hash = (37 * hash) + CHANNEL_CONNECTIONS_FIELD_NUMBER; + hash = (53 * hash) + getChannelConnectionsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The response message for the `ListChannelConnections` method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelConnectionsResponse) + com.google.cloud.eventarc.v1.ListChannelConnectionsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (channelConnectionsBuilder_ == null) { + channelConnections_ = java.util.Collections.emptyList(); + } else { + channelConnections_ = null; + channelConnectionsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse build() { + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse buildPartial() { + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse result = + new com.google.cloud.eventarc.v1.ListChannelConnectionsResponse(this); + int from_bitField0_ = bitField0_; + if (channelConnectionsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + channelConnections_ = java.util.Collections.unmodifiableList(channelConnections_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.channelConnections_ = channelConnections_; + } else { + result.channelConnections_ = channelConnectionsBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + if (((bitField0_ & 0x00000002) != 0)) { + unreachable_ = unreachable_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.unreachable_ = unreachable_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) { + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelConnectionsResponse other) { + if (other == com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.getDefaultInstance()) + return this; + if (channelConnectionsBuilder_ == null) { + if (!other.channelConnections_.isEmpty()) { + if (channelConnections_.isEmpty()) { + channelConnections_ = other.channelConnections_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureChannelConnectionsIsMutable(); + channelConnections_.addAll(other.channelConnections_); + } + onChanged(); + } + } else { + if (!other.channelConnections_.isEmpty()) { + if (channelConnectionsBuilder_.isEmpty()) { + channelConnectionsBuilder_.dispose(); + channelConnectionsBuilder_ = null; + channelConnections_ = other.channelConnections_; + bitField0_ = (bitField0_ & ~0x00000001); + channelConnectionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getChannelConnectionsFieldBuilder() + : null; + } else { + channelConnectionsBuilder_.addAllMessages(other.channelConnections_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.eventarc.v1.ChannelConnection m = + input.readMessage( + com.google.cloud.eventarc.v1.ChannelConnection.parser(), extensionRegistry); + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + channelConnections_.add(m); + } else { + channelConnectionsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List channelConnections_ = + java.util.Collections.emptyList(); + + private void ensureChannelConnectionsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + channelConnections_ = + new java.util.ArrayList( + channelConnections_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + channelConnectionsBuilder_; + + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public java.util.List + getChannelConnectionsList() { + if (channelConnectionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(channelConnections_); + } else { + return channelConnectionsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public int getChannelConnectionsCount() { + if (channelConnectionsBuilder_ == null) { + return channelConnections_.size(); + } else { + return channelConnectionsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnections(int index) { + if (channelConnectionsBuilder_ == null) { + return channelConnections_.get(index); + } else { + return channelConnectionsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder setChannelConnections( + int index, com.google.cloud.eventarc.v1.ChannelConnection value) { + if (channelConnectionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureChannelConnectionsIsMutable(); + channelConnections_.set(index, value); + onChanged(); + } else { + channelConnectionsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder setChannelConnections( + int index, com.google.cloud.eventarc.v1.ChannelConnection.Builder builderForValue) { + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + channelConnections_.set(index, builderForValue.build()); + onChanged(); + } else { + channelConnectionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder addChannelConnections(com.google.cloud.eventarc.v1.ChannelConnection value) { + if (channelConnectionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureChannelConnectionsIsMutable(); + channelConnections_.add(value); + onChanged(); + } else { + channelConnectionsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder addChannelConnections( + int index, com.google.cloud.eventarc.v1.ChannelConnection value) { + if (channelConnectionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureChannelConnectionsIsMutable(); + channelConnections_.add(index, value); + onChanged(); + } else { + channelConnectionsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder addChannelConnections( + com.google.cloud.eventarc.v1.ChannelConnection.Builder builderForValue) { + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + channelConnections_.add(builderForValue.build()); + onChanged(); + } else { + channelConnectionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder addChannelConnections( + int index, com.google.cloud.eventarc.v1.ChannelConnection.Builder builderForValue) { + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + channelConnections_.add(index, builderForValue.build()); + onChanged(); + } else { + channelConnectionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder addAllChannelConnections( + java.lang.Iterable values) { + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, channelConnections_); + onChanged(); + } else { + channelConnectionsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder clearChannelConnections() { + if (channelConnectionsBuilder_ == null) { + channelConnections_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + channelConnectionsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public Builder removeChannelConnections(int index) { + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + channelConnections_.remove(index); + onChanged(); + } else { + channelConnectionsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public com.google.cloud.eventarc.v1.ChannelConnection.Builder getChannelConnectionsBuilder( + int index) { + return getChannelConnectionsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrBuilder( + int index) { + if (channelConnectionsBuilder_ == null) { + return channelConnections_.get(index); + } else { + return channelConnectionsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public java.util.List + getChannelConnectionsOrBuilderList() { + if (channelConnectionsBuilder_ != null) { + return channelConnectionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(channelConnections_); + } + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnectionsBuilder() { + return getChannelConnectionsFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance()); + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnectionsBuilder( + int index) { + return getChannelConnectionsFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance()); + } + /** + * + * + *
+     * The requested channel connections, up to the number specified in
+     * `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + public java.util.List + getChannelConnectionsBuilderList() { + return getChannelConnectionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + getChannelConnectionsFieldBuilder() { + if (channelConnectionsBuilder_ == null) { + channelConnectionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>( + channelConnections_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + channelConnections_ = null; + } + return channelConnectionsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * A page token that can be sent to `ListChannelConnections` to request the
+     * next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListChannelConnections` to request the
+     * next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListChannelConnections` to request the
+     * next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListChannelConnections` to request the
+     * next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListChannelConnections` to request the
+     * next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureUnreachableIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + bitField0_ |= 0x00000002; + } + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_.getUnmodifiableView(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelConnectionsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelConnectionsResponse) + private static final com.google.cloud.eventarc.v1.ListChannelConnectionsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelConnectionsResponse(); + } + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelConnectionsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java new file mode 100644 index 000000000000..5a66f5109514 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java @@ -0,0 +1,162 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListChannelConnectionsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelConnectionsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + java.util.List getChannelConnectionsList(); + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + com.google.cloud.eventarc.v1.ChannelConnection getChannelConnections(int index); + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + int getChannelConnectionsCount(); + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + java.util.List + getChannelConnectionsOrBuilderList(); + /** + * + * + *
+   * The requested channel connections, up to the number specified in
+   * `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1; + */ + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrBuilder(int index); + + /** + * + * + *
+   * A page token that can be sent to `ListChannelConnections` to request the
+   * next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * A page token that can be sent to `ListChannelConnections` to request the
+   * next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java new file mode 100644 index 000000000000..aeb058ec0598 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java @@ -0,0 +1,1122 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the ListChannels method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsRequest} + */ +public final class ListChannelsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelsRequest) + ListChannelsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListChannelsRequest.newBuilder() to construct. + private ListChannelsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListChannelsRequest() { + parent_ = ""; + pageToken_ = ""; + orderBy_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListChannelsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelsRequest.class, + com.google.cloud.eventarc.v1.ListChannelsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent collection to list channels on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent collection to list channels on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of channels to return on each page.
+   * Note: The service may send fewer.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannels` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannels` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannels` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannels` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 4; + private volatile java.lang.Object orderBy_; + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, channel_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, channel_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, orderBy_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, orderBy_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelsRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListChannelsRequest other = + (com.google.cloud.eventarc.v1.ListChannelsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListChannelsRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the ListChannels method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelsRequest) + com.google.cloud.eventarc.v1.ListChannelsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelsRequest.class, + com.google.cloud.eventarc.v1.ListChannelsRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListChannelsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + orderBy_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListChannelsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsRequest build() { + com.google.cloud.eventarc.v1.ListChannelsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsRequest buildPartial() { + com.google.cloud.eventarc.v1.ListChannelsRequest result = + new com.google.cloud.eventarc.v1.ListChannelsRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + result.orderBy_ = orderBy_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListChannelsRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelsRequest other) { + if (other == com.google.cloud.eventarc.v1.ListChannelsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + orderBy_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent collection to list channels on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent collection to list channels on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent collection to list channels on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection to list channels on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection to list channels on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of channels to return on each page.
+     * Note: The service may send fewer.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of channels to return on each page.
+     * Note: The service may send fewer.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of channels to return on each page.
+     * Note: The service may send fewer.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannels` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannels` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannels` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannels` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannels` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannels` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + pageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannels` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannels` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListChannels` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListChannels` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + pageToken_ = value; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, channel_id`.
+     * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, channel_id`.
+     * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, channel_id`.
+     * 
+ * + * string order_by = 4; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + orderBy_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, channel_id`.
+     * 
+ * + * string order_by = 4; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + + orderBy_ = getDefaultInstance().getOrderBy(); + onChanged(); + return this; + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, channel_id`.
+     * 
+ * + * string order_by = 4; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + orderBy_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelsRequest) + private static final com.google.cloud.eventarc.v1.ListChannelsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelsRequest(); + } + + public static com.google.cloud.eventarc.v1.ListChannelsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java new file mode 100644 index 000000000000..b6babeddb2d0 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java @@ -0,0 +1,130 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListChannelsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent collection to list channels on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent collection to list channels on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of channels to return on each page.
+   * Note: The service may send fewer.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannels` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannels` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListChannels` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListChannels` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, channel_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, channel_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java new file mode 100644 index 000000000000..c28cfb2f01c6 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java @@ -0,0 +1,1380 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The response message for the `ListChannels` method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsResponse} + */ +public final class ListChannelsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelsResponse) + ListChannelsResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListChannelsResponse.newBuilder() to construct. + private ListChannelsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListChannelsResponse() { + channels_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListChannelsResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelsResponse.class, + com.google.cloud.eventarc.v1.ListChannelsResponse.Builder.class); + } + + public static final int CHANNELS_FIELD_NUMBER = 1; + private java.util.List channels_; + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + @java.lang.Override + public java.util.List getChannelsList() { + return channels_; + } + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + @java.lang.Override + public java.util.List + getChannelsOrBuilderList() { + return channels_; + } + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + @java.lang.Override + public int getChannelsCount() { + return channels_.size(); + } + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel getChannels(int index) { + return channels_.get(index); + } + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder(int index) { + return channels_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * A page token that can be sent to `ListChannels` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * A page token that can be sent to `ListChannels` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + private com.google.protobuf.LazyStringList unreachable_; + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < channels_.size(); i++) { + output.writeMessage(1, channels_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < channels_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, channels_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelsResponse)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListChannelsResponse other = + (com.google.cloud.eventarc.v1.ListChannelsResponse) obj; + + if (!getChannelsList().equals(other.getChannelsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getChannelsCount() > 0) { + hash = (37 * hash) + CHANNELS_FIELD_NUMBER; + hash = (53 * hash) + getChannelsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListChannelsResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The response message for the `ListChannels` method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelsResponse) + com.google.cloud.eventarc.v1.ListChannelsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListChannelsResponse.class, + com.google.cloud.eventarc.v1.ListChannelsResponse.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListChannelsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (channelsBuilder_ == null) { + channels_ = java.util.Collections.emptyList(); + } else { + channels_ = null; + channelsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsResponse getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListChannelsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsResponse build() { + com.google.cloud.eventarc.v1.ListChannelsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsResponse buildPartial() { + com.google.cloud.eventarc.v1.ListChannelsResponse result = + new com.google.cloud.eventarc.v1.ListChannelsResponse(this); + int from_bitField0_ = bitField0_; + if (channelsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + channels_ = java.util.Collections.unmodifiableList(channels_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.channels_ = channels_; + } else { + result.channels_ = channelsBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + if (((bitField0_ & 0x00000002) != 0)) { + unreachable_ = unreachable_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.unreachable_ = unreachable_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListChannelsResponse) { + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelsResponse other) { + if (other == com.google.cloud.eventarc.v1.ListChannelsResponse.getDefaultInstance()) + return this; + if (channelsBuilder_ == null) { + if (!other.channels_.isEmpty()) { + if (channels_.isEmpty()) { + channels_ = other.channels_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureChannelsIsMutable(); + channels_.addAll(other.channels_); + } + onChanged(); + } + } else { + if (!other.channels_.isEmpty()) { + if (channelsBuilder_.isEmpty()) { + channelsBuilder_.dispose(); + channelsBuilder_ = null; + channels_ = other.channels_; + bitField0_ = (bitField0_ & ~0x00000001); + channelsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getChannelsFieldBuilder() + : null; + } else { + channelsBuilder_.addAllMessages(other.channels_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.eventarc.v1.Channel m = + input.readMessage( + com.google.cloud.eventarc.v1.Channel.parser(), extensionRegistry); + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + channels_.add(m); + } else { + channelsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List channels_ = + java.util.Collections.emptyList(); + + private void ensureChannelsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + channels_ = new java.util.ArrayList(channels_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + channelsBuilder_; + + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public java.util.List getChannelsList() { + if (channelsBuilder_ == null) { + return java.util.Collections.unmodifiableList(channels_); + } else { + return channelsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public int getChannelsCount() { + if (channelsBuilder_ == null) { + return channels_.size(); + } else { + return channelsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public com.google.cloud.eventarc.v1.Channel getChannels(int index) { + if (channelsBuilder_ == null) { + return channels_.get(index); + } else { + return channelsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder setChannels(int index, com.google.cloud.eventarc.v1.Channel value) { + if (channelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureChannelsIsMutable(); + channels_.set(index, value); + onChanged(); + } else { + channelsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder setChannels( + int index, com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + channels_.set(index, builderForValue.build()); + onChanged(); + } else { + channelsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder addChannels(com.google.cloud.eventarc.v1.Channel value) { + if (channelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureChannelsIsMutable(); + channels_.add(value); + onChanged(); + } else { + channelsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder addChannels(int index, com.google.cloud.eventarc.v1.Channel value) { + if (channelsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureChannelsIsMutable(); + channels_.add(index, value); + onChanged(); + } else { + channelsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder addChannels(com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + channels_.add(builderForValue.build()); + onChanged(); + } else { + channelsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder addChannels( + int index, com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + channels_.add(index, builderForValue.build()); + onChanged(); + } else { + channelsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder addAllChannels( + java.lang.Iterable values) { + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, channels_); + onChanged(); + } else { + channelsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder clearChannels() { + if (channelsBuilder_ == null) { + channels_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + channelsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public Builder removeChannels(int index) { + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + channels_.remove(index); + onChanged(); + } else { + channelsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public com.google.cloud.eventarc.v1.Channel.Builder getChannelsBuilder(int index) { + return getChannelsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder(int index) { + if (channelsBuilder_ == null) { + return channels_.get(index); + } else { + return channelsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public java.util.List + getChannelsOrBuilderList() { + if (channelsBuilder_ != null) { + return channelsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(channels_); + } + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public com.google.cloud.eventarc.v1.Channel.Builder addChannelsBuilder() { + return getChannelsFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.Channel.getDefaultInstance()); + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public com.google.cloud.eventarc.v1.Channel.Builder addChannelsBuilder(int index) { + return getChannelsFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.Channel.getDefaultInstance()); + } + /** + * + * + *
+     * The requested channels, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + public java.util.List getChannelsBuilderList() { + return getChannelsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + getChannelsFieldBuilder() { + if (channelsBuilder_ == null) { + channelsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder>( + channels_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + channels_ = null; + } + return channelsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * A page token that can be sent to `ListChannels` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListChannels` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListChannels` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListChannels` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListChannels` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureUnreachableIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + bitField0_ |= 0x00000002; + } + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_.getUnmodifiableView(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelsResponse) + private static final com.google.cloud.eventarc.v1.ListChannelsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelsResponse(); + } + + public static com.google.cloud.eventarc.v1.ListChannelsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListChannelsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java new file mode 100644 index 000000000000..e6603219265a --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java @@ -0,0 +1,155 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListChannelsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + java.util.List getChannelsList(); + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + com.google.cloud.eventarc.v1.Channel getChannels(int index); + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + int getChannelsCount(); + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + java.util.List + getChannelsOrBuilderList(); + /** + * + * + *
+   * The requested channels, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Channel channels = 1; + */ + com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder(int index); + + /** + * + * + *
+   * A page token that can be sent to `ListChannels` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * A page token that can be sent to `ListChannels` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java new file mode 100644 index 000000000000..4c6d5278c66e --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java @@ -0,0 +1,1296 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the ListProviders method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersRequest} + */ +public final class ListProvidersRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListProvidersRequest) + ListProvidersRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListProvidersRequest.newBuilder() to construct. + private ListProvidersRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListProvidersRequest() { + parent_ = ""; + pageToken_ = ""; + orderBy_ = ""; + filter_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListProvidersRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListProvidersRequest.class, + com.google.cloud.eventarc.v1.ListProvidersRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent of the provider to get.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent of the provider to get.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of providers to return on each page.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListProviders` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListProviders` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListProviders` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListProviders` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 4; + private volatile java.lang.Object orderBy_; + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting oder is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, _id`.
+   * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting oder is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, _id`.
+   * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 5; + private volatile java.lang.Object filter_; + /** + * + * + *
+   * The filter field that the list request will filter on.
+   * 
+ * + * string filter = 5; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + /** + * + * + *
+   * The filter field that the list request will filter on.
+   * 
+ * + * string filter = 5; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, orderBy_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, filter_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, orderBy_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, filter_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListProvidersRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListProvidersRequest other = + (com.google.cloud.eventarc.v1.ListProvidersRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListProvidersRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the ListProviders method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListProvidersRequest) + com.google.cloud.eventarc.v1.ListProvidersRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListProvidersRequest.class, + com.google.cloud.eventarc.v1.ListProvidersRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListProvidersRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + orderBy_ = ""; + + filter_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListProvidersRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersRequest build() { + com.google.cloud.eventarc.v1.ListProvidersRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersRequest buildPartial() { + com.google.cloud.eventarc.v1.ListProvidersRequest result = + new com.google.cloud.eventarc.v1.ListProvidersRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + result.orderBy_ = orderBy_; + result.filter_ = filter_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListProvidersRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.ListProvidersRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListProvidersRequest other) { + if (other == com.google.cloud.eventarc.v1.ListProvidersRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + orderBy_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + filter_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent of the provider to get.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent of the provider to get.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent of the provider to get.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent of the provider to get.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent of the provider to get.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of providers to return on each page.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of providers to return on each page.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of providers to return on each page.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListProviders` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListProviders` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListProviders` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListProviders` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListProviders` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListProviders` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + pageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListProviders` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListProviders` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListProviders` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListProviders` must
+     * match the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + pageToken_ = value; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting oder is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, _id`.
+     * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting oder is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, _id`.
+     * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting oder is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, _id`.
+     * 
+ * + * string order_by = 4; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + orderBy_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting oder is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, _id`.
+     * 
+ * + * string order_by = 4; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + + orderBy_ = getDefaultInstance().getOrderBy(); + onChanged(); + return this; + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting oder is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, _id`.
+     * 
+ * + * string order_by = 4; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + orderBy_ = value; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + /** + * + * + *
+     * The filter field that the list request will filter on.
+     * 
+ * + * string filter = 5; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The filter field that the list request will filter on.
+     * 
+ * + * string filter = 5; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The filter field that the list request will filter on.
+     * 
+ * + * string filter = 5; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + filter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The filter field that the list request will filter on.
+     * 
+ * + * string filter = 5; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + + filter_ = getDefaultInstance().getFilter(); + onChanged(); + return this; + } + /** + * + * + *
+     * The filter field that the list request will filter on.
+     * 
+ * + * string filter = 5; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + filter_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListProvidersRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListProvidersRequest) + private static final com.google.cloud.eventarc.v1.ListProvidersRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListProvidersRequest(); + } + + public static com.google.cloud.eventarc.v1.ListProvidersRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListProvidersRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java new file mode 100644 index 000000000000..b385857b96bf --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java @@ -0,0 +1,154 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListProvidersRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListProvidersRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent of the provider to get.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent of the provider to get.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of providers to return on each page.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListProviders` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListProviders` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListProviders` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListProviders` must
+   * match the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting oder is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, _id`.
+   * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting oder is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, _id`.
+   * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); + + /** + * + * + *
+   * The filter field that the list request will filter on.
+   * 
+ * + * string filter = 5; + * + * @return The filter. + */ + java.lang.String getFilter(); + /** + * + * + *
+   * The filter field that the list request will filter on.
+   * 
+ * + * string filter = 5; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java new file mode 100644 index 000000000000..3b509801e9b8 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java @@ -0,0 +1,1380 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The response message for the `ListProviders` method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersResponse} + */ +public final class ListProvidersResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListProvidersResponse) + ListProvidersResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListProvidersResponse.newBuilder() to construct. + private ListProvidersResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListProvidersResponse() { + providers_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListProvidersResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListProvidersResponse.class, + com.google.cloud.eventarc.v1.ListProvidersResponse.Builder.class); + } + + public static final int PROVIDERS_FIELD_NUMBER = 1; + private java.util.List providers_; + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + @java.lang.Override + public java.util.List getProvidersList() { + return providers_; + } + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + @java.lang.Override + public java.util.List + getProvidersOrBuilderList() { + return providers_; + } + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + @java.lang.Override + public int getProvidersCount() { + return providers_.size(); + } + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Provider getProviders(int index) { + return providers_.get(index); + } + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder(int index) { + return providers_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * A page token that can be sent to `ListProviders` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * A page token that can be sent to `ListProviders` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + private com.google.protobuf.LazyStringList unreachable_; + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < providers_.size(); i++) { + output.writeMessage(1, providers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < providers_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, providers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListProvidersResponse)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListProvidersResponse other = + (com.google.cloud.eventarc.v1.ListProvidersResponse) obj; + + if (!getProvidersList().equals(other.getProvidersList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getProvidersCount() > 0) { + hash = (37 * hash) + PROVIDERS_FIELD_NUMBER; + hash = (53 * hash) + getProvidersList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListProvidersResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The response message for the `ListProviders` method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListProvidersResponse) + com.google.cloud.eventarc.v1.ListProvidersResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListProvidersResponse.class, + com.google.cloud.eventarc.v1.ListProvidersResponse.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListProvidersResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (providersBuilder_ == null) { + providers_ = java.util.Collections.emptyList(); + } else { + providers_ = null; + providersBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersResponse getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListProvidersResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersResponse build() { + com.google.cloud.eventarc.v1.ListProvidersResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersResponse buildPartial() { + com.google.cloud.eventarc.v1.ListProvidersResponse result = + new com.google.cloud.eventarc.v1.ListProvidersResponse(this); + int from_bitField0_ = bitField0_; + if (providersBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + providers_ = java.util.Collections.unmodifiableList(providers_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.providers_ = providers_; + } else { + result.providers_ = providersBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + if (((bitField0_ & 0x00000002) != 0)) { + unreachable_ = unreachable_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.unreachable_ = unreachable_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListProvidersResponse) { + return mergeFrom((com.google.cloud.eventarc.v1.ListProvidersResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListProvidersResponse other) { + if (other == com.google.cloud.eventarc.v1.ListProvidersResponse.getDefaultInstance()) + return this; + if (providersBuilder_ == null) { + if (!other.providers_.isEmpty()) { + if (providers_.isEmpty()) { + providers_ = other.providers_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureProvidersIsMutable(); + providers_.addAll(other.providers_); + } + onChanged(); + } + } else { + if (!other.providers_.isEmpty()) { + if (providersBuilder_.isEmpty()) { + providersBuilder_.dispose(); + providersBuilder_ = null; + providers_ = other.providers_; + bitField0_ = (bitField0_ & ~0x00000001); + providersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getProvidersFieldBuilder() + : null; + } else { + providersBuilder_.addAllMessages(other.providers_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.eventarc.v1.Provider m = + input.readMessage( + com.google.cloud.eventarc.v1.Provider.parser(), extensionRegistry); + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + providers_.add(m); + } else { + providersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List providers_ = + java.util.Collections.emptyList(); + + private void ensureProvidersIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + providers_ = new java.util.ArrayList(providers_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Provider, + com.google.cloud.eventarc.v1.Provider.Builder, + com.google.cloud.eventarc.v1.ProviderOrBuilder> + providersBuilder_; + + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public java.util.List getProvidersList() { + if (providersBuilder_ == null) { + return java.util.Collections.unmodifiableList(providers_); + } else { + return providersBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public int getProvidersCount() { + if (providersBuilder_ == null) { + return providers_.size(); + } else { + return providersBuilder_.getCount(); + } + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public com.google.cloud.eventarc.v1.Provider getProviders(int index) { + if (providersBuilder_ == null) { + return providers_.get(index); + } else { + return providersBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder setProviders(int index, com.google.cloud.eventarc.v1.Provider value) { + if (providersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureProvidersIsMutable(); + providers_.set(index, value); + onChanged(); + } else { + providersBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder setProviders( + int index, com.google.cloud.eventarc.v1.Provider.Builder builderForValue) { + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + providers_.set(index, builderForValue.build()); + onChanged(); + } else { + providersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder addProviders(com.google.cloud.eventarc.v1.Provider value) { + if (providersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureProvidersIsMutable(); + providers_.add(value); + onChanged(); + } else { + providersBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder addProviders(int index, com.google.cloud.eventarc.v1.Provider value) { + if (providersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureProvidersIsMutable(); + providers_.add(index, value); + onChanged(); + } else { + providersBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder addProviders(com.google.cloud.eventarc.v1.Provider.Builder builderForValue) { + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + providers_.add(builderForValue.build()); + onChanged(); + } else { + providersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder addProviders( + int index, com.google.cloud.eventarc.v1.Provider.Builder builderForValue) { + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + providers_.add(index, builderForValue.build()); + onChanged(); + } else { + providersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder addAllProviders( + java.lang.Iterable values) { + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, providers_); + onChanged(); + } else { + providersBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder clearProviders() { + if (providersBuilder_ == null) { + providers_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + providersBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public Builder removeProviders(int index) { + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + providers_.remove(index); + onChanged(); + } else { + providersBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public com.google.cloud.eventarc.v1.Provider.Builder getProvidersBuilder(int index) { + return getProvidersFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder(int index) { + if (providersBuilder_ == null) { + return providers_.get(index); + } else { + return providersBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public java.util.List + getProvidersOrBuilderList() { + if (providersBuilder_ != null) { + return providersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(providers_); + } + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public com.google.cloud.eventarc.v1.Provider.Builder addProvidersBuilder() { + return getProvidersFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.Provider.getDefaultInstance()); + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public com.google.cloud.eventarc.v1.Provider.Builder addProvidersBuilder(int index) { + return getProvidersFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.Provider.getDefaultInstance()); + } + /** + * + * + *
+     * The requested providers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + public java.util.List getProvidersBuilderList() { + return getProvidersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Provider, + com.google.cloud.eventarc.v1.Provider.Builder, + com.google.cloud.eventarc.v1.ProviderOrBuilder> + getProvidersFieldBuilder() { + if (providersBuilder_ == null) { + providersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Provider, + com.google.cloud.eventarc.v1.Provider.Builder, + com.google.cloud.eventarc.v1.ProviderOrBuilder>( + providers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + providers_ = null; + } + return providersBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * A page token that can be sent to `ListProviders` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListProviders` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListProviders` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListProviders` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListProviders` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureUnreachableIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + bitField0_ |= 0x00000002; + } + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_.getUnmodifiableView(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListProvidersResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListProvidersResponse) + private static final com.google.cloud.eventarc.v1.ListProvidersResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListProvidersResponse(); + } + + public static com.google.cloud.eventarc.v1.ListProvidersResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListProvidersResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListProvidersResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java new file mode 100644 index 000000000000..a067c8b22b51 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java @@ -0,0 +1,155 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListProvidersResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListProvidersResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + java.util.List getProvidersList(); + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + com.google.cloud.eventarc.v1.Provider getProviders(int index); + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + int getProvidersCount(); + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + java.util.List + getProvidersOrBuilderList(); + /** + * + * + *
+   * The requested providers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Provider providers = 1; + */ + com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder(int index); + + /** + * + * + *
+   * A page token that can be sent to `ListProviders` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * A page token that can be sent to `ListProviders` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java new file mode 100644 index 000000000000..f0dc3919db1f --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java @@ -0,0 +1,1314 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the ListTriggers method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersRequest} + */ +public final class ListTriggersRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListTriggersRequest) + ListTriggersRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListTriggersRequest.newBuilder() to construct. + private ListTriggersRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListTriggersRequest() { + parent_ = ""; + pageToken_ = ""; + orderBy_ = ""; + filter_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListTriggersRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListTriggersRequest.class, + com.google.cloud.eventarc.v1.ListTriggersRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The parent collection to list triggers on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + @java.lang.Override + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The parent collection to list triggers on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + @java.lang.Override + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of triggers to return on each page.
+   * Note: The service may send fewer.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListTriggers` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListTriggers` must match
+   * the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + @java.lang.Override + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } + } + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListTriggers` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListTriggers` must match
+   * the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ORDER_BY_FIELD_NUMBER = 4; + private volatile java.lang.Object orderBy_; + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, trigger_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + @java.lang.Override + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } + } + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, trigger_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + @java.lang.Override + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int FILTER_FIELD_NUMBER = 5; + private volatile java.lang.Object filter_; + /** + * + * + *
+   * Filter field. Used to filter the Triggers to be listed. Possible filters
+   * are described in https://google.aip.dev/160. For example, using
+   * "?filter=destination:gke" would list only Triggers with a gke destination.
+   * 
+ * + * string filter = 5; + * + * @return The filter. + */ + @java.lang.Override + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } + } + /** + * + * + *
+   * Filter field. Used to filter the Triggers to be listed. Possible filters
+   * are described in https://google.aip.dev/160. For example, using
+   * "?filter=destination:gke" would list only Triggers with a gke destination.
+   * 
+ * + * string filter = 5; + * + * @return The bytes for filter. + */ + @java.lang.Override + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, orderBy_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, filter_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, orderBy_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, filter_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListTriggersRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListTriggersRequest other = + (com.google.cloud.eventarc.v1.ListTriggersRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getFilter().equals(other.getFilter())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (37 * hash) + ORDER_BY_FIELD_NUMBER; + hash = (53 * hash) + getOrderBy().hashCode(); + hash = (37 * hash) + FILTER_FIELD_NUMBER; + hash = (53 * hash) + getFilter().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListTriggersRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the ListTriggers method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListTriggersRequest) + com.google.cloud.eventarc.v1.ListTriggersRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListTriggersRequest.class, + com.google.cloud.eventarc.v1.ListTriggersRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListTriggersRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + orderBy_ = ""; + + filter_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListTriggersRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersRequest build() { + com.google.cloud.eventarc.v1.ListTriggersRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersRequest buildPartial() { + com.google.cloud.eventarc.v1.ListTriggersRequest result = + new com.google.cloud.eventarc.v1.ListTriggersRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + result.orderBy_ = orderBy_; + result.filter_ = filter_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListTriggersRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.ListTriggersRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListTriggersRequest other) { + if (other == com.google.cloud.eventarc.v1.ListTriggersRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + if (!other.getOrderBy().isEmpty()) { + orderBy_ = other.orderBy_; + onChanged(); + } + if (!other.getFilter().isEmpty()) { + filter_ = other.filter_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + orderBy_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + filter_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The parent collection to list triggers on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + public java.lang.String getParent() { + java.lang.Object ref = parent_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + parent_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The parent collection to list triggers on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + public com.google.protobuf.ByteString getParentBytes() { + java.lang.Object ref = parent_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + parent_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The parent collection to list triggers on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The parent to set. + * @return This builder for chaining. + */ + public Builder setParent(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + parent_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection to list triggers on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The parent collection to list triggers on.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for parent to set. + * @return This builder for chaining. + */ + public Builder setParentBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + parent_ = value; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of triggers to return on each page.
+     * Note: The service may send fewer.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of triggers to return on each page.
+     * Note: The service may send fewer.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of triggers to return on each page.
+     * Note: The service may send fewer.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListTriggers` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListTriggers` must match
+     * the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + public java.lang.String getPageToken() { + java.lang.Object ref = pageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + pageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListTriggers` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListTriggers` must match
+     * the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListTriggers` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListTriggers` must match
+     * the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + pageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListTriggers` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListTriggers` must match
+     * the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The page token; provide the value from the `next_page_token` field in a
+     * previous `ListTriggers` call to retrieve the subsequent page.
+     * When paginating, all other parameters provided to `ListTriggers` must match
+     * the call that provided the page token.
+     * 
+ * + * string page_token = 3; + * + * @param value The bytes for pageToken to set. + * @return This builder for chaining. + */ + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + pageToken_ = value; + onChanged(); + return this; + } + + private java.lang.Object orderBy_ = ""; + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, trigger_id`.
+     * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + public java.lang.String getOrderBy() { + java.lang.Object ref = orderBy_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + orderBy_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, trigger_id`.
+     * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + public com.google.protobuf.ByteString getOrderByBytes() { + java.lang.Object ref = orderBy_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + orderBy_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, trigger_id`.
+     * 
+ * + * string order_by = 4; + * + * @param value The orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderBy(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + orderBy_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, trigger_id`.
+     * 
+ * + * string order_by = 4; + * + * @return This builder for chaining. + */ + public Builder clearOrderBy() { + + orderBy_ = getDefaultInstance().getOrderBy(); + onChanged(); + return this; + } + /** + * + * + *
+     * The sorting order of the resources returned. Value should be a
+     * comma-separated list of fields. The default sorting order is ascending. To
+     * specify descending order for a field, append a `desc` suffix; for example:
+     * `name desc, trigger_id`.
+     * 
+ * + * string order_by = 4; + * + * @param value The bytes for orderBy to set. + * @return This builder for chaining. + */ + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + orderBy_ = value; + onChanged(); + return this; + } + + private java.lang.Object filter_ = ""; + /** + * + * + *
+     * Filter field. Used to filter the Triggers to be listed. Possible filters
+     * are described in https://google.aip.dev/160. For example, using
+     * "?filter=destination:gke" would list only Triggers with a gke destination.
+     * 
+ * + * string filter = 5; + * + * @return The filter. + */ + public java.lang.String getFilter() { + java.lang.Object ref = filter_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + filter_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Filter field. Used to filter the Triggers to be listed. Possible filters
+     * are described in https://google.aip.dev/160. For example, using
+     * "?filter=destination:gke" would list only Triggers with a gke destination.
+     * 
+ * + * string filter = 5; + * + * @return The bytes for filter. + */ + public com.google.protobuf.ByteString getFilterBytes() { + java.lang.Object ref = filter_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + filter_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Filter field. Used to filter the Triggers to be listed. Possible filters
+     * are described in https://google.aip.dev/160. For example, using
+     * "?filter=destination:gke" would list only Triggers with a gke destination.
+     * 
+ * + * string filter = 5; + * + * @param value The filter to set. + * @return This builder for chaining. + */ + public Builder setFilter(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + filter_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Filter field. Used to filter the Triggers to be listed. Possible filters
+     * are described in https://google.aip.dev/160. For example, using
+     * "?filter=destination:gke" would list only Triggers with a gke destination.
+     * 
+ * + * string filter = 5; + * + * @return This builder for chaining. + */ + public Builder clearFilter() { + + filter_ = getDefaultInstance().getFilter(); + onChanged(); + return this; + } + /** + * + * + *
+     * Filter field. Used to filter the Triggers to be listed. Possible filters
+     * are described in https://google.aip.dev/160. For example, using
+     * "?filter=destination:gke" would list only Triggers with a gke destination.
+     * 
+ * + * string filter = 5; + * + * @param value The bytes for filter to set. + * @return This builder for chaining. + */ + public Builder setFilterBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + filter_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListTriggersRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListTriggersRequest) + private static final com.google.cloud.eventarc.v1.ListTriggersRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListTriggersRequest(); + } + + public static com.google.cloud.eventarc.v1.ListTriggersRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListTriggersRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java new file mode 100644 index 000000000000..50fb48a5666b --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java @@ -0,0 +1,159 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListTriggersRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListTriggersRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The parent collection to list triggers on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The parent collection to list triggers on.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of triggers to return on each page.
+   * Note: The service may send fewer.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListTriggers` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListTriggers` must match
+   * the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The page token; provide the value from the `next_page_token` field in a
+   * previous `ListTriggers` call to retrieve the subsequent page.
+   * When paginating, all other parameters provided to `ListTriggers` must match
+   * the call that provided the page token.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); + + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, trigger_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + /** + * + * + *
+   * The sorting order of the resources returned. Value should be a
+   * comma-separated list of fields. The default sorting order is ascending. To
+   * specify descending order for a field, append a `desc` suffix; for example:
+   * `name desc, trigger_id`.
+   * 
+ * + * string order_by = 4; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); + + /** + * + * + *
+   * Filter field. Used to filter the Triggers to be listed. Possible filters
+   * are described in https://google.aip.dev/160. For example, using
+   * "?filter=destination:gke" would list only Triggers with a gke destination.
+   * 
+ * + * string filter = 5; + * + * @return The filter. + */ + java.lang.String getFilter(); + /** + * + * + *
+   * Filter field. Used to filter the Triggers to be listed. Possible filters
+   * are described in https://google.aip.dev/160. For example, using
+   * "?filter=destination:gke" would list only Triggers with a gke destination.
+   * 
+ * + * string filter = 5; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java new file mode 100644 index 000000000000..c27d36a930a8 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java @@ -0,0 +1,1380 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The response message for the `ListTriggers` method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersResponse} + */ +public final class ListTriggersResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListTriggersResponse) + ListTriggersResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListTriggersResponse.newBuilder() to construct. + private ListTriggersResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListTriggersResponse() { + triggers_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListTriggersResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListTriggersResponse.class, + com.google.cloud.eventarc.v1.ListTriggersResponse.Builder.class); + } + + public static final int TRIGGERS_FIELD_NUMBER = 1; + private java.util.List triggers_; + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + @java.lang.Override + public java.util.List getTriggersList() { + return triggers_; + } + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + @java.lang.Override + public java.util.List + getTriggersOrBuilderList() { + return triggers_; + } + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + @java.lang.Override + public int getTriggersCount() { + return triggers_.size(); + } + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger getTriggers(int index) { + return triggers_.get(index); + } + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder(int index) { + return triggers_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * A page token that can be sent to `ListTriggers` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * A page token that can be sent to `ListTriggers` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UNREACHABLE_FIELD_NUMBER = 3; + private com.google.protobuf.LazyStringList unreachable_; + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_; + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < triggers_.size(); i++) { + output.writeMessage(1, triggers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachable_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, unreachable_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < triggers_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, triggers_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachable_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachable_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableList().size(); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.ListTriggersResponse)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.ListTriggersResponse other = + (com.google.cloud.eventarc.v1.ListTriggersResponse) obj; + + if (!getTriggersList().equals(other.getTriggersList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getTriggersCount() > 0) { + hash = (37 * hash) + TRIGGERS_FIELD_NUMBER; + hash = (53 * hash) + getTriggersList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableCount() > 0) { + hash = (37 * hash) + UNREACHABLE_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListTriggersResponse prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The response message for the `ListTriggers` method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListTriggersResponse) + com.google.cloud.eventarc.v1.ListTriggersResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.ListTriggersResponse.class, + com.google.cloud.eventarc.v1.ListTriggersResponse.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.ListTriggersResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (triggersBuilder_ == null) { + triggers_ = java.util.Collections.emptyList(); + } else { + triggers_ = null; + triggersBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersResponse getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.ListTriggersResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersResponse build() { + com.google.cloud.eventarc.v1.ListTriggersResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersResponse buildPartial() { + com.google.cloud.eventarc.v1.ListTriggersResponse result = + new com.google.cloud.eventarc.v1.ListTriggersResponse(this); + int from_bitField0_ = bitField0_; + if (triggersBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + triggers_ = java.util.Collections.unmodifiableList(triggers_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.triggers_ = triggers_; + } else { + result.triggers_ = triggersBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + if (((bitField0_ & 0x00000002) != 0)) { + unreachable_ = unreachable_.getUnmodifiableView(); + bitField0_ = (bitField0_ & ~0x00000002); + } + result.unreachable_ = unreachable_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.ListTriggersResponse) { + return mergeFrom((com.google.cloud.eventarc.v1.ListTriggersResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.ListTriggersResponse other) { + if (other == com.google.cloud.eventarc.v1.ListTriggersResponse.getDefaultInstance()) + return this; + if (triggersBuilder_ == null) { + if (!other.triggers_.isEmpty()) { + if (triggers_.isEmpty()) { + triggers_ = other.triggers_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureTriggersIsMutable(); + triggers_.addAll(other.triggers_); + } + onChanged(); + } + } else { + if (!other.triggers_.isEmpty()) { + if (triggersBuilder_.isEmpty()) { + triggersBuilder_.dispose(); + triggersBuilder_ = null; + triggers_ = other.triggers_; + bitField0_ = (bitField0_ & ~0x00000001); + triggersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getTriggersFieldBuilder() + : null; + } else { + triggersBuilder_.addAllMessages(other.triggers_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + if (!other.unreachable_.isEmpty()) { + if (unreachable_.isEmpty()) { + unreachable_ = other.unreachable_; + bitField0_ = (bitField0_ & ~0x00000002); + } else { + ensureUnreachableIsMutable(); + unreachable_.addAll(other.unreachable_); + } + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.eventarc.v1.Trigger m = + input.readMessage( + com.google.cloud.eventarc.v1.Trigger.parser(), extensionRegistry); + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.add(m); + } else { + triggersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.util.List triggers_ = + java.util.Collections.emptyList(); + + private void ensureTriggersIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + triggers_ = new java.util.ArrayList(triggers_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + triggersBuilder_; + + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public java.util.List getTriggersList() { + if (triggersBuilder_ == null) { + return java.util.Collections.unmodifiableList(triggers_); + } else { + return triggersBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public int getTriggersCount() { + if (triggersBuilder_ == null) { + return triggers_.size(); + } else { + return triggersBuilder_.getCount(); + } + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public com.google.cloud.eventarc.v1.Trigger getTriggers(int index) { + if (triggersBuilder_ == null) { + return triggers_.get(index); + } else { + return triggersBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder setTriggers(int index, com.google.cloud.eventarc.v1.Trigger value) { + if (triggersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTriggersIsMutable(); + triggers_.set(index, value); + onChanged(); + } else { + triggersBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder setTriggers( + int index, com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.set(index, builderForValue.build()); + onChanged(); + } else { + triggersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder addTriggers(com.google.cloud.eventarc.v1.Trigger value) { + if (triggersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTriggersIsMutable(); + triggers_.add(value); + onChanged(); + } else { + triggersBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder addTriggers(int index, com.google.cloud.eventarc.v1.Trigger value) { + if (triggersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTriggersIsMutable(); + triggers_.add(index, value); + onChanged(); + } else { + triggersBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder addTriggers(com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.add(builderForValue.build()); + onChanged(); + } else { + triggersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder addTriggers( + int index, com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.add(index, builderForValue.build()); + onChanged(); + } else { + triggersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder addAllTriggers( + java.lang.Iterable values) { + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, triggers_); + onChanged(); + } else { + triggersBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder clearTriggers() { + if (triggersBuilder_ == null) { + triggers_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + triggersBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public Builder removeTriggers(int index) { + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.remove(index); + onChanged(); + } else { + triggersBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public com.google.cloud.eventarc.v1.Trigger.Builder getTriggersBuilder(int index) { + return getTriggersFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder(int index) { + if (triggersBuilder_ == null) { + return triggers_.get(index); + } else { + return triggersBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public java.util.List + getTriggersOrBuilderList() { + if (triggersBuilder_ != null) { + return triggersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(triggers_); + } + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public com.google.cloud.eventarc.v1.Trigger.Builder addTriggersBuilder() { + return getTriggersFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()); + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public com.google.cloud.eventarc.v1.Trigger.Builder addTriggersBuilder(int index) { + return getTriggersFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()); + } + /** + * + * + *
+     * The requested triggers, up to the number specified in `page_size`.
+     * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + public java.util.List getTriggersBuilderList() { + return getTriggersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + getTriggersFieldBuilder() { + if (triggersBuilder_ == null) { + triggersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder>( + triggers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + triggers_ = null; + } + return triggersBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * A page token that can be sent to `ListTriggers` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListTriggers` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * A page token that can be sent to `ListTriggers` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListTriggers` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * A page token that can be sent to `ListTriggers` to request the next page.
+     * If this is empty, then there are no more pages.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + + private void ensureUnreachableIsMutable() { + if (!((bitField0_ & 0x00000002) != 0)) { + unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); + bitField0_ |= 0x00000002; + } + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + public com.google.protobuf.ProtocolStringList getUnreachableList() { + return unreachable_.getUnmodifiableView(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + public int getUnreachableCount() { + return unreachable_.size(); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + public java.lang.String getUnreachable(int index) { + return unreachable_.get(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + public com.google.protobuf.ByteString getUnreachableBytes(int index) { + return unreachable_.getByteString(index); + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param index The index to set the value at. + * @param value The unreachable to set. + * @return This builder for chaining. + */ + public Builder setUnreachable(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachable(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param values The unreachable to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachable(java.lang.Iterable values) { + ensureUnreachableIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachable() { + unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + /** + * + * + *
+     * Unreachable resources, if any.
+     * 
+ * + * repeated string unreachable = 3; + * + * @param value The bytes of the unreachable to add. + * @return This builder for chaining. + */ + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableIsMutable(); + unreachable_.add(value); + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListTriggersResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListTriggersResponse) + private static final com.google.cloud.eventarc.v1.ListTriggersResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListTriggersResponse(); + } + + public static com.google.cloud.eventarc.v1.ListTriggersResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListTriggersResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.ListTriggersResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java new file mode 100644 index 000000000000..25a658f80a87 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java @@ -0,0 +1,155 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface ListTriggersResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListTriggersResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + java.util.List getTriggersList(); + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + com.google.cloud.eventarc.v1.Trigger getTriggers(int index); + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + int getTriggersCount(); + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + java.util.List + getTriggersOrBuilderList(); + /** + * + * + *
+   * The requested triggers, up to the number specified in `page_size`.
+   * 
+ * + * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; + */ + com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder(int index); + + /** + * + * + *
+   * A page token that can be sent to `ListTriggers` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * A page token that can be sent to `ListTriggers` to request the next page.
+   * If this is empty, then there are no more pages.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); + + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return A list containing the unreachable. + */ + java.util.List getUnreachableList(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @return The count of unreachable. + */ + int getUnreachableCount(); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the element to return. + * @return The unreachable at the given index. + */ + java.lang.String getUnreachable(int index); + /** + * + * + *
+   * Unreachable resources, if any.
+   * 
+ * + * repeated string unreachable = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachable at the given index. + */ + com.google.protobuf.ByteString getUnreachableBytes(int index); +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java new file mode 100644 index 000000000000..6e0c99101512 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java @@ -0,0 +1,1806 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * Represents the metadata of the long-running operation.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.OperationMetadata} + */ +public final class OperationMetadata extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.OperationMetadata) + OperationMetadataOrBuilder { + private static final long serialVersionUID = 0L; + // Use OperationMetadata.newBuilder() to construct. + private OperationMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private OperationMetadata() { + target_ = ""; + verb_ = ""; + statusMessage_ = ""; + apiVersion_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new OperationMetadata(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.OperationMetadata.class, + com.google.cloud.eventarc.v1.OperationMetadata.Builder.class); + } + + public static final int CREATE_TIME_FIELD_NUMBER = 1; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+   * Output only. The time the operation was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+   * Output only. The time the operation was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+   * Output only. The time the operation was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int END_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp endTime_; + /** + * + * + *
+   * Output only. The time the operation finished running.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the endTime field is set. + */ + @java.lang.Override + public boolean hasEndTime() { + return endTime_ != null; + } + /** + * + * + *
+   * Output only. The time the operation finished running.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The endTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getEndTime() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + /** + * + * + *
+   * Output only. The time the operation finished running.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + return getEndTime(); + } + + public static final int TARGET_FIELD_NUMBER = 3; + private volatile java.lang.Object target_; + /** + * + * + *
+   * Output only. Server-defined resource path for the target of the operation.
+   * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + @java.lang.Override + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Server-defined resource path for the target of the operation.
+   * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VERB_FIELD_NUMBER = 4; + private volatile java.lang.Object verb_; + /** + * + * + *
+   * Output only. Name of the verb executed by the operation.
+   * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The verb. + */ + @java.lang.Override + public java.lang.String getVerb() { + java.lang.Object ref = verb_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + verb_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Name of the verb executed by the operation.
+   * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for verb. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVerbBytes() { + java.lang.Object ref = verb_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + verb_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATUS_MESSAGE_FIELD_NUMBER = 5; + private volatile java.lang.Object statusMessage_; + /** + * + * + *
+   * Output only. Human-readable status of the operation, if any.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + @java.lang.Override + public java.lang.String getStatusMessage() { + java.lang.Object ref = statusMessage_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + statusMessage_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Human-readable status of the operation, if any.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + @java.lang.Override + public com.google.protobuf.ByteString getStatusMessageBytes() { + java.lang.Object ref = statusMessage_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + statusMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REQUESTED_CANCELLATION_FIELD_NUMBER = 6; + private boolean requestedCancellation_; + /** + * + * + *
+   * Output only. Identifies whether the user has requested cancellation
+   * of the operation. Operations that have successfully been cancelled
+   * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
+   * corresponding to `Code.CANCELLED`.
+   * 
+ * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The requestedCancellation. + */ + @java.lang.Override + public boolean getRequestedCancellation() { + return requestedCancellation_; + } + + public static final int API_VERSION_FIELD_NUMBER = 7; + private volatile java.lang.Object apiVersion_; + /** + * + * + *
+   * Output only. API version used to start the operation.
+   * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The apiVersion. + */ + @java.lang.Override + public java.lang.String getApiVersion() { + java.lang.Object ref = apiVersion_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + apiVersion_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. API version used to start the operation.
+   * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for apiVersion. + */ + @java.lang.Override + public com.google.protobuf.ByteString getApiVersionBytes() { + java.lang.Object ref = apiVersion_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + apiVersion_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (createTime_ != null) { + output.writeMessage(1, getCreateTime()); + } + if (endTime_ != null) { + output.writeMessage(2, getEndTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(target_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, target_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(verb_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, verb_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(statusMessage_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, statusMessage_); + } + if (requestedCancellation_ != false) { + output.writeBool(6, requestedCancellation_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(apiVersion_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 7, apiVersion_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCreateTime()); + } + if (endTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getEndTime()); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(target_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, target_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(verb_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, verb_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(statusMessage_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, statusMessage_); + } + if (requestedCancellation_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, requestedCancellation_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(apiVersion_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, apiVersion_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.OperationMetadata)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.OperationMetadata other = + (com.google.cloud.eventarc.v1.OperationMetadata) obj; + + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasEndTime() != other.hasEndTime()) return false; + if (hasEndTime()) { + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (!getTarget().equals(other.getTarget())) return false; + if (!getVerb().equals(other.getVerb())) return false; + if (!getStatusMessage().equals(other.getStatusMessage())) return false; + if (getRequestedCancellation() != other.getRequestedCancellation()) return false; + if (!getApiVersion().equals(other.getApiVersion())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasEndTime()) { + hash = (37 * hash) + END_TIME_FIELD_NUMBER; + hash = (53 * hash) + getEndTime().hashCode(); + } + hash = (37 * hash) + TARGET_FIELD_NUMBER; + hash = (53 * hash) + getTarget().hashCode(); + hash = (37 * hash) + VERB_FIELD_NUMBER; + hash = (53 * hash) + getVerb().hashCode(); + hash = (37 * hash) + STATUS_MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getStatusMessage().hashCode(); + hash = (37 * hash) + REQUESTED_CANCELLATION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getRequestedCancellation()); + hash = (37 * hash) + API_VERSION_FIELD_NUMBER; + hash = (53 * hash) + getApiVersion().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.OperationMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Represents the metadata of the long-running operation.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.OperationMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.OperationMetadata) + com.google.cloud.eventarc.v1.OperationMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.OperationMetadata.class, + com.google.cloud.eventarc.v1.OperationMetadata.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.OperationMetadata.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (endTimeBuilder_ == null) { + endTime_ = null; + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + target_ = ""; + + verb_ = ""; + + statusMessage_ = ""; + + requestedCancellation_ = false; + + apiVersion_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.OperationMetadata getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.OperationMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.OperationMetadata build() { + com.google.cloud.eventarc.v1.OperationMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.OperationMetadata buildPartial() { + com.google.cloud.eventarc.v1.OperationMetadata result = + new com.google.cloud.eventarc.v1.OperationMetadata(this); + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (endTimeBuilder_ == null) { + result.endTime_ = endTime_; + } else { + result.endTime_ = endTimeBuilder_.build(); + } + result.target_ = target_; + result.verb_ = verb_; + result.statusMessage_ = statusMessage_; + result.requestedCancellation_ = requestedCancellation_; + result.apiVersion_ = apiVersion_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.OperationMetadata) { + return mergeFrom((com.google.cloud.eventarc.v1.OperationMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.OperationMetadata other) { + if (other == com.google.cloud.eventarc.v1.OperationMetadata.getDefaultInstance()) return this; + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasEndTime()) { + mergeEndTime(other.getEndTime()); + } + if (!other.getTarget().isEmpty()) { + target_ = other.target_; + onChanged(); + } + if (!other.getVerb().isEmpty()) { + verb_ = other.verb_; + onChanged(); + } + if (!other.getStatusMessage().isEmpty()) { + statusMessage_ = other.statusMessage_; + onChanged(); + } + if (other.getRequestedCancellation() != false) { + setRequestedCancellation(other.getRequestedCancellation()); + } + if (!other.getApiVersion().isEmpty()) { + apiVersion_ = other.apiVersion_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + target_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + verb_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + statusMessage_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 48: + { + requestedCancellation_ = input.readBool(); + + break; + } // case 48 + case 58: + { + apiVersion_ = input.readStringRequireUtf8(); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+     * Output only. The time the operation was created.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp endTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the endTime field is set. + */ + public boolean hasEndTime() { + return endTimeBuilder_ != null || endTime_ != null; + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The endTime. + */ + public com.google.protobuf.Timestamp getEndTime() { + if (endTimeBuilder_ == null) { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } else { + return endTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + endTime_ = value; + onChanged(); + } else { + endTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (endTimeBuilder_ == null) { + endTime_ = builderForValue.build(); + onChanged(); + } else { + endTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (endTime_ != null) { + endTime_ = + com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); + } else { + endTime_ = value; + } + onChanged(); + } else { + endTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearEndTime() { + if (endTimeBuilder_ == null) { + endTime_ = null; + onChanged(); + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { + + onChanged(); + return getEndTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + if (endTimeBuilder_ != null) { + return endTimeBuilder_.getMessageOrBuilder(); + } else { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + } + /** + * + * + *
+     * Output only. The time the operation finished running.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getEndTimeFieldBuilder() { + if (endTimeBuilder_ == null) { + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); + endTime_ = null; + } + return endTimeBuilder_; + } + + private java.lang.Object target_ = ""; + /** + * + * + *
+     * Output only. Server-defined resource path for the target of the operation.
+     * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + public java.lang.String getTarget() { + java.lang.Object ref = target_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + target_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Server-defined resource path for the target of the operation.
+     * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + public com.google.protobuf.ByteString getTargetBytes() { + java.lang.Object ref = target_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + target_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Server-defined resource path for the target of the operation.
+     * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The target to set. + * @return This builder for chaining. + */ + public Builder setTarget(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + target_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server-defined resource path for the target of the operation.
+     * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearTarget() { + + target_ = getDefaultInstance().getTarget(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server-defined resource path for the target of the operation.
+     * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for target to set. + * @return This builder for chaining. + */ + public Builder setTargetBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + target_ = value; + onChanged(); + return this; + } + + private java.lang.Object verb_ = ""; + /** + * + * + *
+     * Output only. Name of the verb executed by the operation.
+     * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The verb. + */ + public java.lang.String getVerb() { + java.lang.Object ref = verb_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + verb_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Name of the verb executed by the operation.
+     * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for verb. + */ + public com.google.protobuf.ByteString getVerbBytes() { + java.lang.Object ref = verb_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + verb_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Name of the verb executed by the operation.
+     * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The verb to set. + * @return This builder for chaining. + */ + public Builder setVerb(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + verb_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Name of the verb executed by the operation.
+     * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearVerb() { + + verb_ = getDefaultInstance().getVerb(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Name of the verb executed by the operation.
+     * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for verb to set. + * @return This builder for chaining. + */ + public Builder setVerbBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + verb_ = value; + onChanged(); + return this; + } + + private java.lang.Object statusMessage_ = ""; + /** + * + * + *
+     * Output only. Human-readable status of the operation, if any.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + public java.lang.String getStatusMessage() { + java.lang.Object ref = statusMessage_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + statusMessage_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Human-readable status of the operation, if any.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + public com.google.protobuf.ByteString getStatusMessageBytes() { + java.lang.Object ref = statusMessage_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + statusMessage_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Human-readable status of the operation, if any.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The statusMessage to set. + * @return This builder for chaining. + */ + public Builder setStatusMessage(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + statusMessage_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Human-readable status of the operation, if any.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearStatusMessage() { + + statusMessage_ = getDefaultInstance().getStatusMessage(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Human-readable status of the operation, if any.
+     * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for statusMessage to set. + * @return This builder for chaining. + */ + public Builder setStatusMessageBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + statusMessage_ = value; + onChanged(); + return this; + } + + private boolean requestedCancellation_; + /** + * + * + *
+     * Output only. Identifies whether the user has requested cancellation
+     * of the operation. Operations that have successfully been cancelled
+     * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
+     * corresponding to `Code.CANCELLED`.
+     * 
+ * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The requestedCancellation. + */ + @java.lang.Override + public boolean getRequestedCancellation() { + return requestedCancellation_; + } + /** + * + * + *
+     * Output only. Identifies whether the user has requested cancellation
+     * of the operation. Operations that have successfully been cancelled
+     * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
+     * corresponding to `Code.CANCELLED`.
+     * 
+ * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The requestedCancellation to set. + * @return This builder for chaining. + */ + public Builder setRequestedCancellation(boolean value) { + + requestedCancellation_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Identifies whether the user has requested cancellation
+     * of the operation. Operations that have successfully been cancelled
+     * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
+     * corresponding to `Code.CANCELLED`.
+     * 
+ * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearRequestedCancellation() { + + requestedCancellation_ = false; + onChanged(); + return this; + } + + private java.lang.Object apiVersion_ = ""; + /** + * + * + *
+     * Output only. API version used to start the operation.
+     * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The apiVersion. + */ + public java.lang.String getApiVersion() { + java.lang.Object ref = apiVersion_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + apiVersion_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. API version used to start the operation.
+     * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for apiVersion. + */ + public com.google.protobuf.ByteString getApiVersionBytes() { + java.lang.Object ref = apiVersion_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + apiVersion_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. API version used to start the operation.
+     * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The apiVersion to set. + * @return This builder for chaining. + */ + public Builder setApiVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + apiVersion_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. API version used to start the operation.
+     * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearApiVersion() { + + apiVersion_ = getDefaultInstance().getApiVersion(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. API version used to start the operation.
+     * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for apiVersion to set. + * @return This builder for chaining. + */ + public Builder setApiVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + apiVersion_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.OperationMetadata) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.OperationMetadata) + private static final com.google.cloud.eventarc.v1.OperationMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.OperationMetadata(); + } + + public static com.google.cloud.eventarc.v1.OperationMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public OperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.OperationMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java new file mode 100644 index 000000000000..891692ece878 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java @@ -0,0 +1,217 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface OperationMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.OperationMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Output only. The time the operation was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+   * Output only. The time the operation was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+   * Output only. The time the operation was created.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The time the operation finished running.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the endTime field is set. + */ + boolean hasEndTime(); + /** + * + * + *
+   * Output only. The time the operation finished running.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The endTime. + */ + com.google.protobuf.Timestamp getEndTime(); + /** + * + * + *
+   * Output only. The time the operation finished running.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Server-defined resource path for the target of the operation.
+   * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The target. + */ + java.lang.String getTarget(); + /** + * + * + *
+   * Output only. Server-defined resource path for the target of the operation.
+   * 
+ * + * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for target. + */ + com.google.protobuf.ByteString getTargetBytes(); + + /** + * + * + *
+   * Output only. Name of the verb executed by the operation.
+   * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The verb. + */ + java.lang.String getVerb(); + /** + * + * + *
+   * Output only. Name of the verb executed by the operation.
+   * 
+ * + * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for verb. + */ + com.google.protobuf.ByteString getVerbBytes(); + + /** + * + * + *
+   * Output only. Human-readable status of the operation, if any.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The statusMessage. + */ + java.lang.String getStatusMessage(); + /** + * + * + *
+   * Output only. Human-readable status of the operation, if any.
+   * 
+ * + * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for statusMessage. + */ + com.google.protobuf.ByteString getStatusMessageBytes(); + + /** + * + * + *
+   * Output only. Identifies whether the user has requested cancellation
+   * of the operation. Operations that have successfully been cancelled
+   * have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1,
+   * corresponding to `Code.CANCELLED`.
+   * 
+ * + * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The requestedCancellation. + */ + boolean getRequestedCancellation(); + + /** + * + * + *
+   * Output only. API version used to start the operation.
+   * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The apiVersion. + */ + java.lang.String getApiVersion(); + /** + * + * + *
+   * Output only. API version used to start the operation.
+   * 
+ * + * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for apiVersion. + */ + com.google.protobuf.ByteString getApiVersionBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java new file mode 100644 index 000000000000..e9ce9f21c96d --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java @@ -0,0 +1,1332 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A representation of the Provider resource.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Provider} + */ +public final class Provider extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Provider) + ProviderOrBuilder { + private static final long serialVersionUID = 0L; + // Use Provider.newBuilder() to construct. + private Provider(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Provider() { + name_ = ""; + displayName_ = ""; + eventTypes_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Provider(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Provider.class, + com.google.cloud.eventarc.v1.Provider.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+   * format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+   * format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object displayName_; + /** + * + * + *
+   * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int EVENT_TYPES_FIELD_NUMBER = 3; + private java.util.List eventTypes_; + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List getEventTypesList() { + return eventTypes_; + } + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getEventTypesOrBuilderList() { + return eventTypes_; + } + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public int getEventTypesCount() { + return eventTypes_.size(); + } + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.EventType getEventTypes(int index) { + return eventTypes_.get(index); + } + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder(int index) { + return eventTypes_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); + } + for (int i = 0; i < eventTypes_.size(); i++) { + output.writeMessage(3, eventTypes_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); + } + for (int i = 0; i < eventTypes_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, eventTypes_.get(i)); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.Provider)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.Provider other = (com.google.cloud.eventarc.v1.Provider) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getEventTypesList().equals(other.getEventTypesList())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + if (getEventTypesCount() > 0) { + hash = (37 * hash) + EVENT_TYPES_FIELD_NUMBER; + hash = (53 * hash) + getEventTypesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Provider parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Provider parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Provider parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.Provider prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A representation of the Provider resource.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Provider} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Provider) + com.google.cloud.eventarc.v1.ProviderOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Provider.class, + com.google.cloud.eventarc.v1.Provider.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.Provider.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + displayName_ = ""; + + if (eventTypesBuilder_ == null) { + eventTypes_ = java.util.Collections.emptyList(); + } else { + eventTypes_ = null; + eventTypesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Provider getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.Provider.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Provider build() { + com.google.cloud.eventarc.v1.Provider result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Provider buildPartial() { + com.google.cloud.eventarc.v1.Provider result = + new com.google.cloud.eventarc.v1.Provider(this); + int from_bitField0_ = bitField0_; + result.name_ = name_; + result.displayName_ = displayName_; + if (eventTypesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + eventTypes_ = java.util.Collections.unmodifiableList(eventTypes_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.eventTypes_ = eventTypes_; + } else { + result.eventTypes_ = eventTypesBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.Provider) { + return mergeFrom((com.google.cloud.eventarc.v1.Provider) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.Provider other) { + if (other == com.google.cloud.eventarc.v1.Provider.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + onChanged(); + } + if (eventTypesBuilder_ == null) { + if (!other.eventTypes_.isEmpty()) { + if (eventTypes_.isEmpty()) { + eventTypes_ = other.eventTypes_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureEventTypesIsMutable(); + eventTypes_.addAll(other.eventTypes_); + } + onChanged(); + } + } else { + if (!other.eventTypes_.isEmpty()) { + if (eventTypesBuilder_.isEmpty()) { + eventTypesBuilder_.dispose(); + eventTypesBuilder_ = null; + eventTypes_ = other.eventTypes_; + bitField0_ = (bitField0_ & ~0x00000001); + eventTypesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getEventTypesFieldBuilder() + : null; + } else { + eventTypesBuilder_.addAllMessages(other.eventTypes_); + } + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + com.google.cloud.eventarc.v1.EventType m = + input.readMessage( + com.google.cloud.eventarc.v1.EventType.parser(), extensionRegistry); + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + eventTypes_.add(m); + } else { + eventTypesBuilder_.addMessage(m); + } + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+     * format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+     * format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+     * format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+     * format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+     * format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + /** + * + * + *
+     * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + displayName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + + displayName_ = getDefaultInstance().getDisplayName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + displayName_ = value; + onChanged(); + return this; + } + + private java.util.List eventTypes_ = + java.util.Collections.emptyList(); + + private void ensureEventTypesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + eventTypes_ = new java.util.ArrayList(eventTypes_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventType, + com.google.cloud.eventarc.v1.EventType.Builder, + com.google.cloud.eventarc.v1.EventTypeOrBuilder> + eventTypesBuilder_; + + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List getEventTypesList() { + if (eventTypesBuilder_ == null) { + return java.util.Collections.unmodifiableList(eventTypes_); + } else { + return eventTypesBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public int getEventTypesCount() { + if (eventTypesBuilder_ == null) { + return eventTypes_.size(); + } else { + return eventTypesBuilder_.getCount(); + } + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.EventType getEventTypes(int index) { + if (eventTypesBuilder_ == null) { + return eventTypes_.get(index); + } else { + return eventTypesBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setEventTypes(int index, com.google.cloud.eventarc.v1.EventType value) { + if (eventTypesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEventTypesIsMutable(); + eventTypes_.set(index, value); + onChanged(); + } else { + eventTypesBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setEventTypes( + int index, com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + eventTypes_.set(index, builderForValue.build()); + onChanged(); + } else { + eventTypesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addEventTypes(com.google.cloud.eventarc.v1.EventType value) { + if (eventTypesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEventTypesIsMutable(); + eventTypes_.add(value); + onChanged(); + } else { + eventTypesBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addEventTypes(int index, com.google.cloud.eventarc.v1.EventType value) { + if (eventTypesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEventTypesIsMutable(); + eventTypes_.add(index, value); + onChanged(); + } else { + eventTypesBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addEventTypes(com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + eventTypes_.add(builderForValue.build()); + onChanged(); + } else { + eventTypesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addEventTypes( + int index, com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + eventTypes_.add(index, builderForValue.build()); + onChanged(); + } else { + eventTypesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAllEventTypes( + java.lang.Iterable values) { + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, eventTypes_); + onChanged(); + } else { + eventTypesBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearEventTypes() { + if (eventTypesBuilder_ == null) { + eventTypes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + eventTypesBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeEventTypes(int index) { + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + eventTypes_.remove(index); + onChanged(); + } else { + eventTypesBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.EventType.Builder getEventTypesBuilder(int index) { + return getEventTypesFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder(int index) { + if (eventTypesBuilder_ == null) { + return eventTypes_.get(index); + } else { + return eventTypesBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getEventTypesOrBuilderList() { + if (eventTypesBuilder_ != null) { + return eventTypesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(eventTypes_); + } + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.EventType.Builder addEventTypesBuilder() { + return getEventTypesFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.EventType.getDefaultInstance()); + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.eventarc.v1.EventType.Builder addEventTypesBuilder(int index) { + return getEventTypesFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.EventType.getDefaultInstance()); + } + /** + * + * + *
+     * Output only. Event types for this provider.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getEventTypesBuilderList() { + return getEventTypesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventType, + com.google.cloud.eventarc.v1.EventType.Builder, + com.google.cloud.eventarc.v1.EventTypeOrBuilder> + getEventTypesFieldBuilder() { + if (eventTypesBuilder_ == null) { + eventTypesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventType, + com.google.cloud.eventarc.v1.EventType.Builder, + com.google.cloud.eventarc.v1.EventTypeOrBuilder>( + eventTypes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + eventTypes_ = null; + } + return eventTypesBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Provider) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Provider) + private static final com.google.cloud.eventarc.v1.Provider DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Provider(); + } + + public static com.google.cloud.eventarc.v1.Provider getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Provider parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Provider getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java new file mode 100644 index 000000000000..5a9200c102d7 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java @@ -0,0 +1,139 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +public interface ProviderOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Provider) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+   * format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
+   * format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + /** + * + * + *
+   * Output only. Human friendly name for the Provider. For example "Cloud Storage".
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List getEventTypesList(); + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.eventarc.v1.EventType getEventTypes(int index); + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getEventTypesCount(); + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List + getEventTypesOrBuilderList(); + /** + * + * + *
+   * Output only. Event types for this provider.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder(int index); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java new file mode 100644 index 000000000000..44db1804cedd --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java @@ -0,0 +1,838 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * Represents a Pub/Sub transport.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Pubsub} + */ +public final class Pubsub extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Pubsub) + PubsubOrBuilder { + private static final long serialVersionUID = 0L; + // Use Pubsub.newBuilder() to construct. + private Pubsub(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Pubsub() { + topic_ = ""; + subscription_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Pubsub(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Pubsub.class, + com.google.cloud.eventarc.v1.Pubsub.Builder.class); + } + + public static final int TOPIC_FIELD_NUMBER = 1; + private volatile java.lang.Object topic_; + /** + * + * + *
+   * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+   * a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+   * You can set an existing topic for triggers of the type
+   * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+   * here is not deleted by Eventarc at trigger deletion.
+   * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topic. + */ + @java.lang.Override + public java.lang.String getTopic() { + java.lang.Object ref = topic_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + topic_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+   * a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+   * You can set an existing topic for triggers of the type
+   * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+   * here is not deleted by Eventarc at trigger deletion.
+   * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for topic. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTopicBytes() { + java.lang.Object ref = topic_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + topic_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int SUBSCRIPTION_FIELD_NUMBER = 2; + private volatile java.lang.Object subscription_; + /** + * + * + *
+   * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+   * as a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+   * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The subscription. + */ + @java.lang.Override + public java.lang.String getSubscription() { + java.lang.Object ref = subscription_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subscription_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+   * as a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+   * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for subscription. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSubscriptionBytes() { + java.lang.Object ref = subscription_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subscription_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(topic_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, topic_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subscription_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, subscription_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(topic_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, topic_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subscription_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, subscription_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.Pubsub)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.Pubsub other = (com.google.cloud.eventarc.v1.Pubsub) obj; + + if (!getTopic().equals(other.getTopic())) return false; + if (!getSubscription().equals(other.getSubscription())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + TOPIC_FIELD_NUMBER; + hash = (53 * hash) + getTopic().hashCode(); + hash = (37 * hash) + SUBSCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getSubscription().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.Pubsub prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Represents a Pub/Sub transport.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Pubsub} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Pubsub) + com.google.cloud.eventarc.v1.PubsubOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Pubsub.class, + com.google.cloud.eventarc.v1.Pubsub.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.Pubsub.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + topic_ = ""; + + subscription_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Pubsub getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Pubsub build() { + com.google.cloud.eventarc.v1.Pubsub result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Pubsub buildPartial() { + com.google.cloud.eventarc.v1.Pubsub result = new com.google.cloud.eventarc.v1.Pubsub(this); + result.topic_ = topic_; + result.subscription_ = subscription_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.Pubsub) { + return mergeFrom((com.google.cloud.eventarc.v1.Pubsub) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.Pubsub other) { + if (other == com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance()) return this; + if (!other.getTopic().isEmpty()) { + topic_ = other.topic_; + onChanged(); + } + if (!other.getSubscription().isEmpty()) { + subscription_ = other.subscription_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + topic_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + subscription_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object topic_ = ""; + /** + * + * + *
+     * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+     * a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+     * You can set an existing topic for triggers of the type
+     * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+     * here is not deleted by Eventarc at trigger deletion.
+     * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topic. + */ + public java.lang.String getTopic() { + java.lang.Object ref = topic_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + topic_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+     * a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+     * You can set an existing topic for triggers of the type
+     * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+     * here is not deleted by Eventarc at trigger deletion.
+     * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for topic. + */ + public com.google.protobuf.ByteString getTopicBytes() { + java.lang.Object ref = topic_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + topic_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+     * a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+     * You can set an existing topic for triggers of the type
+     * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+     * here is not deleted by Eventarc at trigger deletion.
+     * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The topic to set. + * @return This builder for chaining. + */ + public Builder setTopic(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + topic_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+     * a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+     * You can set an existing topic for triggers of the type
+     * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+     * here is not deleted by Eventarc at trigger deletion.
+     * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearTopic() { + + topic_ = getDefaultInstance().getTopic(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+     * a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+     * You can set an existing topic for triggers of the type
+     * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+     * here is not deleted by Eventarc at trigger deletion.
+     * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for topic to set. + * @return This builder for chaining. + */ + public Builder setTopicBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + topic_ = value; + onChanged(); + return this; + } + + private java.lang.Object subscription_ = ""; + /** + * + * + *
+     * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+     * as a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+     * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The subscription. + */ + public java.lang.String getSubscription() { + java.lang.Object ref = subscription_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + subscription_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+     * as a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+     * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for subscription. + */ + public com.google.protobuf.ByteString getSubscriptionBytes() { + java.lang.Object ref = subscription_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + subscription_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+     * as a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+     * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The subscription to set. + * @return This builder for chaining. + */ + public Builder setSubscription(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + subscription_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+     * as a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+     * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSubscription() { + + subscription_ = getDefaultInstance().getSubscription(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+     * as a transport for the event delivery. Format:
+     * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+     * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for subscription to set. + * @return This builder for chaining. + */ + public Builder setSubscriptionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + subscription_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Pubsub) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Pubsub) + private static final com.google.cloud.eventarc.v1.Pubsub DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Pubsub(); + } + + public static com.google.cloud.eventarc.v1.Pubsub getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Pubsub parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Pubsub getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java new file mode 100644 index 000000000000..54553b1ec298 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java @@ -0,0 +1,89 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface PubsubOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Pubsub) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+   * a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+   * You can set an existing topic for triggers of the type
+   * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+   * here is not deleted by Eventarc at trigger deletion.
+   * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topic. + */ + java.lang.String getTopic(); + /** + * + * + *
+   * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
+   * a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`.
+   * You can set an existing topic for triggers of the type
+   * `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide
+   * here is not deleted by Eventarc at trigger deletion.
+   * 
+ * + * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for topic. + */ + com.google.protobuf.ByteString getTopicBytes(); + + /** + * + * + *
+   * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+   * as a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+   * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The subscription. + */ + java.lang.String getSubscription(); + /** + * + * + *
+   * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
+   * as a transport for the event delivery. Format:
+   * `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`.
+   * 
+ * + * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for subscription. + */ + com.google.protobuf.ByteString getSubscriptionBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java new file mode 100644 index 000000000000..f1b6ba3671e3 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java @@ -0,0 +1,761 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A condition that is part of the trigger state computation.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.StateCondition} + */ +public final class StateCondition extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.StateCondition) + StateConditionOrBuilder { + private static final long serialVersionUID = 0L; + // Use StateCondition.newBuilder() to construct. + private StateCondition(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private StateCondition() { + code_ = 0; + message_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StateCondition(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.StateCondition.class, + com.google.cloud.eventarc.v1.StateCondition.Builder.class); + } + + public static final int CODE_FIELD_NUMBER = 1; + private int code_; + /** + * + * + *
+   * The canonical code of the condition.
+   * 
+ * + * .google.rpc.Code code = 1; + * + * @return The enum numeric value on the wire for code. + */ + @java.lang.Override + public int getCodeValue() { + return code_; + } + /** + * + * + *
+   * The canonical code of the condition.
+   * 
+ * + * .google.rpc.Code code = 1; + * + * @return The code. + */ + @java.lang.Override + public com.google.rpc.Code getCode() { + @SuppressWarnings("deprecation") + com.google.rpc.Code result = com.google.rpc.Code.valueOf(code_); + return result == null ? com.google.rpc.Code.UNRECOGNIZED : result; + } + + public static final int MESSAGE_FIELD_NUMBER = 2; + private volatile java.lang.Object message_; + /** + * + * + *
+   * Human-readable message.
+   * 
+ * + * string message = 2; + * + * @return The message. + */ + @java.lang.Override + public java.lang.String getMessage() { + java.lang.Object ref = message_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + message_ = s; + return s; + } + } + /** + * + * + *
+   * Human-readable message.
+   * 
+ * + * string message = 2; + * + * @return The bytes for message. + */ + @java.lang.Override + public com.google.protobuf.ByteString getMessageBytes() { + java.lang.Object ref = message_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + message_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (code_ != com.google.rpc.Code.OK.getNumber()) { + output.writeEnum(1, code_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, message_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (code_ != com.google.rpc.Code.OK.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, code_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.StateCondition)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.StateCondition other = + (com.google.cloud.eventarc.v1.StateCondition) obj; + + if (code_ != other.code_) return false; + if (!getMessage().equals(other.getMessage())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + CODE_FIELD_NUMBER; + hash = (53 * hash) + code_; + hash = (37 * hash) + MESSAGE_FIELD_NUMBER; + hash = (53 * hash) + getMessage().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.StateCondition prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A condition that is part of the trigger state computation.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.StateCondition} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.StateCondition) + com.google.cloud.eventarc.v1.StateConditionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.StateCondition.class, + com.google.cloud.eventarc.v1.StateCondition.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.StateCondition.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + code_ = 0; + + message_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.StateCondition.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition build() { + com.google.cloud.eventarc.v1.StateCondition result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition buildPartial() { + com.google.cloud.eventarc.v1.StateCondition result = + new com.google.cloud.eventarc.v1.StateCondition(this); + result.code_ = code_; + result.message_ = message_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.StateCondition) { + return mergeFrom((com.google.cloud.eventarc.v1.StateCondition) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.StateCondition other) { + if (other == com.google.cloud.eventarc.v1.StateCondition.getDefaultInstance()) return this; + if (other.code_ != 0) { + setCodeValue(other.getCodeValue()); + } + if (!other.getMessage().isEmpty()) { + message_ = other.message_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + code_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + message_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int code_ = 0; + /** + * + * + *
+     * The canonical code of the condition.
+     * 
+ * + * .google.rpc.Code code = 1; + * + * @return The enum numeric value on the wire for code. + */ + @java.lang.Override + public int getCodeValue() { + return code_; + } + /** + * + * + *
+     * The canonical code of the condition.
+     * 
+ * + * .google.rpc.Code code = 1; + * + * @param value The enum numeric value on the wire for code to set. + * @return This builder for chaining. + */ + public Builder setCodeValue(int value) { + + code_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The canonical code of the condition.
+     * 
+ * + * .google.rpc.Code code = 1; + * + * @return The code. + */ + @java.lang.Override + public com.google.rpc.Code getCode() { + @SuppressWarnings("deprecation") + com.google.rpc.Code result = com.google.rpc.Code.valueOf(code_); + return result == null ? com.google.rpc.Code.UNRECOGNIZED : result; + } + /** + * + * + *
+     * The canonical code of the condition.
+     * 
+ * + * .google.rpc.Code code = 1; + * + * @param value The code to set. + * @return This builder for chaining. + */ + public Builder setCode(com.google.rpc.Code value) { + if (value == null) { + throw new NullPointerException(); + } + + code_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The canonical code of the condition.
+     * 
+ * + * .google.rpc.Code code = 1; + * + * @return This builder for chaining. + */ + public Builder clearCode() { + + code_ = 0; + onChanged(); + return this; + } + + private java.lang.Object message_ = ""; + /** + * + * + *
+     * Human-readable message.
+     * 
+ * + * string message = 2; + * + * @return The message. + */ + public java.lang.String getMessage() { + java.lang.Object ref = message_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + message_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Human-readable message.
+     * 
+ * + * string message = 2; + * + * @return The bytes for message. + */ + public com.google.protobuf.ByteString getMessageBytes() { + java.lang.Object ref = message_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + message_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Human-readable message.
+     * 
+ * + * string message = 2; + * + * @param value The message to set. + * @return This builder for chaining. + */ + public Builder setMessage(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + message_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Human-readable message.
+     * 
+ * + * string message = 2; + * + * @return This builder for chaining. + */ + public Builder clearMessage() { + + message_ = getDefaultInstance().getMessage(); + onChanged(); + return this; + } + /** + * + * + *
+     * Human-readable message.
+     * 
+ * + * string message = 2; + * + * @param value The bytes for message to set. + * @return This builder for chaining. + */ + public Builder setMessageBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + message_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.StateCondition) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.StateCondition) + private static final com.google.cloud.eventarc.v1.StateCondition DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.StateCondition(); + } + + public static com.google.cloud.eventarc.v1.StateCondition getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StateCondition parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java new file mode 100644 index 000000000000..f99922fa22f0 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java @@ -0,0 +1,75 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface StateConditionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.StateCondition) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The canonical code of the condition.
+   * 
+ * + * .google.rpc.Code code = 1; + * + * @return The enum numeric value on the wire for code. + */ + int getCodeValue(); + /** + * + * + *
+   * The canonical code of the condition.
+   * 
+ * + * .google.rpc.Code code = 1; + * + * @return The code. + */ + com.google.rpc.Code getCode(); + + /** + * + * + *
+   * Human-readable message.
+   * 
+ * + * string message = 2; + * + * @return The message. + */ + java.lang.String getMessage(); + /** + * + * + *
+   * Human-readable message.
+   * 
+ * + * string message = 2; + * + * @return The bytes for message. + */ + com.google.protobuf.ByteString getMessageBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java new file mode 100644 index 000000000000..b4d20bedf709 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java @@ -0,0 +1,820 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * Represents the transport intermediaries created for the trigger to
+ * deliver events.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Transport} + */ +public final class Transport extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Transport) + TransportOrBuilder { + private static final long serialVersionUID = 0L; + // Use Transport.newBuilder() to construct. + private Transport(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Transport() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Transport(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Transport_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Transport.class, + com.google.cloud.eventarc.v1.Transport.Builder.class); + } + + private int intermediaryCase_ = 0; + private java.lang.Object intermediary_; + + public enum IntermediaryCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + PUBSUB(1), + INTERMEDIARY_NOT_SET(0); + private final int value; + + private IntermediaryCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static IntermediaryCase valueOf(int value) { + return forNumber(value); + } + + public static IntermediaryCase forNumber(int value) { + switch (value) { + case 1: + return PUBSUB; + case 0: + return INTERMEDIARY_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public IntermediaryCase getIntermediaryCase() { + return IntermediaryCase.forNumber(intermediaryCase_); + } + + public static final int PUBSUB_FIELD_NUMBER = 1; + /** + * + * + *
+   * The Pub/Sub topic and subscription used by Eventarc as a transport
+   * intermediary.
+   * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * + * @return Whether the pubsub field is set. + */ + @java.lang.Override + public boolean hasPubsub() { + return intermediaryCase_ == 1; + } + /** + * + * + *
+   * The Pub/Sub topic and subscription used by Eventarc as a transport
+   * intermediary.
+   * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * + * @return The pubsub. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Pubsub getPubsub() { + if (intermediaryCase_ == 1) { + return (com.google.cloud.eventarc.v1.Pubsub) intermediary_; + } + return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } + /** + * + * + *
+   * The Pub/Sub topic and subscription used by Eventarc as a transport
+   * intermediary.
+   * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.PubsubOrBuilder getPubsubOrBuilder() { + if (intermediaryCase_ == 1) { + return (com.google.cloud.eventarc.v1.Pubsub) intermediary_; + } + return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (intermediaryCase_ == 1) { + output.writeMessage(1, (com.google.cloud.eventarc.v1.Pubsub) intermediary_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (intermediaryCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.eventarc.v1.Pubsub) intermediary_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.Transport)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.Transport other = (com.google.cloud.eventarc.v1.Transport) obj; + + if (!getIntermediaryCase().equals(other.getIntermediaryCase())) return false; + switch (intermediaryCase_) { + case 1: + if (!getPubsub().equals(other.getPubsub())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (intermediaryCase_) { + case 1: + hash = (37 * hash) + PUBSUB_FIELD_NUMBER; + hash = (53 * hash) + getPubsub().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Transport parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Transport parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Transport parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.Transport prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Represents the transport intermediaries created for the trigger to
+   * deliver events.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Transport} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Transport) + com.google.cloud.eventarc.v1.TransportOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Transport_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Transport.class, + com.google.cloud.eventarc.v1.Transport.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.Transport.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (pubsubBuilder_ != null) { + pubsubBuilder_.clear(); + } + intermediaryCase_ = 0; + intermediary_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Transport_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Transport getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.Transport.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Transport build() { + com.google.cloud.eventarc.v1.Transport result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Transport buildPartial() { + com.google.cloud.eventarc.v1.Transport result = + new com.google.cloud.eventarc.v1.Transport(this); + if (intermediaryCase_ == 1) { + if (pubsubBuilder_ == null) { + result.intermediary_ = intermediary_; + } else { + result.intermediary_ = pubsubBuilder_.build(); + } + } + result.intermediaryCase_ = intermediaryCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.Transport) { + return mergeFrom((com.google.cloud.eventarc.v1.Transport) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.Transport other) { + if (other == com.google.cloud.eventarc.v1.Transport.getDefaultInstance()) return this; + switch (other.getIntermediaryCase()) { + case PUBSUB: + { + mergePubsub(other.getPubsub()); + break; + } + case INTERMEDIARY_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getPubsubFieldBuilder().getBuilder(), extensionRegistry); + intermediaryCase_ = 1; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int intermediaryCase_ = 0; + private java.lang.Object intermediary_; + + public IntermediaryCase getIntermediaryCase() { + return IntermediaryCase.forNumber(intermediaryCase_); + } + + public Builder clearIntermediary() { + intermediaryCase_ = 0; + intermediary_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Pubsub, + com.google.cloud.eventarc.v1.Pubsub.Builder, + com.google.cloud.eventarc.v1.PubsubOrBuilder> + pubsubBuilder_; + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * + * @return Whether the pubsub field is set. + */ + @java.lang.Override + public boolean hasPubsub() { + return intermediaryCase_ == 1; + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * + * @return The pubsub. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Pubsub getPubsub() { + if (pubsubBuilder_ == null) { + if (intermediaryCase_ == 1) { + return (com.google.cloud.eventarc.v1.Pubsub) intermediary_; + } + return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } else { + if (intermediaryCase_ == 1) { + return pubsubBuilder_.getMessage(); + } + return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + public Builder setPubsub(com.google.cloud.eventarc.v1.Pubsub value) { + if (pubsubBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + intermediary_ = value; + onChanged(); + } else { + pubsubBuilder_.setMessage(value); + } + intermediaryCase_ = 1; + return this; + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + public Builder setPubsub(com.google.cloud.eventarc.v1.Pubsub.Builder builderForValue) { + if (pubsubBuilder_ == null) { + intermediary_ = builderForValue.build(); + onChanged(); + } else { + pubsubBuilder_.setMessage(builderForValue.build()); + } + intermediaryCase_ = 1; + return this; + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + public Builder mergePubsub(com.google.cloud.eventarc.v1.Pubsub value) { + if (pubsubBuilder_ == null) { + if (intermediaryCase_ == 1 + && intermediary_ != com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance()) { + intermediary_ = + com.google.cloud.eventarc.v1.Pubsub.newBuilder( + (com.google.cloud.eventarc.v1.Pubsub) intermediary_) + .mergeFrom(value) + .buildPartial(); + } else { + intermediary_ = value; + } + onChanged(); + } else { + if (intermediaryCase_ == 1) { + pubsubBuilder_.mergeFrom(value); + } else { + pubsubBuilder_.setMessage(value); + } + } + intermediaryCase_ = 1; + return this; + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + public Builder clearPubsub() { + if (pubsubBuilder_ == null) { + if (intermediaryCase_ == 1) { + intermediaryCase_ = 0; + intermediary_ = null; + onChanged(); + } + } else { + if (intermediaryCase_ == 1) { + intermediaryCase_ = 0; + intermediary_ = null; + } + pubsubBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + public com.google.cloud.eventarc.v1.Pubsub.Builder getPubsubBuilder() { + return getPubsubFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.PubsubOrBuilder getPubsubOrBuilder() { + if ((intermediaryCase_ == 1) && (pubsubBuilder_ != null)) { + return pubsubBuilder_.getMessageOrBuilder(); + } else { + if (intermediaryCase_ == 1) { + return (com.google.cloud.eventarc.v1.Pubsub) intermediary_; + } + return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } + } + /** + * + * + *
+     * The Pub/Sub topic and subscription used by Eventarc as a transport
+     * intermediary.
+     * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Pubsub, + com.google.cloud.eventarc.v1.Pubsub.Builder, + com.google.cloud.eventarc.v1.PubsubOrBuilder> + getPubsubFieldBuilder() { + if (pubsubBuilder_ == null) { + if (!(intermediaryCase_ == 1)) { + intermediary_ = com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); + } + pubsubBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Pubsub, + com.google.cloud.eventarc.v1.Pubsub.Builder, + com.google.cloud.eventarc.v1.PubsubOrBuilder>( + (com.google.cloud.eventarc.v1.Pubsub) intermediary_, + getParentForChildren(), + isClean()); + intermediary_ = null; + } + intermediaryCase_ = 1; + onChanged(); + ; + return pubsubBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Transport) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Transport) + private static final com.google.cloud.eventarc.v1.Transport DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Transport(); + } + + public static com.google.cloud.eventarc.v1.Transport getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Transport parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Transport getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java new file mode 100644 index 000000000000..6ff4a6e7aa4c --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java @@ -0,0 +1,65 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface TransportOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Transport) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The Pub/Sub topic and subscription used by Eventarc as a transport
+   * intermediary.
+   * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * + * @return Whether the pubsub field is set. + */ + boolean hasPubsub(); + /** + * + * + *
+   * The Pub/Sub topic and subscription used by Eventarc as a transport
+   * intermediary.
+   * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * + * @return The pubsub. + */ + com.google.cloud.eventarc.v1.Pubsub getPubsub(); + /** + * + * + *
+   * The Pub/Sub topic and subscription used by Eventarc as a transport
+   * intermediary.
+   * 
+ * + * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + */ + com.google.cloud.eventarc.v1.PubsubOrBuilder getPubsubOrBuilder(); + + public com.google.cloud.eventarc.v1.Transport.IntermediaryCase getIntermediaryCase(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java new file mode 100644 index 000000000000..4c016a63dd45 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java @@ -0,0 +1,3874 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * A representation of the trigger resource.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Trigger} + */ +public final class Trigger extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Trigger) + TriggerOrBuilder { + private static final long serialVersionUID = 0L; + // Use Trigger.newBuilder() to construct. + private Trigger(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Trigger() { + name_ = ""; + uid_ = ""; + eventFilters_ = java.util.Collections.emptyList(); + serviceAccount_ = ""; + channel_ = ""; + etag_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Trigger(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 12: + return internalGetLabels(); + case 15: + return internalGetConditions(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Trigger.class, + com.google.cloud.eventarc.v1.Trigger.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The resource name of the trigger. Must be unique within the location of the
+   * project and must be in
+   * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The resource name of the trigger. Must be unique within the location of the
+   * project and must be in
+   * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int UID_FIELD_NUMBER = 2; + private volatile java.lang.Object uid_; + /** + * + * + *
+   * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+   * string and guaranteed to remain unchanged until the resource is deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + @java.lang.Override + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+   * string and guaranteed to remain unchanged until the resource is deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 6; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + public static final int EVENT_FILTERS_FIELD_NUMBER = 8; + private java.util.List eventFilters_; + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List getEventFiltersList() { + return eventFilters_; + } + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List + getEventFiltersOrBuilderList() { + return eventFilters_; + } + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public int getEventFiltersCount() { + return eventFilters_.size(); + } + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index) { + return eventFilters_.get(index); + } + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(int index) { + return eventFilters_.get(index); + } + + public static final int SERVICE_ACCOUNT_FIELD_NUMBER = 9; + private volatile java.lang.Object serviceAccount_; + /** + * + * + *
+   * Optional. The IAM service account email associated with the trigger. The
+   * service account represents the identity of the trigger.
+   * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+   * permission in the service account. See
+   * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+   * for more information.
+   * For Cloud Run destinations, this service account is used to generate
+   * identity tokens when invoking the service. See
+   * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+   * for information on how to invoke authenticated Cloud Run services.
+   * To create Audit Log triggers, the service account should also
+   * have the `roles/eventarc.eventReceiver` IAM role.
+   * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The serviceAccount. + */ + @java.lang.Override + public java.lang.String getServiceAccount() { + java.lang.Object ref = serviceAccount_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + serviceAccount_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. The IAM service account email associated with the trigger. The
+   * service account represents the identity of the trigger.
+   * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+   * permission in the service account. See
+   * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+   * for more information.
+   * For Cloud Run destinations, this service account is used to generate
+   * identity tokens when invoking the service. See
+   * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+   * for information on how to invoke authenticated Cloud Run services.
+   * To create Audit Log triggers, the service account should also
+   * have the `roles/eventarc.eventReceiver` IAM role.
+   * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for serviceAccount. + */ + @java.lang.Override + public com.google.protobuf.ByteString getServiceAccountBytes() { + java.lang.Object ref = serviceAccount_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + serviceAccount_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESTINATION_FIELD_NUMBER = 10; + private com.google.cloud.eventarc.v1.Destination destination_; + /** + * + * + *
+   * Required. Destination specifies where the events should be sent to.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the destination field is set. + */ + @java.lang.Override + public boolean hasDestination() { + return destination_ != null; + } + /** + * + * + *
+   * Required. Destination specifies where the events should be sent to.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The destination. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Destination getDestination() { + return destination_ == null + ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() + : destination_; + } + /** + * + * + *
+   * Required. Destination specifies where the events should be sent to.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder() { + return getDestination(); + } + + public static final int TRANSPORT_FIELD_NUMBER = 11; + private com.google.cloud.eventarc.v1.Transport transport_; + /** + * + * + *
+   * Optional. To deliver messages, Eventarc might use other GCP
+   * products as a transport intermediary. This field contains a reference to
+   * that transport intermediary. This information can be used for debugging
+   * purposes.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the transport field is set. + */ + @java.lang.Override + public boolean hasTransport() { + return transport_ != null; + } + /** + * + * + *
+   * Optional. To deliver messages, Eventarc might use other GCP
+   * products as a transport intermediary. This field contains a reference to
+   * that transport intermediary. This information can be used for debugging
+   * purposes.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The transport. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Transport getTransport() { + return transport_ == null + ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() + : transport_; + } + /** + * + * + *
+   * Optional. To deliver messages, Eventarc might use other GCP
+   * products as a transport intermediary. This field contains a reference to
+   * that transport intermediary. This information can be used for debugging
+   * purposes.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder() { + return getTransport(); + } + + public static final int LABELS_FIELD_NUMBER = 12; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public static final int CHANNEL_FIELD_NUMBER = 13; + private volatile java.lang.Object channel_; + /** + * + * + *
+   * Optional. The name of the channel associated with the trigger in
+   * `projects/{project}/locations/{location}/channels/{channel}` format.
+   * You must provide a channel to receive events from Eventarc SaaS partners.
+   * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The channel. + */ + @java.lang.Override + public java.lang.String getChannel() { + java.lang.Object ref = channel_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channel_ = s; + return s; + } + } + /** + * + * + *
+   * Optional. The name of the channel associated with the trigger in
+   * `projects/{project}/locations/{location}/channels/{channel}` format.
+   * You must provide a channel to receive events from Eventarc SaaS partners.
+   * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for channel. + */ + @java.lang.Override + public com.google.protobuf.ByteString getChannelBytes() { + java.lang.Object ref = channel_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channel_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CONDITIONS_FIELD_NUMBER = 15; + + private static final class ConditionsDefaultEntryHolder { + static final com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + defaultEntry = + com.google.protobuf.MapEntry + .newDefaultInstance( + com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.eventarc.v1.StateCondition.getDefaultInstance()); + } + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + conditions_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + internalGetConditions() { + if (conditions_ == null) { + return com.google.protobuf.MapField.emptyMapField(ConditionsDefaultEntryHolder.defaultEntry); + } + return conditions_; + } + + public int getConditionsCount() { + return internalGetConditions().getMap().size(); + } + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public boolean containsConditions(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetConditions().getMap().containsKey(key); + } + /** Use {@link #getConditionsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map + getConditions() { + return getConditionsMap(); + } + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.Map + getConditionsMap() { + return internalGetConditions().getMap(); + } + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( + java.lang.String key, com.google.cloud.eventarc.v1.StateCondition defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetConditions().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetConditions().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public static final int ETAG_FIELD_NUMBER = 99; + private volatile java.lang.Object etag_; + /** + * + * + *
+   * Output only. This checksum is computed by the server based on the value of other
+   * fields, and might be sent only on create requests to ensure that the
+   * client has an up-to-date value before proceeding.
+   * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The etag. + */ + @java.lang.Override + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } + } + /** + * + * + *
+   * Output only. This checksum is computed by the server based on the value of other
+   * fields, and might be sent only on create requests to ensure that the
+   * client has an up-to-date value before proceeding.
+   * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for etag. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uid_); + } + if (createTime_ != null) { + output.writeMessage(5, getCreateTime()); + } + if (updateTime_ != null) { + output.writeMessage(6, getUpdateTime()); + } + for (int i = 0; i < eventFilters_.size(); i++) { + output.writeMessage(8, eventFilters_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 9, serviceAccount_); + } + if (destination_ != null) { + output.writeMessage(10, getDestination()); + } + if (transport_ != null) { + output.writeMessage(11, getTransport()); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 12); + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channel_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 13, channel_); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetConditions(), ConditionsDefaultEntryHolder.defaultEntry, 15); + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 99, etag_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); + } + for (int i = 0; i < eventFilters_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, eventFilters_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, serviceAccount_); + } + if (destination_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getDestination()); + } + if (transport_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getTransport()); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, labels__); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channel_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(13, channel_); + } + for (java.util.Map.Entry entry : + internalGetConditions().getMap().entrySet()) { + com.google.protobuf.MapEntry + conditions__ = + ConditionsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, conditions__); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(99, etag_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.Trigger)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.Trigger other = (com.google.cloud.eventarc.v1.Trigger) obj; + + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getEventFiltersList().equals(other.getEventFiltersList())) return false; + if (!getServiceAccount().equals(other.getServiceAccount())) return false; + if (hasDestination() != other.hasDestination()) return false; + if (hasDestination()) { + if (!getDestination().equals(other.getDestination())) return false; + } + if (hasTransport() != other.hasTransport()) return false; + if (hasTransport()) { + if (!getTransport().equals(other.getTransport())) return false; + } + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!getChannel().equals(other.getChannel())) return false; + if (!internalGetConditions().equals(other.internalGetConditions())) return false; + if (!getEtag().equals(other.getEtag())) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + UID_FIELD_NUMBER; + hash = (53 * hash) + getUid().hashCode(); + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + if (getEventFiltersCount() > 0) { + hash = (37 * hash) + EVENT_FILTERS_FIELD_NUMBER; + hash = (53 * hash) + getEventFiltersList().hashCode(); + } + hash = (37 * hash) + SERVICE_ACCOUNT_FIELD_NUMBER; + hash = (53 * hash) + getServiceAccount().hashCode(); + if (hasDestination()) { + hash = (37 * hash) + DESTINATION_FIELD_NUMBER; + hash = (53 * hash) + getDestination().hashCode(); + } + if (hasTransport()) { + hash = (37 * hash) + TRANSPORT_FIELD_NUMBER; + hash = (53 * hash) + getTransport().hashCode(); + } + if (!internalGetLabels().getMap().isEmpty()) { + hash = (37 * hash) + LABELS_FIELD_NUMBER; + hash = (53 * hash) + internalGetLabels().hashCode(); + } + hash = (37 * hash) + CHANNEL_FIELD_NUMBER; + hash = (53 * hash) + getChannel().hashCode(); + if (!internalGetConditions().getMap().isEmpty()) { + hash = (37 * hash) + CONDITIONS_FIELD_NUMBER; + hash = (53 * hash) + internalGetConditions().hashCode(); + } + hash = (37 * hash) + ETAG_FIELD_NUMBER; + hash = (53 * hash) + getEtag().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Trigger parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Trigger parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.Trigger parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.Trigger prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * A representation of the trigger resource.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.Trigger} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Trigger) + com.google.cloud.eventarc.v1.TriggerOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 12: + return internalGetLabels(); + case 15: + return internalGetConditions(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { + switch (number) { + case 12: + return internalGetMutableLabels(); + case 15: + return internalGetMutableConditions(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.Trigger.class, + com.google.cloud.eventarc.v1.Trigger.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.Trigger.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + uid_ = ""; + + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + if (eventFiltersBuilder_ == null) { + eventFilters_ = java.util.Collections.emptyList(); + } else { + eventFilters_ = null; + eventFiltersBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + serviceAccount_ = ""; + + if (destinationBuilder_ == null) { + destination_ = null; + } else { + destination_ = null; + destinationBuilder_ = null; + } + if (transportBuilder_ == null) { + transport_ = null; + } else { + transport_ = null; + transportBuilder_ = null; + } + internalGetMutableLabels().clear(); + channel_ = ""; + + internalGetMutableConditions().clear(); + etag_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.Trigger.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger build() { + com.google.cloud.eventarc.v1.Trigger result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger buildPartial() { + com.google.cloud.eventarc.v1.Trigger result = new com.google.cloud.eventarc.v1.Trigger(this); + int from_bitField0_ = bitField0_; + result.name_ = name_; + result.uid_ = uid_; + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + if (eventFiltersBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + eventFilters_ = java.util.Collections.unmodifiableList(eventFilters_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.eventFilters_ = eventFilters_; + } else { + result.eventFilters_ = eventFiltersBuilder_.build(); + } + result.serviceAccount_ = serviceAccount_; + if (destinationBuilder_ == null) { + result.destination_ = destination_; + } else { + result.destination_ = destinationBuilder_.build(); + } + if (transportBuilder_ == null) { + result.transport_ = transport_; + } else { + result.transport_ = transportBuilder_.build(); + } + result.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + result.channel_ = channel_; + result.conditions_ = internalGetConditions(); + result.conditions_.makeImmutable(); + result.etag_ = etag_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.Trigger) { + return mergeFrom((com.google.cloud.eventarc.v1.Trigger) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.Trigger other) { + if (other == com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getUid().isEmpty()) { + uid_ = other.uid_; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (eventFiltersBuilder_ == null) { + if (!other.eventFilters_.isEmpty()) { + if (eventFilters_.isEmpty()) { + eventFilters_ = other.eventFilters_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureEventFiltersIsMutable(); + eventFilters_.addAll(other.eventFilters_); + } + onChanged(); + } + } else { + if (!other.eventFilters_.isEmpty()) { + if (eventFiltersBuilder_.isEmpty()) { + eventFiltersBuilder_.dispose(); + eventFiltersBuilder_ = null; + eventFilters_ = other.eventFilters_; + bitField0_ = (bitField0_ & ~0x00000001); + eventFiltersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getEventFiltersFieldBuilder() + : null; + } else { + eventFiltersBuilder_.addAllMessages(other.eventFilters_); + } + } + } + if (!other.getServiceAccount().isEmpty()) { + serviceAccount_ = other.serviceAccount_; + onChanged(); + } + if (other.hasDestination()) { + mergeDestination(other.getDestination()); + } + if (other.hasTransport()) { + mergeTransport(other.getTransport()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + if (!other.getChannel().isEmpty()) { + channel_ = other.channel_; + onChanged(); + } + internalGetMutableConditions().mergeFrom(other.internalGetConditions()); + if (!other.getEtag().isEmpty()) { + etag_ = other.etag_; + onChanged(); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + uid_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 66: + { + com.google.cloud.eventarc.v1.EventFilter m = + input.readMessage( + com.google.cloud.eventarc.v1.EventFilter.parser(), extensionRegistry); + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + eventFilters_.add(m); + } else { + eventFiltersBuilder_.addMessage(m); + } + break; + } // case 66 + case 74: + { + serviceAccount_ = input.readStringRequireUtf8(); + + break; + } // case 74 + case 82: + { + input.readMessage(getDestinationFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 82 + case 90: + { + input.readMessage(getTransportFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 90 + case 98: + { + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableLabels() + .getMutableMap() + .put(labels__.getKey(), labels__.getValue()); + break; + } // case 98 + case 106: + { + channel_ = input.readStringRequireUtf8(); + + break; + } // case 106 + case 122: + { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + conditions__ = + input.readMessage( + ConditionsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableConditions() + .getMutableMap() + .put(conditions__.getKey(), conditions__.getValue()); + break; + } // case 122 + case 794: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 794 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The resource name of the trigger. Must be unique within the location of the
+     * project and must be in
+     * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The resource name of the trigger. Must be unique within the location of the
+     * project and must be in
+     * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The resource name of the trigger. Must be unique within the location of the
+     * project and must be in
+     * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The resource name of the trigger. Must be unique within the location of the
+     * project and must be in
+     * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The resource name of the trigger. Must be unique within the location of the
+     * project and must be in
+     * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private java.lang.Object uid_ = ""; + /** + * + * + *
+     * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+     * string and guaranteed to remain unchanged until the resource is deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + public java.lang.String getUid() { + java.lang.Object ref = uid_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + uid_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+     * string and guaranteed to remain unchanged until the resource is deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + public com.google.protobuf.ByteString getUidBytes() { + java.lang.Object ref = uid_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + uid_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+     * string and guaranteed to remain unchanged until the resource is deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The uid to set. + * @return This builder for chaining. + */ + public Builder setUid(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + uid_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+     * string and guaranteed to remain unchanged until the resource is deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearUid() { + + uid_ = getDefaultInstance().getUid(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+     * string and guaranteed to remain unchanged until the resource is deleted.
+     * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for uid to set. + * @return This builder for chaining. + */ + public Builder setUidBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + uid_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + public com.google.protobuf.Timestamp getCreateTime() { + if (createTimeBuilder_ == null) { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } else { + return createTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+     * Output only. The creation time.
+     * 
+ * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); + createTime_ = null; + } + return createTimeBuilder_; + } + + private com.google.protobuf.Timestamp updateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + public com.google.protobuf.Timestamp getUpdateTime() { + if (updateTimeBuilder_ == null) { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } else { + return updateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+     * Output only. The last-modified time.
+     * 
+ * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private java.util.List eventFilters_ = + java.util.Collections.emptyList(); + + private void ensureEventFiltersIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + eventFilters_ = + new java.util.ArrayList(eventFilters_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventFilter, + com.google.cloud.eventarc.v1.EventFilter.Builder, + com.google.cloud.eventarc.v1.EventFilterOrBuilder> + eventFiltersBuilder_; + + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List getEventFiltersList() { + if (eventFiltersBuilder_ == null) { + return java.util.Collections.unmodifiableList(eventFilters_); + } else { + return eventFiltersBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public int getEventFiltersCount() { + if (eventFiltersBuilder_ == null) { + return eventFilters_.size(); + } else { + return eventFiltersBuilder_.getCount(); + } + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index) { + if (eventFiltersBuilder_ == null) { + return eventFilters_.get(index); + } else { + return eventFiltersBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setEventFilters(int index, com.google.cloud.eventarc.v1.EventFilter value) { + if (eventFiltersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEventFiltersIsMutable(); + eventFilters_.set(index, value); + onChanged(); + } else { + eventFiltersBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setEventFilters( + int index, com.google.cloud.eventarc.v1.EventFilter.Builder builderForValue) { + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + eventFilters_.set(index, builderForValue.build()); + onChanged(); + } else { + eventFiltersBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEventFilters(com.google.cloud.eventarc.v1.EventFilter value) { + if (eventFiltersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEventFiltersIsMutable(); + eventFilters_.add(value); + onChanged(); + } else { + eventFiltersBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEventFilters(int index, com.google.cloud.eventarc.v1.EventFilter value) { + if (eventFiltersBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEventFiltersIsMutable(); + eventFilters_.add(index, value); + onChanged(); + } else { + eventFiltersBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEventFilters( + com.google.cloud.eventarc.v1.EventFilter.Builder builderForValue) { + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + eventFilters_.add(builderForValue.build()); + onChanged(); + } else { + eventFiltersBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEventFilters( + int index, com.google.cloud.eventarc.v1.EventFilter.Builder builderForValue) { + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + eventFilters_.add(index, builderForValue.build()); + onChanged(); + } else { + eventFiltersBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addAllEventFilters( + java.lang.Iterable values) { + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, eventFilters_); + onChanged(); + } else { + eventFiltersBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearEventFilters() { + if (eventFiltersBuilder_ == null) { + eventFilters_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + eventFiltersBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder removeEventFilters(int index) { + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + eventFilters_.remove(index); + onChanged(); + } else { + eventFiltersBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.EventFilter.Builder getEventFiltersBuilder(int index) { + return getEventFiltersFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(int index) { + if (eventFiltersBuilder_ == null) { + return eventFilters_.get(index); + } else { + return eventFiltersBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getEventFiltersOrBuilderList() { + if (eventFiltersBuilder_ != null) { + return eventFiltersBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(eventFilters_); + } + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder() { + return getEventFiltersFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()); + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder(int index) { + return getEventFiltersFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()); + } + /** + * + * + *
+     * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+     * match all the provided filters are sent to the destination.
+     * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getEventFiltersBuilderList() { + return getEventFiltersFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventFilter, + com.google.cloud.eventarc.v1.EventFilter.Builder, + com.google.cloud.eventarc.v1.EventFilterOrBuilder> + getEventFiltersFieldBuilder() { + if (eventFiltersBuilder_ == null) { + eventFiltersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventFilter, + com.google.cloud.eventarc.v1.EventFilter.Builder, + com.google.cloud.eventarc.v1.EventFilterOrBuilder>( + eventFilters_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + eventFilters_ = null; + } + return eventFiltersBuilder_; + } + + private java.lang.Object serviceAccount_ = ""; + /** + * + * + *
+     * Optional. The IAM service account email associated with the trigger. The
+     * service account represents the identity of the trigger.
+     * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+     * permission in the service account. See
+     * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+     * for more information.
+     * For Cloud Run destinations, this service account is used to generate
+     * identity tokens when invoking the service. See
+     * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+     * for information on how to invoke authenticated Cloud Run services.
+     * To create Audit Log triggers, the service account should also
+     * have the `roles/eventarc.eventReceiver` IAM role.
+     * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The serviceAccount. + */ + public java.lang.String getServiceAccount() { + java.lang.Object ref = serviceAccount_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + serviceAccount_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. The IAM service account email associated with the trigger. The
+     * service account represents the identity of the trigger.
+     * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+     * permission in the service account. See
+     * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+     * for more information.
+     * For Cloud Run destinations, this service account is used to generate
+     * identity tokens when invoking the service. See
+     * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+     * for information on how to invoke authenticated Cloud Run services.
+     * To create Audit Log triggers, the service account should also
+     * have the `roles/eventarc.eventReceiver` IAM role.
+     * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for serviceAccount. + */ + public com.google.protobuf.ByteString getServiceAccountBytes() { + java.lang.Object ref = serviceAccount_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + serviceAccount_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. The IAM service account email associated with the trigger. The
+     * service account represents the identity of the trigger.
+     * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+     * permission in the service account. See
+     * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+     * for more information.
+     * For Cloud Run destinations, this service account is used to generate
+     * identity tokens when invoking the service. See
+     * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+     * for information on how to invoke authenticated Cloud Run services.
+     * To create Audit Log triggers, the service account should also
+     * have the `roles/eventarc.eventReceiver` IAM role.
+     * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The serviceAccount to set. + * @return This builder for chaining. + */ + public Builder setServiceAccount(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + serviceAccount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The IAM service account email associated with the trigger. The
+     * service account represents the identity of the trigger.
+     * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+     * permission in the service account. See
+     * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+     * for more information.
+     * For Cloud Run destinations, this service account is used to generate
+     * identity tokens when invoking the service. See
+     * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+     * for information on how to invoke authenticated Cloud Run services.
+     * To create Audit Log triggers, the service account should also
+     * have the `roles/eventarc.eventReceiver` IAM role.
+     * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearServiceAccount() { + + serviceAccount_ = getDefaultInstance().getServiceAccount(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The IAM service account email associated with the trigger. The
+     * service account represents the identity of the trigger.
+     * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+     * permission in the service account. See
+     * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+     * for more information.
+     * For Cloud Run destinations, this service account is used to generate
+     * identity tokens when invoking the service. See
+     * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+     * for information on how to invoke authenticated Cloud Run services.
+     * To create Audit Log triggers, the service account should also
+     * have the `roles/eventarc.eventReceiver` IAM role.
+     * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for serviceAccount to set. + * @return This builder for chaining. + */ + public Builder setServiceAccountBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + serviceAccount_ = value; + onChanged(); + return this; + } + + private com.google.cloud.eventarc.v1.Destination destination_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Destination, + com.google.cloud.eventarc.v1.Destination.Builder, + com.google.cloud.eventarc.v1.DestinationOrBuilder> + destinationBuilder_; + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the destination field is set. + */ + public boolean hasDestination() { + return destinationBuilder_ != null || destination_ != null; + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The destination. + */ + public com.google.cloud.eventarc.v1.Destination getDestination() { + if (destinationBuilder_ == null) { + return destination_ == null + ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() + : destination_; + } else { + return destinationBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setDestination(com.google.cloud.eventarc.v1.Destination value) { + if (destinationBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + destination_ = value; + onChanged(); + } else { + destinationBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setDestination( + com.google.cloud.eventarc.v1.Destination.Builder builderForValue) { + if (destinationBuilder_ == null) { + destination_ = builderForValue.build(); + onChanged(); + } else { + destinationBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeDestination(com.google.cloud.eventarc.v1.Destination value) { + if (destinationBuilder_ == null) { + if (destination_ != null) { + destination_ = + com.google.cloud.eventarc.v1.Destination.newBuilder(destination_) + .mergeFrom(value) + .buildPartial(); + } else { + destination_ = value; + } + onChanged(); + } else { + destinationBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearDestination() { + if (destinationBuilder_ == null) { + destination_ = null; + onChanged(); + } else { + destination_ = null; + destinationBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.Destination.Builder getDestinationBuilder() { + + onChanged(); + return getDestinationFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder() { + if (destinationBuilder_ != null) { + return destinationBuilder_.getMessageOrBuilder(); + } else { + return destination_ == null + ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() + : destination_; + } + } + /** + * + * + *
+     * Required. Destination specifies where the events should be sent to.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Destination, + com.google.cloud.eventarc.v1.Destination.Builder, + com.google.cloud.eventarc.v1.DestinationOrBuilder> + getDestinationFieldBuilder() { + if (destinationBuilder_ == null) { + destinationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Destination, + com.google.cloud.eventarc.v1.Destination.Builder, + com.google.cloud.eventarc.v1.DestinationOrBuilder>( + getDestination(), getParentForChildren(), isClean()); + destination_ = null; + } + return destinationBuilder_; + } + + private com.google.cloud.eventarc.v1.Transport transport_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Transport, + com.google.cloud.eventarc.v1.Transport.Builder, + com.google.cloud.eventarc.v1.TransportOrBuilder> + transportBuilder_; + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the transport field is set. + */ + public boolean hasTransport() { + return transportBuilder_ != null || transport_ != null; + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The transport. + */ + public com.google.cloud.eventarc.v1.Transport getTransport() { + if (transportBuilder_ == null) { + return transport_ == null + ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() + : transport_; + } else { + return transportBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setTransport(com.google.cloud.eventarc.v1.Transport value) { + if (transportBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + transport_ = value; + onChanged(); + } else { + transportBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setTransport(com.google.cloud.eventarc.v1.Transport.Builder builderForValue) { + if (transportBuilder_ == null) { + transport_ = builderForValue.build(); + onChanged(); + } else { + transportBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeTransport(com.google.cloud.eventarc.v1.Transport value) { + if (transportBuilder_ == null) { + if (transport_ != null) { + transport_ = + com.google.cloud.eventarc.v1.Transport.newBuilder(transport_) + .mergeFrom(value) + .buildPartial(); + } else { + transport_ = value; + } + onChanged(); + } else { + transportBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearTransport() { + if (transportBuilder_ == null) { + transport_ = null; + onChanged(); + } else { + transport_ = null; + transportBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.eventarc.v1.Transport.Builder getTransportBuilder() { + + onChanged(); + return getTransportFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder() { + if (transportBuilder_ != null) { + return transportBuilder_.getMessageOrBuilder(); + } else { + return transport_ == null + ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() + : transport_; + } + } + /** + * + * + *
+     * Optional. To deliver messages, Eventarc might use other GCP
+     * products as a transport intermediary. This field contains a reference to
+     * that transport intermediary. This information can be used for debugging
+     * purposes.
+     * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Transport, + com.google.cloud.eventarc.v1.Transport.Builder, + com.google.cloud.eventarc.v1.TransportOrBuilder> + getTransportFieldBuilder() { + if (transportBuilder_ == null) { + transportBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Transport, + com.google.cloud.eventarc.v1.Transport.Builder, + com.google.cloud.eventarc.v1.TransportOrBuilder>( + getTransport(), getParentForChildren(), isClean()); + transport_ = null; + } + return transportBuilder_; + } + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { + if (labels_ == null) { + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); + } + return labels_; + } + + private com.google.protobuf.MapField + internalGetMutableLabels() { + onChanged(); + ; + if (labels_ == null) { + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); + } + if (!labels_.isMutable()) { + labels_ = labels_.copy(); + } + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetLabels().getMap().containsKey(key); + } + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getLabels() { + return getLabelsMap(); + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearLabels() { + internalGetMutableLabels().getMutableMap().clear(); + return this; + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableLabels().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableLabels() { + return internalGetMutableLabels().getMutableMap(); + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + + internalGetMutableLabels().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+     * Optional. User labels attached to the triggers that can be used to group resources.
+     * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); + return this; + } + + private java.lang.Object channel_ = ""; + /** + * + * + *
+     * Optional. The name of the channel associated with the trigger in
+     * `projects/{project}/locations/{location}/channels/{channel}` format.
+     * You must provide a channel to receive events from Eventarc SaaS partners.
+     * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The channel. + */ + public java.lang.String getChannel() { + java.lang.Object ref = channel_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + channel_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Optional. The name of the channel associated with the trigger in
+     * `projects/{project}/locations/{location}/channels/{channel}` format.
+     * You must provide a channel to receive events from Eventarc SaaS partners.
+     * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for channel. + */ + public com.google.protobuf.ByteString getChannelBytes() { + java.lang.Object ref = channel_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + channel_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Optional. The name of the channel associated with the trigger in
+     * `projects/{project}/locations/{location}/channels/{channel}` format.
+     * You must provide a channel to receive events from Eventarc SaaS partners.
+     * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The channel to set. + * @return This builder for chaining. + */ + public Builder setChannel(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + channel_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The name of the channel associated with the trigger in
+     * `projects/{project}/locations/{location}/channels/{channel}` format.
+     * You must provide a channel to receive events from Eventarc SaaS partners.
+     * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearChannel() { + + channel_ = getDefaultInstance().getChannel(); + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The name of the channel associated with the trigger in
+     * `projects/{project}/locations/{location}/channels/{channel}` format.
+     * You must provide a channel to receive events from Eventarc SaaS partners.
+     * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes for channel to set. + * @return This builder for chaining. + */ + public Builder setChannelBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + channel_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + conditions_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + internalGetConditions() { + if (conditions_ == null) { + return com.google.protobuf.MapField.emptyMapField( + ConditionsDefaultEntryHolder.defaultEntry); + } + return conditions_; + } + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + internalGetMutableConditions() { + onChanged(); + ; + if (conditions_ == null) { + conditions_ = + com.google.protobuf.MapField.newMapField(ConditionsDefaultEntryHolder.defaultEntry); + } + if (!conditions_.isMutable()) { + conditions_ = conditions_.copy(); + } + return conditions_; + } + + public int getConditionsCount() { + return internalGetConditions().getMap().size(); + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public boolean containsConditions(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetConditions().getMap().containsKey(key); + } + /** Use {@link #getConditionsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map + getConditions() { + return getConditionsMap(); + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.Map + getConditionsMap() { + return internalGetConditions().getMap(); + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( + java.lang.String key, com.google.cloud.eventarc.v1.StateCondition defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetConditions().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = + internalGetConditions().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearConditions() { + internalGetMutableConditions().getMutableMap().clear(); + return this; + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeConditions(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableConditions().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map + getMutableConditions() { + return internalGetMutableConditions().getMutableMap(); + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder putConditions( + java.lang.String key, com.google.cloud.eventarc.v1.StateCondition value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + + internalGetMutableConditions().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+     * Output only. The reason(s) why a trigger is in FAILED state.
+     * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder putAllConditions( + java.util.Map values) { + internalGetMutableConditions().getMutableMap().putAll(values); + return this; + } + + private java.lang.Object etag_ = ""; + /** + * + * + *
+     * Output only. This checksum is computed by the server based on the value of other
+     * fields, and might be sent only on create requests to ensure that the
+     * client has an up-to-date value before proceeding.
+     * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The etag. + */ + public java.lang.String getEtag() { + java.lang.Object ref = etag_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + etag_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Output only. This checksum is computed by the server based on the value of other
+     * fields, and might be sent only on create requests to ensure that the
+     * client has an up-to-date value before proceeding.
+     * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for etag. + */ + public com.google.protobuf.ByteString getEtagBytes() { + java.lang.Object ref = etag_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + etag_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Output only. This checksum is computed by the server based on the value of other
+     * fields, and might be sent only on create requests to ensure that the
+     * client has an up-to-date value before proceeding.
+     * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The etag to set. + * @return This builder for chaining. + */ + public Builder setEtag(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + etag_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. This checksum is computed by the server based on the value of other
+     * fields, and might be sent only on create requests to ensure that the
+     * client has an up-to-date value before proceeding.
+     * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearEtag() { + + etag_ = getDefaultInstance().getEtag(); + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. This checksum is computed by the server based on the value of other
+     * fields, and might be sent only on create requests to ensure that the
+     * client has an up-to-date value before proceeding.
+     * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The bytes for etag to set. + * @return This builder for chaining. + */ + public Builder setEtagBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + etag_ = value; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Trigger) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Trigger) + private static final com.google.cloud.eventarc.v1.Trigger DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Trigger(); + } + + public static com.google.cloud.eventarc.v1.Trigger getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Trigger parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java new file mode 100644 index 000000000000..b70bcf81e424 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java @@ -0,0 +1,552 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public interface TriggerOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Trigger) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The resource name of the trigger. Must be unique within the location of the
+   * project and must be in
+   * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. The resource name of the trigger. Must be unique within the location of the
+   * project and must be in
+   * `projects/{project}/locations/{location}/triggers/{trigger}` format.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+   * string and guaranteed to remain unchanged until the resource is deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The uid. + */ + java.lang.String getUid(); + /** + * + * + *
+   * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
+   * string and guaranteed to remain unchanged until the resource is deleted.
+   * 
+ * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+   * Output only. The creation time.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+   * Output only. The last-modified time.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List getEventFiltersList(); + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index); + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + int getEventFiltersCount(); + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List + getEventFiltersOrBuilderList(); + /** + * + * + *
+   * Required. Unordered list. The list of filters that applies to event attributes. Only events that
+   * match all the provided filters are sent to the destination.
+   * 
+ * + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(int index); + + /** + * + * + *
+   * Optional. The IAM service account email associated with the trigger. The
+   * service account represents the identity of the trigger.
+   * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+   * permission in the service account. See
+   * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+   * for more information.
+   * For Cloud Run destinations, this service account is used to generate
+   * identity tokens when invoking the service. See
+   * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+   * for information on how to invoke authenticated Cloud Run services.
+   * To create Audit Log triggers, the service account should also
+   * have the `roles/eventarc.eventReceiver` IAM role.
+   * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The serviceAccount. + */ + java.lang.String getServiceAccount(); + /** + * + * + *
+   * Optional. The IAM service account email associated with the trigger. The
+   * service account represents the identity of the trigger.
+   * The principal who calls this API must have the `iam.serviceAccounts.actAs`
+   * permission in the service account. See
+   * https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common
+   * for more information.
+   * For Cloud Run destinations, this service account is used to generate
+   * identity tokens when invoking the service. See
+   * https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account
+   * for information on how to invoke authenticated Cloud Run services.
+   * To create Audit Log triggers, the service account should also
+   * have the `roles/eventarc.eventReceiver` IAM role.
+   * 
+ * + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for serviceAccount. + */ + com.google.protobuf.ByteString getServiceAccountBytes(); + + /** + * + * + *
+   * Required. Destination specifies where the events should be sent to.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the destination field is set. + */ + boolean hasDestination(); + /** + * + * + *
+   * Required. Destination specifies where the events should be sent to.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The destination. + */ + com.google.cloud.eventarc.v1.Destination getDestination(); + /** + * + * + *
+   * Required. Destination specifies where the events should be sent to.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder(); + + /** + * + * + *
+   * Optional. To deliver messages, Eventarc might use other GCP
+   * products as a transport intermediary. This field contains a reference to
+   * that transport intermediary. This information can be used for debugging
+   * purposes.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the transport field is set. + */ + boolean hasTransport(); + /** + * + * + *
+   * Optional. To deliver messages, Eventarc might use other GCP
+   * products as a transport intermediary. This field contains a reference to
+   * that transport intermediary. This information can be used for debugging
+   * purposes.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The transport. + */ + com.google.cloud.eventarc.v1.Transport getTransport(); + /** + * + * + *
+   * Optional. To deliver messages, Eventarc might use other GCP
+   * products as a transport intermediary. This field contains a reference to
+   * that transport intermediary. This information can be used for debugging
+   * purposes.
+   * 
+ * + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder(); + + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getLabelsCount(); + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + boolean containsLabels(java.lang.String key); + /** Use {@link #getLabelsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getLabels(); + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getLabelsMap(); + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + + /* nullable */ + java.lang.String getLabelsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + /** + * + * + *
+   * Optional. User labels attached to the triggers that can be used to group resources.
+   * 
+ * + * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + /** + * + * + *
+   * Optional. The name of the channel associated with the trigger in
+   * `projects/{project}/locations/{location}/channels/{channel}` format.
+   * You must provide a channel to receive events from Eventarc SaaS partners.
+   * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The channel. + */ + java.lang.String getChannel(); + /** + * + * + *
+   * Optional. The name of the channel associated with the trigger in
+   * `projects/{project}/locations/{location}/channels/{channel}` format.
+   * You must provide a channel to receive events from Eventarc SaaS partners.
+   * 
+ * + * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for channel. + */ + com.google.protobuf.ByteString getChannelBytes(); + + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getConditionsCount(); + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + boolean containsConditions(java.lang.String key); + /** Use {@link #getConditionsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getConditions(); + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.Map getConditionsMap(); + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + + /* nullable */ + com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( + java.lang.String key, + /* nullable */ + com.google.cloud.eventarc.v1.StateCondition defaultValue); + /** + * + * + *
+   * Output only. The reason(s) why a trigger is in FAILED state.
+   * 
+ * + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(java.lang.String key); + + /** + * + * + *
+   * Output only. This checksum is computed by the server based on the value of other
+   * fields, and might be sent only on create requests to ensure that the
+   * client has an up-to-date value before proceeding.
+   * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The etag. + */ + java.lang.String getEtag(); + /** + * + * + *
+   * Output only. This checksum is computed by the server based on the value of other
+   * fields, and might be sent only on create requests to ensure that the
+   * client has an up-to-date value before proceeding.
+   * 
+ * + * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The bytes for etag. + */ + com.google.protobuf.ByteString getEtagBytes(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java new file mode 100644 index 000000000000..5e0e15dff700 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java @@ -0,0 +1,253 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public final class TriggerProto { + private TriggerProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Destination_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Transport_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GKE_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n&google/cloud/eventarc/v1/trigger.proto" + + "\022\030google.cloud.eventarc.v1\032\037google/api/f" + + "ield_behavior.proto\032\031google/api/resource" + + ".proto\032\037google/protobuf/timestamp.proto\032" + + "\025google/rpc/code.proto\"\334\006\n\007Trigger\022\021\n\004na" + + "me\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 \001(\tB\003\340A\003\0224\n\013creat" + + "e_time\030\005 \001(\0132\032.google.protobuf.Timestamp" + + "B\003\340A\003\0224\n\013update_time\030\006 \001(\0132\032.google.prot" + + "obuf.TimestampB\003\340A\003\022D\n\revent_filters\030\010 \003" + + "(\0132%.google.cloud.eventarc.v1.EventFilte" + + "rB\006\340A\006\340A\002\022B\n\017service_account\030\t \001(\tB)\340A\001\372" + + "A#\n!iam.googleapis.com/ServiceAccount\022?\n" + + "\013destination\030\n \001(\0132%.google.cloud.eventa" + + "rc.v1.DestinationB\003\340A\002\022;\n\ttransport\030\013 \001(" + + "\0132#.google.cloud.eventarc.v1.TransportB\003" + + "\340A\001\022B\n\006labels\030\014 \003(\0132-.google.cloud.event" + + "arc.v1.Trigger.LabelsEntryB\003\340A\001\022\024\n\007chann" + + "el\030\r \001(\tB\003\340A\001\022J\n\nconditions\030\017 \003(\01321.goog" + + "le.cloud.eventarc.v1.Trigger.ConditionsE" + + "ntryB\003\340A\003\022\021\n\004etag\030c \001(\tB\003\340A\003\032-\n\013LabelsEn" + + "try\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\032[\n\017C" + + "onditionsEntry\022\013\n\003key\030\001 \001(\t\0227\n\005value\030\002 \001" + + "(\0132(.google.cloud.eventarc.v1.StateCondi" + + "tion:\0028\001:s\352Ap\n\037eventarc.googleapis.com/T" + + "rigger\022:projects/{project}/locations/{lo" + + "cation}/triggers/{trigger}*\010triggers2\007tr" + + "igger\"P\n\013EventFilter\022\026\n\tattribute\030\001 \001(\tB" + + "\003\340A\002\022\022\n\005value\030\002 \001(\tB\003\340A\002\022\025\n\010operator\030\003 \001" + + "(\tB\003\340A\001\"A\n\016StateCondition\022\036\n\004code\030\001 \001(\0162" + + "\020.google.rpc.Code\022\017\n\007message\030\002 \001(\t\"\212\002\n\013D" + + "estination\0227\n\tcloud_run\030\001 \001(\0132\".google.c" + + "loud.eventarc.v1.CloudRunH\000\022J\n\016cloud_fun" + + "ction\030\002 \001(\tB0\372A-\n+cloudfunctions.googlea" + + "pis.com/CloudFunctionH\000\022,\n\003gke\030\003 \001(\0132\035.g" + + "oogle.cloud.eventarc.v1.GKEH\000\022:\n\010workflo" + + "w\030\004 \001(\tB&\372A#\n!workflows.googleapis.com/W" + + "orkflowH\000B\014\n\ndescriptor\"O\n\tTransport\0222\n\006" + + "pubsub\030\001 \001(\0132 .google.cloud.eventarc.v1." + + "PubsubH\000B\016\n\014intermediary\"g\n\010CloudRun\0223\n\007" + + "service\030\001 \001(\tB\"\340A\002\372A\034\n\032run.googleapis.co" + + "m/Service\022\021\n\004path\030\002 \001(\tB\003\340A\001\022\023\n\006region\030\003" + + " \001(\tB\003\340A\002\"s\n\003GKE\022\024\n\007cluster\030\001 \001(\tB\003\340A\002\022\025" + + "\n\010location\030\002 \001(\tB\003\340A\002\022\026\n\tnamespace\030\003 \001(\t" + + "B\003\340A\002\022\024\n\007service\030\004 \001(\tB\003\340A\002\022\021\n\004path\030\005 \001(" + + "\tB\003\340A\001\"7\n\006Pubsub\022\022\n\005topic\030\001 \001(\tB\003\340A\001\022\031\n\014" + + "subscription\030\002 \001(\tB\003\340A\003B\300\003\n\034com.google.c" + + "loud.eventarc.v1B\014TriggerProtoP\001Z@google" + + ".golang.org/genproto/googleapis/cloud/ev" + + "entarc/v1;eventarc\352Ak\n+cloudfunctions.go" + + "ogleapis.com/CloudFunction\022 + * The request message for the UpdateChannel method. + * + * + * Protobuf type {@code google.cloud.eventarc.v1.UpdateChannelRequest} + */ +public final class UpdateChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.UpdateChannelRequest) + UpdateChannelRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateChannelRequest.newBuilder() to construct. + private UpdateChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateChannelRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateChannelRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.UpdateChannelRequest.class, + com.google.cloud.eventarc.v1.UpdateChannelRequest.Builder.class); + } + + public static final int CHANNEL_FIELD_NUMBER = 1; + private com.google.cloud.eventarc.v1.Channel channel_; + /** + * + * + *
+   * The channel to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + * + * @return Whether the channel field is set. + */ + @java.lang.Override + public boolean hasChannel() { + return channel_ != null; + } + /** + * + * + *
+   * The channel to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + * + * @return The channel. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel getChannel() { + return channel_ == null ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; + } + /** + * + * + *
+   * The channel to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { + return getChannel(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return updateMask_ != null; + } + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 3; + private boolean validateOnly_; + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (channel_ != null) { + output.writeMessage(1, getChannel()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + if (validateOnly_ != false) { + output.writeBool(3, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (channel_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getChannel()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, validateOnly_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.UpdateChannelRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.UpdateChannelRequest other = + (com.google.cloud.eventarc.v1.UpdateChannelRequest) obj; + + if (hasChannel() != other.hasChannel()) return false; + if (hasChannel()) { + if (!getChannel().equals(other.getChannel())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (getValidateOnly() != other.getValidateOnly()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasChannel()) { + hash = (37 * hash) + CHANNEL_FIELD_NUMBER; + hash = (53 * hash) + getChannel().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.UpdateChannelRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the UpdateChannel method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.UpdateChannelRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.UpdateChannelRequest) + com.google.cloud.eventarc.v1.UpdateChannelRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.UpdateChannelRequest.class, + com.google.cloud.eventarc.v1.UpdateChannelRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.UpdateChannelRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (channelBuilder_ == null) { + channel_ = null; + } else { + channel_ = null; + channelBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + validateOnly_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateChannelRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.UpdateChannelRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateChannelRequest build() { + com.google.cloud.eventarc.v1.UpdateChannelRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateChannelRequest buildPartial() { + com.google.cloud.eventarc.v1.UpdateChannelRequest result = + new com.google.cloud.eventarc.v1.UpdateChannelRequest(this); + if (channelBuilder_ == null) { + result.channel_ = channel_; + } else { + result.channel_ = channelBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + result.validateOnly_ = validateOnly_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.UpdateChannelRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.UpdateChannelRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.UpdateChannelRequest other) { + if (other == com.google.cloud.eventarc.v1.UpdateChannelRequest.getDefaultInstance()) + return this; + if (other.hasChannel()) { + mergeChannel(other.getChannel()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getChannelFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 24: + { + validateOnly_ = input.readBool(); + + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.cloud.eventarc.v1.Channel channel_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + channelBuilder_; + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + * + * @return Whether the channel field is set. + */ + public boolean hasChannel() { + return channelBuilder_ != null || channel_ != null; + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + * + * @return The channel. + */ + public com.google.cloud.eventarc.v1.Channel getChannel() { + if (channelBuilder_ == null) { + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; + } else { + return channelBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + public Builder setChannel(com.google.cloud.eventarc.v1.Channel value) { + if (channelBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + channel_ = value; + onChanged(); + } else { + channelBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + public Builder setChannel(com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + if (channelBuilder_ == null) { + channel_ = builderForValue.build(); + onChanged(); + } else { + channelBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + public Builder mergeChannel(com.google.cloud.eventarc.v1.Channel value) { + if (channelBuilder_ == null) { + if (channel_ != null) { + channel_ = + com.google.cloud.eventarc.v1.Channel.newBuilder(channel_) + .mergeFrom(value) + .buildPartial(); + } else { + channel_ = value; + } + onChanged(); + } else { + channelBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + public Builder clearChannel() { + if (channelBuilder_ == null) { + channel_ = null; + onChanged(); + } else { + channel_ = null; + channelBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + public com.google.cloud.eventarc.v1.Channel.Builder getChannelBuilder() { + + onChanged(); + return getChannelFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { + if (channelBuilder_ != null) { + return channelBuilder_.getMessageOrBuilder(); + } else { + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; + } + } + /** + * + * + *
+     * The channel to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + getChannelFieldBuilder() { + if (channelBuilder_ == null) { + channelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder>( + getChannel(), getParentForChildren(), isClean()); + channel_ = null; + } + return channelBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private boolean validateOnly_; + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.UpdateChannelRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.UpdateChannelRequest) + private static final com.google.cloud.eventarc.v1.UpdateChannelRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.UpdateChannelRequest(); + } + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateChannelRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java new file mode 100644 index 000000000000..82601981d0ec --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java @@ -0,0 +1,115 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface UpdateChannelRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.UpdateChannelRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The channel to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + * + * @return Whether the channel field is set. + */ + boolean hasChannel(); + /** + * + * + *
+   * The channel to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + * + * @return The channel. + */ + com.google.cloud.eventarc.v1.Channel getChannel(); + /** + * + * + *
+   * The channel to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Channel channel = 1; + */ + com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder(); + + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); + + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java new file mode 100644 index 000000000000..22b465ec31cc --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java @@ -0,0 +1,1025 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the UpdateGoogleChannelConfig method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest} + */ +public final class UpdateGoogleChannelConfigRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) + UpdateGoogleChannelConfigRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateGoogleChannelConfigRequest.newBuilder() to construct. + private UpdateGoogleChannelConfigRequest( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateGoogleChannelConfigRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateGoogleChannelConfigRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.Builder.class); + } + + public static final int GOOGLE_CHANNEL_CONFIG_FIELD_NUMBER = 1; + private com.google.cloud.eventarc.v1.GoogleChannelConfig googleChannelConfig_; + /** + * + * + *
+   * Required. The config to be updated.
+   * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the googleChannelConfig field is set. + */ + @java.lang.Override + public boolean hasGoogleChannelConfig() { + return googleChannelConfig_ != null; + } + /** + * + * + *
+   * Required. The config to be updated.
+   * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The googleChannelConfig. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig() { + return googleChannelConfig_ == null + ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() + : googleChannelConfig_; + } + /** + * + * + *
+   * Required. The config to be updated.
+   * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder + getGoogleChannelConfigOrBuilder() { + return getGoogleChannelConfig(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return updateMask_ != null; + } + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (googleChannelConfig_ != null) { + output.writeMessage(1, getGoogleChannelConfig()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (googleChannelConfig_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGoogleChannelConfig()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest other = + (com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) obj; + + if (hasGoogleChannelConfig() != other.hasGoogleChannelConfig()) return false; + if (hasGoogleChannelConfig()) { + if (!getGoogleChannelConfig().equals(other.getGoogleChannelConfig())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasGoogleChannelConfig()) { + hash = (37 * hash) + GOOGLE_CHANNEL_CONFIG_FIELD_NUMBER; + hash = (53 * hash) + getGoogleChannelConfig().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the UpdateGoogleChannelConfig method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (googleChannelConfigBuilder_ == null) { + googleChannelConfig_ = null; + } else { + googleChannelConfig_ = null; + googleChannelConfigBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest + getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest build() { + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest buildPartial() { + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest result = + new com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest(this); + if (googleChannelConfigBuilder_ == null) { + result.googleChannelConfig_ = googleChannelConfig_; + } else { + result.googleChannelConfig_ = googleChannelConfigBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest other) { + if (other + == com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.getDefaultInstance()) + return this; + if (other.hasGoogleChannelConfig()) { + mergeGoogleChannelConfig(other.getGoogleChannelConfig()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getGoogleChannelConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.cloud.eventarc.v1.GoogleChannelConfig googleChannelConfig_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GoogleChannelConfig, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder> + googleChannelConfigBuilder_; + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the googleChannelConfig field is set. + */ + public boolean hasGoogleChannelConfig() { + return googleChannelConfigBuilder_ != null || googleChannelConfig_ != null; + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The googleChannelConfig. + */ + public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig() { + if (googleChannelConfigBuilder_ == null) { + return googleChannelConfig_ == null + ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() + : googleChannelConfig_; + } else { + return googleChannelConfigBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGoogleChannelConfig(com.google.cloud.eventarc.v1.GoogleChannelConfig value) { + if (googleChannelConfigBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + googleChannelConfig_ = value; + onChanged(); + } else { + googleChannelConfigBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGoogleChannelConfig( + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder builderForValue) { + if (googleChannelConfigBuilder_ == null) { + googleChannelConfig_ = builderForValue.build(); + onChanged(); + } else { + googleChannelConfigBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeGoogleChannelConfig( + com.google.cloud.eventarc.v1.GoogleChannelConfig value) { + if (googleChannelConfigBuilder_ == null) { + if (googleChannelConfig_ != null) { + googleChannelConfig_ = + com.google.cloud.eventarc.v1.GoogleChannelConfig.newBuilder(googleChannelConfig_) + .mergeFrom(value) + .buildPartial(); + } else { + googleChannelConfig_ = value; + } + onChanged(); + } else { + googleChannelConfigBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearGoogleChannelConfig() { + if (googleChannelConfigBuilder_ == null) { + googleChannelConfig_ = null; + onChanged(); + } else { + googleChannelConfig_ = null; + googleChannelConfigBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder + getGoogleChannelConfigBuilder() { + + onChanged(); + return getGoogleChannelConfigFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder + getGoogleChannelConfigOrBuilder() { + if (googleChannelConfigBuilder_ != null) { + return googleChannelConfigBuilder_.getMessageOrBuilder(); + } else { + return googleChannelConfig_ == null + ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() + : googleChannelConfig_; + } + } + /** + * + * + *
+     * Required. The config to be updated.
+     * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GoogleChannelConfig, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder> + getGoogleChannelConfigFieldBuilder() { + if (googleChannelConfigBuilder_ == null) { + googleChannelConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GoogleChannelConfig, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder>( + getGoogleChannelConfig(), getParentForChildren(), isClean()); + googleChannelConfig_ = null; + } + return googleChannelConfigBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) + private static final com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest(); + } + + public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateGoogleChannelConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java new file mode 100644 index 000000000000..ac41284ecb50 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java @@ -0,0 +1,107 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface UpdateGoogleChannelConfigRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The config to be updated.
+   * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the googleChannelConfig field is set. + */ + boolean hasGoogleChannelConfig(); + /** + * + * + *
+   * Required. The config to be updated.
+   * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The googleChannelConfig. + */ + com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig(); + /** + * + * + *
+   * Required. The config to be updated.
+   * 
+ * + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChannelConfigOrBuilder(); + + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java new file mode 100644 index 000000000000..7f572a08167f --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java @@ -0,0 +1,1178 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +/** + * + * + *
+ * The request message for the UpdateTrigger method.
+ * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.UpdateTriggerRequest} + */ +public final class UpdateTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.UpdateTriggerRequest) + UpdateTriggerRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateTriggerRequest.newBuilder() to construct. + private UpdateTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateTriggerRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateTriggerRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, + com.google.cloud.eventarc.v1.UpdateTriggerRequest.Builder.class); + } + + public static final int TRIGGER_FIELD_NUMBER = 1; + private com.google.cloud.eventarc.v1.Trigger trigger_; + /** + * + * + *
+   * The trigger to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + * + * @return Whether the trigger field is set. + */ + @java.lang.Override + public boolean hasTrigger() { + return trigger_ != null; + } + /** + * + * + *
+   * The trigger to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + * + * @return The trigger. + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.Trigger getTrigger() { + return trigger_ == null ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; + } + /** + * + * + *
+   * The trigger to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + @java.lang.Override + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { + return getTrigger(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return updateMask_ != null; + } + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + public static final int ALLOW_MISSING_FIELD_NUMBER = 3; + private boolean allowMissing_; + /** + * + * + *
+   * If set to true, and the trigger is not found, a new trigger will be
+   * created. In this situation, `update_mask` is ignored.
+   * 
+ * + * bool allow_missing = 3; + * + * @return The allowMissing. + */ + @java.lang.Override + public boolean getAllowMissing() { + return allowMissing_; + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; + private boolean validateOnly_; + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (trigger_ != null) { + output.writeMessage(1, getTrigger()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + if (allowMissing_ != false) { + output.writeBool(3, allowMissing_); + } + if (validateOnly_ != false) { + output.writeBool(4, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (trigger_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTrigger()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + if (allowMissing_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowMissing_); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.eventarc.v1.UpdateTriggerRequest)) { + return super.equals(obj); + } + com.google.cloud.eventarc.v1.UpdateTriggerRequest other = + (com.google.cloud.eventarc.v1.UpdateTriggerRequest) obj; + + if (hasTrigger() != other.hasTrigger()) return false; + if (hasTrigger()) { + if (!getTrigger().equals(other.getTrigger())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (getAllowMissing() != other.getAllowMissing()) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasTrigger()) { + hash = (37 * hash) + TRIGGER_FIELD_NUMBER; + hash = (53 * hash) + getTrigger().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (37 * hash) + ALLOW_MISSING_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowMissing()); + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.cloud.eventarc.v1.UpdateTriggerRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request message for the UpdateTrigger method.
+   * 
+ * + * Protobuf type {@code google.cloud.eventarc.v1.UpdateTriggerRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.UpdateTriggerRequest) + com.google.cloud.eventarc.v1.UpdateTriggerRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, + com.google.cloud.eventarc.v1.UpdateTriggerRequest.Builder.class); + } + + // Construct using com.google.cloud.eventarc.v1.UpdateTriggerRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (triggerBuilder_ == null) { + trigger_ = null; + } else { + trigger_ = null; + triggerBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + allowMissing_ = false; + + validateOnly_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateTriggerRequest getDefaultInstanceForType() { + return com.google.cloud.eventarc.v1.UpdateTriggerRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateTriggerRequest build() { + com.google.cloud.eventarc.v1.UpdateTriggerRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateTriggerRequest buildPartial() { + com.google.cloud.eventarc.v1.UpdateTriggerRequest result = + new com.google.cloud.eventarc.v1.UpdateTriggerRequest(this); + if (triggerBuilder_ == null) { + result.trigger_ = trigger_; + } else { + result.trigger_ = triggerBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + result.allowMissing_ = allowMissing_; + result.validateOnly_ = validateOnly_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.eventarc.v1.UpdateTriggerRequest) { + return mergeFrom((com.google.cloud.eventarc.v1.UpdateTriggerRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.eventarc.v1.UpdateTriggerRequest other) { + if (other == com.google.cloud.eventarc.v1.UpdateTriggerRequest.getDefaultInstance()) + return this; + if (other.hasTrigger()) { + mergeTrigger(other.getTrigger()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (other.getAllowMissing() != false) { + setAllowMissing(other.getAllowMissing()); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 24: + { + allowMissing_ = input.readBool(); + + break; + } // case 24 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.cloud.eventarc.v1.Trigger trigger_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + triggerBuilder_; + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + * + * @return Whether the trigger field is set. + */ + public boolean hasTrigger() { + return triggerBuilder_ != null || trigger_ != null; + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + * + * @return The trigger. + */ + public com.google.cloud.eventarc.v1.Trigger getTrigger() { + if (triggerBuilder_ == null) { + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; + } else { + return triggerBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger value) { + if (triggerBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + trigger_ = value; + onChanged(); + } else { + triggerBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + if (triggerBuilder_ == null) { + trigger_ = builderForValue.build(); + onChanged(); + } else { + triggerBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + public Builder mergeTrigger(com.google.cloud.eventarc.v1.Trigger value) { + if (triggerBuilder_ == null) { + if (trigger_ != null) { + trigger_ = + com.google.cloud.eventarc.v1.Trigger.newBuilder(trigger_) + .mergeFrom(value) + .buildPartial(); + } else { + trigger_ = value; + } + onChanged(); + } else { + triggerBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + public Builder clearTrigger() { + if (triggerBuilder_ == null) { + trigger_ = null; + onChanged(); + } else { + trigger_ = null; + triggerBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + public com.google.cloud.eventarc.v1.Trigger.Builder getTriggerBuilder() { + + onChanged(); + return getTriggerFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { + if (triggerBuilder_ != null) { + return triggerBuilder_.getMessageOrBuilder(); + } else { + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; + } + } + /** + * + * + *
+     * The trigger to be updated.
+     * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + getTriggerFieldBuilder() { + if (triggerBuilder_ == null) { + triggerBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder>( + getTrigger(), getParentForChildren(), isClean()); + trigger_ = null; + } + return triggerBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + /** + * + * + *
+     * The fields to be updated; only fields explicitly provided are updated.
+     * If no field mask is provided, all provided fields in the request are
+     * updated. To update all fields, provide a field mask of "*".
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private boolean allowMissing_; + /** + * + * + *
+     * If set to true, and the trigger is not found, a new trigger will be
+     * created. In this situation, `update_mask` is ignored.
+     * 
+ * + * bool allow_missing = 3; + * + * @return The allowMissing. + */ + @java.lang.Override + public boolean getAllowMissing() { + return allowMissing_; + } + /** + * + * + *
+     * If set to true, and the trigger is not found, a new trigger will be
+     * created. In this situation, `update_mask` is ignored.
+     * 
+ * + * bool allow_missing = 3; + * + * @param value The allowMissing to set. + * @return This builder for chaining. + */ + public Builder setAllowMissing(boolean value) { + + allowMissing_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * If set to true, and the trigger is not found, a new trigger will be
+     * created. In this situation, `update_mask` is ignored.
+     * 
+ * + * bool allow_missing = 3; + * + * @return This builder for chaining. + */ + public Builder clearAllowMissing() { + + allowMissing_ = false; + onChanged(); + return this; + } + + private boolean validateOnly_; + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. If set, validate the request and preview the review, but do not
+     * post it.
+     * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.UpdateTriggerRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.UpdateTriggerRequest) + private static final com.google.cloud.eventarc.v1.UpdateTriggerRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.UpdateTriggerRequest(); + } + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.eventarc.v1.UpdateTriggerRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java new file mode 100644 index 000000000000..352f4054f793 --- /dev/null +++ b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java @@ -0,0 +1,129 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public interface UpdateTriggerRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.UpdateTriggerRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The trigger to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + * + * @return Whether the trigger field is set. + */ + boolean hasTrigger(); + /** + * + * + *
+   * The trigger to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + * + * @return The trigger. + */ + com.google.cloud.eventarc.v1.Trigger getTrigger(); + /** + * + * + *
+   * The trigger to be updated.
+   * 
+ * + * .google.cloud.eventarc.v1.Trigger trigger = 1; + */ + com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder(); + + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * The fields to be updated; only fields explicitly provided are updated.
+   * If no field mask is provided, all provided fields in the request are
+   * updated. To update all fields, provide a field mask of "*".
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2; + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); + + /** + * + * + *
+   * If set to true, and the trigger is not found, a new trigger will be
+   * created. In this situation, `update_mask` is ignored.
+   * 
+ * + * bool allow_missing = 3; + * + * @return The allowMissing. + */ + boolean getAllowMissing(); + + /** + * + * + *
+   * Required. If set, validate the request and preview the review, but do not
+   * post it.
+   * 
+ * + * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto b/java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto similarity index 100% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto rename to java-eventarc/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java diff --git a/owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java b/java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java similarity index 100% rename from owl-bot-staging/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java rename to java-eventarc/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java new file mode 100644 index 000000000000..befd0432cfb5 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcClient.java @@ -0,0 +1,3509 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.ApiFuture; +import com.google.api.core.ApiFutures; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.httpjson.longrunning.OperationsClient; +import com.google.api.gax.longrunning.OperationFuture; +import com.google.api.gax.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.eventarc.v1.stub.EventarcStub; +import com.google.cloud.eventarc.v1.stub.EventarcStubSettings; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: Eventarc allows users to subscribe to various events that are provided by + * Google Cloud services and forward them to supported destinations. + * + *

This class provides the ability to make remote calls to the backing service through method + * calls that map to API methods. Sample code to get started: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (EventarcClient eventarcClient = EventarcClient.create()) {
+ *   TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]");
+ *   Trigger response = eventarcClient.getTrigger(name);
+ * }
+ * }
+ * + *

Note: close() needs to be called on the EventarcClient object to clean up resources such as + * threads. In the example above, try-with-resources is used, which automatically calls close(). + * + *

The surface of this class includes several types of Java methods for each of the API's + * methods: + * + *

    + *
  1. A "flattened" method. With this type of method, the fields of the request type have been + * converted into function parameters. It may be the case that not all fields are available as + * parameters, and not every API method will have a flattened method entry point. + *
  2. A "request object" method. This type of method only takes one parameter, a request object, + * which must be constructed before the call. Not every API method will have a request object + * method. + *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API + * callable object, which can be used to initiate calls to the service. + *
+ * + *

See the individual methods for example code. + * + *

Many parameters require resource names to be formatted in a particular way. To assist with + * these names, this class includes a format method for each type of name, and additionally a parse + * method to extract the individual identifiers contained within names that are returned. + * + *

This class can be customized by passing in a custom instance of EventarcSettings to create(). + * For example: + * + *

To customize credentials: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * EventarcSettings eventarcSettings =
+ *     EventarcSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * EventarcClient eventarcClient = EventarcClient.create(eventarcSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * EventarcSettings eventarcSettings =
+ *     EventarcSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * EventarcClient eventarcClient = EventarcClient.create(eventarcSettings);
+ * }
+ * + *

To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over + * the wire: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * EventarcSettings eventarcSettings = EventarcSettings.newHttpJsonBuilder().build();
+ * EventarcClient eventarcClient = EventarcClient.create(eventarcSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@Generated("by gapic-generator-java") +public class EventarcClient implements BackgroundResource { + private final EventarcSettings settings; + private final EventarcStub stub; + private final OperationsClient httpJsonOperationsClient; + private final com.google.longrunning.OperationsClient operationsClient; + + /** Constructs an instance of EventarcClient with default settings. */ + public static final EventarcClient create() throws IOException { + return create(EventarcSettings.newBuilder().build()); + } + + /** + * Constructs an instance of EventarcClient, using the given settings. The channels are created + * based on the settings passed in, or defaults for any settings that are not set. + */ + public static final EventarcClient create(EventarcSettings settings) throws IOException { + return new EventarcClient(settings); + } + + /** + * Constructs an instance of EventarcClient, using the given stub for making calls. This is for + * advanced usage - prefer using create(EventarcSettings). + */ + public static final EventarcClient create(EventarcStub stub) { + return new EventarcClient(stub); + } + + /** + * Constructs an instance of EventarcClient, using the given settings. This is protected so that + * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. + */ + protected EventarcClient(EventarcSettings settings) throws IOException { + this.settings = settings; + this.stub = ((EventarcStubSettings) settings.getStubSettings()).createStub(); + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + protected EventarcClient(EventarcStub stub) { + this.settings = null; + this.stub = stub; + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + public final EventarcSettings getSettings() { + return settings; + } + + public EventarcStub getStub() { + return stub; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + public final com.google.longrunning.OperationsClient getOperationsClient() { + return operationsClient; + } + + /** + * Returns the OperationsClient that can be used to query the status of a long-running operation + * returned by another API method call. + */ + @BetaApi + public final OperationsClient getHttpJsonOperationsClient() { + return httpJsonOperationsClient; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]");
+   *   Trigger response = eventarcClient.getTrigger(name);
+   * }
+   * }
+ * + * @param name Required. The name of the trigger to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Trigger getTrigger(TriggerName name) { + GetTriggerRequest request = + GetTriggerRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getTrigger(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString();
+   *   Trigger response = eventarcClient.getTrigger(name);
+   * }
+   * }
+ * + * @param name Required. The name of the trigger to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Trigger getTrigger(String name) { + GetTriggerRequest request = GetTriggerRequest.newBuilder().setName(name).build(); + return getTrigger(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetTriggerRequest request =
+   *       GetTriggerRequest.newBuilder()
+   *           .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString())
+   *           .build();
+   *   Trigger response = eventarcClient.getTrigger(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Trigger getTrigger(GetTriggerRequest request) { + return getTriggerCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetTriggerRequest request =
+   *       GetTriggerRequest.newBuilder()
+   *           .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString())
+   *           .build();
+   *   ApiFuture future = eventarcClient.getTriggerCallable().futureCall(request);
+   *   // Do something.
+   *   Trigger response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getTriggerCallable() { + return stub.getTriggerCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List triggers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Trigger element : eventarcClient.listTriggers(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent collection to list triggers on. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListTriggersPagedResponse listTriggers(LocationName parent) { + ListTriggersRequest request = + ListTriggersRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listTriggers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List triggers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Trigger element : eventarcClient.listTriggers(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent collection to list triggers on. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListTriggersPagedResponse listTriggers(String parent) { + ListTriggersRequest request = ListTriggersRequest.newBuilder().setParent(parent).build(); + return listTriggers(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List triggers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListTriggersRequest request =
+   *       ListTriggersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   for (Trigger element : eventarcClient.listTriggers(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListTriggersPagedResponse listTriggers(ListTriggersRequest request) { + return listTriggersPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List triggers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListTriggersRequest request =
+   *       ListTriggersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   ApiFuture future = eventarcClient.listTriggersPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Trigger element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listTriggersPagedCallable() { + return stub.listTriggersPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List triggers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListTriggersRequest request =
+   *       ListTriggersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   while (true) {
+   *     ListTriggersResponse response = eventarcClient.listTriggersCallable().call(request);
+   *     for (Trigger element : response.getTriggersList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listTriggersCallable() { + return stub.listTriggersCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new trigger in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   Trigger trigger = Trigger.newBuilder().build();
+   *   String triggerId = "triggerId-648752909";
+   *   Trigger response = eventarcClient.createTriggerAsync(parent, trigger, triggerId).get();
+   * }
+   * }
+ * + * @param parent Required. The parent collection in which to add this trigger. + * @param trigger Required. The trigger to create. + * @param triggerId Required. The user-provided ID to be assigned to the trigger. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createTriggerAsync( + LocationName parent, Trigger trigger, String triggerId) { + CreateTriggerRequest request = + CreateTriggerRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setTrigger(trigger) + .setTriggerId(triggerId) + .build(); + return createTriggerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new trigger in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   Trigger trigger = Trigger.newBuilder().build();
+   *   String triggerId = "triggerId-648752909";
+   *   Trigger response = eventarcClient.createTriggerAsync(parent, trigger, triggerId).get();
+   * }
+   * }
+ * + * @param parent Required. The parent collection in which to add this trigger. + * @param trigger Required. The trigger to create. + * @param triggerId Required. The user-provided ID to be assigned to the trigger. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createTriggerAsync( + String parent, Trigger trigger, String triggerId) { + CreateTriggerRequest request = + CreateTriggerRequest.newBuilder() + .setParent(parent) + .setTrigger(trigger) + .setTriggerId(triggerId) + .build(); + return createTriggerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new trigger in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateTriggerRequest request =
+   *       CreateTriggerRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setTrigger(Trigger.newBuilder().build())
+   *           .setTriggerId("triggerId-648752909")
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Trigger response = eventarcClient.createTriggerAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createTriggerAsync( + CreateTriggerRequest request) { + return createTriggerOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new trigger in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateTriggerRequest request =
+   *       CreateTriggerRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setTrigger(Trigger.newBuilder().build())
+   *           .setTriggerId("triggerId-648752909")
+   *           .setValidateOnly(true)
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.createTriggerOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Trigger response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + createTriggerOperationCallable() { + return stub.createTriggerOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new trigger in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateTriggerRequest request =
+   *       CreateTriggerRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setTrigger(Trigger.newBuilder().build())
+   *           .setTriggerId("triggerId-648752909")
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future = eventarcClient.createTriggerCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable createTriggerCallable() { + return stub.createTriggerCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   Trigger trigger = Trigger.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   boolean allowMissing = true;
+   *   Trigger response = eventarcClient.updateTriggerAsync(trigger, updateMask, allowMissing).get();
+   * }
+   * }
+ * + * @param trigger The trigger to be updated. + * @param updateMask The fields to be updated; only fields explicitly provided are updated. If no + * field mask is provided, all provided fields in the request are updated. To update all + * fields, provide a field mask of "*". + * @param allowMissing If set to true, and the trigger is not found, a new trigger will be + * created. In this situation, `update_mask` is ignored. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateTriggerAsync( + Trigger trigger, FieldMask updateMask, boolean allowMissing) { + UpdateTriggerRequest request = + UpdateTriggerRequest.newBuilder() + .setTrigger(trigger) + .setUpdateMask(updateMask) + .setAllowMissing(allowMissing) + .build(); + return updateTriggerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateTriggerRequest request =
+   *       UpdateTriggerRequest.newBuilder()
+   *           .setTrigger(Trigger.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setAllowMissing(true)
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Trigger response = eventarcClient.updateTriggerAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateTriggerAsync( + UpdateTriggerRequest request) { + return updateTriggerOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateTriggerRequest request =
+   *       UpdateTriggerRequest.newBuilder()
+   *           .setTrigger(Trigger.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setAllowMissing(true)
+   *           .setValidateOnly(true)
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.updateTriggerOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Trigger response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + updateTriggerOperationCallable() { + return stub.updateTriggerOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateTriggerRequest request =
+   *       UpdateTriggerRequest.newBuilder()
+   *           .setTrigger(Trigger.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setAllowMissing(true)
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future = eventarcClient.updateTriggerCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateTriggerCallable() { + return stub.updateTriggerCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]");
+   *   boolean allowMissing = true;
+   *   Trigger response = eventarcClient.deleteTriggerAsync(name, allowMissing).get();
+   * }
+   * }
+ * + * @param name Required. The name of the trigger to be deleted. + * @param allowMissing If set to true, and the trigger is not found, the request will succeed but + * no action will be taken on the server. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteTriggerAsync( + TriggerName name, boolean allowMissing) { + DeleteTriggerRequest request = + DeleteTriggerRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .setAllowMissing(allowMissing) + .build(); + return deleteTriggerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString();
+   *   boolean allowMissing = true;
+   *   Trigger response = eventarcClient.deleteTriggerAsync(name, allowMissing).get();
+   * }
+   * }
+ * + * @param name Required. The name of the trigger to be deleted. + * @param allowMissing If set to true, and the trigger is not found, the request will succeed but + * no action will be taken on the server. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteTriggerAsync( + String name, boolean allowMissing) { + DeleteTriggerRequest request = + DeleteTriggerRequest.newBuilder().setName(name).setAllowMissing(allowMissing).build(); + return deleteTriggerAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteTriggerRequest request =
+   *       DeleteTriggerRequest.newBuilder()
+   *           .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString())
+   *           .setEtag("etag3123477")
+   *           .setAllowMissing(true)
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Trigger response = eventarcClient.deleteTriggerAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteTriggerAsync( + DeleteTriggerRequest request) { + return deleteTriggerOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteTriggerRequest request =
+   *       DeleteTriggerRequest.newBuilder()
+   *           .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString())
+   *           .setEtag("etag3123477")
+   *           .setAllowMissing(true)
+   *           .setValidateOnly(true)
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.deleteTriggerOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Trigger response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + deleteTriggerOperationCallable() { + return stub.deleteTriggerOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single trigger. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteTriggerRequest request =
+   *       DeleteTriggerRequest.newBuilder()
+   *           .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString())
+   *           .setEtag("etag3123477")
+   *           .setAllowMissing(true)
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future = eventarcClient.deleteTriggerCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable deleteTriggerCallable() { + return stub.deleteTriggerCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]");
+   *   Channel response = eventarcClient.getChannel(name);
+   * }
+   * }
+ * + * @param name Required. The name of the channel to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Channel getChannel(ChannelName name) { + GetChannelRequest request = + GetChannelRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getChannel(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString();
+   *   Channel response = eventarcClient.getChannel(name);
+   * }
+   * }
+ * + * @param name Required. The name of the channel to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Channel getChannel(String name) { + GetChannelRequest request = GetChannelRequest.newBuilder().setName(name).build(); + return getChannel(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetChannelRequest request =
+   *       GetChannelRequest.newBuilder()
+   *           .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .build();
+   *   Channel response = eventarcClient.getChannel(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Channel getChannel(GetChannelRequest request) { + return getChannelCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetChannelRequest request =
+   *       GetChannelRequest.newBuilder()
+   *           .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .build();
+   *   ApiFuture future = eventarcClient.getChannelCallable().futureCall(request);
+   *   // Do something.
+   *   Channel response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getChannelCallable() { + return stub.getChannelCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channels. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Channel element : eventarcClient.listChannels(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent collection to list channels on. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListChannelsPagedResponse listChannels(LocationName parent) { + ListChannelsRequest request = + ListChannelsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listChannels(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channels. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Channel element : eventarcClient.listChannels(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent collection to list channels on. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListChannelsPagedResponse listChannels(String parent) { + ListChannelsRequest request = ListChannelsRequest.newBuilder().setParent(parent).build(); + return listChannels(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channels. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListChannelsRequest request =
+   *       ListChannelsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (Channel element : eventarcClient.listChannels(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListChannelsPagedResponse listChannels(ListChannelsRequest request) { + return listChannelsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channels. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListChannelsRequest request =
+   *       ListChannelsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future = eventarcClient.listChannelsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Channel element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listChannelsPagedCallable() { + return stub.listChannelsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channels. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListChannelsRequest request =
+   *       ListChannelsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListChannelsResponse response = eventarcClient.listChannelsCallable().call(request);
+   *     for (Channel element : response.getChannelsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listChannelsCallable() { + return stub.listChannelsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new channel in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   Channel channel = Channel.newBuilder().build();
+   *   String channelId = "channelId1461735806";
+   *   Channel response = eventarcClient.createChannelAsync(parent, channel, channelId).get();
+   * }
+   * }
+ * + * @param parent Required. The parent collection in which to add this channel. + * @param channel Required. The channel to create. + * @param channelId Required. The user-provided ID to be assigned to the channel. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createChannelAsync( + LocationName parent, Channel channel, String channelId) { + CreateChannelRequest request = + CreateChannelRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setChannel(channel) + .setChannelId(channelId) + .build(); + return createChannelAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new channel in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   Channel channel = Channel.newBuilder().build();
+   *   String channelId = "channelId1461735806";
+   *   Channel response = eventarcClient.createChannelAsync(parent, channel, channelId).get();
+   * }
+   * }
+ * + * @param parent Required. The parent collection in which to add this channel. + * @param channel Required. The channel to create. + * @param channelId Required. The user-provided ID to be assigned to the channel. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createChannelAsync( + String parent, Channel channel, String channelId) { + CreateChannelRequest request = + CreateChannelRequest.newBuilder() + .setParent(parent) + .setChannel(channel) + .setChannelId(channelId) + .build(); + return createChannelAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new channel in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateChannelRequest request =
+   *       CreateChannelRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setChannel(Channel.newBuilder().build())
+   *           .setChannelId("channelId1461735806")
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Channel response = eventarcClient.createChannelAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createChannelAsync( + CreateChannelRequest request) { + return createChannelOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new channel in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateChannelRequest request =
+   *       CreateChannelRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setChannel(Channel.newBuilder().build())
+   *           .setChannelId("channelId1461735806")
+   *           .setValidateOnly(true)
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.createChannelOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Channel response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + createChannelOperationCallable() { + return stub.createChannelOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new channel in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateChannelRequest request =
+   *       CreateChannelRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setChannel(Channel.newBuilder().build())
+   *           .setChannelId("channelId1461735806")
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future = eventarcClient.createChannelCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable createChannelCallable() { + return stub.createChannelCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   Channel channel = Channel.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Channel response = eventarcClient.updateChannelAsync(channel, updateMask).get();
+   * }
+   * }
+ * + * @param channel The channel to be updated. + * @param updateMask The fields to be updated; only fields explicitly provided are updated. If no + * field mask is provided, all provided fields in the request are updated. To update all + * fields, provide a field mask of "*". + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateChannelAsync( + Channel channel, FieldMask updateMask) { + UpdateChannelRequest request = + UpdateChannelRequest.newBuilder().setChannel(channel).setUpdateMask(updateMask).build(); + return updateChannelAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateChannelRequest request =
+   *       UpdateChannelRequest.newBuilder()
+   *           .setChannel(Channel.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Channel response = eventarcClient.updateChannelAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateChannelAsync( + UpdateChannelRequest request) { + return updateChannelOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateChannelRequest request =
+   *       UpdateChannelRequest.newBuilder()
+   *           .setChannel(Channel.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.updateChannelOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Channel response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + updateChannelOperationCallable() { + return stub.updateChannelOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateChannelRequest request =
+   *       UpdateChannelRequest.newBuilder()
+   *           .setChannel(Channel.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future = eventarcClient.updateChannelCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateChannelCallable() { + return stub.updateChannelCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]");
+   *   Channel response = eventarcClient.deleteChannelAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the channel to be deleted. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteChannelAsync(ChannelName name) { + DeleteChannelRequest request = + DeleteChannelRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteChannelAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString();
+   *   Channel response = eventarcClient.deleteChannelAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the channel to be deleted. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteChannelAsync(String name) { + DeleteChannelRequest request = DeleteChannelRequest.newBuilder().setName(name).build(); + return deleteChannelAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteChannelRequest request =
+   *       DeleteChannelRequest.newBuilder()
+   *           .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Channel response = eventarcClient.deleteChannelAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteChannelAsync( + DeleteChannelRequest request) { + return deleteChannelOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteChannelRequest request =
+   *       DeleteChannelRequest.newBuilder()
+   *           .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.deleteChannelOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Channel response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + deleteChannelOperationCallable() { + return stub.deleteChannelOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single channel. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteChannelRequest request =
+   *       DeleteChannelRequest.newBuilder()
+   *           .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future = eventarcClient.deleteChannelCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable deleteChannelCallable() { + return stub.deleteChannelCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Provider. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ProviderName name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]");
+   *   Provider response = eventarcClient.getProvider(name);
+   * }
+   * }
+ * + * @param name Required. The name of the provider to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Provider getProvider(ProviderName name) { + GetProviderRequest request = + GetProviderRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getProvider(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Provider. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString();
+   *   Provider response = eventarcClient.getProvider(name);
+   * }
+   * }
+ * + * @param name Required. The name of the provider to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Provider getProvider(String name) { + GetProviderRequest request = GetProviderRequest.newBuilder().setName(name).build(); + return getProvider(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Provider. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetProviderRequest request =
+   *       GetProviderRequest.newBuilder()
+   *           .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString())
+   *           .build();
+   *   Provider response = eventarcClient.getProvider(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Provider getProvider(GetProviderRequest request) { + return getProviderCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single Provider. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetProviderRequest request =
+   *       GetProviderRequest.newBuilder()
+   *           .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString())
+   *           .build();
+   *   ApiFuture future = eventarcClient.getProviderCallable().futureCall(request);
+   *   // Do something.
+   *   Provider response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getProviderCallable() { + return stub.getProviderCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List providers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Provider element : eventarcClient.listProviders(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent of the provider to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListProvidersPagedResponse listProviders(LocationName parent) { + ListProvidersRequest request = + ListProvidersRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listProviders(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List providers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Provider element : eventarcClient.listProviders(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent of the provider to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListProvidersPagedResponse listProviders(String parent) { + ListProvidersRequest request = ListProvidersRequest.newBuilder().setParent(parent).build(); + return listProviders(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List providers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListProvidersRequest request =
+   *       ListProvidersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   for (Provider element : eventarcClient.listProviders(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListProvidersPagedResponse listProviders(ListProvidersRequest request) { + return listProvidersPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List providers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListProvidersRequest request =
+   *       ListProvidersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   ApiFuture future = eventarcClient.listProvidersPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Provider element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listProvidersPagedCallable() { + return stub.listProvidersPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List providers. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListProvidersRequest request =
+   *       ListProvidersRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .setFilter("filter-1274492040")
+   *           .build();
+   *   while (true) {
+   *     ListProvidersResponse response = eventarcClient.listProvidersCallable().call(request);
+   *     for (Provider element : response.getProvidersList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listProvidersCallable() { + return stub.listProvidersCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ChannelConnectionName name =
+   *       ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]");
+   *   ChannelConnection response = eventarcClient.getChannelConnection(name);
+   * }
+   * }
+ * + * @param name Required. The name of the channel connection to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChannelConnection getChannelConnection(ChannelConnectionName name) { + GetChannelConnectionRequest request = + GetChannelConnectionRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getChannelConnection(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name =
+   *       ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]").toString();
+   *   ChannelConnection response = eventarcClient.getChannelConnection(name);
+   * }
+   * }
+ * + * @param name Required. The name of the channel connection to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChannelConnection getChannelConnection(String name) { + GetChannelConnectionRequest request = + GetChannelConnectionRequest.newBuilder().setName(name).build(); + return getChannelConnection(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetChannelConnectionRequest request =
+   *       GetChannelConnectionRequest.newBuilder()
+   *           .setName(
+   *               ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]")
+   *                   .toString())
+   *           .build();
+   *   ChannelConnection response = eventarcClient.getChannelConnection(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ChannelConnection getChannelConnection(GetChannelConnectionRequest request) { + return getChannelConnectionCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetChannelConnectionRequest request =
+   *       GetChannelConnectionRequest.newBuilder()
+   *           .setName(
+   *               ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.getChannelConnectionCallable().futureCall(request);
+   *   // Do something.
+   *   ChannelConnection response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + getChannelConnectionCallable() { + return stub.getChannelConnectionCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channel connections. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (ChannelConnection element : eventarcClient.listChannelConnections(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent collection from which to list channel connections. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListChannelConnectionsPagedResponse listChannelConnections(LocationName parent) { + ListChannelConnectionsRequest request = + ListChannelConnectionsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listChannelConnections(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channel connections. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (ChannelConnection element : eventarcClient.listChannelConnections(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent collection from which to list channel connections. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListChannelConnectionsPagedResponse listChannelConnections(String parent) { + ListChannelConnectionsRequest request = + ListChannelConnectionsRequest.newBuilder().setParent(parent).build(); + return listChannelConnections(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channel connections. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListChannelConnectionsRequest request =
+   *       ListChannelConnectionsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (ChannelConnection element :
+   *       eventarcClient.listChannelConnections(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListChannelConnectionsPagedResponse listChannelConnections( + ListChannelConnectionsRequest request) { + return listChannelConnectionsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channel connections. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListChannelConnectionsRequest request =
+   *       ListChannelConnectionsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.listChannelConnectionsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (ChannelConnection element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listChannelConnectionsPagedCallable() { + return stub.listChannelConnectionsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * List channel connections. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListChannelConnectionsRequest request =
+   *       ListChannelConnectionsRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListChannelConnectionsResponse response =
+   *         eventarcClient.listChannelConnectionsCallable().call(request);
+   *     for (ChannelConnection element : response.getChannelConnectionsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listChannelConnectionsCallable() { + return stub.listChannelConnectionsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new ChannelConnection in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   ChannelConnection channelConnection = ChannelConnection.newBuilder().build();
+   *   String channelConnectionId = "channelConnectionId-1246974660";
+   *   ChannelConnection response =
+   *       eventarcClient
+   *           .createChannelConnectionAsync(parent, channelConnection, channelConnectionId)
+   *           .get();
+   * }
+   * }
+ * + * @param parent Required. The parent collection in which to add this channel connection. + * @param channelConnection Required. Channel connection to create. + * @param channelConnectionId Required. The user-provided ID to be assigned to the channel + * connection. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createChannelConnectionAsync( + LocationName parent, ChannelConnection channelConnection, String channelConnectionId) { + CreateChannelConnectionRequest request = + CreateChannelConnectionRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setChannelConnection(channelConnection) + .setChannelConnectionId(channelConnectionId) + .build(); + return createChannelConnectionAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new ChannelConnection in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   ChannelConnection channelConnection = ChannelConnection.newBuilder().build();
+   *   String channelConnectionId = "channelConnectionId-1246974660";
+   *   ChannelConnection response =
+   *       eventarcClient
+   *           .createChannelConnectionAsync(parent, channelConnection, channelConnectionId)
+   *           .get();
+   * }
+   * }
+ * + * @param parent Required. The parent collection in which to add this channel connection. + * @param channelConnection Required. Channel connection to create. + * @param channelConnectionId Required. The user-provided ID to be assigned to the channel + * connection. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createChannelConnectionAsync( + String parent, ChannelConnection channelConnection, String channelConnectionId) { + CreateChannelConnectionRequest request = + CreateChannelConnectionRequest.newBuilder() + .setParent(parent) + .setChannelConnection(channelConnection) + .setChannelConnectionId(channelConnectionId) + .build(); + return createChannelConnectionAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new ChannelConnection in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateChannelConnectionRequest request =
+   *       CreateChannelConnectionRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setChannelConnection(ChannelConnection.newBuilder().build())
+   *           .setChannelConnectionId("channelConnectionId-1246974660")
+   *           .build();
+   *   ChannelConnection response = eventarcClient.createChannelConnectionAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createChannelConnectionAsync( + CreateChannelConnectionRequest request) { + return createChannelConnectionOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new ChannelConnection in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateChannelConnectionRequest request =
+   *       CreateChannelConnectionRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setChannelConnection(ChannelConnection.newBuilder().build())
+   *           .setChannelConnectionId("channelConnectionId-1246974660")
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.createChannelConnectionOperationCallable().futureCall(request);
+   *   // Do something.
+   *   ChannelConnection response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationCallable() { + return stub.createChannelConnectionOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create a new ChannelConnection in a particular project and location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   CreateChannelConnectionRequest request =
+   *       CreateChannelConnectionRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setChannelConnection(ChannelConnection.newBuilder().build())
+   *           .setChannelConnectionId("channelConnectionId-1246974660")
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.createChannelConnectionCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + createChannelConnectionCallable() { + return stub.createChannelConnectionCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ChannelConnectionName name =
+   *       ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]");
+   *   ChannelConnection response = eventarcClient.deleteChannelConnectionAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the channel connection to delete. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteChannelConnectionAsync( + ChannelConnectionName name) { + DeleteChannelConnectionRequest request = + DeleteChannelConnectionRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return deleteChannelConnectionAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name =
+   *       ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]").toString();
+   *   ChannelConnection response = eventarcClient.deleteChannelConnectionAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the channel connection to delete. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteChannelConnectionAsync( + String name) { + DeleteChannelConnectionRequest request = + DeleteChannelConnectionRequest.newBuilder().setName(name).build(); + return deleteChannelConnectionAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteChannelConnectionRequest request =
+   *       DeleteChannelConnectionRequest.newBuilder()
+   *           .setName(
+   *               ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]")
+   *                   .toString())
+   *           .build();
+   *   ChannelConnection response = eventarcClient.deleteChannelConnectionAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteChannelConnectionAsync( + DeleteChannelConnectionRequest request) { + return deleteChannelConnectionOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteChannelConnectionRequest request =
+   *       DeleteChannelConnectionRequest.newBuilder()
+   *           .setName(
+   *               ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]")
+   *                   .toString())
+   *           .build();
+   *   OperationFuture future =
+   *       eventarcClient.deleteChannelConnectionOperationCallable().futureCall(request);
+   *   // Do something.
+   *   ChannelConnection response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationCallable() { + return stub.deleteChannelConnectionOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Delete a single ChannelConnection. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   DeleteChannelConnectionRequest request =
+   *       DeleteChannelConnectionRequest.newBuilder()
+   *           .setName(
+   *               ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]")
+   *                   .toString())
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.deleteChannelConnectionCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + deleteChannelConnectionCallable() { + return stub.deleteChannelConnectionCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GoogleChannelConfigName name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]");
+   *   GoogleChannelConfig response = eventarcClient.getGoogleChannelConfig(name);
+   * }
+   * }
+ * + * @param name Required. The name of the config to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GoogleChannelConfig getGoogleChannelConfig(GoogleChannelConfigName name) { + GetGoogleChannelConfigRequest request = + GetGoogleChannelConfigRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getGoogleChannelConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   String name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString();
+   *   GoogleChannelConfig response = eventarcClient.getGoogleChannelConfig(name);
+   * }
+   * }
+ * + * @param name Required. The name of the config to get. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GoogleChannelConfig getGoogleChannelConfig(String name) { + GetGoogleChannelConfigRequest request = + GetGoogleChannelConfigRequest.newBuilder().setName(name).build(); + return getGoogleChannelConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetGoogleChannelConfigRequest request =
+   *       GetGoogleChannelConfigRequest.newBuilder()
+   *           .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .build();
+   *   GoogleChannelConfig response = eventarcClient.getGoogleChannelConfig(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GoogleChannelConfig getGoogleChannelConfig(GetGoogleChannelConfigRequest request) { + return getGoogleChannelConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Get a GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetGoogleChannelConfigRequest request =
+   *       GetGoogleChannelConfigRequest.newBuilder()
+   *           .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.getGoogleChannelConfigCallable().futureCall(request);
+   *   // Do something.
+   *   GoogleChannelConfig response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + getGoogleChannelConfigCallable() { + return stub.getGoogleChannelConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GoogleChannelConfig googleChannelConfig = GoogleChannelConfig.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   GoogleChannelConfig response =
+   *       eventarcClient.updateGoogleChannelConfig(googleChannelConfig, updateMask);
+   * }
+   * }
+ * + * @param googleChannelConfig Required. The config to be updated. + * @param updateMask The fields to be updated; only fields explicitly provided are updated. If no + * field mask is provided, all provided fields in the request are updated. To update all + * fields, provide a field mask of "*". + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GoogleChannelConfig updateGoogleChannelConfig( + GoogleChannelConfig googleChannelConfig, FieldMask updateMask) { + UpdateGoogleChannelConfigRequest request = + UpdateGoogleChannelConfigRequest.newBuilder() + .setGoogleChannelConfig(googleChannelConfig) + .setUpdateMask(updateMask) + .build(); + return updateGoogleChannelConfig(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateGoogleChannelConfigRequest request =
+   *       UpdateGoogleChannelConfigRequest.newBuilder()
+   *           .setGoogleChannelConfig(GoogleChannelConfig.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   GoogleChannelConfig response = eventarcClient.updateGoogleChannelConfig(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GoogleChannelConfig updateGoogleChannelConfig( + UpdateGoogleChannelConfigRequest request) { + return updateGoogleChannelConfigCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Update a single GoogleChannelConfig + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   UpdateGoogleChannelConfigRequest request =
+   *       UpdateGoogleChannelConfigRequest.newBuilder()
+   *           .setGoogleChannelConfig(GoogleChannelConfig.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.updateGoogleChannelConfigCallable().futureCall(request);
+   *   // Do something.
+   *   GoogleChannelConfig response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + updateGoogleChannelConfigCallable() { + return stub.updateGoogleChannelConfigCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Location element : eventarcClient.listLocations(request).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListLocationsPagedResponse listLocations(ListLocationsRequest request) { + return listLocationsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future = eventarcClient.listLocationsPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Location element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listLocationsPagedCallable() { + return stub.listLocationsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists information about the supported locations for this service. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListLocationsResponse response = eventarcClient.listLocationsCallable().call(request);
+   *     for (Location element : response.getLocationsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable listLocationsCallable() { + return stub.listLocationsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   Location response = eventarcClient.getLocation(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Location getLocation(GetLocationRequest request) { + return getLocationCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets information about a location. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   ApiFuture future = eventarcClient.getLocationCallable().futureCall(request);
+   *   // Do something.
+   *   Location response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getLocationCallable() { + return stub.getLocationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Sets the access control policy on the specified resource. Replacesany existing policy. + * + *

Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   SetIamPolicyRequest request =
+   *       SetIamPolicyRequest.newBuilder()
+   *           .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setPolicy(Policy.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   Policy response = eventarcClient.setIamPolicy(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy setIamPolicy(SetIamPolicyRequest request) { + return setIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Sets the access control policy on the specified resource. Replacesany existing policy. + * + *

Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`errors. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   SetIamPolicyRequest request =
+   *       SetIamPolicyRequest.newBuilder()
+   *           .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setPolicy(Policy.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   ApiFuture future = eventarcClient.setIamPolicyCallable().futureCall(request);
+   *   // Do something.
+   *   Policy response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable setIamPolicyCallable() { + return stub.setIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the access control policy for a resource. Returns an empty policyif the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetIamPolicyRequest request =
+   *       GetIamPolicyRequest.newBuilder()
+   *           .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setOptions(GetPolicyOptions.newBuilder().build())
+   *           .build();
+   *   Policy response = eventarcClient.getIamPolicy(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Policy getIamPolicy(GetIamPolicyRequest request) { + return getIamPolicyCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets the access control policy for a resource. Returns an empty policyif the resource exists + * and does not have a policy set. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   GetIamPolicyRequest request =
+   *       GetIamPolicyRequest.newBuilder()
+   *           .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .setOptions(GetPolicyOptions.newBuilder().build())
+   *           .build();
+   *   ApiFuture future = eventarcClient.getIamPolicyCallable().futureCall(request);
+   *   // Do something.
+   *   Policy response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getIamPolicyCallable() { + return stub.getIamPolicyCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns permissions that a caller has on the specified resource. If theresource does not exist, + * this will return an empty set ofpermissions, not a `NOT_FOUND` error. + * + *

Note: This operation is designed to be used for buildingpermission-aware UIs and + * command-line tools, not for authorizationchecking. This operation may "fail open" without + * warning. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   TestIamPermissionsRequest request =
+   *       TestIamPermissionsRequest.newBuilder()
+   *           .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .addAllPermissions(new ArrayList())
+   *           .build();
+   *   TestIamPermissionsResponse response = eventarcClient.testIamPermissions(request);
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { + return testIamPermissionsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns permissions that a caller has on the specified resource. If theresource does not exist, + * this will return an empty set ofpermissions, not a `NOT_FOUND` error. + * + *

Note: This operation is designed to be used for buildingpermission-aware UIs and + * command-line tools, not for authorizationchecking. This operation may "fail open" without + * warning. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (EventarcClient eventarcClient = EventarcClient.create()) {
+   *   TestIamPermissionsRequest request =
+   *       TestIamPermissionsRequest.newBuilder()
+   *           .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString())
+   *           .addAllPermissions(new ArrayList())
+   *           .build();
+   *   ApiFuture future =
+   *       eventarcClient.testIamPermissionsCallable().futureCall(request);
+   *   // Do something.
+   *   TestIamPermissionsResponse response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + testIamPermissionsCallable() { + return stub.testIamPermissionsCallable(); + } + + @Override + public final void close() { + stub.close(); + } + + @Override + public void shutdown() { + stub.shutdown(); + } + + @Override + public boolean isShutdown() { + return stub.isShutdown(); + } + + @Override + public boolean isTerminated() { + return stub.isTerminated(); + } + + @Override + public void shutdownNow() { + stub.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return stub.awaitTermination(duration, unit); + } + + public static class ListTriggersPagedResponse + extends AbstractPagedListResponse< + ListTriggersRequest, + ListTriggersResponse, + Trigger, + ListTriggersPage, + ListTriggersFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListTriggersPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListTriggersPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListTriggersPagedResponse(ListTriggersPage page) { + super(page, ListTriggersFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListTriggersPage + extends AbstractPage { + + private ListTriggersPage( + PageContext context, + ListTriggersResponse response) { + super(context, response); + } + + private static ListTriggersPage createEmptyPage() { + return new ListTriggersPage(null, null); + } + + @Override + protected ListTriggersPage createPage( + PageContext context, + ListTriggersResponse response) { + return new ListTriggersPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListTriggersFixedSizeCollection + extends AbstractFixedSizeCollection< + ListTriggersRequest, + ListTriggersResponse, + Trigger, + ListTriggersPage, + ListTriggersFixedSizeCollection> { + + private ListTriggersFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListTriggersFixedSizeCollection createEmptyCollection() { + return new ListTriggersFixedSizeCollection(null, 0); + } + + @Override + protected ListTriggersFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListTriggersFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListChannelsPagedResponse + extends AbstractPagedListResponse< + ListChannelsRequest, + ListChannelsResponse, + Channel, + ListChannelsPage, + ListChannelsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListChannelsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListChannelsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListChannelsPagedResponse(ListChannelsPage page) { + super(page, ListChannelsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListChannelsPage + extends AbstractPage { + + private ListChannelsPage( + PageContext context, + ListChannelsResponse response) { + super(context, response); + } + + private static ListChannelsPage createEmptyPage() { + return new ListChannelsPage(null, null); + } + + @Override + protected ListChannelsPage createPage( + PageContext context, + ListChannelsResponse response) { + return new ListChannelsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListChannelsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListChannelsRequest, + ListChannelsResponse, + Channel, + ListChannelsPage, + ListChannelsFixedSizeCollection> { + + private ListChannelsFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListChannelsFixedSizeCollection createEmptyCollection() { + return new ListChannelsFixedSizeCollection(null, 0); + } + + @Override + protected ListChannelsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListChannelsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListProvidersPagedResponse + extends AbstractPagedListResponse< + ListProvidersRequest, + ListProvidersResponse, + Provider, + ListProvidersPage, + ListProvidersFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListProvidersPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListProvidersPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListProvidersPagedResponse(ListProvidersPage page) { + super(page, ListProvidersFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListProvidersPage + extends AbstractPage< + ListProvidersRequest, ListProvidersResponse, Provider, ListProvidersPage> { + + private ListProvidersPage( + PageContext context, + ListProvidersResponse response) { + super(context, response); + } + + private static ListProvidersPage createEmptyPage() { + return new ListProvidersPage(null, null); + } + + @Override + protected ListProvidersPage createPage( + PageContext context, + ListProvidersResponse response) { + return new ListProvidersPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListProvidersFixedSizeCollection + extends AbstractFixedSizeCollection< + ListProvidersRequest, + ListProvidersResponse, + Provider, + ListProvidersPage, + ListProvidersFixedSizeCollection> { + + private ListProvidersFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListProvidersFixedSizeCollection createEmptyCollection() { + return new ListProvidersFixedSizeCollection(null, 0); + } + + @Override + protected ListProvidersFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListProvidersFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListChannelConnectionsPagedResponse + extends AbstractPagedListResponse< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ChannelConnection, + ListChannelConnectionsPage, + ListChannelConnectionsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext< + ListChannelConnectionsRequest, ListChannelConnectionsResponse, ChannelConnection> + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListChannelConnectionsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListChannelConnectionsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListChannelConnectionsPagedResponse(ListChannelConnectionsPage page) { + super(page, ListChannelConnectionsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListChannelConnectionsPage + extends AbstractPage< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ChannelConnection, + ListChannelConnectionsPage> { + + private ListChannelConnectionsPage( + PageContext< + ListChannelConnectionsRequest, ListChannelConnectionsResponse, ChannelConnection> + context, + ListChannelConnectionsResponse response) { + super(context, response); + } + + private static ListChannelConnectionsPage createEmptyPage() { + return new ListChannelConnectionsPage(null, null); + } + + @Override + protected ListChannelConnectionsPage createPage( + PageContext< + ListChannelConnectionsRequest, ListChannelConnectionsResponse, ChannelConnection> + context, + ListChannelConnectionsResponse response) { + return new ListChannelConnectionsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext< + ListChannelConnectionsRequest, ListChannelConnectionsResponse, ChannelConnection> + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListChannelConnectionsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ChannelConnection, + ListChannelConnectionsPage, + ListChannelConnectionsFixedSizeCollection> { + + private ListChannelConnectionsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListChannelConnectionsFixedSizeCollection createEmptyCollection() { + return new ListChannelConnectionsFixedSizeCollection(null, 0); + } + + @Override + protected ListChannelConnectionsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListChannelConnectionsFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListLocationsPagedResponse + extends AbstractPagedListResponse< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListLocationsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListLocationsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListLocationsPagedResponse(ListLocationsPage page) { + super(page, ListLocationsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListLocationsPage + extends AbstractPage< + ListLocationsRequest, ListLocationsResponse, Location, ListLocationsPage> { + + private ListLocationsPage( + PageContext context, + ListLocationsResponse response) { + super(context, response); + } + + private static ListLocationsPage createEmptyPage() { + return new ListLocationsPage(null, null); + } + + @Override + protected ListLocationsPage createPage( + PageContext context, + ListLocationsResponse response) { + return new ListLocationsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListLocationsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + private ListLocationsFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListLocationsFixedSizeCollection createEmptyCollection() { + return new ListLocationsFixedSizeCollection(null, 0); + } + + @Override + protected ListLocationsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListLocationsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java new file mode 100644 index 000000000000..a50feecfd4d8 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/EventarcSettings.java @@ -0,0 +1,568 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.cloud.eventarc.v1.stub.EventarcStubSettings; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link EventarcClient}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (eventarc.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the total timeout of getTrigger to 30 seconds: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * EventarcSettings.Builder eventarcSettingsBuilder = EventarcSettings.newBuilder();
+ * eventarcSettingsBuilder
+ *     .getTriggerSettings()
+ *     .setRetrySettings(
+ *         eventarcSettingsBuilder.getTriggerSettings().getRetrySettings().toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * EventarcSettings eventarcSettings = eventarcSettingsBuilder.build();
+ * }
+ */ +@Generated("by gapic-generator-java") +public class EventarcSettings extends ClientSettings { + + /** Returns the object with the settings used for calls to getTrigger. */ + public UnaryCallSettings getTriggerSettings() { + return ((EventarcStubSettings) getStubSettings()).getTriggerSettings(); + } + + /** Returns the object with the settings used for calls to listTriggers. */ + public PagedCallSettings + listTriggersSettings() { + return ((EventarcStubSettings) getStubSettings()).listTriggersSettings(); + } + + /** Returns the object with the settings used for calls to createTrigger. */ + public UnaryCallSettings createTriggerSettings() { + return ((EventarcStubSettings) getStubSettings()).createTriggerSettings(); + } + + /** Returns the object with the settings used for calls to createTrigger. */ + public OperationCallSettings + createTriggerOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).createTriggerOperationSettings(); + } + + /** Returns the object with the settings used for calls to updateTrigger. */ + public UnaryCallSettings updateTriggerSettings() { + return ((EventarcStubSettings) getStubSettings()).updateTriggerSettings(); + } + + /** Returns the object with the settings used for calls to updateTrigger. */ + public OperationCallSettings + updateTriggerOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).updateTriggerOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteTrigger. */ + public UnaryCallSettings deleteTriggerSettings() { + return ((EventarcStubSettings) getStubSettings()).deleteTriggerSettings(); + } + + /** Returns the object with the settings used for calls to deleteTrigger. */ + public OperationCallSettings + deleteTriggerOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).deleteTriggerOperationSettings(); + } + + /** Returns the object with the settings used for calls to getChannel. */ + public UnaryCallSettings getChannelSettings() { + return ((EventarcStubSettings) getStubSettings()).getChannelSettings(); + } + + /** Returns the object with the settings used for calls to listChannels. */ + public PagedCallSettings + listChannelsSettings() { + return ((EventarcStubSettings) getStubSettings()).listChannelsSettings(); + } + + /** Returns the object with the settings used for calls to createChannel. */ + public UnaryCallSettings createChannelSettings() { + return ((EventarcStubSettings) getStubSettings()).createChannelSettings(); + } + + /** Returns the object with the settings used for calls to createChannel. */ + public OperationCallSettings + createChannelOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).createChannelOperationSettings(); + } + + /** Returns the object with the settings used for calls to updateChannel. */ + public UnaryCallSettings updateChannelSettings() { + return ((EventarcStubSettings) getStubSettings()).updateChannelSettings(); + } + + /** Returns the object with the settings used for calls to updateChannel. */ + public OperationCallSettings + updateChannelOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).updateChannelOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteChannel. */ + public UnaryCallSettings deleteChannelSettings() { + return ((EventarcStubSettings) getStubSettings()).deleteChannelSettings(); + } + + /** Returns the object with the settings used for calls to deleteChannel. */ + public OperationCallSettings + deleteChannelOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).deleteChannelOperationSettings(); + } + + /** Returns the object with the settings used for calls to getProvider. */ + public UnaryCallSettings getProviderSettings() { + return ((EventarcStubSettings) getStubSettings()).getProviderSettings(); + } + + /** Returns the object with the settings used for calls to listProviders. */ + public PagedCallSettings + listProvidersSettings() { + return ((EventarcStubSettings) getStubSettings()).listProvidersSettings(); + } + + /** Returns the object with the settings used for calls to getChannelConnection. */ + public UnaryCallSettings + getChannelConnectionSettings() { + return ((EventarcStubSettings) getStubSettings()).getChannelConnectionSettings(); + } + + /** Returns the object with the settings used for calls to listChannelConnections. */ + public PagedCallSettings< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + listChannelConnectionsSettings() { + return ((EventarcStubSettings) getStubSettings()).listChannelConnectionsSettings(); + } + + /** Returns the object with the settings used for calls to createChannelConnection. */ + public UnaryCallSettings + createChannelConnectionSettings() { + return ((EventarcStubSettings) getStubSettings()).createChannelConnectionSettings(); + } + + /** Returns the object with the settings used for calls to createChannelConnection. */ + public OperationCallSettings + createChannelConnectionOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).createChannelConnectionOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteChannelConnection. */ + public UnaryCallSettings + deleteChannelConnectionSettings() { + return ((EventarcStubSettings) getStubSettings()).deleteChannelConnectionSettings(); + } + + /** Returns the object with the settings used for calls to deleteChannelConnection. */ + public OperationCallSettings + deleteChannelConnectionOperationSettings() { + return ((EventarcStubSettings) getStubSettings()).deleteChannelConnectionOperationSettings(); + } + + /** Returns the object with the settings used for calls to getGoogleChannelConfig. */ + public UnaryCallSettings + getGoogleChannelConfigSettings() { + return ((EventarcStubSettings) getStubSettings()).getGoogleChannelConfigSettings(); + } + + /** Returns the object with the settings used for calls to updateGoogleChannelConfig. */ + public UnaryCallSettings + updateGoogleChannelConfigSettings() { + return ((EventarcStubSettings) getStubSettings()).updateGoogleChannelConfigSettings(); + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return ((EventarcStubSettings) getStubSettings()).listLocationsSettings(); + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return ((EventarcStubSettings) getStubSettings()).getLocationSettings(); + } + + /** Returns the object with the settings used for calls to setIamPolicy. */ + public UnaryCallSettings setIamPolicySettings() { + return ((EventarcStubSettings) getStubSettings()).setIamPolicySettings(); + } + + /** Returns the object with the settings used for calls to getIamPolicy. */ + public UnaryCallSettings getIamPolicySettings() { + return ((EventarcStubSettings) getStubSettings()).getIamPolicySettings(); + } + + /** Returns the object with the settings used for calls to testIamPermissions. */ + public UnaryCallSettings + testIamPermissionsSettings() { + return ((EventarcStubSettings) getStubSettings()).testIamPermissionsSettings(); + } + + public static final EventarcSettings create(EventarcStubSettings stub) throws IOException { + return new EventarcSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return EventarcStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return EventarcStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return EventarcStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return EventarcStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default gRPC ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return EventarcStubSettings.defaultGrpcTransportProviderBuilder(); + } + + /** Returns a builder for the default REST ChannelProvider for this service. */ + @BetaApi + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return EventarcStubSettings.defaultHttpJsonTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return EventarcStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return EventarcStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new gRPC builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new REST builder for this class. */ + @BetaApi + public static Builder newHttpJsonBuilder() { + return Builder.createHttpJsonDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected EventarcSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for EventarcSettings. */ + public static class Builder extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(EventarcStubSettings.newBuilder(clientContext)); + } + + protected Builder(EventarcSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(EventarcStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(EventarcStubSettings.newBuilder()); + } + + @BetaApi + private static Builder createHttpJsonDefault() { + return new Builder(EventarcStubSettings.newHttpJsonBuilder()); + } + + public EventarcStubSettings.Builder getStubSettingsBuilder() { + return ((EventarcStubSettings.Builder) getStubSettings()); + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to getTrigger. */ + public UnaryCallSettings.Builder getTriggerSettings() { + return getStubSettingsBuilder().getTriggerSettings(); + } + + /** Returns the builder for the settings used for calls to listTriggers. */ + public PagedCallSettings.Builder< + ListTriggersRequest, ListTriggersResponse, ListTriggersPagedResponse> + listTriggersSettings() { + return getStubSettingsBuilder().listTriggersSettings(); + } + + /** Returns the builder for the settings used for calls to createTrigger. */ + public UnaryCallSettings.Builder createTriggerSettings() { + return getStubSettingsBuilder().createTriggerSettings(); + } + + /** Returns the builder for the settings used for calls to createTrigger. */ + public OperationCallSettings.Builder + createTriggerOperationSettings() { + return getStubSettingsBuilder().createTriggerOperationSettings(); + } + + /** Returns the builder for the settings used for calls to updateTrigger. */ + public UnaryCallSettings.Builder updateTriggerSettings() { + return getStubSettingsBuilder().updateTriggerSettings(); + } + + /** Returns the builder for the settings used for calls to updateTrigger. */ + public OperationCallSettings.Builder + updateTriggerOperationSettings() { + return getStubSettingsBuilder().updateTriggerOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteTrigger. */ + public UnaryCallSettings.Builder deleteTriggerSettings() { + return getStubSettingsBuilder().deleteTriggerSettings(); + } + + /** Returns the builder for the settings used for calls to deleteTrigger. */ + public OperationCallSettings.Builder + deleteTriggerOperationSettings() { + return getStubSettingsBuilder().deleteTriggerOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getChannel. */ + public UnaryCallSettings.Builder getChannelSettings() { + return getStubSettingsBuilder().getChannelSettings(); + } + + /** Returns the builder for the settings used for calls to listChannels. */ + public PagedCallSettings.Builder< + ListChannelsRequest, ListChannelsResponse, ListChannelsPagedResponse> + listChannelsSettings() { + return getStubSettingsBuilder().listChannelsSettings(); + } + + /** Returns the builder for the settings used for calls to createChannel. */ + public UnaryCallSettings.Builder createChannelSettings() { + return getStubSettingsBuilder().createChannelSettings(); + } + + /** Returns the builder for the settings used for calls to createChannel. */ + public OperationCallSettings.Builder + createChannelOperationSettings() { + return getStubSettingsBuilder().createChannelOperationSettings(); + } + + /** Returns the builder for the settings used for calls to updateChannel. */ + public UnaryCallSettings.Builder updateChannelSettings() { + return getStubSettingsBuilder().updateChannelSettings(); + } + + /** Returns the builder for the settings used for calls to updateChannel. */ + public OperationCallSettings.Builder + updateChannelOperationSettings() { + return getStubSettingsBuilder().updateChannelOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteChannel. */ + public UnaryCallSettings.Builder deleteChannelSettings() { + return getStubSettingsBuilder().deleteChannelSettings(); + } + + /** Returns the builder for the settings used for calls to deleteChannel. */ + public OperationCallSettings.Builder + deleteChannelOperationSettings() { + return getStubSettingsBuilder().deleteChannelOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getProvider. */ + public UnaryCallSettings.Builder getProviderSettings() { + return getStubSettingsBuilder().getProviderSettings(); + } + + /** Returns the builder for the settings used for calls to listProviders. */ + public PagedCallSettings.Builder< + ListProvidersRequest, ListProvidersResponse, ListProvidersPagedResponse> + listProvidersSettings() { + return getStubSettingsBuilder().listProvidersSettings(); + } + + /** Returns the builder for the settings used for calls to getChannelConnection. */ + public UnaryCallSettings.Builder + getChannelConnectionSettings() { + return getStubSettingsBuilder().getChannelConnectionSettings(); + } + + /** Returns the builder for the settings used for calls to listChannelConnections. */ + public PagedCallSettings.Builder< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + listChannelConnectionsSettings() { + return getStubSettingsBuilder().listChannelConnectionsSettings(); + } + + /** Returns the builder for the settings used for calls to createChannelConnection. */ + public UnaryCallSettings.Builder + createChannelConnectionSettings() { + return getStubSettingsBuilder().createChannelConnectionSettings(); + } + + /** Returns the builder for the settings used for calls to createChannelConnection. */ + public OperationCallSettings.Builder< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationSettings() { + return getStubSettingsBuilder().createChannelConnectionOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteChannelConnection. */ + public UnaryCallSettings.Builder + deleteChannelConnectionSettings() { + return getStubSettingsBuilder().deleteChannelConnectionSettings(); + } + + /** Returns the builder for the settings used for calls to deleteChannelConnection. */ + public OperationCallSettings.Builder< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationSettings() { + return getStubSettingsBuilder().deleteChannelConnectionOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getGoogleChannelConfig. */ + public UnaryCallSettings.Builder + getGoogleChannelConfigSettings() { + return getStubSettingsBuilder().getGoogleChannelConfigSettings(); + } + + /** Returns the builder for the settings used for calls to updateGoogleChannelConfig. */ + public UnaryCallSettings.Builder + updateGoogleChannelConfigSettings() { + return getStubSettingsBuilder().updateGoogleChannelConfigSettings(); + } + + /** Returns the builder for the settings used for calls to listLocations. */ + public PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings() { + return getStubSettingsBuilder().listLocationsSettings(); + } + + /** Returns the builder for the settings used for calls to getLocation. */ + public UnaryCallSettings.Builder getLocationSettings() { + return getStubSettingsBuilder().getLocationSettings(); + } + + /** Returns the builder for the settings used for calls to setIamPolicy. */ + public UnaryCallSettings.Builder setIamPolicySettings() { + return getStubSettingsBuilder().setIamPolicySettings(); + } + + /** Returns the builder for the settings used for calls to getIamPolicy. */ + public UnaryCallSettings.Builder getIamPolicySettings() { + return getStubSettingsBuilder().getIamPolicySettings(); + } + + /** Returns the builder for the settings used for calls to testIamPermissions. */ + public UnaryCallSettings.Builder + testIamPermissionsSettings() { + return getStubSettingsBuilder().testIamPermissionsSettings(); + } + + @Override + public EventarcSettings build() throws IOException { + return new EventarcSettings(this); + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json new file mode 100644 index 000000000000..c39073db2898 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/gapic_metadata.json @@ -0,0 +1,87 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", + "language": "java", + "protoPackage": "google.cloud.eventarc.v1", + "libraryPackage": "com.google.cloud.eventarc.v1", + "services": { + "Eventarc": { + "clients": { + "grpc": { + "libraryClient": "EventarcClient", + "rpcs": { + "CreateChannel": { + "methods": ["createChannelAsync", "createChannelAsync", "createChannelAsync", "createChannelOperationCallable", "createChannelCallable"] + }, + "CreateChannelConnection": { + "methods": ["createChannelConnectionAsync", "createChannelConnectionAsync", "createChannelConnectionAsync", "createChannelConnectionOperationCallable", "createChannelConnectionCallable"] + }, + "CreateTrigger": { + "methods": ["createTriggerAsync", "createTriggerAsync", "createTriggerAsync", "createTriggerOperationCallable", "createTriggerCallable"] + }, + "DeleteChannel": { + "methods": ["deleteChannelAsync", "deleteChannelAsync", "deleteChannelAsync", "deleteChannelOperationCallable", "deleteChannelCallable"] + }, + "DeleteChannelConnection": { + "methods": ["deleteChannelConnectionAsync", "deleteChannelConnectionAsync", "deleteChannelConnectionAsync", "deleteChannelConnectionOperationCallable", "deleteChannelConnectionCallable"] + }, + "DeleteTrigger": { + "methods": ["deleteTriggerAsync", "deleteTriggerAsync", "deleteTriggerAsync", "deleteTriggerOperationCallable", "deleteTriggerCallable"] + }, + "GetChannel": { + "methods": ["getChannel", "getChannel", "getChannel", "getChannelCallable"] + }, + "GetChannelConnection": { + "methods": ["getChannelConnection", "getChannelConnection", "getChannelConnection", "getChannelConnectionCallable"] + }, + "GetGoogleChannelConfig": { + "methods": ["getGoogleChannelConfig", "getGoogleChannelConfig", "getGoogleChannelConfig", "getGoogleChannelConfigCallable"] + }, + "GetIamPolicy": { + "methods": ["getIamPolicy", "getIamPolicyCallable"] + }, + "GetLocation": { + "methods": ["getLocation", "getLocationCallable"] + }, + "GetProvider": { + "methods": ["getProvider", "getProvider", "getProvider", "getProviderCallable"] + }, + "GetTrigger": { + "methods": ["getTrigger", "getTrigger", "getTrigger", "getTriggerCallable"] + }, + "ListChannelConnections": { + "methods": ["listChannelConnections", "listChannelConnections", "listChannelConnections", "listChannelConnectionsPagedCallable", "listChannelConnectionsCallable"] + }, + "ListChannels": { + "methods": ["listChannels", "listChannels", "listChannels", "listChannelsPagedCallable", "listChannelsCallable"] + }, + "ListLocations": { + "methods": ["listLocations", "listLocationsPagedCallable", "listLocationsCallable"] + }, + "ListProviders": { + "methods": ["listProviders", "listProviders", "listProviders", "listProvidersPagedCallable", "listProvidersCallable"] + }, + "ListTriggers": { + "methods": ["listTriggers", "listTriggers", "listTriggers", "listTriggersPagedCallable", "listTriggersCallable"] + }, + "SetIamPolicy": { + "methods": ["setIamPolicy", "setIamPolicyCallable"] + }, + "TestIamPermissions": { + "methods": ["testIamPermissions", "testIamPermissionsCallable"] + }, + "UpdateChannel": { + "methods": ["updateChannelAsync", "updateChannelAsync", "updateChannelOperationCallable", "updateChannelCallable"] + }, + "UpdateGoogleChannelConfig": { + "methods": ["updateGoogleChannelConfig", "updateGoogleChannelConfig", "updateGoogleChannelConfigCallable"] + }, + "UpdateTrigger": { + "methods": ["updateTriggerAsync", "updateTriggerAsync", "updateTriggerOperationCallable", "updateTriggerCallable"] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java new file mode 100644 index 000000000000..8a22d29cd7bf --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/package-info.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + * A client to Eventarc API + * + *

The interfaces provided are listed below, along with usage samples. + * + *

======================= EventarcClient ======================= + * + *

Service Description: Eventarc allows users to subscribe to various events that are provided by + * Google Cloud services and forward them to supported destinations. + * + *

Sample for EventarcClient: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * try (EventarcClient eventarcClient = EventarcClient.create()) {
+ *   TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]");
+ *   Trigger response = eventarcClient.getTrigger(name);
+ * }
+ * }
+ */ +@Generated("by gapic-generator-java") +package com.google.cloud.eventarc.v1; + +import javax.annotation.Generated; diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java new file mode 100644 index 000000000000..1d5e1e334be2 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStub.java @@ -0,0 +1,253 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.GetChannelConnectionRequest; +import com.google.cloud.eventarc.v1.GetChannelRequest; +import com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.GetProviderRequest; +import com.google.cloud.eventarc.v1.GetTriggerRequest; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.ListChannelConnectionsResponse; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.ListChannelsResponse; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.ListProvidersResponse; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.ListTriggersResponse; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the Eventarc service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public abstract class EventarcStub implements BackgroundResource { + + public OperationsStub getOperationsStub() { + return null; + } + + public com.google.api.gax.httpjson.longrunning.stub.OperationsStub getHttpJsonOperationsStub() { + return null; + } + + public UnaryCallable getTriggerCallable() { + throw new UnsupportedOperationException("Not implemented: getTriggerCallable()"); + } + + public UnaryCallable listTriggersPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listTriggersPagedCallable()"); + } + + public UnaryCallable listTriggersCallable() { + throw new UnsupportedOperationException("Not implemented: listTriggersCallable()"); + } + + public OperationCallable + createTriggerOperationCallable() { + throw new UnsupportedOperationException("Not implemented: createTriggerOperationCallable()"); + } + + public UnaryCallable createTriggerCallable() { + throw new UnsupportedOperationException("Not implemented: createTriggerCallable()"); + } + + public OperationCallable + updateTriggerOperationCallable() { + throw new UnsupportedOperationException("Not implemented: updateTriggerOperationCallable()"); + } + + public UnaryCallable updateTriggerCallable() { + throw new UnsupportedOperationException("Not implemented: updateTriggerCallable()"); + } + + public OperationCallable + deleteTriggerOperationCallable() { + throw new UnsupportedOperationException("Not implemented: deleteTriggerOperationCallable()"); + } + + public UnaryCallable deleteTriggerCallable() { + throw new UnsupportedOperationException("Not implemented: deleteTriggerCallable()"); + } + + public UnaryCallable getChannelCallable() { + throw new UnsupportedOperationException("Not implemented: getChannelCallable()"); + } + + public UnaryCallable listChannelsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listChannelsPagedCallable()"); + } + + public UnaryCallable listChannelsCallable() { + throw new UnsupportedOperationException("Not implemented: listChannelsCallable()"); + } + + public OperationCallable + createChannelOperationCallable() { + throw new UnsupportedOperationException("Not implemented: createChannelOperationCallable()"); + } + + public UnaryCallable createChannelCallable() { + throw new UnsupportedOperationException("Not implemented: createChannelCallable()"); + } + + public OperationCallable + updateChannelOperationCallable() { + throw new UnsupportedOperationException("Not implemented: updateChannelOperationCallable()"); + } + + public UnaryCallable updateChannelCallable() { + throw new UnsupportedOperationException("Not implemented: updateChannelCallable()"); + } + + public OperationCallable + deleteChannelOperationCallable() { + throw new UnsupportedOperationException("Not implemented: deleteChannelOperationCallable()"); + } + + public UnaryCallable deleteChannelCallable() { + throw new UnsupportedOperationException("Not implemented: deleteChannelCallable()"); + } + + public UnaryCallable getProviderCallable() { + throw new UnsupportedOperationException("Not implemented: getProviderCallable()"); + } + + public UnaryCallable + listProvidersPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listProvidersPagedCallable()"); + } + + public UnaryCallable listProvidersCallable() { + throw new UnsupportedOperationException("Not implemented: listProvidersCallable()"); + } + + public UnaryCallable + getChannelConnectionCallable() { + throw new UnsupportedOperationException("Not implemented: getChannelConnectionCallable()"); + } + + public UnaryCallable + listChannelConnectionsPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listChannelConnectionsPagedCallable()"); + } + + public UnaryCallable + listChannelConnectionsCallable() { + throw new UnsupportedOperationException("Not implemented: listChannelConnectionsCallable()"); + } + + public OperationCallable + createChannelConnectionOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: createChannelConnectionOperationCallable()"); + } + + public UnaryCallable + createChannelConnectionCallable() { + throw new UnsupportedOperationException("Not implemented: createChannelConnectionCallable()"); + } + + public OperationCallable + deleteChannelConnectionOperationCallable() { + throw new UnsupportedOperationException( + "Not implemented: deleteChannelConnectionOperationCallable()"); + } + + public UnaryCallable + deleteChannelConnectionCallable() { + throw new UnsupportedOperationException("Not implemented: deleteChannelConnectionCallable()"); + } + + public UnaryCallable + getGoogleChannelConfigCallable() { + throw new UnsupportedOperationException("Not implemented: getGoogleChannelConfigCallable()"); + } + + public UnaryCallable + updateGoogleChannelConfigCallable() { + throw new UnsupportedOperationException("Not implemented: updateGoogleChannelConfigCallable()"); + } + + public UnaryCallable + listLocationsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); + } + + public UnaryCallable listLocationsCallable() { + throw new UnsupportedOperationException("Not implemented: listLocationsCallable()"); + } + + public UnaryCallable getLocationCallable() { + throw new UnsupportedOperationException("Not implemented: getLocationCallable()"); + } + + public UnaryCallable setIamPolicyCallable() { + throw new UnsupportedOperationException("Not implemented: setIamPolicyCallable()"); + } + + public UnaryCallable getIamPolicyCallable() { + throw new UnsupportedOperationException("Not implemented: getIamPolicyCallable()"); + } + + public UnaryCallable + testIamPermissionsCallable() { + throw new UnsupportedOperationException("Not implemented: testIamPermissionsCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java new file mode 100644 index 000000000000..5763313de532 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/EventarcStubSettings.java @@ -0,0 +1,1568 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +import com.google.api.gax.core.GaxProperties; +import com.google.api.gax.core.GoogleCredentialsProvider; +import com.google.api.gax.core.InstantiatingExecutorProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.GrpcTransportChannel; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.grpc.ProtoOperationTransformers; +import com.google.api.gax.httpjson.GaxHttpJsonProperties; +import com.google.api.gax.httpjson.HttpJsonTransportChannel; +import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; +import com.google.api.gax.longrunning.OperationSnapshot; +import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; +import com.google.api.gax.retrying.RetrySettings; +import com.google.api.gax.rpc.ApiCallContext; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.PagedListDescriptor; +import com.google.api.gax.rpc.PagedListResponseFactory; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.StubSettings; +import com.google.api.gax.rpc.TransportChannelProvider; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.GetChannelConnectionRequest; +import com.google.cloud.eventarc.v1.GetChannelRequest; +import com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.GetProviderRequest; +import com.google.cloud.eventarc.v1.GetTriggerRequest; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.ListChannelConnectionsResponse; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.ListChannelsResponse; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.ListProvidersResponse; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.ListTriggersResponse; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableSet; +import com.google.common.collect.Lists; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link EventarcStub}. + * + *

The default instance has everything set to sensible defaults: + * + *

    + *
  • The default service address (eventarc.googleapis.com) and default port (443) are used. + *
  • Credentials are acquired automatically through Application Default Credentials. + *
  • Retries are configured for idempotent methods but not for non-idempotent methods. + *
+ * + *

The builder of this class is recursive, so contained classes are themselves builders. When + * build() is called, the tree of builders is called to create the complete settings object. + * + *

For example, to set the total timeout of getTrigger to 30 seconds: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * EventarcStubSettings.Builder eventarcSettingsBuilder = EventarcStubSettings.newBuilder();
+ * eventarcSettingsBuilder
+ *     .getTriggerSettings()
+ *     .setRetrySettings(
+ *         eventarcSettingsBuilder.getTriggerSettings().getRetrySettings().toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * EventarcStubSettings eventarcSettings = eventarcSettingsBuilder.build();
+ * }
+ */ +@Generated("by gapic-generator-java") +public class EventarcStubSettings extends StubSettings { + /** The default scopes of the service. */ + private static final ImmutableList DEFAULT_SERVICE_SCOPES = + ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); + + private final UnaryCallSettings getTriggerSettings; + private final PagedCallSettings< + ListTriggersRequest, ListTriggersResponse, ListTriggersPagedResponse> + listTriggersSettings; + private final UnaryCallSettings createTriggerSettings; + private final OperationCallSettings + createTriggerOperationSettings; + private final UnaryCallSettings updateTriggerSettings; + private final OperationCallSettings + updateTriggerOperationSettings; + private final UnaryCallSettings deleteTriggerSettings; + private final OperationCallSettings + deleteTriggerOperationSettings; + private final UnaryCallSettings getChannelSettings; + private final PagedCallSettings< + ListChannelsRequest, ListChannelsResponse, ListChannelsPagedResponse> + listChannelsSettings; + private final UnaryCallSettings createChannelSettings; + private final OperationCallSettings + createChannelOperationSettings; + private final UnaryCallSettings updateChannelSettings; + private final OperationCallSettings + updateChannelOperationSettings; + private final UnaryCallSettings deleteChannelSettings; + private final OperationCallSettings + deleteChannelOperationSettings; + private final UnaryCallSettings getProviderSettings; + private final PagedCallSettings< + ListProvidersRequest, ListProvidersResponse, ListProvidersPagedResponse> + listProvidersSettings; + private final UnaryCallSettings + getChannelConnectionSettings; + private final PagedCallSettings< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + listChannelConnectionsSettings; + private final UnaryCallSettings + createChannelConnectionSettings; + private final OperationCallSettings< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationSettings; + private final UnaryCallSettings + deleteChannelConnectionSettings; + private final OperationCallSettings< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationSettings; + private final UnaryCallSettings + getGoogleChannelConfigSettings; + private final UnaryCallSettings + updateGoogleChannelConfigSettings; + private final PagedCallSettings< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings getLocationSettings; + private final UnaryCallSettings setIamPolicySettings; + private final UnaryCallSettings getIamPolicySettings; + private final UnaryCallSettings + testIamPermissionsSettings; + + private static final PagedListDescriptor + LIST_TRIGGERS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListTriggersRequest injectToken(ListTriggersRequest payload, String token) { + return ListTriggersRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListTriggersRequest injectPageSize(ListTriggersRequest payload, int pageSize) { + return ListTriggersRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListTriggersRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListTriggersResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListTriggersResponse payload) { + return payload.getTriggersList() == null + ? ImmutableList.of() + : payload.getTriggersList(); + } + }; + + private static final PagedListDescriptor + LIST_CHANNELS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListChannelsRequest injectToken(ListChannelsRequest payload, String token) { + return ListChannelsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListChannelsRequest injectPageSize(ListChannelsRequest payload, int pageSize) { + return ListChannelsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListChannelsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListChannelsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListChannelsResponse payload) { + return payload.getChannelsList() == null + ? ImmutableList.of() + : payload.getChannelsList(); + } + }; + + private static final PagedListDescriptor + LIST_PROVIDERS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListProvidersRequest injectToken(ListProvidersRequest payload, String token) { + return ListProvidersRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListProvidersRequest injectPageSize(ListProvidersRequest payload, int pageSize) { + return ListProvidersRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListProvidersRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListProvidersResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListProvidersResponse payload) { + return payload.getProvidersList() == null + ? ImmutableList.of() + : payload.getProvidersList(); + } + }; + + private static final PagedListDescriptor< + ListChannelConnectionsRequest, ListChannelConnectionsResponse, ChannelConnection> + LIST_CHANNEL_CONNECTIONS_PAGE_STR_DESC = + new PagedListDescriptor< + ListChannelConnectionsRequest, ListChannelConnectionsResponse, ChannelConnection>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListChannelConnectionsRequest injectToken( + ListChannelConnectionsRequest payload, String token) { + return ListChannelConnectionsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListChannelConnectionsRequest injectPageSize( + ListChannelConnectionsRequest payload, int pageSize) { + return ListChannelConnectionsRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListChannelConnectionsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListChannelConnectionsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListChannelConnectionsResponse payload) { + return payload.getChannelConnectionsList() == null + ? ImmutableList.of() + : payload.getChannelConnectionsList(); + } + }; + + private static final PagedListDescriptor + LIST_LOCATIONS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListLocationsRequest injectToken(ListLocationsRequest payload, String token) { + return ListLocationsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListLocationsRequest injectPageSize(ListLocationsRequest payload, int pageSize) { + return ListLocationsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListLocationsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListLocationsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListLocationsResponse payload) { + return payload.getLocationsList() == null + ? ImmutableList.of() + : payload.getLocationsList(); + } + }; + + private static final PagedListResponseFactory< + ListTriggersRequest, ListTriggersResponse, ListTriggersPagedResponse> + LIST_TRIGGERS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListTriggersRequest, ListTriggersResponse, ListTriggersPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListTriggersRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_TRIGGERS_PAGE_STR_DESC, request, context); + return ListTriggersPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListChannelsRequest, ListChannelsResponse, ListChannelsPagedResponse> + LIST_CHANNELS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListChannelsRequest, ListChannelsResponse, ListChannelsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListChannelsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_CHANNELS_PAGE_STR_DESC, request, context); + return ListChannelsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListProvidersRequest, ListProvidersResponse, ListProvidersPagedResponse> + LIST_PROVIDERS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListProvidersRequest, ListProvidersResponse, ListProvidersPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListProvidersRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_PROVIDERS_PAGE_STR_DESC, request, context); + return ListProvidersPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + LIST_CHANNEL_CONNECTIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable + callable, + ListChannelConnectionsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ChannelConnection> + pageContext = + PageContext.create( + callable, LIST_CHANNEL_CONNECTIONS_PAGE_STR_DESC, request, context); + return ListChannelConnectionsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + LIST_LOCATIONS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListLocationsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_LOCATIONS_PAGE_STR_DESC, request, context); + return ListLocationsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to getTrigger. */ + public UnaryCallSettings getTriggerSettings() { + return getTriggerSettings; + } + + /** Returns the object with the settings used for calls to listTriggers. */ + public PagedCallSettings + listTriggersSettings() { + return listTriggersSettings; + } + + /** Returns the object with the settings used for calls to createTrigger. */ + public UnaryCallSettings createTriggerSettings() { + return createTriggerSettings; + } + + /** Returns the object with the settings used for calls to createTrigger. */ + public OperationCallSettings + createTriggerOperationSettings() { + return createTriggerOperationSettings; + } + + /** Returns the object with the settings used for calls to updateTrigger. */ + public UnaryCallSettings updateTriggerSettings() { + return updateTriggerSettings; + } + + /** Returns the object with the settings used for calls to updateTrigger. */ + public OperationCallSettings + updateTriggerOperationSettings() { + return updateTriggerOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteTrigger. */ + public UnaryCallSettings deleteTriggerSettings() { + return deleteTriggerSettings; + } + + /** Returns the object with the settings used for calls to deleteTrigger. */ + public OperationCallSettings + deleteTriggerOperationSettings() { + return deleteTriggerOperationSettings; + } + + /** Returns the object with the settings used for calls to getChannel. */ + public UnaryCallSettings getChannelSettings() { + return getChannelSettings; + } + + /** Returns the object with the settings used for calls to listChannels. */ + public PagedCallSettings + listChannelsSettings() { + return listChannelsSettings; + } + + /** Returns the object with the settings used for calls to createChannel. */ + public UnaryCallSettings createChannelSettings() { + return createChannelSettings; + } + + /** Returns the object with the settings used for calls to createChannel. */ + public OperationCallSettings + createChannelOperationSettings() { + return createChannelOperationSettings; + } + + /** Returns the object with the settings used for calls to updateChannel. */ + public UnaryCallSettings updateChannelSettings() { + return updateChannelSettings; + } + + /** Returns the object with the settings used for calls to updateChannel. */ + public OperationCallSettings + updateChannelOperationSettings() { + return updateChannelOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteChannel. */ + public UnaryCallSettings deleteChannelSettings() { + return deleteChannelSettings; + } + + /** Returns the object with the settings used for calls to deleteChannel. */ + public OperationCallSettings + deleteChannelOperationSettings() { + return deleteChannelOperationSettings; + } + + /** Returns the object with the settings used for calls to getProvider. */ + public UnaryCallSettings getProviderSettings() { + return getProviderSettings; + } + + /** Returns the object with the settings used for calls to listProviders. */ + public PagedCallSettings + listProvidersSettings() { + return listProvidersSettings; + } + + /** Returns the object with the settings used for calls to getChannelConnection. */ + public UnaryCallSettings + getChannelConnectionSettings() { + return getChannelConnectionSettings; + } + + /** Returns the object with the settings used for calls to listChannelConnections. */ + public PagedCallSettings< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + listChannelConnectionsSettings() { + return listChannelConnectionsSettings; + } + + /** Returns the object with the settings used for calls to createChannelConnection. */ + public UnaryCallSettings + createChannelConnectionSettings() { + return createChannelConnectionSettings; + } + + /** Returns the object with the settings used for calls to createChannelConnection. */ + public OperationCallSettings + createChannelConnectionOperationSettings() { + return createChannelConnectionOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteChannelConnection. */ + public UnaryCallSettings + deleteChannelConnectionSettings() { + return deleteChannelConnectionSettings; + } + + /** Returns the object with the settings used for calls to deleteChannelConnection. */ + public OperationCallSettings + deleteChannelConnectionOperationSettings() { + return deleteChannelConnectionOperationSettings; + } + + /** Returns the object with the settings used for calls to getGoogleChannelConfig. */ + public UnaryCallSettings + getGoogleChannelConfigSettings() { + return getGoogleChannelConfigSettings; + } + + /** Returns the object with the settings used for calls to updateGoogleChannelConfig. */ + public UnaryCallSettings + updateGoogleChannelConfigSettings() { + return updateGoogleChannelConfigSettings; + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return listLocationsSettings; + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return getLocationSettings; + } + + /** Returns the object with the settings used for calls to setIamPolicy. */ + public UnaryCallSettings setIamPolicySettings() { + return setIamPolicySettings; + } + + /** Returns the object with the settings used for calls to getIamPolicy. */ + public UnaryCallSettings getIamPolicySettings() { + return getIamPolicySettings; + } + + /** Returns the object with the settings used for calls to testIamPermissions. */ + public UnaryCallSettings + testIamPermissionsSettings() { + return testIamPermissionsSettings; + } + + public EventarcStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcEventarcStub.create(this); + } + if (getTransportChannelProvider() + .getTransportName() + .equals(HttpJsonTransportChannel.getHttpJsonTransportName())) { + return HttpJsonEventarcStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "eventarc.googleapis.com:443"; + } + + /** Returns the default mTLS service endpoint. */ + public static String getDefaultMtlsEndpoint() { + return "eventarc.mtls.googleapis.com:443"; + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return DEFAULT_SERVICE_SCOPES; + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return GoogleCredentialsProvider.newBuilder() + .setScopesToApply(DEFAULT_SERVICE_SCOPES) + .setUseJwtAccessWithScope(true); + } + + /** Returns a builder for the default gRPC ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + /** Returns a builder for the default REST ChannelProvider for this service. */ + @BetaApi + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return InstantiatingHttpJsonChannelProvider.newBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultGrpcApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken("gapic", GaxProperties.getLibraryVersion(EventarcStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultHttpJsonApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken("gapic", GaxProperties.getLibraryVersion(EventarcStubSettings.class)) + .setTransportToken( + GaxHttpJsonProperties.getHttpJsonTokenName(), + GaxHttpJsonProperties.getHttpJsonVersion()); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return EventarcStubSettings.defaultGrpcApiClientHeaderProviderBuilder(); + } + + /** Returns a new gRPC builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new REST builder for this class. */ + public static Builder newHttpJsonBuilder() { + return Builder.createHttpJsonDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(ClientContext clientContext) { + return new Builder(clientContext); + } + + /** Returns a builder containing all the values of this settings class. */ + public Builder toBuilder() { + return new Builder(this); + } + + protected EventarcStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + getTriggerSettings = settingsBuilder.getTriggerSettings().build(); + listTriggersSettings = settingsBuilder.listTriggersSettings().build(); + createTriggerSettings = settingsBuilder.createTriggerSettings().build(); + createTriggerOperationSettings = settingsBuilder.createTriggerOperationSettings().build(); + updateTriggerSettings = settingsBuilder.updateTriggerSettings().build(); + updateTriggerOperationSettings = settingsBuilder.updateTriggerOperationSettings().build(); + deleteTriggerSettings = settingsBuilder.deleteTriggerSettings().build(); + deleteTriggerOperationSettings = settingsBuilder.deleteTriggerOperationSettings().build(); + getChannelSettings = settingsBuilder.getChannelSettings().build(); + listChannelsSettings = settingsBuilder.listChannelsSettings().build(); + createChannelSettings = settingsBuilder.createChannelSettings().build(); + createChannelOperationSettings = settingsBuilder.createChannelOperationSettings().build(); + updateChannelSettings = settingsBuilder.updateChannelSettings().build(); + updateChannelOperationSettings = settingsBuilder.updateChannelOperationSettings().build(); + deleteChannelSettings = settingsBuilder.deleteChannelSettings().build(); + deleteChannelOperationSettings = settingsBuilder.deleteChannelOperationSettings().build(); + getProviderSettings = settingsBuilder.getProviderSettings().build(); + listProvidersSettings = settingsBuilder.listProvidersSettings().build(); + getChannelConnectionSettings = settingsBuilder.getChannelConnectionSettings().build(); + listChannelConnectionsSettings = settingsBuilder.listChannelConnectionsSettings().build(); + createChannelConnectionSettings = settingsBuilder.createChannelConnectionSettings().build(); + createChannelConnectionOperationSettings = + settingsBuilder.createChannelConnectionOperationSettings().build(); + deleteChannelConnectionSettings = settingsBuilder.deleteChannelConnectionSettings().build(); + deleteChannelConnectionOperationSettings = + settingsBuilder.deleteChannelConnectionOperationSettings().build(); + getGoogleChannelConfigSettings = settingsBuilder.getGoogleChannelConfigSettings().build(); + updateGoogleChannelConfigSettings = settingsBuilder.updateGoogleChannelConfigSettings().build(); + listLocationsSettings = settingsBuilder.listLocationsSettings().build(); + getLocationSettings = settingsBuilder.getLocationSettings().build(); + setIamPolicySettings = settingsBuilder.setIamPolicySettings().build(); + getIamPolicySettings = settingsBuilder.getIamPolicySettings().build(); + testIamPermissionsSettings = settingsBuilder.testIamPermissionsSettings().build(); + } + + /** Builder for EventarcStubSettings. */ + public static class Builder extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final UnaryCallSettings.Builder getTriggerSettings; + private final PagedCallSettings.Builder< + ListTriggersRequest, ListTriggersResponse, ListTriggersPagedResponse> + listTriggersSettings; + private final UnaryCallSettings.Builder createTriggerSettings; + private final OperationCallSettings.Builder + createTriggerOperationSettings; + private final UnaryCallSettings.Builder updateTriggerSettings; + private final OperationCallSettings.Builder + updateTriggerOperationSettings; + private final UnaryCallSettings.Builder deleteTriggerSettings; + private final OperationCallSettings.Builder + deleteTriggerOperationSettings; + private final UnaryCallSettings.Builder getChannelSettings; + private final PagedCallSettings.Builder< + ListChannelsRequest, ListChannelsResponse, ListChannelsPagedResponse> + listChannelsSettings; + private final UnaryCallSettings.Builder createChannelSettings; + private final OperationCallSettings.Builder + createChannelOperationSettings; + private final UnaryCallSettings.Builder updateChannelSettings; + private final OperationCallSettings.Builder + updateChannelOperationSettings; + private final UnaryCallSettings.Builder deleteChannelSettings; + private final OperationCallSettings.Builder + deleteChannelOperationSettings; + private final UnaryCallSettings.Builder getProviderSettings; + private final PagedCallSettings.Builder< + ListProvidersRequest, ListProvidersResponse, ListProvidersPagedResponse> + listProvidersSettings; + private final UnaryCallSettings.Builder + getChannelConnectionSettings; + private final PagedCallSettings.Builder< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + listChannelConnectionsSettings; + private final UnaryCallSettings.Builder + createChannelConnectionSettings; + private final OperationCallSettings.Builder< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationSettings; + private final UnaryCallSettings.Builder + deleteChannelConnectionSettings; + private final OperationCallSettings.Builder< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationSettings; + private final UnaryCallSettings.Builder + getGoogleChannelConfigSettings; + private final UnaryCallSettings.Builder + updateGoogleChannelConfigSettings; + private final PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings.Builder getLocationSettings; + private final UnaryCallSettings.Builder setIamPolicySettings; + private final UnaryCallSettings.Builder getIamPolicySettings; + private final UnaryCallSettings.Builder + testIamPermissionsSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put("no_retry_codes", ImmutableSet.copyOf(Lists.newArrayList())); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = RetrySettings.newBuilder().setRpcTimeoutMultiplier(1.0).build(); + definitions.put("no_retry_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + getTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listTriggersSettings = PagedCallSettings.newBuilder(LIST_TRIGGERS_PAGE_STR_FACT); + createTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createTriggerOperationSettings = OperationCallSettings.newBuilder(); + updateTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateTriggerOperationSettings = OperationCallSettings.newBuilder(); + deleteTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteTriggerOperationSettings = OperationCallSettings.newBuilder(); + getChannelSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listChannelsSettings = PagedCallSettings.newBuilder(LIST_CHANNELS_PAGE_STR_FACT); + createChannelSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createChannelOperationSettings = OperationCallSettings.newBuilder(); + updateChannelSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateChannelOperationSettings = OperationCallSettings.newBuilder(); + deleteChannelSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteChannelOperationSettings = OperationCallSettings.newBuilder(); + getProviderSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listProvidersSettings = PagedCallSettings.newBuilder(LIST_PROVIDERS_PAGE_STR_FACT); + getChannelConnectionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listChannelConnectionsSettings = + PagedCallSettings.newBuilder(LIST_CHANNEL_CONNECTIONS_PAGE_STR_FACT); + createChannelConnectionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createChannelConnectionOperationSettings = OperationCallSettings.newBuilder(); + deleteChannelConnectionSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteChannelConnectionOperationSettings = OperationCallSettings.newBuilder(); + getGoogleChannelConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateGoogleChannelConfigSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); + getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + setIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getIamPolicySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + testIamPermissionsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + getTriggerSettings, + listTriggersSettings, + createTriggerSettings, + updateTriggerSettings, + deleteTriggerSettings, + getChannelSettings, + listChannelsSettings, + createChannelSettings, + updateChannelSettings, + deleteChannelSettings, + getProviderSettings, + listProvidersSettings, + getChannelConnectionSettings, + listChannelConnectionsSettings, + createChannelConnectionSettings, + deleteChannelConnectionSettings, + getGoogleChannelConfigSettings, + updateGoogleChannelConfigSettings, + listLocationsSettings, + getLocationSettings, + setIamPolicySettings, + getIamPolicySettings, + testIamPermissionsSettings); + initDefaults(this); + } + + protected Builder(EventarcStubSettings settings) { + super(settings); + + getTriggerSettings = settings.getTriggerSettings.toBuilder(); + listTriggersSettings = settings.listTriggersSettings.toBuilder(); + createTriggerSettings = settings.createTriggerSettings.toBuilder(); + createTriggerOperationSettings = settings.createTriggerOperationSettings.toBuilder(); + updateTriggerSettings = settings.updateTriggerSettings.toBuilder(); + updateTriggerOperationSettings = settings.updateTriggerOperationSettings.toBuilder(); + deleteTriggerSettings = settings.deleteTriggerSettings.toBuilder(); + deleteTriggerOperationSettings = settings.deleteTriggerOperationSettings.toBuilder(); + getChannelSettings = settings.getChannelSettings.toBuilder(); + listChannelsSettings = settings.listChannelsSettings.toBuilder(); + createChannelSettings = settings.createChannelSettings.toBuilder(); + createChannelOperationSettings = settings.createChannelOperationSettings.toBuilder(); + updateChannelSettings = settings.updateChannelSettings.toBuilder(); + updateChannelOperationSettings = settings.updateChannelOperationSettings.toBuilder(); + deleteChannelSettings = settings.deleteChannelSettings.toBuilder(); + deleteChannelOperationSettings = settings.deleteChannelOperationSettings.toBuilder(); + getProviderSettings = settings.getProviderSettings.toBuilder(); + listProvidersSettings = settings.listProvidersSettings.toBuilder(); + getChannelConnectionSettings = settings.getChannelConnectionSettings.toBuilder(); + listChannelConnectionsSettings = settings.listChannelConnectionsSettings.toBuilder(); + createChannelConnectionSettings = settings.createChannelConnectionSettings.toBuilder(); + createChannelConnectionOperationSettings = + settings.createChannelConnectionOperationSettings.toBuilder(); + deleteChannelConnectionSettings = settings.deleteChannelConnectionSettings.toBuilder(); + deleteChannelConnectionOperationSettings = + settings.deleteChannelConnectionOperationSettings.toBuilder(); + getGoogleChannelConfigSettings = settings.getGoogleChannelConfigSettings.toBuilder(); + updateGoogleChannelConfigSettings = settings.updateGoogleChannelConfigSettings.toBuilder(); + listLocationsSettings = settings.listLocationsSettings.toBuilder(); + getLocationSettings = settings.getLocationSettings.toBuilder(); + setIamPolicySettings = settings.setIamPolicySettings.toBuilder(); + getIamPolicySettings = settings.getIamPolicySettings.toBuilder(); + testIamPermissionsSettings = settings.testIamPermissionsSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + getTriggerSettings, + listTriggersSettings, + createTriggerSettings, + updateTriggerSettings, + deleteTriggerSettings, + getChannelSettings, + listChannelsSettings, + createChannelSettings, + updateChannelSettings, + deleteChannelSettings, + getProviderSettings, + listProvidersSettings, + getChannelConnectionSettings, + listChannelConnectionsSettings, + createChannelConnectionSettings, + deleteChannelConnectionSettings, + getGoogleChannelConfigSettings, + updateGoogleChannelConfigSettings, + listLocationsSettings, + getLocationSettings, + setIamPolicySettings, + getIamPolicySettings, + testIamPermissionsSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder createHttpJsonDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultHttpJsonTransportProviderBuilder().build()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultHttpJsonApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); + builder.setSwitchToMtlsEndpointAllowed(true); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .getTriggerSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listTriggersSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createTriggerSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .updateTriggerSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteTriggerSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getChannelSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listChannelsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createChannelSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .updateChannelSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteChannelSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getProviderSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listProvidersSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getChannelConnectionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listChannelConnectionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createChannelConnectionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteChannelConnectionSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getGoogleChannelConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .updateGoogleChannelConfigSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listLocationsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getLocationSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .setIamPolicySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getIamPolicySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .testIamPermissionsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createTriggerOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Trigger.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .updateTriggerOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Trigger.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteTriggerOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Trigger.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .createChannelOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Channel.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .updateChannelOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Channel.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteChannelOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Channel.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .createChannelConnectionOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(ChannelConnection.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + builder + .deleteChannelConnectionOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(ChannelConnection.class)) + .setMetadataTransformer( + ProtoOperationTransformers.MetadataTransformer.create(OperationMetadata.class)) + .setPollingAlgorithm( + OperationTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(5000L)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelay(Duration.ofMillis(45000L)) + .setInitialRpcTimeout(Duration.ZERO) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ZERO) + .setTotalTimeout(Duration.ofMillis(300000L)) + .build())); + + return builder; + } + + /** + * Applies the given settings updater function to all of the unary API methods in this service. + * + *

Note: This method does not support applying settings to streaming methods. + */ + public Builder applyToAllUnaryMethods( + ApiFunction, Void> settingsUpdater) { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to getTrigger. */ + public UnaryCallSettings.Builder getTriggerSettings() { + return getTriggerSettings; + } + + /** Returns the builder for the settings used for calls to listTriggers. */ + public PagedCallSettings.Builder< + ListTriggersRequest, ListTriggersResponse, ListTriggersPagedResponse> + listTriggersSettings() { + return listTriggersSettings; + } + + /** Returns the builder for the settings used for calls to createTrigger. */ + public UnaryCallSettings.Builder createTriggerSettings() { + return createTriggerSettings; + } + + /** Returns the builder for the settings used for calls to createTrigger. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder + createTriggerOperationSettings() { + return createTriggerOperationSettings; + } + + /** Returns the builder for the settings used for calls to updateTrigger. */ + public UnaryCallSettings.Builder updateTriggerSettings() { + return updateTriggerSettings; + } + + /** Returns the builder for the settings used for calls to updateTrigger. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder + updateTriggerOperationSettings() { + return updateTriggerOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteTrigger. */ + public UnaryCallSettings.Builder deleteTriggerSettings() { + return deleteTriggerSettings; + } + + /** Returns the builder for the settings used for calls to deleteTrigger. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder + deleteTriggerOperationSettings() { + return deleteTriggerOperationSettings; + } + + /** Returns the builder for the settings used for calls to getChannel. */ + public UnaryCallSettings.Builder getChannelSettings() { + return getChannelSettings; + } + + /** Returns the builder for the settings used for calls to listChannels. */ + public PagedCallSettings.Builder< + ListChannelsRequest, ListChannelsResponse, ListChannelsPagedResponse> + listChannelsSettings() { + return listChannelsSettings; + } + + /** Returns the builder for the settings used for calls to createChannel. */ + public UnaryCallSettings.Builder createChannelSettings() { + return createChannelSettings; + } + + /** Returns the builder for the settings used for calls to createChannel. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder + createChannelOperationSettings() { + return createChannelOperationSettings; + } + + /** Returns the builder for the settings used for calls to updateChannel. */ + public UnaryCallSettings.Builder updateChannelSettings() { + return updateChannelSettings; + } + + /** Returns the builder for the settings used for calls to updateChannel. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder + updateChannelOperationSettings() { + return updateChannelOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteChannel. */ + public UnaryCallSettings.Builder deleteChannelSettings() { + return deleteChannelSettings; + } + + /** Returns the builder for the settings used for calls to deleteChannel. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder + deleteChannelOperationSettings() { + return deleteChannelOperationSettings; + } + + /** Returns the builder for the settings used for calls to getProvider. */ + public UnaryCallSettings.Builder getProviderSettings() { + return getProviderSettings; + } + + /** Returns the builder for the settings used for calls to listProviders. */ + public PagedCallSettings.Builder< + ListProvidersRequest, ListProvidersResponse, ListProvidersPagedResponse> + listProvidersSettings() { + return listProvidersSettings; + } + + /** Returns the builder for the settings used for calls to getChannelConnection. */ + public UnaryCallSettings.Builder + getChannelConnectionSettings() { + return getChannelConnectionSettings; + } + + /** Returns the builder for the settings used for calls to listChannelConnections. */ + public PagedCallSettings.Builder< + ListChannelConnectionsRequest, + ListChannelConnectionsResponse, + ListChannelConnectionsPagedResponse> + listChannelConnectionsSettings() { + return listChannelConnectionsSettings; + } + + /** Returns the builder for the settings used for calls to createChannelConnection. */ + public UnaryCallSettings.Builder + createChannelConnectionSettings() { + return createChannelConnectionSettings; + } + + /** Returns the builder for the settings used for calls to createChannelConnection. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationSettings() { + return createChannelConnectionOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteChannelConnection. */ + public UnaryCallSettings.Builder + deleteChannelConnectionSettings() { + return deleteChannelConnectionSettings; + } + + /** Returns the builder for the settings used for calls to deleteChannelConnection. */ + @BetaApi( + "The surface for use by generated code is not stable yet and may change in the future.") + public OperationCallSettings.Builder< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationSettings() { + return deleteChannelConnectionOperationSettings; + } + + /** Returns the builder for the settings used for calls to getGoogleChannelConfig. */ + public UnaryCallSettings.Builder + getGoogleChannelConfigSettings() { + return getGoogleChannelConfigSettings; + } + + /** Returns the builder for the settings used for calls to updateGoogleChannelConfig. */ + public UnaryCallSettings.Builder + updateGoogleChannelConfigSettings() { + return updateGoogleChannelConfigSettings; + } + + /** Returns the builder for the settings used for calls to listLocations. */ + public PagedCallSettings.Builder< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings() { + return listLocationsSettings; + } + + /** Returns the builder for the settings used for calls to getLocation. */ + public UnaryCallSettings.Builder getLocationSettings() { + return getLocationSettings; + } + + /** Returns the builder for the settings used for calls to setIamPolicy. */ + public UnaryCallSettings.Builder setIamPolicySettings() { + return setIamPolicySettings; + } + + /** Returns the builder for the settings used for calls to getIamPolicy. */ + public UnaryCallSettings.Builder getIamPolicySettings() { + return getIamPolicySettings; + } + + /** Returns the builder for the settings used for calls to testIamPermissions. */ + public UnaryCallSettings.Builder + testIamPermissionsSettings() { + return testIamPermissionsSettings; + } + + @Override + public EventarcStubSettings build() throws IOException { + return new EventarcStubSettings(this); + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java new file mode 100644 index 000000000000..77df91c9fb99 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcCallableFactory.java @@ -0,0 +1,113 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub; + +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcCallableFactory; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.BidiStreamingCallable; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientStreamingCallable; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.StreamingCallSettings; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.OperationsStub; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC callable factory implementation for the Eventarc service API. + * + *

This class is for advanced usage. + */ +@Generated("by gapic-generator-java") +public class GrpcEventarcCallableFactory implements GrpcStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + GrpcCallSettings grpcCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + GrpcCallSettings grpcCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createPagedCallable(grpcCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + GrpcCallSettings grpcCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBatchingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + OperationCallable createOperationCallable( + GrpcCallSettings grpcCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + return GrpcCallableFactory.createOperationCallable( + grpcCallSettings, callSettings, clientContext, operationsStub); + } + + @Override + public + BidiStreamingCallable createBidiStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createBidiStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + GrpcCallSettings grpcCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createServerStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } + + @Override + public + ClientStreamingCallable createClientStreamingCallable( + GrpcCallSettings grpcCallSettings, + StreamingCallSettings callSettings, + ClientContext clientContext) { + return GrpcCallableFactory.createClientStreamingCallable( + grpcCallSettings, callSettings, clientContext); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java new file mode 100644 index 000000000000..907248b7ea27 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/GrpcEventarcStub.java @@ -0,0 +1,1041 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.grpc.GrpcCallSettings; +import com.google.api.gax.grpc.GrpcStubCallableFactory; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.GetChannelConnectionRequest; +import com.google.cloud.eventarc.v1.GetChannelRequest; +import com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.GetProviderRequest; +import com.google.cloud.eventarc.v1.GetTriggerRequest; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.ListChannelConnectionsResponse; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.ListChannelsResponse; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.ListProvidersResponse; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.ListTriggersResponse; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.ImmutableMap; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.longrunning.stub.GrpcOperationsStub; +import io.grpc.MethodDescriptor; +import io.grpc.protobuf.ProtoUtils; +import java.io.IOException; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the Eventarc service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public class GrpcEventarcStub extends EventarcStub { + private static final MethodDescriptor getTriggerMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetTrigger") + .setRequestMarshaller(ProtoUtils.marshaller(GetTriggerRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Trigger.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + listTriggersMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListTriggers") + .setRequestMarshaller(ProtoUtils.marshaller(ListTriggersRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListTriggersResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + createTriggerMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/CreateTrigger") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateTriggerRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + updateTriggerMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/UpdateTrigger") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateTriggerRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + deleteTriggerMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/DeleteTrigger") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteTriggerRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor getChannelMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetChannel") + .setRequestMarshaller(ProtoUtils.marshaller(GetChannelRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Channel.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + listChannelsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListChannels") + .setRequestMarshaller(ProtoUtils.marshaller(ListChannelsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListChannelsResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + createChannelMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/CreateChannel") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateChannelRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + updateChannelMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/UpdateChannel") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateChannelRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + deleteChannelMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/DeleteChannel") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteChannelRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor getProviderMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetProvider") + .setRequestMarshaller(ProtoUtils.marshaller(GetProviderRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Provider.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + listProvidersMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListProviders") + .setRequestMarshaller( + ProtoUtils.marshaller(ListProvidersRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListProvidersResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + getChannelConnectionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetChannelConnection") + .setRequestMarshaller( + ProtoUtils.marshaller(GetChannelConnectionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(ChannelConnection.getDefaultInstance())) + .build(); + + private static final MethodDescriptor< + ListChannelConnectionsRequest, ListChannelConnectionsResponse> + listChannelConnectionsMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListChannelConnections") + .setRequestMarshaller( + ProtoUtils.marshaller(ListChannelConnectionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListChannelConnectionsResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + createChannelConnectionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/CreateChannelConnection") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateChannelConnectionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + deleteChannelConnectionMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/DeleteChannelConnection") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteChannelConnectionRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + getGoogleChannelConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetGoogleChannelConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(GetGoogleChannelConfigRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(GoogleChannelConfig.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + updateGoogleChannelConfigMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/UpdateGoogleChannelConfig") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateGoogleChannelConfigRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(GoogleChannelConfig.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + listLocationsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.location.Locations/ListLocations") + .setRequestMarshaller( + ProtoUtils.marshaller(ListLocationsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListLocationsResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor getLocationMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.location.Locations/GetLocation") + .setRequestMarshaller(ProtoUtils.marshaller(GetLocationRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Location.getDefaultInstance())) + .build(); + + private static final MethodDescriptor setIamPolicyMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.iam.v1.IAMPolicy/SetIamPolicy") + .setRequestMarshaller(ProtoUtils.marshaller(SetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) + .build(); + + private static final MethodDescriptor getIamPolicyMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.iam.v1.IAMPolicy/GetIamPolicy") + .setRequestMarshaller(ProtoUtils.marshaller(GetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Policy.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + testIamPermissionsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.iam.v1.IAMPolicy/TestIamPermissions") + .setRequestMarshaller( + ProtoUtils.marshaller(TestIamPermissionsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(TestIamPermissionsResponse.getDefaultInstance())) + .build(); + + private final UnaryCallable getTriggerCallable; + private final UnaryCallable listTriggersCallable; + private final UnaryCallable + listTriggersPagedCallable; + private final UnaryCallable createTriggerCallable; + private final OperationCallable + createTriggerOperationCallable; + private final UnaryCallable updateTriggerCallable; + private final OperationCallable + updateTriggerOperationCallable; + private final UnaryCallable deleteTriggerCallable; + private final OperationCallable + deleteTriggerOperationCallable; + private final UnaryCallable getChannelCallable; + private final UnaryCallable listChannelsCallable; + private final UnaryCallable + listChannelsPagedCallable; + private final UnaryCallable createChannelCallable; + private final OperationCallable + createChannelOperationCallable; + private final UnaryCallable updateChannelCallable; + private final OperationCallable + updateChannelOperationCallable; + private final UnaryCallable deleteChannelCallable; + private final OperationCallable + deleteChannelOperationCallable; + private final UnaryCallable getProviderCallable; + private final UnaryCallable listProvidersCallable; + private final UnaryCallable + listProvidersPagedCallable; + private final UnaryCallable + getChannelConnectionCallable; + private final UnaryCallable + listChannelConnectionsCallable; + private final UnaryCallable + listChannelConnectionsPagedCallable; + private final UnaryCallable + createChannelConnectionCallable; + private final OperationCallable< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationCallable; + private final UnaryCallable + deleteChannelConnectionCallable; + private final OperationCallable< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationCallable; + private final UnaryCallable + getGoogleChannelConfigCallable; + private final UnaryCallable + updateGoogleChannelConfigCallable; + private final UnaryCallable listLocationsCallable; + private final UnaryCallable + listLocationsPagedCallable; + private final UnaryCallable getLocationCallable; + private final UnaryCallable setIamPolicyCallable; + private final UnaryCallable getIamPolicyCallable; + private final UnaryCallable + testIamPermissionsCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcEventarcStub create(EventarcStubSettings settings) throws IOException { + return new GrpcEventarcStub(settings, ClientContext.create(settings)); + } + + public static final GrpcEventarcStub create(ClientContext clientContext) throws IOException { + return new GrpcEventarcStub(EventarcStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcEventarcStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcEventarcStub( + EventarcStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcEventarcStub, using the given settings. This is protected so that + * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. + */ + protected GrpcEventarcStub(EventarcStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcEventarcCallableFactory()); + } + + /** + * Constructs an instance of GrpcEventarcStub, using the given settings. This is protected so that + * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. + */ + protected GrpcEventarcStub( + EventarcStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings getTriggerTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getTriggerMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings listTriggersTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listTriggersMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings createTriggerTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createTriggerMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings updateTriggerTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateTriggerMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("trigger.name", String.valueOf(request.getTrigger().getName())); + return params.build(); + }) + .build(); + GrpcCallSettings deleteTriggerTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteTriggerMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings getChannelTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getChannelMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings listChannelsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listChannelsMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings createChannelTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createChannelMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings updateChannelTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateChannelMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("channel.name", String.valueOf(request.getChannel().getName())); + return params.build(); + }) + .build(); + GrpcCallSettings deleteChannelTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteChannelMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings getProviderTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getProviderMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings listProvidersTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listProvidersMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings + getChannelConnectionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getChannelConnectionMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings + listChannelConnectionsTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(listChannelConnectionsMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings + createChannelConnectionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createChannelConnectionMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + }) + .build(); + GrpcCallSettings + deleteChannelConnectionTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteChannelConnectionMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings + getGoogleChannelConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getGoogleChannelConfigMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings + updateGoogleChannelConfigTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateGoogleChannelConfigMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put( + "google_channel_config.name", + String.valueOf(request.getGoogleChannelConfig().getName())); + return params.build(); + }) + .build(); + GrpcCallSettings listLocationsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listLocationsMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings getLocationTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getLocationMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + }) + .build(); + GrpcCallSettings setIamPolicyTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(setIamPolicyMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("resource", String.valueOf(request.getResource())); + return params.build(); + }) + .build(); + GrpcCallSettings getIamPolicyTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getIamPolicyMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("resource", String.valueOf(request.getResource())); + return params.build(); + }) + .build(); + GrpcCallSettings + testIamPermissionsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(testIamPermissionsMethodDescriptor) + .setParamsExtractor( + request -> { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("resource", String.valueOf(request.getResource())); + return params.build(); + }) + .build(); + + this.getTriggerCallable = + callableFactory.createUnaryCallable( + getTriggerTransportSettings, settings.getTriggerSettings(), clientContext); + this.listTriggersCallable = + callableFactory.createUnaryCallable( + listTriggersTransportSettings, settings.listTriggersSettings(), clientContext); + this.listTriggersPagedCallable = + callableFactory.createPagedCallable( + listTriggersTransportSettings, settings.listTriggersSettings(), clientContext); + this.createTriggerCallable = + callableFactory.createUnaryCallable( + createTriggerTransportSettings, settings.createTriggerSettings(), clientContext); + this.createTriggerOperationCallable = + callableFactory.createOperationCallable( + createTriggerTransportSettings, + settings.createTriggerOperationSettings(), + clientContext, + operationsStub); + this.updateTriggerCallable = + callableFactory.createUnaryCallable( + updateTriggerTransportSettings, settings.updateTriggerSettings(), clientContext); + this.updateTriggerOperationCallable = + callableFactory.createOperationCallable( + updateTriggerTransportSettings, + settings.updateTriggerOperationSettings(), + clientContext, + operationsStub); + this.deleteTriggerCallable = + callableFactory.createUnaryCallable( + deleteTriggerTransportSettings, settings.deleteTriggerSettings(), clientContext); + this.deleteTriggerOperationCallable = + callableFactory.createOperationCallable( + deleteTriggerTransportSettings, + settings.deleteTriggerOperationSettings(), + clientContext, + operationsStub); + this.getChannelCallable = + callableFactory.createUnaryCallable( + getChannelTransportSettings, settings.getChannelSettings(), clientContext); + this.listChannelsCallable = + callableFactory.createUnaryCallable( + listChannelsTransportSettings, settings.listChannelsSettings(), clientContext); + this.listChannelsPagedCallable = + callableFactory.createPagedCallable( + listChannelsTransportSettings, settings.listChannelsSettings(), clientContext); + this.createChannelCallable = + callableFactory.createUnaryCallable( + createChannelTransportSettings, settings.createChannelSettings(), clientContext); + this.createChannelOperationCallable = + callableFactory.createOperationCallable( + createChannelTransportSettings, + settings.createChannelOperationSettings(), + clientContext, + operationsStub); + this.updateChannelCallable = + callableFactory.createUnaryCallable( + updateChannelTransportSettings, settings.updateChannelSettings(), clientContext); + this.updateChannelOperationCallable = + callableFactory.createOperationCallable( + updateChannelTransportSettings, + settings.updateChannelOperationSettings(), + clientContext, + operationsStub); + this.deleteChannelCallable = + callableFactory.createUnaryCallable( + deleteChannelTransportSettings, settings.deleteChannelSettings(), clientContext); + this.deleteChannelOperationCallable = + callableFactory.createOperationCallable( + deleteChannelTransportSettings, + settings.deleteChannelOperationSettings(), + clientContext, + operationsStub); + this.getProviderCallable = + callableFactory.createUnaryCallable( + getProviderTransportSettings, settings.getProviderSettings(), clientContext); + this.listProvidersCallable = + callableFactory.createUnaryCallable( + listProvidersTransportSettings, settings.listProvidersSettings(), clientContext); + this.listProvidersPagedCallable = + callableFactory.createPagedCallable( + listProvidersTransportSettings, settings.listProvidersSettings(), clientContext); + this.getChannelConnectionCallable = + callableFactory.createUnaryCallable( + getChannelConnectionTransportSettings, + settings.getChannelConnectionSettings(), + clientContext); + this.listChannelConnectionsCallable = + callableFactory.createUnaryCallable( + listChannelConnectionsTransportSettings, + settings.listChannelConnectionsSettings(), + clientContext); + this.listChannelConnectionsPagedCallable = + callableFactory.createPagedCallable( + listChannelConnectionsTransportSettings, + settings.listChannelConnectionsSettings(), + clientContext); + this.createChannelConnectionCallable = + callableFactory.createUnaryCallable( + createChannelConnectionTransportSettings, + settings.createChannelConnectionSettings(), + clientContext); + this.createChannelConnectionOperationCallable = + callableFactory.createOperationCallable( + createChannelConnectionTransportSettings, + settings.createChannelConnectionOperationSettings(), + clientContext, + operationsStub); + this.deleteChannelConnectionCallable = + callableFactory.createUnaryCallable( + deleteChannelConnectionTransportSettings, + settings.deleteChannelConnectionSettings(), + clientContext); + this.deleteChannelConnectionOperationCallable = + callableFactory.createOperationCallable( + deleteChannelConnectionTransportSettings, + settings.deleteChannelConnectionOperationSettings(), + clientContext, + operationsStub); + this.getGoogleChannelConfigCallable = + callableFactory.createUnaryCallable( + getGoogleChannelConfigTransportSettings, + settings.getGoogleChannelConfigSettings(), + clientContext); + this.updateGoogleChannelConfigCallable = + callableFactory.createUnaryCallable( + updateGoogleChannelConfigTransportSettings, + settings.updateGoogleChannelConfigSettings(), + clientContext); + this.listLocationsCallable = + callableFactory.createUnaryCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.listLocationsPagedCallable = + callableFactory.createPagedCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.getLocationCallable = + callableFactory.createUnaryCallable( + getLocationTransportSettings, settings.getLocationSettings(), clientContext); + this.setIamPolicyCallable = + callableFactory.createUnaryCallable( + setIamPolicyTransportSettings, settings.setIamPolicySettings(), clientContext); + this.getIamPolicyCallable = + callableFactory.createUnaryCallable( + getIamPolicyTransportSettings, settings.getIamPolicySettings(), clientContext); + this.testIamPermissionsCallable = + callableFactory.createUnaryCallable( + testIamPermissionsTransportSettings, + settings.testIamPermissionsSettings(), + clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + @Override + public UnaryCallable getTriggerCallable() { + return getTriggerCallable; + } + + @Override + public UnaryCallable listTriggersCallable() { + return listTriggersCallable; + } + + @Override + public UnaryCallable listTriggersPagedCallable() { + return listTriggersPagedCallable; + } + + @Override + public UnaryCallable createTriggerCallable() { + return createTriggerCallable; + } + + @Override + public OperationCallable + createTriggerOperationCallable() { + return createTriggerOperationCallable; + } + + @Override + public UnaryCallable updateTriggerCallable() { + return updateTriggerCallable; + } + + @Override + public OperationCallable + updateTriggerOperationCallable() { + return updateTriggerOperationCallable; + } + + @Override + public UnaryCallable deleteTriggerCallable() { + return deleteTriggerCallable; + } + + @Override + public OperationCallable + deleteTriggerOperationCallable() { + return deleteTriggerOperationCallable; + } + + @Override + public UnaryCallable getChannelCallable() { + return getChannelCallable; + } + + @Override + public UnaryCallable listChannelsCallable() { + return listChannelsCallable; + } + + @Override + public UnaryCallable listChannelsPagedCallable() { + return listChannelsPagedCallable; + } + + @Override + public UnaryCallable createChannelCallable() { + return createChannelCallable; + } + + @Override + public OperationCallable + createChannelOperationCallable() { + return createChannelOperationCallable; + } + + @Override + public UnaryCallable updateChannelCallable() { + return updateChannelCallable; + } + + @Override + public OperationCallable + updateChannelOperationCallable() { + return updateChannelOperationCallable; + } + + @Override + public UnaryCallable deleteChannelCallable() { + return deleteChannelCallable; + } + + @Override + public OperationCallable + deleteChannelOperationCallable() { + return deleteChannelOperationCallable; + } + + @Override + public UnaryCallable getProviderCallable() { + return getProviderCallable; + } + + @Override + public UnaryCallable listProvidersCallable() { + return listProvidersCallable; + } + + @Override + public UnaryCallable + listProvidersPagedCallable() { + return listProvidersPagedCallable; + } + + @Override + public UnaryCallable + getChannelConnectionCallable() { + return getChannelConnectionCallable; + } + + @Override + public UnaryCallable + listChannelConnectionsCallable() { + return listChannelConnectionsCallable; + } + + @Override + public UnaryCallable + listChannelConnectionsPagedCallable() { + return listChannelConnectionsPagedCallable; + } + + @Override + public UnaryCallable + createChannelConnectionCallable() { + return createChannelConnectionCallable; + } + + @Override + public OperationCallable + createChannelConnectionOperationCallable() { + return createChannelConnectionOperationCallable; + } + + @Override + public UnaryCallable + deleteChannelConnectionCallable() { + return deleteChannelConnectionCallable; + } + + @Override + public OperationCallable + deleteChannelConnectionOperationCallable() { + return deleteChannelConnectionOperationCallable; + } + + @Override + public UnaryCallable + getGoogleChannelConfigCallable() { + return getGoogleChannelConfigCallable; + } + + @Override + public UnaryCallable + updateGoogleChannelConfigCallable() { + return updateGoogleChannelConfigCallable; + } + + @Override + public UnaryCallable listLocationsCallable() { + return listLocationsCallable; + } + + @Override + public UnaryCallable + listLocationsPagedCallable() { + return listLocationsPagedCallable; + } + + @Override + public UnaryCallable getLocationCallable() { + return getLocationCallable; + } + + @Override + public UnaryCallable setIamPolicyCallable() { + return setIamPolicyCallable; + } + + @Override + public UnaryCallable getIamPolicyCallable() { + return getIamPolicyCallable; + } + + @Override + public UnaryCallable + testIamPermissionsCallable() { + return testIamPermissionsCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java new file mode 100644 index 000000000000..a3d7450d753f --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcCallableFactory.java @@ -0,0 +1,105 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub; + +import com.google.api.core.BetaApi; +import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonCallableFactory; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshotCallable; +import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; +import com.google.api.gax.httpjson.longrunning.stub.OperationsStub; +import com.google.api.gax.rpc.BatchingCallSettings; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallSettings; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.PagedCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallSettings; +import com.google.api.gax.rpc.ServerStreamingCallable; +import com.google.api.gax.rpc.UnaryCallSettings; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.longrunning.Operation; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST callable factory implementation for the Eventarc service API. + * + *

This class is for advanced usage. + */ +@Generated("by gapic-generator-java") +@BetaApi +public class HttpJsonEventarcCallableFactory + implements HttpJsonStubCallableFactory { + + @Override + public UnaryCallable createUnaryCallable( + HttpJsonCallSettings httpJsonCallSettings, + UnaryCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createUnaryCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public + UnaryCallable createPagedCallable( + HttpJsonCallSettings httpJsonCallSettings, + PagedCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createPagedCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @Override + public UnaryCallable createBatchingCallable( + HttpJsonCallSettings httpJsonCallSettings, + BatchingCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createBatchingCallable( + httpJsonCallSettings, callSettings, clientContext); + } + + @BetaApi( + "The surface for long-running operations is not stable yet and may change in the future.") + @Override + public + OperationCallable createOperationCallable( + HttpJsonCallSettings httpJsonCallSettings, + OperationCallSettings callSettings, + ClientContext clientContext, + OperationsStub operationsStub) { + UnaryCallable innerCallable = + HttpJsonCallableFactory.createBaseUnaryCallable( + httpJsonCallSettings, callSettings.getInitialCallSettings(), clientContext); + HttpJsonOperationSnapshotCallable initialCallable = + new HttpJsonOperationSnapshotCallable( + innerCallable, + httpJsonCallSettings.getMethodDescriptor().getOperationSnapshotFactory()); + return HttpJsonCallableFactory.createOperationCallable( + callSettings, clientContext, operationsStub.longRunningClient(), initialCallable); + } + + @Override + public + ServerStreamingCallable createServerStreamingCallable( + HttpJsonCallSettings httpJsonCallSettings, + ServerStreamingCallSettings callSettings, + ClientContext clientContext) { + return HttpJsonCallableFactory.createServerStreamingCallable( + httpJsonCallSettings, callSettings, clientContext); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java new file mode 100644 index 000000000000..c268fc5b7b07 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/main/java/com/google/cloud/eventarc/v1/stub/HttpJsonEventarcStub.java @@ -0,0 +1,1614 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.core.InternalApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.core.BackgroundResourceAggregation; +import com.google.api.gax.httpjson.ApiMethodDescriptor; +import com.google.api.gax.httpjson.HttpJsonCallSettings; +import com.google.api.gax.httpjson.HttpJsonOperationSnapshot; +import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; +import com.google.api.gax.httpjson.ProtoMessageRequestFormatter; +import com.google.api.gax.httpjson.ProtoMessageResponseParser; +import com.google.api.gax.httpjson.ProtoRestSerializer; +import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.OperationCallable; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.GetChannelConnectionRequest; +import com.google.cloud.eventarc.v1.GetChannelRequest; +import com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.GetProviderRequest; +import com.google.cloud.eventarc.v1.GetTriggerRequest; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.ListChannelConnectionsResponse; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.ListChannelsResponse; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.ListProvidersResponse; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.ListTriggersResponse; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.TypeRegistry; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST stub implementation for the Eventarc service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +@BetaApi +public class HttpJsonEventarcStub extends EventarcStub { + private static final TypeRegistry typeRegistry = + TypeRegistry.newBuilder() + .add(Channel.getDescriptor()) + .add(OperationMetadata.getDescriptor()) + .add(Trigger.getDescriptor()) + .add(ChannelConnection.getDescriptor()) + .build(); + + private static final ApiMethodDescriptor getTriggerMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetTrigger") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/triggers/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Trigger.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listTriggersMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListTriggers") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/triggers", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListTriggersResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createTriggerMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/CreateTrigger") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/triggers", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "triggerId", request.getTriggerId()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("trigger", request.getTrigger(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateTriggerRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + updateTriggerMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/UpdateTrigger") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{trigger.name=projects/*/locations/*/triggers/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "trigger.name", request.getTrigger().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "allowMissing", request.getAllowMissing()); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("trigger", request.getTrigger(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateTriggerRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + deleteTriggerMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/DeleteTrigger") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/triggers/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "allowMissing", request.getAllowMissing()); + serializer.putQueryParam(fields, "etag", request.getEtag()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (DeleteTriggerRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor getChannelMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetChannel") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/channels/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Channel.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listChannelsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListChannels") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/channels", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListChannelsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createChannelMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/CreateChannel") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/channels", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "channelId", request.getChannelId()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("channel", request.getChannel(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateChannelRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + updateChannelMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/UpdateChannel") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{channel.name=projects/*/locations/*/channels/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "channel.name", request.getChannel().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("channel", request.getChannel(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateChannelRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + deleteChannelMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/DeleteChannel") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/channels/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (DeleteChannelRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + getProviderMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetProvider") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/providers/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Provider.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listProvidersMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListProviders") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/providers", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "filter", request.getFilter()); + serializer.putQueryParam(fields, "orderBy", request.getOrderBy()); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListProvidersResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getChannelConnectionMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetChannelConnection") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/channelConnections/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ChannelConnection.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor< + ListChannelConnectionsRequest, ListChannelConnectionsResponse> + listChannelConnectionsMethodDescriptor = + ApiMethodDescriptor + .newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/ListChannelConnections") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/channelConnections", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "pageSize", request.getPageSize()); + serializer.putQueryParam(fields, "pageToken", request.getPageToken()); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListChannelConnectionsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createChannelConnectionMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/CreateChannelConnection") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/channelConnections", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "parent", request.getParent()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam( + fields, "channelConnectionId", request.getChannelConnectionId()); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody( + "channelConnection", request.getChannelConnection(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateChannelConnectionRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + deleteChannelConnectionMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/DeleteChannelConnection") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/channelConnections/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (DeleteChannelConnectionRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + getGoogleChannelConfigMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/GetGoogleChannelConfig") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/googleChannelConfig}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(GoogleChannelConfig.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + updateGoogleChannelConfigMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.eventarc.v1.Eventarc/UpdateGoogleChannelConfig") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{googleChannelConfig.name=projects/*/locations/*/googleChannelConfig}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, + "googleChannelConfig.name", + request.getGoogleChannelConfig().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody( + "googleChannelConfig", + request.getGoogleChannelConfig(), + false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(GoogleChannelConfig.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listLocationsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.location.Locations/ListLocations") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*}/locations", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(ListLocationsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getLocationMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.location.Locations/GetLocation") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "name", request.getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Location.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + setIamPolicyMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.iam.v1.IAMPolicy/SetIamPolicy") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{resource=projects/*/locations/*/triggers/*}:setIamPolicy", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "resource", request.getResource()); + return fields; + }) + .setAdditionalPaths( + "/v1/{resource=projects/*/locations/*/channels/*}:setIamPolicy", + "/v1/{resource=projects/*/locations/*/channelConnections/*}:setIamPolicy") + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearResource().build(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Policy.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getIamPolicyMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.iam.v1.IAMPolicy/GetIamPolicy") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{resource=projects/*/locations/*/triggers/*}:getIamPolicy", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "resource", request.getResource()); + return fields; + }) + .setAdditionalPaths( + "/v1/{resource=projects/*/locations/*/channels/*}:getIamPolicy", + "/v1/{resource=projects/*/locations/*/channelConnections/*}:getIamPolicy") + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor(request -> null) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Policy.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + testIamPermissionsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.iam.v1.IAMPolicy/TestIamPermissions") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{resource=projects/*/locations/*/triggers/*}:testIamPermissions", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam(fields, "resource", request.getResource()); + return fields; + }) + .setAdditionalPaths( + "/v1/{resource=projects/*/locations/*/channels/*}:testIamPermissions", + "/v1/{resource=projects/*/locations/*/channelConnections/*}:testIamPermissions") + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("*", request.toBuilder().clearResource().build(), false)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(TestIamPermissionsResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private final UnaryCallable getTriggerCallable; + private final UnaryCallable listTriggersCallable; + private final UnaryCallable + listTriggersPagedCallable; + private final UnaryCallable createTriggerCallable; + private final OperationCallable + createTriggerOperationCallable; + private final UnaryCallable updateTriggerCallable; + private final OperationCallable + updateTriggerOperationCallable; + private final UnaryCallable deleteTriggerCallable; + private final OperationCallable + deleteTriggerOperationCallable; + private final UnaryCallable getChannelCallable; + private final UnaryCallable listChannelsCallable; + private final UnaryCallable + listChannelsPagedCallable; + private final UnaryCallable createChannelCallable; + private final OperationCallable + createChannelOperationCallable; + private final UnaryCallable updateChannelCallable; + private final OperationCallable + updateChannelOperationCallable; + private final UnaryCallable deleteChannelCallable; + private final OperationCallable + deleteChannelOperationCallable; + private final UnaryCallable getProviderCallable; + private final UnaryCallable listProvidersCallable; + private final UnaryCallable + listProvidersPagedCallable; + private final UnaryCallable + getChannelConnectionCallable; + private final UnaryCallable + listChannelConnectionsCallable; + private final UnaryCallable + listChannelConnectionsPagedCallable; + private final UnaryCallable + createChannelConnectionCallable; + private final OperationCallable< + CreateChannelConnectionRequest, ChannelConnection, OperationMetadata> + createChannelConnectionOperationCallable; + private final UnaryCallable + deleteChannelConnectionCallable; + private final OperationCallable< + DeleteChannelConnectionRequest, ChannelConnection, OperationMetadata> + deleteChannelConnectionOperationCallable; + private final UnaryCallable + getGoogleChannelConfigCallable; + private final UnaryCallable + updateGoogleChannelConfigCallable; + private final UnaryCallable listLocationsCallable; + private final UnaryCallable + listLocationsPagedCallable; + private final UnaryCallable getLocationCallable; + private final UnaryCallable setIamPolicyCallable; + private final UnaryCallable getIamPolicyCallable; + private final UnaryCallable + testIamPermissionsCallable; + + private final BackgroundResource backgroundResources; + private final HttpJsonOperationsStub httpJsonOperationsStub; + private final HttpJsonStubCallableFactory callableFactory; + + public static final HttpJsonEventarcStub create(EventarcStubSettings settings) + throws IOException { + return new HttpJsonEventarcStub(settings, ClientContext.create(settings)); + } + + public static final HttpJsonEventarcStub create(ClientContext clientContext) throws IOException { + return new HttpJsonEventarcStub( + EventarcStubSettings.newHttpJsonBuilder().build(), clientContext); + } + + public static final HttpJsonEventarcStub create( + ClientContext clientContext, HttpJsonStubCallableFactory callableFactory) throws IOException { + return new HttpJsonEventarcStub( + EventarcStubSettings.newHttpJsonBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of HttpJsonEventarcStub, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected HttpJsonEventarcStub(EventarcStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new HttpJsonEventarcCallableFactory()); + } + + /** + * Constructs an instance of HttpJsonEventarcStub, using the given settings. This is protected so + * that it is easy to make a subclass, but otherwise, the static factory methods should be + * preferred. + */ + protected HttpJsonEventarcStub( + EventarcStubSettings settings, + ClientContext clientContext, + HttpJsonStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.httpJsonOperationsStub = + HttpJsonOperationsStub.create(clientContext, callableFactory, typeRegistry); + + HttpJsonCallSettings getTriggerTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getTriggerMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings listTriggersTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listTriggersMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings createTriggerTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createTriggerMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings updateTriggerTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateTriggerMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings deleteTriggerTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteTriggerMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings getChannelTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getChannelMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings listChannelsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listChannelsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings createChannelTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createChannelMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings updateChannelTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateChannelMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings deleteChannelTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteChannelMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings getProviderTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getProviderMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + listProvidersTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listProvidersMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + getChannelConnectionTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getChannelConnectionMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + listChannelConnectionsTransportSettings = + HttpJsonCallSettings + .newBuilder() + .setMethodDescriptor(listChannelConnectionsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + createChannelConnectionTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createChannelConnectionMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + deleteChannelConnectionTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteChannelConnectionMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + getGoogleChannelConfigTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getGoogleChannelConfigMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + updateGoogleChannelConfigTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateGoogleChannelConfigMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + listLocationsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listLocationsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings getLocationTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getLocationMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings setIamPolicyTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(setIamPolicyMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings getIamPolicyTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getIamPolicyMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + HttpJsonCallSettings + testIamPermissionsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(testIamPermissionsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .build(); + + this.getTriggerCallable = + callableFactory.createUnaryCallable( + getTriggerTransportSettings, settings.getTriggerSettings(), clientContext); + this.listTriggersCallable = + callableFactory.createUnaryCallable( + listTriggersTransportSettings, settings.listTriggersSettings(), clientContext); + this.listTriggersPagedCallable = + callableFactory.createPagedCallable( + listTriggersTransportSettings, settings.listTriggersSettings(), clientContext); + this.createTriggerCallable = + callableFactory.createUnaryCallable( + createTriggerTransportSettings, settings.createTriggerSettings(), clientContext); + this.createTriggerOperationCallable = + callableFactory.createOperationCallable( + createTriggerTransportSettings, + settings.createTriggerOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.updateTriggerCallable = + callableFactory.createUnaryCallable( + updateTriggerTransportSettings, settings.updateTriggerSettings(), clientContext); + this.updateTriggerOperationCallable = + callableFactory.createOperationCallable( + updateTriggerTransportSettings, + settings.updateTriggerOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.deleteTriggerCallable = + callableFactory.createUnaryCallable( + deleteTriggerTransportSettings, settings.deleteTriggerSettings(), clientContext); + this.deleteTriggerOperationCallable = + callableFactory.createOperationCallable( + deleteTriggerTransportSettings, + settings.deleteTriggerOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.getChannelCallable = + callableFactory.createUnaryCallable( + getChannelTransportSettings, settings.getChannelSettings(), clientContext); + this.listChannelsCallable = + callableFactory.createUnaryCallable( + listChannelsTransportSettings, settings.listChannelsSettings(), clientContext); + this.listChannelsPagedCallable = + callableFactory.createPagedCallable( + listChannelsTransportSettings, settings.listChannelsSettings(), clientContext); + this.createChannelCallable = + callableFactory.createUnaryCallable( + createChannelTransportSettings, settings.createChannelSettings(), clientContext); + this.createChannelOperationCallable = + callableFactory.createOperationCallable( + createChannelTransportSettings, + settings.createChannelOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.updateChannelCallable = + callableFactory.createUnaryCallable( + updateChannelTransportSettings, settings.updateChannelSettings(), clientContext); + this.updateChannelOperationCallable = + callableFactory.createOperationCallable( + updateChannelTransportSettings, + settings.updateChannelOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.deleteChannelCallable = + callableFactory.createUnaryCallable( + deleteChannelTransportSettings, settings.deleteChannelSettings(), clientContext); + this.deleteChannelOperationCallable = + callableFactory.createOperationCallable( + deleteChannelTransportSettings, + settings.deleteChannelOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.getProviderCallable = + callableFactory.createUnaryCallable( + getProviderTransportSettings, settings.getProviderSettings(), clientContext); + this.listProvidersCallable = + callableFactory.createUnaryCallable( + listProvidersTransportSettings, settings.listProvidersSettings(), clientContext); + this.listProvidersPagedCallable = + callableFactory.createPagedCallable( + listProvidersTransportSettings, settings.listProvidersSettings(), clientContext); + this.getChannelConnectionCallable = + callableFactory.createUnaryCallable( + getChannelConnectionTransportSettings, + settings.getChannelConnectionSettings(), + clientContext); + this.listChannelConnectionsCallable = + callableFactory.createUnaryCallable( + listChannelConnectionsTransportSettings, + settings.listChannelConnectionsSettings(), + clientContext); + this.listChannelConnectionsPagedCallable = + callableFactory.createPagedCallable( + listChannelConnectionsTransportSettings, + settings.listChannelConnectionsSettings(), + clientContext); + this.createChannelConnectionCallable = + callableFactory.createUnaryCallable( + createChannelConnectionTransportSettings, + settings.createChannelConnectionSettings(), + clientContext); + this.createChannelConnectionOperationCallable = + callableFactory.createOperationCallable( + createChannelConnectionTransportSettings, + settings.createChannelConnectionOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.deleteChannelConnectionCallable = + callableFactory.createUnaryCallable( + deleteChannelConnectionTransportSettings, + settings.deleteChannelConnectionSettings(), + clientContext); + this.deleteChannelConnectionOperationCallable = + callableFactory.createOperationCallable( + deleteChannelConnectionTransportSettings, + settings.deleteChannelConnectionOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.getGoogleChannelConfigCallable = + callableFactory.createUnaryCallable( + getGoogleChannelConfigTransportSettings, + settings.getGoogleChannelConfigSettings(), + clientContext); + this.updateGoogleChannelConfigCallable = + callableFactory.createUnaryCallable( + updateGoogleChannelConfigTransportSettings, + settings.updateGoogleChannelConfigSettings(), + clientContext); + this.listLocationsCallable = + callableFactory.createUnaryCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.listLocationsPagedCallable = + callableFactory.createPagedCallable( + listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); + this.getLocationCallable = + callableFactory.createUnaryCallable( + getLocationTransportSettings, settings.getLocationSettings(), clientContext); + this.setIamPolicyCallable = + callableFactory.createUnaryCallable( + setIamPolicyTransportSettings, settings.setIamPolicySettings(), clientContext); + this.getIamPolicyCallable = + callableFactory.createUnaryCallable( + getIamPolicyTransportSettings, settings.getIamPolicySettings(), clientContext); + this.testIamPermissionsCallable = + callableFactory.createUnaryCallable( + testIamPermissionsTransportSettings, + settings.testIamPermissionsSettings(), + clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + @InternalApi + public static List getMethodDescriptors() { + List methodDescriptors = new ArrayList<>(); + methodDescriptors.add(getTriggerMethodDescriptor); + methodDescriptors.add(listTriggersMethodDescriptor); + methodDescriptors.add(createTriggerMethodDescriptor); + methodDescriptors.add(updateTriggerMethodDescriptor); + methodDescriptors.add(deleteTriggerMethodDescriptor); + methodDescriptors.add(getChannelMethodDescriptor); + methodDescriptors.add(listChannelsMethodDescriptor); + methodDescriptors.add(createChannelMethodDescriptor); + methodDescriptors.add(updateChannelMethodDescriptor); + methodDescriptors.add(deleteChannelMethodDescriptor); + methodDescriptors.add(getProviderMethodDescriptor); + methodDescriptors.add(listProvidersMethodDescriptor); + methodDescriptors.add(getChannelConnectionMethodDescriptor); + methodDescriptors.add(listChannelConnectionsMethodDescriptor); + methodDescriptors.add(createChannelConnectionMethodDescriptor); + methodDescriptors.add(deleteChannelConnectionMethodDescriptor); + methodDescriptors.add(getGoogleChannelConfigMethodDescriptor); + methodDescriptors.add(updateGoogleChannelConfigMethodDescriptor); + methodDescriptors.add(listLocationsMethodDescriptor); + methodDescriptors.add(getLocationMethodDescriptor); + methodDescriptors.add(setIamPolicyMethodDescriptor); + methodDescriptors.add(getIamPolicyMethodDescriptor); + methodDescriptors.add(testIamPermissionsMethodDescriptor); + return methodDescriptors; + } + + public HttpJsonOperationsStub getHttpJsonOperationsStub() { + return httpJsonOperationsStub; + } + + @Override + public UnaryCallable getTriggerCallable() { + return getTriggerCallable; + } + + @Override + public UnaryCallable listTriggersCallable() { + return listTriggersCallable; + } + + @Override + public UnaryCallable listTriggersPagedCallable() { + return listTriggersPagedCallable; + } + + @Override + public UnaryCallable createTriggerCallable() { + return createTriggerCallable; + } + + @Override + public OperationCallable + createTriggerOperationCallable() { + return createTriggerOperationCallable; + } + + @Override + public UnaryCallable updateTriggerCallable() { + return updateTriggerCallable; + } + + @Override + public OperationCallable + updateTriggerOperationCallable() { + return updateTriggerOperationCallable; + } + + @Override + public UnaryCallable deleteTriggerCallable() { + return deleteTriggerCallable; + } + + @Override + public OperationCallable + deleteTriggerOperationCallable() { + return deleteTriggerOperationCallable; + } + + @Override + public UnaryCallable getChannelCallable() { + return getChannelCallable; + } + + @Override + public UnaryCallable listChannelsCallable() { + return listChannelsCallable; + } + + @Override + public UnaryCallable listChannelsPagedCallable() { + return listChannelsPagedCallable; + } + + @Override + public UnaryCallable createChannelCallable() { + return createChannelCallable; + } + + @Override + public OperationCallable + createChannelOperationCallable() { + return createChannelOperationCallable; + } + + @Override + public UnaryCallable updateChannelCallable() { + return updateChannelCallable; + } + + @Override + public OperationCallable + updateChannelOperationCallable() { + return updateChannelOperationCallable; + } + + @Override + public UnaryCallable deleteChannelCallable() { + return deleteChannelCallable; + } + + @Override + public OperationCallable + deleteChannelOperationCallable() { + return deleteChannelOperationCallable; + } + + @Override + public UnaryCallable getProviderCallable() { + return getProviderCallable; + } + + @Override + public UnaryCallable listProvidersCallable() { + return listProvidersCallable; + } + + @Override + public UnaryCallable + listProvidersPagedCallable() { + return listProvidersPagedCallable; + } + + @Override + public UnaryCallable + getChannelConnectionCallable() { + return getChannelConnectionCallable; + } + + @Override + public UnaryCallable + listChannelConnectionsCallable() { + return listChannelConnectionsCallable; + } + + @Override + public UnaryCallable + listChannelConnectionsPagedCallable() { + return listChannelConnectionsPagedCallable; + } + + @Override + public UnaryCallable + createChannelConnectionCallable() { + return createChannelConnectionCallable; + } + + @Override + public OperationCallable + createChannelConnectionOperationCallable() { + return createChannelConnectionOperationCallable; + } + + @Override + public UnaryCallable + deleteChannelConnectionCallable() { + return deleteChannelConnectionCallable; + } + + @Override + public OperationCallable + deleteChannelConnectionOperationCallable() { + return deleteChannelConnectionOperationCallable; + } + + @Override + public UnaryCallable + getGoogleChannelConfigCallable() { + return getGoogleChannelConfigCallable; + } + + @Override + public UnaryCallable + updateGoogleChannelConfigCallable() { + return updateGoogleChannelConfigCallable; + } + + @Override + public UnaryCallable listLocationsCallable() { + return listLocationsCallable; + } + + @Override + public UnaryCallable + listLocationsPagedCallable() { + return listLocationsPagedCallable; + } + + @Override + public UnaryCallable getLocationCallable() { + return getLocationCallable; + } + + @Override + public UnaryCallable setIamPolicyCallable() { + return setIamPolicyCallable; + } + + @Override + public UnaryCallable getIamPolicyCallable() { + return getIamPolicyCallable; + } + + @Override + public UnaryCallable + testIamPermissionsCallable() { + return testIamPermissionsCallable; + } + + @Override + public final void close() { + try { + backgroundResources.close(); + } catch (RuntimeException e) { + throw e; + } catch (Exception e) { + throw new IllegalStateException("Failed to close resource", e); + } + } + + @Override + public void shutdown() { + backgroundResources.shutdown(); + } + + @Override + public boolean isShutdown() { + return backgroundResources.isShutdown(); + } + + @Override + public boolean isTerminated() { + return backgroundResources.isTerminated(); + } + + @Override + public void shutdownNow() { + backgroundResources.shutdownNow(); + } + + @Override + public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { + return backgroundResources.awaitTermination(duration, unit); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java new file mode 100644 index 000000000000..af9056d0ab2e --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientHttpJsonTest.java @@ -0,0 +1,2222 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.httpjson.GaxHttpJsonProperties; +import com.google.api.gax.httpjson.testing.MockHttpService; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ApiException; +import com.google.api.gax.rpc.ApiExceptionFactory; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.api.gax.rpc.testing.FakeStatusCode; +import com.google.cloud.eventarc.v1.stub.HttpJsonEventarcStub; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.Lists; +import com.google.iam.v1.AuditConfig; +import com.google.iam.v1.Binding; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.Any; +import com.google.protobuf.ByteString; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.concurrent.ExecutionException; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class EventarcClientHttpJsonTest { + private static MockHttpService mockService; + private static EventarcClient client; + + @BeforeClass + public static void startStaticServer() throws IOException { + mockService = + new MockHttpService( + HttpJsonEventarcStub.getMethodDescriptors(), EventarcSettings.getDefaultEndpoint()); + EventarcSettings settings = + EventarcSettings.newHttpJsonBuilder() + .setTransportChannelProvider( + EventarcSettings.defaultHttpJsonTransportProviderBuilder() + .setHttpTransport(mockService) + .build()) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = EventarcClient.create(settings); + } + + @AfterClass + public static void stopServer() { + client.close(); + } + + @Before + public void setUp() {} + + @After + public void tearDown() throws Exception { + mockService.reset(); + } + + @Test + public void getTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + mockService.addResponse(expectedResponse); + + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + + Trigger actualResponse = client.getTrigger(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getTriggerExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + client.getTrigger(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getTriggerTest2() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-3275/locations/location-3275/triggers/trigger-3275"; + + Trigger actualResponse = client.getTrigger(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getTriggerExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-3275/locations/location-3275/triggers/trigger-3275"; + client.getTrigger(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listTriggersTest() throws Exception { + Trigger responsesElement = Trigger.newBuilder().build(); + ListTriggersResponse expectedResponse = + ListTriggersResponse.newBuilder() + .setNextPageToken("") + .addAllTriggers(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListTriggersPagedResponse pagedListResponse = client.listTriggers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTriggersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listTriggersExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listTriggers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listTriggersTest2() throws Exception { + Trigger responsesElement = Trigger.newBuilder().build(); + ListTriggersResponse expectedResponse = + ListTriggersResponse.newBuilder() + .setNextPageToken("") + .addAllTriggers(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListTriggersPagedResponse pagedListResponse = client.listTriggers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTriggersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listTriggersExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listTriggers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + + Trigger actualResponse = client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createTriggerExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createTriggerTest2() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + + Trigger actualResponse = client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createTriggerExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void updateTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + Trigger trigger = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + boolean allowMissing = true; + + Trigger actualResponse = client.updateTriggerAsync(trigger, updateMask, allowMissing).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateTriggerExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + Trigger trigger = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + boolean allowMissing = true; + client.updateTriggerAsync(trigger, updateMask, allowMissing).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + boolean allowMissing = true; + + Trigger actualResponse = client.deleteTriggerAsync(name, allowMissing).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteTriggerExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + boolean allowMissing = true; + client.deleteTriggerAsync(name, allowMissing).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteTriggerTest2() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-3275/locations/location-3275/triggers/trigger-3275"; + boolean allowMissing = true; + + Trigger actualResponse = client.deleteTriggerAsync(name, allowMissing).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteTriggerExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-3275/locations/location-3275/triggers/trigger-3275"; + boolean allowMissing = true; + client.deleteTriggerAsync(name, allowMissing).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void getChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockService.addResponse(expectedResponse); + + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + + Channel actualResponse = client.getChannel(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getChannelExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + client.getChannel(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChannelTest2() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-3296/locations/location-3296/channels/channel-3296"; + + Channel actualResponse = client.getChannel(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getChannelExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-3296/locations/location-3296/channels/channel-3296"; + client.getChannel(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelsTest() throws Exception { + Channel responsesElement = Channel.newBuilder().build(); + ListChannelsResponse expectedResponse = + ListChannelsResponse.newBuilder() + .setNextPageToken("") + .addAllChannels(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListChannelsPagedResponse pagedListResponse = client.listChannels(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listChannelsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listChannels(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelsTest2() throws Exception { + Channel responsesElement = Channel.newBuilder().build(); + ListChannelsResponse expectedResponse = + ListChannelsResponse.newBuilder() + .setNextPageToken("") + .addAllChannels(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListChannelsPagedResponse pagedListResponse = client.listChannels(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listChannelsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listChannels(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + + Channel actualResponse = client.createChannelAsync(parent, channel, channelId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createChannelExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + client.createChannelAsync(parent, channel, channelId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createChannelTest2() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + + Channel actualResponse = client.createChannelAsync(parent, channel, channelId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createChannelExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + client.createChannelAsync(parent, channel, channelId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void updateChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + Channel channel = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Channel actualResponse = client.updateChannelAsync(channel, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateChannelExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + Channel channel = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateChannelAsync(channel, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + + Channel actualResponse = client.deleteChannelAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteChannelExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + client.deleteChannelAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteChannelTest2() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-3296/locations/location-3296/channels/channel-3296"; + + Channel actualResponse = client.deleteChannelAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteChannelExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-3296/locations/location-3296/channels/channel-3296"; + client.deleteChannelAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void getProviderTest() throws Exception { + Provider expectedResponse = + Provider.newBuilder() + .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString()) + .setDisplayName("displayName1714148973") + .addAllEventTypes(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + ProviderName name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]"); + + Provider actualResponse = client.getProvider(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getProviderExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ProviderName name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]"); + client.getProvider(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getProviderTest2() throws Exception { + Provider expectedResponse = + Provider.newBuilder() + .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString()) + .setDisplayName("displayName1714148973") + .addAllEventTypes(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-9368/locations/location-9368/providers/provider-9368"; + + Provider actualResponse = client.getProvider(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getProviderExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-9368/locations/location-9368/providers/provider-9368"; + client.getProvider(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listProvidersTest() throws Exception { + Provider responsesElement = Provider.newBuilder().build(); + ListProvidersResponse expectedResponse = + ListProvidersResponse.newBuilder() + .setNextPageToken("") + .addAllProviders(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListProvidersPagedResponse pagedListResponse = client.listProviders(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getProvidersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listProvidersExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listProviders(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listProvidersTest2() throws Exception { + Provider responsesElement = Provider.newBuilder().build(); + ListProvidersResponse expectedResponse = + ListProvidersResponse.newBuilder() + .setNextPageToken("") + .addAllProviders(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListProvidersPagedResponse pagedListResponse = client.listProviders(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getProvidersList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listProvidersExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listProviders(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChannelConnectionTest() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + mockService.addResponse(expectedResponse); + + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + + ChannelConnection actualResponse = client.getChannelConnection(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getChannelConnectionExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + client.getChannelConnection(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChannelConnectionTest2() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-8642/locations/location-8642/channelConnections/channelConnection-8642"; + + ChannelConnection actualResponse = client.getChannelConnection(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getChannelConnectionExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-8642/locations/location-8642/channelConnections/channelConnection-8642"; + client.getChannelConnection(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelConnectionsTest() throws Exception { + ChannelConnection responsesElement = ChannelConnection.newBuilder().build(); + ListChannelConnectionsResponse expectedResponse = + ListChannelConnectionsResponse.newBuilder() + .setNextPageToken("") + .addAllChannelConnections(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListChannelConnectionsPagedResponse pagedListResponse = client.listChannelConnections(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelConnectionsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listChannelConnectionsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listChannelConnections(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelConnectionsTest2() throws Exception { + ChannelConnection responsesElement = ChannelConnection.newBuilder().build(); + ListChannelConnectionsResponse expectedResponse = + ListChannelConnectionsResponse.newBuilder() + .setNextPageToken("") + .addAllChannelConnections(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListChannelConnectionsPagedResponse pagedListResponse = client.listChannelConnections(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelConnectionsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listChannelConnectionsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + client.listChannelConnections(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createChannelConnectionTest() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + + ChannelConnection actualResponse = + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createChannelConnectionExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createChannelConnectionTest2() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + + ChannelConnection actualResponse = + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void createChannelConnectionExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-5833/locations/location-5833"; + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteChannelConnectionTest() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + + ChannelConnection actualResponse = client.deleteChannelConnectionAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteChannelConnectionExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + client.deleteChannelConnectionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteChannelConnectionTest2() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = + "projects/project-8642/locations/location-8642/channelConnections/channelConnection-8642"; + + ChannelConnection actualResponse = client.deleteChannelConnectionAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void deleteChannelConnectionExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-8642/locations/location-8642/channelConnections/channelConnection-8642"; + client.deleteChannelConnectionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void getGoogleChannelConfigTest() throws Exception { + GoogleChannelConfig expectedResponse = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockService.addResponse(expectedResponse); + + GoogleChannelConfigName name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]"); + + GoogleChannelConfig actualResponse = client.getGoogleChannelConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getGoogleChannelConfigExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GoogleChannelConfigName name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]"); + client.getGoogleChannelConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGoogleChannelConfigTest2() throws Exception { + GoogleChannelConfig expectedResponse = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-4921/locations/location-4921/googleChannelConfig"; + + GoogleChannelConfig actualResponse = client.getGoogleChannelConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getGoogleChannelConfigExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-4921/locations/location-4921/googleChannelConfig"; + client.getGoogleChannelConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGoogleChannelConfigTest() throws Exception { + GoogleChannelConfig expectedResponse = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockService.addResponse(expectedResponse); + + GoogleChannelConfig googleChannelConfig = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GoogleChannelConfig actualResponse = + client.updateGoogleChannelConfig(googleChannelConfig, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void updateGoogleChannelConfigExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GoogleChannelConfig googleChannelConfig = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGoogleChannelConfig(googleChannelConfig, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listLocationsTest() throws Exception { + Location responsesElement = Location.newBuilder().build(); + ListLocationsResponse expectedResponse = + ListLocationsResponse.newBuilder() + .setNextPageToken("") + .addAllLocations(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("projects/project-3664") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + + ListLocationsPagedResponse pagedListResponse = client.listLocations(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getLocationsList().get(0), resources.get(0)); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void listLocationsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("projects/project-3664") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + client.listLocations(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getLocationTest() throws Exception { + Location expectedResponse = + Location.newBuilder() + .setName("name3373707") + .setLocationId("locationId1541836720") + .setDisplayName("displayName1714148973") + .putAllLabels(new HashMap()) + .setMetadata(Any.newBuilder().build()) + .build(); + mockService.addResponse(expectedResponse); + + GetLocationRequest request = + GetLocationRequest.newBuilder() + .setName("projects/project-9062/locations/location-9062") + .build(); + + Location actualResponse = client.getLocation(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getLocationExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GetLocationRequest request = + GetLocationRequest.newBuilder() + .setName("projects/project-9062/locations/location-9062") + .build(); + client.getLocation(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void setIamPolicyTest() throws Exception { + Policy expectedResponse = + Policy.newBuilder() + .setVersion(351608024) + .addAllBindings(new ArrayList()) + .addAllAuditConfigs(new ArrayList()) + .setEtag(ByteString.EMPTY) + .build(); + mockService.addResponse(expectedResponse); + + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + + Policy actualResponse = client.setIamPolicy(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void setIamPolicyExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + client.setIamPolicy(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getIamPolicyTest() throws Exception { + Policy expectedResponse = + Policy.newBuilder() + .setVersion(351608024) + .addAllBindings(new ArrayList()) + .addAllAuditConfigs(new ArrayList()) + .setEtag(ByteString.EMPTY) + .build(); + mockService.addResponse(expectedResponse); + + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + + Policy actualResponse = client.getIamPolicy(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void getIamPolicyExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + client.getIamPolicy(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void testIamPermissionsTest() throws Exception { + TestIamPermissionsResponse expectedResponse = + TestIamPermissionsResponse.newBuilder().addAllPermissions(new ArrayList()).build(); + mockService.addResponse(expectedResponse); + + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .addAllPermissions(new ArrayList()) + .build(); + + TestIamPermissionsResponse actualResponse = client.testIamPermissions(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockService.getRequestPaths(); + Assert.assertEquals(1, actualRequests.size()); + + String apiClientHeaderKey = + mockService + .getRequestHeaders() + .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) + .iterator() + .next(); + Assert.assertTrue( + GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() + .matcher(apiClientHeaderKey) + .matches()); + } + + @Test + public void testIamPermissionsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .addAllPermissions(new ArrayList()) + .build(); + client.testIamPermissions(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java new file mode 100644 index 000000000000..4f5f31a4a178 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/EventarcClientTest.java @@ -0,0 +1,2016 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelConnectionsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListChannelsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListLocationsPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListProvidersPagedResponse; +import static com.google.cloud.eventarc.v1.EventarcClient.ListTriggersPagedResponse; + +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.GaxGrpcProperties; +import com.google.api.gax.grpc.testing.LocalChannelProvider; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.api.gax.grpc.testing.MockServiceHelper; +import com.google.api.gax.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.InvalidArgumentException; +import com.google.api.gax.rpc.StatusCode; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.collect.Lists; +import com.google.iam.v1.AuditConfig; +import com.google.iam.v1.Binding; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Any; +import com.google.protobuf.ByteString; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.UUID; +import java.util.concurrent.ExecutionException; +import javax.annotation.Generated; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.Before; +import org.junit.BeforeClass; +import org.junit.Test; + +@Generated("by gapic-generator-java") +public class EventarcClientTest { + private static MockEventarc mockEventarc; + private static MockIAMPolicy mockIAMPolicy; + private static MockLocations mockLocations; + private static MockServiceHelper mockServiceHelper; + private LocalChannelProvider channelProvider; + private EventarcClient client; + + @BeforeClass + public static void startStaticServer() { + mockEventarc = new MockEventarc(); + mockLocations = new MockLocations(); + mockIAMPolicy = new MockIAMPolicy(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), + Arrays.asList(mockEventarc, mockLocations, mockIAMPolicy)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + EventarcSettings settings = + EventarcSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = EventarcClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void getTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + mockEventarc.addResponse(expectedResponse); + + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + + Trigger actualResponse = client.getTrigger(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetTriggerRequest actualRequest = ((GetTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getTriggerExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + client.getTrigger(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getTriggerTest2() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + mockEventarc.addResponse(expectedResponse); + + String name = "name3373707"; + + Trigger actualResponse = client.getTrigger(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetTriggerRequest actualRequest = ((GetTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getTriggerExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.getTrigger(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listTriggersTest() throws Exception { + Trigger responsesElement = Trigger.newBuilder().build(); + ListTriggersResponse expectedResponse = + ListTriggersResponse.newBuilder() + .setNextPageToken("") + .addAllTriggers(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListTriggersPagedResponse pagedListResponse = client.listTriggers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTriggersList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListTriggersRequest actualRequest = ((ListTriggersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listTriggersExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listTriggers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listTriggersTest2() throws Exception { + Trigger responsesElement = Trigger.newBuilder().build(); + ListTriggersResponse expectedResponse = + ListTriggersResponse.newBuilder() + .setNextPageToken("") + .addAllTriggers(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListTriggersPagedResponse pagedListResponse = client.listTriggers(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTriggersList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListTriggersRequest actualRequest = ((ListTriggersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listTriggersExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + client.listTriggers(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + + Trigger actualResponse = client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateTriggerRequest actualRequest = ((CreateTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(trigger, actualRequest.getTrigger()); + Assert.assertEquals(triggerId, actualRequest.getTriggerId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createTriggerExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createTriggerTest2() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + String parent = "parent-995424086"; + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + + Trigger actualResponse = client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateTriggerRequest actualRequest = ((CreateTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(trigger, actualRequest.getTrigger()); + Assert.assertEquals(triggerId, actualRequest.getTriggerId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createTriggerExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + client.createTriggerAsync(parent, trigger, triggerId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void updateTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + Trigger trigger = Trigger.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + boolean allowMissing = true; + + Trigger actualResponse = client.updateTriggerAsync(trigger, updateMask, allowMissing).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateTriggerRequest actualRequest = ((UpdateTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(trigger, actualRequest.getTrigger()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertEquals(allowMissing, actualRequest.getAllowMissing()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateTriggerExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + Trigger trigger = Trigger.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + boolean allowMissing = true; + client.updateTriggerAsync(trigger, updateMask, allowMissing).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteTriggerTest() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + boolean allowMissing = true; + + Trigger actualResponse = client.deleteTriggerAsync(name, allowMissing).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteTriggerRequest actualRequest = ((DeleteTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertEquals(allowMissing, actualRequest.getAllowMissing()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteTriggerExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + boolean allowMissing = true; + client.deleteTriggerAsync(name, allowMissing).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteTriggerTest2() throws Exception { + Trigger expectedResponse = + Trigger.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEventFilters(new ArrayList()) + .setServiceAccount("serviceAccount1079137720") + .setDestination(Destination.newBuilder().build()) + .setTransport(Transport.newBuilder().build()) + .putAllLabels(new HashMap()) + .setChannel("channel738950403") + .putAllConditions(new HashMap()) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteTriggerTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + String name = "name3373707"; + boolean allowMissing = true; + + Trigger actualResponse = client.deleteTriggerAsync(name, allowMissing).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteTriggerRequest actualRequest = ((DeleteTriggerRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertEquals(allowMissing, actualRequest.getAllowMissing()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteTriggerExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + boolean allowMissing = true; + client.deleteTriggerAsync(name, allowMissing).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void getChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockEventarc.addResponse(expectedResponse); + + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + + Channel actualResponse = client.getChannel(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetChannelRequest actualRequest = ((GetChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getChannelExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + client.getChannel(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChannelTest2() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockEventarc.addResponse(expectedResponse); + + String name = "name3373707"; + + Channel actualResponse = client.getChannel(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetChannelRequest actualRequest = ((GetChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getChannelExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.getChannel(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelsTest() throws Exception { + Channel responsesElement = Channel.newBuilder().build(); + ListChannelsResponse expectedResponse = + ListChannelsResponse.newBuilder() + .setNextPageToken("") + .addAllChannels(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListChannelsPagedResponse pagedListResponse = client.listChannels(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelsList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListChannelsRequest actualRequest = ((ListChannelsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listChannelsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listChannels(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelsTest2() throws Exception { + Channel responsesElement = Channel.newBuilder().build(); + ListChannelsResponse expectedResponse = + ListChannelsResponse.newBuilder() + .setNextPageToken("") + .addAllChannels(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListChannelsPagedResponse pagedListResponse = client.listChannels(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelsList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListChannelsRequest actualRequest = ((ListChannelsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listChannelsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + client.listChannels(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + + Channel actualResponse = client.createChannelAsync(parent, channel, channelId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateChannelRequest actualRequest = ((CreateChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(channel, actualRequest.getChannel()); + Assert.assertEquals(channelId, actualRequest.getChannelId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createChannelExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + client.createChannelAsync(parent, channel, channelId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createChannelTest2() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + String parent = "parent-995424086"; + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + + Channel actualResponse = client.createChannelAsync(parent, channel, channelId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateChannelRequest actualRequest = ((CreateChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(channel, actualRequest.getChannel()); + Assert.assertEquals(channelId, actualRequest.getChannelId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createChannelExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + client.createChannelAsync(parent, channel, channelId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void updateChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + Channel channel = Channel.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Channel actualResponse = client.updateChannelAsync(channel, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateChannelRequest actualRequest = ((UpdateChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(channel, actualRequest.getChannel()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateChannelExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + Channel channel = Channel.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateChannelAsync(channel, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteChannelTest() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + + Channel actualResponse = client.deleteChannelAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteChannelRequest actualRequest = ((DeleteChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteChannelExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + client.deleteChannelAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteChannelTest2() throws Exception { + Channel expectedResponse = + Channel.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setUid("uid115792") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setProvider("provider-987494927") + .setActivationToken("activationToken1276937859") + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + String name = "name3373707"; + + Channel actualResponse = client.deleteChannelAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteChannelRequest actualRequest = ((DeleteChannelRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteChannelExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.deleteChannelAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void getProviderTest() throws Exception { + Provider expectedResponse = + Provider.newBuilder() + .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString()) + .setDisplayName("displayName1714148973") + .addAllEventTypes(new ArrayList()) + .build(); + mockEventarc.addResponse(expectedResponse); + + ProviderName name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]"); + + Provider actualResponse = client.getProvider(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetProviderRequest actualRequest = ((GetProviderRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getProviderExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + ProviderName name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]"); + client.getProvider(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getProviderTest2() throws Exception { + Provider expectedResponse = + Provider.newBuilder() + .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString()) + .setDisplayName("displayName1714148973") + .addAllEventTypes(new ArrayList()) + .build(); + mockEventarc.addResponse(expectedResponse); + + String name = "name3373707"; + + Provider actualResponse = client.getProvider(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetProviderRequest actualRequest = ((GetProviderRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getProviderExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.getProvider(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listProvidersTest() throws Exception { + Provider responsesElement = Provider.newBuilder().build(); + ListProvidersResponse expectedResponse = + ListProvidersResponse.newBuilder() + .setNextPageToken("") + .addAllProviders(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListProvidersPagedResponse pagedListResponse = client.listProviders(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getProvidersList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListProvidersRequest actualRequest = ((ListProvidersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listProvidersExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listProviders(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listProvidersTest2() throws Exception { + Provider responsesElement = Provider.newBuilder().build(); + ListProvidersResponse expectedResponse = + ListProvidersResponse.newBuilder() + .setNextPageToken("") + .addAllProviders(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListProvidersPagedResponse pagedListResponse = client.listProviders(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getProvidersList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListProvidersRequest actualRequest = ((ListProvidersRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listProvidersExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + client.listProviders(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChannelConnectionTest() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + mockEventarc.addResponse(expectedResponse); + + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + + ChannelConnection actualResponse = client.getChannelConnection(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetChannelConnectionRequest actualRequest = + ((GetChannelConnectionRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getChannelConnectionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + client.getChannelConnection(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getChannelConnectionTest2() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + mockEventarc.addResponse(expectedResponse); + + String name = "name3373707"; + + ChannelConnection actualResponse = client.getChannelConnection(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetChannelConnectionRequest actualRequest = + ((GetChannelConnectionRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getChannelConnectionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.getChannelConnection(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelConnectionsTest() throws Exception { + ChannelConnection responsesElement = ChannelConnection.newBuilder().build(); + ListChannelConnectionsResponse expectedResponse = + ListChannelConnectionsResponse.newBuilder() + .setNextPageToken("") + .addAllChannelConnections(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListChannelConnectionsPagedResponse pagedListResponse = client.listChannelConnections(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelConnectionsList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListChannelConnectionsRequest actualRequest = + ((ListChannelConnectionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listChannelConnectionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listChannelConnections(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listChannelConnectionsTest2() throws Exception { + ChannelConnection responsesElement = ChannelConnection.newBuilder().build(); + ListChannelConnectionsResponse expectedResponse = + ListChannelConnectionsResponse.newBuilder() + .setNextPageToken("") + .addAllChannelConnections(Arrays.asList(responsesElement)) + .build(); + mockEventarc.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListChannelConnectionsPagedResponse pagedListResponse = client.listChannelConnections(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getChannelConnectionsList().get(0), resources.get(0)); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListChannelConnectionsRequest actualRequest = + ((ListChannelConnectionsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listChannelConnectionsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + client.listChannelConnections(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createChannelConnectionTest() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + + ChannelConnection actualResponse = + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateChannelConnectionRequest actualRequest = + ((CreateChannelConnectionRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(channelConnection, actualRequest.getChannelConnection()); + Assert.assertEquals(channelConnectionId, actualRequest.getChannelConnectionId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createChannelConnectionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void createChannelConnectionTest2() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + String parent = "parent-995424086"; + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + + ChannelConnection actualResponse = + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateChannelConnectionRequest actualRequest = + ((CreateChannelConnectionRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(channelConnection, actualRequest.getChannelConnection()); + Assert.assertEquals(channelConnectionId, actualRequest.getChannelConnectionId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createChannelConnectionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String parent = "parent-995424086"; + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + client.createChannelConnectionAsync(parent, channelConnection, channelConnectionId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteChannelConnectionTest() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + + ChannelConnection actualResponse = client.deleteChannelConnectionAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteChannelConnectionRequest actualRequest = + ((DeleteChannelConnectionRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteChannelConnectionExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + client.deleteChannelConnectionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void deleteChannelConnectionTest2() throws Exception { + ChannelConnection expectedResponse = + ChannelConnection.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .setUid("uid115792") + .setChannel(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setActivationToken("activationToken1276937859") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteChannelConnectionTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockEventarc.addResponse(resultOperation); + + String name = "name3373707"; + + ChannelConnection actualResponse = client.deleteChannelConnectionAsync(name).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteChannelConnectionRequest actualRequest = + ((DeleteChannelConnectionRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteChannelConnectionExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.deleteChannelConnectionAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + + @Test + public void getGoogleChannelConfigTest() throws Exception { + GoogleChannelConfig expectedResponse = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockEventarc.addResponse(expectedResponse); + + GoogleChannelConfigName name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]"); + + GoogleChannelConfig actualResponse = client.getGoogleChannelConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGoogleChannelConfigRequest actualRequest = + ((GetGoogleChannelConfigRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGoogleChannelConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + GoogleChannelConfigName name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]"); + client.getGoogleChannelConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGoogleChannelConfigTest2() throws Exception { + GoogleChannelConfig expectedResponse = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockEventarc.addResponse(expectedResponse); + + String name = "name3373707"; + + GoogleChannelConfig actualResponse = client.getGoogleChannelConfig(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGoogleChannelConfigRequest actualRequest = + ((GetGoogleChannelConfigRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGoogleChannelConfigExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + String name = "name3373707"; + client.getGoogleChannelConfig(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGoogleChannelConfigTest() throws Exception { + GoogleChannelConfig expectedResponse = + GoogleChannelConfig.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .setUpdateTime(Timestamp.newBuilder().build()) + .setCryptoKeyName("cryptoKeyName1447084425") + .build(); + mockEventarc.addResponse(expectedResponse); + + GoogleChannelConfig googleChannelConfig = GoogleChannelConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GoogleChannelConfig actualResponse = + client.updateGoogleChannelConfig(googleChannelConfig, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockEventarc.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateGoogleChannelConfigRequest actualRequest = + ((UpdateGoogleChannelConfigRequest) actualRequests.get(0)); + + Assert.assertEquals(googleChannelConfig, actualRequest.getGoogleChannelConfig()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateGoogleChannelConfigExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockEventarc.addException(exception); + + try { + GoogleChannelConfig googleChannelConfig = GoogleChannelConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGoogleChannelConfig(googleChannelConfig, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listLocationsTest() throws Exception { + Location responsesElement = Location.newBuilder().build(); + ListLocationsResponse expectedResponse = + ListLocationsResponse.newBuilder() + .setNextPageToken("") + .addAllLocations(Arrays.asList(responsesElement)) + .build(); + mockLocations.addResponse(expectedResponse); + + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + + ListLocationsPagedResponse pagedListResponse = client.listLocations(request); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getLocationsList().get(0), resources.get(0)); + + List actualRequests = mockLocations.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListLocationsRequest actualRequest = ((ListLocationsRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getName(), actualRequest.getName()); + Assert.assertEquals(request.getFilter(), actualRequest.getFilter()); + Assert.assertEquals(request.getPageSize(), actualRequest.getPageSize()); + Assert.assertEquals(request.getPageToken(), actualRequest.getPageToken()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listLocationsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockLocations.addException(exception); + + try { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + client.listLocations(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getLocationTest() throws Exception { + Location expectedResponse = + Location.newBuilder() + .setName("name3373707") + .setLocationId("locationId1541836720") + .setDisplayName("displayName1714148973") + .putAllLabels(new HashMap()) + .setMetadata(Any.newBuilder().build()) + .build(); + mockLocations.addResponse(expectedResponse); + + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + + Location actualResponse = client.getLocation(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockLocations.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetLocationRequest actualRequest = ((GetLocationRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getName(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getLocationExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockLocations.addException(exception); + + try { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + client.getLocation(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void setIamPolicyTest() throws Exception { + Policy expectedResponse = + Policy.newBuilder() + .setVersion(351608024) + .addAllBindings(new ArrayList()) + .addAllAuditConfigs(new ArrayList()) + .setEtag(ByteString.EMPTY) + .build(); + mockIAMPolicy.addResponse(expectedResponse); + + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + + Policy actualResponse = client.setIamPolicy(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockIAMPolicy.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + SetIamPolicyRequest actualRequest = ((SetIamPolicyRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getResource(), actualRequest.getResource()); + Assert.assertEquals(request.getPolicy(), actualRequest.getPolicy()); + Assert.assertEquals(request.getUpdateMask(), actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void setIamPolicyExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockIAMPolicy.addException(exception); + + try { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + client.setIamPolicy(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getIamPolicyTest() throws Exception { + Policy expectedResponse = + Policy.newBuilder() + .setVersion(351608024) + .addAllBindings(new ArrayList()) + .addAllAuditConfigs(new ArrayList()) + .setEtag(ByteString.EMPTY) + .build(); + mockIAMPolicy.addResponse(expectedResponse); + + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + + Policy actualResponse = client.getIamPolicy(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockIAMPolicy.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetIamPolicyRequest actualRequest = ((GetIamPolicyRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getResource(), actualRequest.getResource()); + Assert.assertEquals(request.getOptions(), actualRequest.getOptions()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getIamPolicyExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockIAMPolicy.addException(exception); + + try { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + client.getIamPolicy(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void testIamPermissionsTest() throws Exception { + TestIamPermissionsResponse expectedResponse = + TestIamPermissionsResponse.newBuilder().addAllPermissions(new ArrayList()).build(); + mockIAMPolicy.addResponse(expectedResponse); + + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .addAllPermissions(new ArrayList()) + .build(); + + TestIamPermissionsResponse actualResponse = client.testIamPermissions(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockIAMPolicy.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + TestIamPermissionsRequest actualRequest = ((TestIamPermissionsRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getResource(), actualRequest.getResource()); + Assert.assertEquals(request.getPermissionsList(), actualRequest.getPermissionsList()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void testIamPermissionsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockIAMPolicy.addException(exception); + + try { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .addAllPermissions(new ArrayList()) + .build(); + client.testIamPermissions(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java new file mode 100644 index 000000000000..f7fecd4b4c0d --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarc.java @@ -0,0 +1,59 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.AbstractMessage; +import io.grpc.ServerServiceDefinition; +import java.util.List; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockEventarc implements MockGrpcService { + private final MockEventarcImpl serviceImpl; + + public MockEventarc() { + serviceImpl = new MockEventarcImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(AbstractMessage response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java new file mode 100644 index 000000000000..27cb6c689ab3 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockEventarcImpl.java @@ -0,0 +1,438 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.BetaApi; +import com.google.cloud.eventarc.v1.EventarcGrpc.EventarcImplBase; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockEventarcImpl extends EventarcImplBase { + private List requests; + private Queue responses; + + public MockEventarcImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(AbstractMessage response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void getTrigger(GetTriggerRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Trigger) { + requests.add(request); + responseObserver.onNext(((Trigger) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetTrigger, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Trigger.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listTriggers( + ListTriggersRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListTriggersResponse) { + requests.add(request); + responseObserver.onNext(((ListTriggersResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListTriggers, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListTriggersResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createTrigger( + CreateTriggerRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateTrigger, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateTrigger( + UpdateTriggerRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateTrigger, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteTrigger( + DeleteTriggerRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteTrigger, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getChannel(GetChannelRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Channel) { + requests.add(request); + responseObserver.onNext(((Channel) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetChannel, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Channel.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listChannels( + ListChannelsRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListChannelsResponse) { + requests.add(request); + responseObserver.onNext(((ListChannelsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListChannels, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListChannelsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createChannel( + CreateChannelRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateChannel, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateChannel( + UpdateChannelRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateChannel, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteChannel( + DeleteChannelRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteChannel, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getProvider(GetProviderRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Provider) { + requests.add(request); + responseObserver.onNext(((Provider) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetProvider, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Provider.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listProviders( + ListProvidersRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListProvidersResponse) { + requests.add(request); + responseObserver.onNext(((ListProvidersResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListProviders, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListProvidersResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getChannelConnection( + GetChannelConnectionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ChannelConnection) { + requests.add(request); + responseObserver.onNext(((ChannelConnection) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetChannelConnection, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ChannelConnection.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listChannelConnections( + ListChannelConnectionsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListChannelConnectionsResponse) { + requests.add(request); + responseObserver.onNext(((ListChannelConnectionsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListChannelConnections, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListChannelConnectionsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createChannelConnection( + CreateChannelConnectionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method CreateChannelConnection, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteChannelConnection( + DeleteChannelConnectionRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method DeleteChannelConnection, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getGoogleChannelConfig( + GetGoogleChannelConfigRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GoogleChannelConfig) { + requests.add(request); + responseObserver.onNext(((GoogleChannelConfig) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetGoogleChannelConfig, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + GoogleChannelConfig.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateGoogleChannelConfig( + UpdateGoogleChannelConfigRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GoogleChannelConfig) { + requests.add(request); + responseObserver.onNext(((GoogleChannelConfig) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateGoogleChannelConfig, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + GoogleChannelConfig.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java new file mode 100644 index 000000000000..6cf2e63c55f8 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicy.java @@ -0,0 +1,59 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.AbstractMessage; +import io.grpc.ServerServiceDefinition; +import java.util.List; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockIAMPolicy implements MockGrpcService { + private final MockIAMPolicyImpl serviceImpl; + + public MockIAMPolicy() { + serviceImpl = new MockIAMPolicyImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(AbstractMessage response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java new file mode 100644 index 000000000000..86b589fc912c --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockIAMPolicyImpl.java @@ -0,0 +1,127 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.BetaApi; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.IAMPolicyGrpc.IAMPolicyImplBase; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import com.google.protobuf.AbstractMessage; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockIAMPolicyImpl extends IAMPolicyImplBase { + private List requests; + private Queue responses; + + public MockIAMPolicyImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(AbstractMessage response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void testIamPermissions( + TestIamPermissionsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof TestIamPermissionsResponse) { + requests.add(request); + responseObserver.onNext(((TestIamPermissionsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method TestIamPermissions, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + TestIamPermissionsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void setIamPolicy(SetIamPolicyRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Policy) { + requests.add(request); + responseObserver.onNext(((Policy) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method SetIamPolicy, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Policy.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getIamPolicy(GetIamPolicyRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Policy) { + requests.add(request); + responseObserver.onNext(((Policy) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetIamPolicy, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Policy.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java new file mode 100644 index 000000000000..86c6a24785d1 --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocations.java @@ -0,0 +1,59 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.BetaApi; +import com.google.api.gax.grpc.testing.MockGrpcService; +import com.google.protobuf.AbstractMessage; +import io.grpc.ServerServiceDefinition; +import java.util.List; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockLocations implements MockGrpcService { + private final MockLocationsImpl serviceImpl; + + public MockLocations() { + serviceImpl = new MockLocationsImpl(); + } + + @Override + public List getRequests() { + return serviceImpl.getRequests(); + } + + @Override + public void addResponse(AbstractMessage response) { + serviceImpl.addResponse(response); + } + + @Override + public void addException(Exception exception) { + serviceImpl.addException(exception); + } + + @Override + public ServerServiceDefinition getServiceDefinition() { + return serviceImpl.bindService(); + } + + @Override + public void reset() { + serviceImpl.reset(); + } +} diff --git a/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java new file mode 100644 index 000000000000..6475bd3bbb5a --- /dev/null +++ b/java-eventarc/v1/google-cloud-eventarc/src/test/java/com/google/cloud/eventarc/v1/MockLocationsImpl.java @@ -0,0 +1,105 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.core.BetaApi; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.cloud.location.LocationsGrpc.LocationsImplBase; +import com.google.protobuf.AbstractMessage; +import io.grpc.stub.StreamObserver; +import java.util.ArrayList; +import java.util.LinkedList; +import java.util.List; +import java.util.Queue; +import javax.annotation.Generated; + +@BetaApi +@Generated("by gapic-generator-java") +public class MockLocationsImpl extends LocationsImplBase { + private List requests; + private Queue responses; + + public MockLocationsImpl() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + public List getRequests() { + return requests; + } + + public void addResponse(AbstractMessage response) { + responses.add(response); + } + + public void setResponses(List responses) { + this.responses = new LinkedList(responses); + } + + public void addException(Exception exception) { + responses.add(exception); + } + + public void reset() { + requests = new ArrayList<>(); + responses = new LinkedList<>(); + } + + @Override + public void listLocations( + ListLocationsRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListLocationsResponse) { + requests.add(request); + responseObserver.onNext(((ListLocationsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method ListLocations, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListLocationsResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getLocation(GetLocationRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Location) { + requests.add(request); + responseObserver.onNext(((Location) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method GetLocation, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Location.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java b/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java new file mode 100644 index 000000000000..beee251d1021 --- /dev/null +++ b/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java @@ -0,0 +1,2308 @@ +package com.google.cloud.eventarc.v1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; + +/** + * + * + *
+ * Eventarc allows users to subscribe to various events that are provided by
+ * Google Cloud services and forward them to supported destinations.
+ * 
+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/cloud/eventarc/v1/eventarc.proto") +@io.grpc.stub.annotations.GrpcGenerated +public final class EventarcGrpc { + + private EventarcGrpc() {} + + public static final String SERVICE_NAME = "google.cloud.eventarc.v1.Eventarc"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetTriggerRequest, com.google.cloud.eventarc.v1.Trigger> + getGetTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetTrigger", + requestType = com.google.cloud.eventarc.v1.GetTriggerRequest.class, + responseType = com.google.cloud.eventarc.v1.Trigger.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetTriggerRequest, com.google.cloud.eventarc.v1.Trigger> + getGetTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetTriggerRequest, com.google.cloud.eventarc.v1.Trigger> + getGetTriggerMethod; + if ((getGetTriggerMethod = EventarcGrpc.getGetTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetTriggerMethod = EventarcGrpc.getGetTriggerMethod) == null) { + EventarcGrpc.getGetTriggerMethod = + getGetTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetTriggerRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.Trigger.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetTrigger")) + .build(); + } + } + } + return getGetTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse> + getListTriggersMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListTriggers", + requestType = com.google.cloud.eventarc.v1.ListTriggersRequest.class, + responseType = com.google.cloud.eventarc.v1.ListTriggersResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse> + getListTriggersMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse> + getListTriggersMethod; + if ((getListTriggersMethod = EventarcGrpc.getListTriggersMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListTriggersMethod = EventarcGrpc.getListTriggersMethod) == null) { + EventarcGrpc.getListTriggersMethod = + getListTriggersMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListTriggers")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListTriggersRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListTriggersResponse + .getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListTriggers")) + .build(); + } + } + } + return getListTriggersMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateTriggerRequest, com.google.longrunning.Operation> + getCreateTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateTrigger", + requestType = com.google.cloud.eventarc.v1.CreateTriggerRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateTriggerRequest, com.google.longrunning.Operation> + getCreateTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateTriggerRequest, com.google.longrunning.Operation> + getCreateTriggerMethod; + if ((getCreateTriggerMethod = EventarcGrpc.getCreateTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getCreateTriggerMethod = EventarcGrpc.getCreateTriggerMethod) == null) { + EventarcGrpc.getCreateTriggerMethod = + getCreateTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.CreateTriggerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateTrigger")) + .build(); + } + } + } + return getCreateTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, com.google.longrunning.Operation> + getUpdateTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateTrigger", + requestType = com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, com.google.longrunning.Operation> + getUpdateTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, com.google.longrunning.Operation> + getUpdateTriggerMethod; + if ((getUpdateTriggerMethod = EventarcGrpc.getUpdateTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getUpdateTriggerMethod = EventarcGrpc.getUpdateTriggerMethod) == null) { + EventarcGrpc.getUpdateTriggerMethod = + getUpdateTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.UpdateTriggerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateTrigger")) + .build(); + } + } + } + return getUpdateTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, com.google.longrunning.Operation> + getDeleteTriggerMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteTrigger", + requestType = com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, com.google.longrunning.Operation> + getDeleteTriggerMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, com.google.longrunning.Operation> + getDeleteTriggerMethod; + if ((getDeleteTriggerMethod = EventarcGrpc.getDeleteTriggerMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getDeleteTriggerMethod = EventarcGrpc.getDeleteTriggerMethod) == null) { + EventarcGrpc.getDeleteTriggerMethod = + getDeleteTriggerMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteTrigger")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.DeleteTriggerRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteTrigger")) + .build(); + } + } + } + return getDeleteTriggerMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelRequest, com.google.cloud.eventarc.v1.Channel> + getGetChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetChannel", + requestType = com.google.cloud.eventarc.v1.GetChannelRequest.class, + responseType = com.google.cloud.eventarc.v1.Channel.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelRequest, com.google.cloud.eventarc.v1.Channel> + getGetChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelRequest, com.google.cloud.eventarc.v1.Channel> + getGetChannelMethod; + if ((getGetChannelMethod = EventarcGrpc.getGetChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetChannelMethod = EventarcGrpc.getGetChannelMethod) == null) { + EventarcGrpc.getGetChannelMethod = + getGetChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetChannelRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.Channel.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetChannel")) + .build(); + } + } + } + return getGetChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse> + getListChannelsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListChannels", + requestType = com.google.cloud.eventarc.v1.ListChannelsRequest.class, + responseType = com.google.cloud.eventarc.v1.ListChannelsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse> + getListChannelsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse> + getListChannelsMethod; + if ((getListChannelsMethod = EventarcGrpc.getListChannelsMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListChannelsMethod = EventarcGrpc.getListChannelsMethod) == null) { + EventarcGrpc.getListChannelsMethod = + getListChannelsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListChannels")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelsResponse + .getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListChannels")) + .build(); + } + } + } + return getListChannelsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelRequest, com.google.longrunning.Operation> + getCreateChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateChannel", + requestType = com.google.cloud.eventarc.v1.CreateChannelRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelRequest, com.google.longrunning.Operation> + getCreateChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelRequest, com.google.longrunning.Operation> + getCreateChannelMethod; + if ((getCreateChannelMethod = EventarcGrpc.getCreateChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getCreateChannelMethod = EventarcGrpc.getCreateChannelMethod) == null) { + EventarcGrpc.getCreateChannelMethod = + getCreateChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.CreateChannelRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateChannel")) + .build(); + } + } + } + return getCreateChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateChannelRequest, com.google.longrunning.Operation> + getUpdateChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateChannel", + requestType = com.google.cloud.eventarc.v1.UpdateChannelRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateChannelRequest, com.google.longrunning.Operation> + getUpdateChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateChannelRequest, com.google.longrunning.Operation> + getUpdateChannelMethod; + if ((getUpdateChannelMethod = EventarcGrpc.getUpdateChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getUpdateChannelMethod = EventarcGrpc.getUpdateChannelMethod) == null) { + EventarcGrpc.getUpdateChannelMethod = + getUpdateChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.UpdateChannelRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateChannel")) + .build(); + } + } + } + return getUpdateChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelRequest, com.google.longrunning.Operation> + getDeleteChannelMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteChannel", + requestType = com.google.cloud.eventarc.v1.DeleteChannelRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelRequest, com.google.longrunning.Operation> + getDeleteChannelMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelRequest, com.google.longrunning.Operation> + getDeleteChannelMethod; + if ((getDeleteChannelMethod = EventarcGrpc.getDeleteChannelMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getDeleteChannelMethod = EventarcGrpc.getDeleteChannelMethod) == null) { + EventarcGrpc.getDeleteChannelMethod = + getDeleteChannelMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteChannel")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.DeleteChannelRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteChannel")) + .build(); + } + } + } + return getDeleteChannelMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetProviderRequest, com.google.cloud.eventarc.v1.Provider> + getGetProviderMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetProvider", + requestType = com.google.cloud.eventarc.v1.GetProviderRequest.class, + responseType = com.google.cloud.eventarc.v1.Provider.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetProviderRequest, com.google.cloud.eventarc.v1.Provider> + getGetProviderMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetProviderRequest, com.google.cloud.eventarc.v1.Provider> + getGetProviderMethod; + if ((getGetProviderMethod = EventarcGrpc.getGetProviderMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetProviderMethod = EventarcGrpc.getGetProviderMethod) == null) { + EventarcGrpc.getGetProviderMethod = + getGetProviderMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetProvider")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.Provider.getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetProvider")) + .build(); + } + } + } + return getGetProviderMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse> + getListProvidersMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListProviders", + requestType = com.google.cloud.eventarc.v1.ListProvidersRequest.class, + responseType = com.google.cloud.eventarc.v1.ListProvidersResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse> + getListProvidersMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse> + getListProvidersMethod; + if ((getListProvidersMethod = EventarcGrpc.getListProvidersMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListProvidersMethod = EventarcGrpc.getListProvidersMethod) == null) { + EventarcGrpc.getListProvidersMethod = + getListProvidersMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListProviders")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListProvidersRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListProvidersResponse + .getDefaultInstance())) + .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListProviders")) + .build(); + } + } + } + return getListProvidersMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection> + getGetChannelConnectionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetChannelConnection", + requestType = com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, + responseType = com.google.cloud.eventarc.v1.ChannelConnection.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection> + getGetChannelConnectionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection> + getGetChannelConnectionMethod; + if ((getGetChannelConnectionMethod = EventarcGrpc.getGetChannelConnectionMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetChannelConnectionMethod = EventarcGrpc.getGetChannelConnectionMethod) == null) { + EventarcGrpc.getGetChannelConnectionMethod = + getGetChannelConnectionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetChannelConnection")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("GetChannelConnection")) + .build(); + } + } + } + return getGetChannelConnectionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + getListChannelConnectionsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListChannelConnections", + requestType = com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, + responseType = com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + getListChannelConnectionsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + getListChannelConnectionsMethod; + if ((getListChannelConnectionsMethod = EventarcGrpc.getListChannelConnectionsMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getListChannelConnectionsMethod = EventarcGrpc.getListChannelConnectionsMethod) + == null) { + EventarcGrpc.getListChannelConnectionsMethod = + getListChannelConnectionsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListChannelConnections")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("ListChannelConnections")) + .build(); + } + } + } + return getListChannelConnectionsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation> + getCreateChannelConnectionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateChannelConnection", + requestType = com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation> + getCreateChannelConnectionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation> + getCreateChannelConnectionMethod; + if ((getCreateChannelConnectionMethod = EventarcGrpc.getCreateChannelConnectionMethod) + == null) { + synchronized (EventarcGrpc.class) { + if ((getCreateChannelConnectionMethod = EventarcGrpc.getCreateChannelConnectionMethod) + == null) { + EventarcGrpc.getCreateChannelConnectionMethod = + getCreateChannelConnectionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateChannelConnection")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("CreateChannelConnection")) + .build(); + } + } + } + return getCreateChannelConnectionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation> + getDeleteChannelConnectionMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteChannelConnection", + requestType = com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation> + getDeleteChannelConnectionMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation> + getDeleteChannelConnectionMethod; + if ((getDeleteChannelConnectionMethod = EventarcGrpc.getDeleteChannelConnectionMethod) + == null) { + synchronized (EventarcGrpc.class) { + if ((getDeleteChannelConnectionMethod = EventarcGrpc.getDeleteChannelConnectionMethod) + == null) { + EventarcGrpc.getDeleteChannelConnectionMethod = + getDeleteChannelConnectionMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteChannelConnection")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("DeleteChannelConnection")) + .build(); + } + } + } + return getDeleteChannelConnectionMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGetGoogleChannelConfigMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetGoogleChannelConfig", + requestType = com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, + responseType = com.google.cloud.eventarc.v1.GoogleChannelConfig.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGetGoogleChannelConfigMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGetGoogleChannelConfigMethod; + if ((getGetGoogleChannelConfigMethod = EventarcGrpc.getGetGoogleChannelConfigMethod) == null) { + synchronized (EventarcGrpc.class) { + if ((getGetGoogleChannelConfigMethod = EventarcGrpc.getGetGoogleChannelConfigMethod) + == null) { + EventarcGrpc.getGetGoogleChannelConfigMethod = + getGetGoogleChannelConfigMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetGoogleChannelConfig")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GoogleChannelConfig + .getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("GetGoogleChannelConfig")) + .build(); + } + } + } + return getGetGoogleChannelConfigMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getUpdateGoogleChannelConfigMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateGoogleChannelConfig", + requestType = com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, + responseType = com.google.cloud.eventarc.v1.GoogleChannelConfig.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getUpdateGoogleChannelConfigMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getUpdateGoogleChannelConfigMethod; + if ((getUpdateGoogleChannelConfigMethod = EventarcGrpc.getUpdateGoogleChannelConfigMethod) + == null) { + synchronized (EventarcGrpc.class) { + if ((getUpdateGoogleChannelConfigMethod = EventarcGrpc.getUpdateGoogleChannelConfigMethod) + == null) { + EventarcGrpc.getUpdateGoogleChannelConfigMethod = + getUpdateGoogleChannelConfigMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateGoogleChannelConfig")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.eventarc.v1.GoogleChannelConfig + .getDefaultInstance())) + .setSchemaDescriptor( + new EventarcMethodDescriptorSupplier("UpdateGoogleChannelConfig")) + .build(); + } + } + } + return getUpdateGoogleChannelConfigMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static EventarcStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public EventarcStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcStub(channel, callOptions); + } + }; + return EventarcStub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static EventarcBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public EventarcBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcBlockingStub(channel, callOptions); + } + }; + return EventarcBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static EventarcFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public EventarcFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcFutureStub(channel, callOptions); + } + }; + return EventarcFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public abstract static class EventarcImplBase implements io.grpc.BindableService { + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public void getTrigger( + com.google.cloud.eventarc.v1.GetTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public void listTriggers( + com.google.cloud.eventarc.v1.ListTriggersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListTriggersMethod(), responseObserver); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public void createTrigger( + com.google.cloud.eventarc.v1.CreateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public void updateTrigger( + com.google.cloud.eventarc.v1.UpdateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public void deleteTrigger( + com.google.cloud.eventarc.v1.DeleteTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteTriggerMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public void getChannel( + com.google.cloud.eventarc.v1.GetChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public void listChannels( + com.google.cloud.eventarc.v1.ListChannelsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListChannelsMethod(), responseObserver); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public void createChannel( + com.google.cloud.eventarc.v1.CreateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public void updateChannel( + com.google.cloud.eventarc.v1.UpdateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public void deleteChannel( + com.google.cloud.eventarc.v1.DeleteChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteChannelMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public void getProvider( + com.google.cloud.eventarc.v1.GetProviderRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetProviderMethod(), responseObserver); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public void listProviders( + com.google.cloud.eventarc.v1.ListProvidersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListProvidersMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public void getChannelConnection( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetChannelConnectionMethod(), responseObserver); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public void listChannelConnections( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListChannelConnectionsMethod(), responseObserver); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public void createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateChannelConnectionMethod(), responseObserver); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public void deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteChannelConnectionMethod(), responseObserver); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public void getGoogleChannelConfig( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetGoogleChannelConfigMethod(), responseObserver); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public void updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateGoogleChannelConfigMethod(), responseObserver); + } + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getGetTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetTriggerRequest, + com.google.cloud.eventarc.v1.Trigger>(this, METHODID_GET_TRIGGER))) + .addMethod( + getListTriggersMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListTriggersRequest, + com.google.cloud.eventarc.v1.ListTriggersResponse>( + this, METHODID_LIST_TRIGGERS))) + .addMethod( + getCreateTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.CreateTriggerRequest, + com.google.longrunning.Operation>(this, METHODID_CREATE_TRIGGER))) + .addMethod( + getUpdateTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.UpdateTriggerRequest, + com.google.longrunning.Operation>(this, METHODID_UPDATE_TRIGGER))) + .addMethod( + getDeleteTriggerMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.DeleteTriggerRequest, + com.google.longrunning.Operation>(this, METHODID_DELETE_TRIGGER))) + .addMethod( + getGetChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetChannelRequest, + com.google.cloud.eventarc.v1.Channel>(this, METHODID_GET_CHANNEL))) + .addMethod( + getListChannelsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListChannelsRequest, + com.google.cloud.eventarc.v1.ListChannelsResponse>( + this, METHODID_LIST_CHANNELS))) + .addMethod( + getCreateChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.CreateChannelRequest, + com.google.longrunning.Operation>(this, METHODID_CREATE_CHANNEL))) + .addMethod( + getUpdateChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.UpdateChannelRequest, + com.google.longrunning.Operation>(this, METHODID_UPDATE_CHANNEL))) + .addMethod( + getDeleteChannelMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.DeleteChannelRequest, + com.google.longrunning.Operation>(this, METHODID_DELETE_CHANNEL))) + .addMethod( + getGetProviderMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetProviderRequest, + com.google.cloud.eventarc.v1.Provider>(this, METHODID_GET_PROVIDER))) + .addMethod( + getListProvidersMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListProvidersRequest, + com.google.cloud.eventarc.v1.ListProvidersResponse>( + this, METHODID_LIST_PROVIDERS))) + .addMethod( + getGetChannelConnectionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetChannelConnectionRequest, + com.google.cloud.eventarc.v1.ChannelConnection>( + this, METHODID_GET_CHANNEL_CONNECTION))) + .addMethod( + getListChannelConnectionsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse>( + this, METHODID_LIST_CHANNEL_CONNECTIONS))) + .addMethod( + getCreateChannelConnectionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, + com.google.longrunning.Operation>(this, METHODID_CREATE_CHANNEL_CONNECTION))) + .addMethod( + getDeleteChannelConnectionMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, + com.google.longrunning.Operation>(this, METHODID_DELETE_CHANNEL_CONNECTION))) + .addMethod( + getGetGoogleChannelConfigMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig>( + this, METHODID_GET_GOOGLE_CHANNEL_CONFIG))) + .addMethod( + getUpdateGoogleChannelConfigMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, + com.google.cloud.eventarc.v1.GoogleChannelConfig>( + this, METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG))) + .build(); + } + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public static final class EventarcStub extends io.grpc.stub.AbstractAsyncStub { + private EventarcStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected EventarcStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcStub(channel, callOptions); + } + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public void getTrigger( + com.google.cloud.eventarc.v1.GetTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetTriggerMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public void listTriggers( + com.google.cloud.eventarc.v1.ListTriggersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListTriggersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public void createTrigger( + com.google.cloud.eventarc.v1.CreateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateTriggerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public void updateTrigger( + com.google.cloud.eventarc.v1.UpdateTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateTriggerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public void deleteTrigger( + com.google.cloud.eventarc.v1.DeleteTriggerRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteTriggerMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public void getChannel( + com.google.cloud.eventarc.v1.GetChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetChannelMethod(), getCallOptions()), request, responseObserver); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public void listChannels( + com.google.cloud.eventarc.v1.ListChannelsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListChannelsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public void createChannel( + com.google.cloud.eventarc.v1.CreateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateChannelMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public void updateChannel( + com.google.cloud.eventarc.v1.UpdateChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateChannelMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public void deleteChannel( + com.google.cloud.eventarc.v1.DeleteChannelRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteChannelMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public void getProvider( + com.google.cloud.eventarc.v1.GetProviderRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetProviderMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public void listProviders( + com.google.cloud.eventarc.v1.ListProvidersRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListProvidersMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public void getChannelConnection( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetChannelConnectionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public void listChannelConnections( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListChannelConnectionsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public void createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateChannelConnectionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public void deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteChannelConnectionMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public void getGoogleChannelConfig( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetGoogleChannelConfigMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public void updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateGoogleChannelConfigMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public static final class EventarcBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private EventarcBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected EventarcBlockingStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public com.google.cloud.eventarc.v1.Trigger getTrigger( + com.google.cloud.eventarc.v1.GetTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListTriggersResponse listTriggers( + com.google.cloud.eventarc.v1.ListTriggersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListTriggersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public com.google.longrunning.Operation createTrigger( + com.google.cloud.eventarc.v1.CreateTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public com.google.longrunning.Operation updateTrigger( + com.google.cloud.eventarc.v1.UpdateTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public com.google.longrunning.Operation deleteTrigger( + com.google.cloud.eventarc.v1.DeleteTriggerRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteTriggerMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public com.google.cloud.eventarc.v1.Channel getChannel( + com.google.cloud.eventarc.v1.GetChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListChannelsResponse listChannels( + com.google.cloud.eventarc.v1.ListChannelsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListChannelsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public com.google.longrunning.Operation createChannel( + com.google.cloud.eventarc.v1.CreateChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public com.google.longrunning.Operation updateChannel( + com.google.cloud.eventarc.v1.UpdateChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public com.google.longrunning.Operation deleteChannel( + com.google.cloud.eventarc.v1.DeleteChannelRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteChannelMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public com.google.cloud.eventarc.v1.Provider getProvider( + com.google.cloud.eventarc.v1.GetProviderRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetProviderMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListProvidersResponse listProviders( + com.google.cloud.eventarc.v1.ListProvidersRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListProvidersMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetChannelConnectionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse listChannelConnections( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListChannelConnectionsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public com.google.longrunning.Operation createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateChannelConnectionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public com.google.longrunning.Operation deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteChannelConnectionMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGoogleChannelConfigMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public com.google.cloud.eventarc.v1.GoogleChannelConfig updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGoogleChannelConfigMethod(), getCallOptions(), request); + } + } + + /** + * + * + *
+   * Eventarc allows users to subscribe to various events that are provided by
+   * Google Cloud services and forward them to supported destinations.
+   * 
+ */ + public static final class EventarcFutureStub + extends io.grpc.stub.AbstractFutureStub { + private EventarcFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected EventarcFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new EventarcFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Get a single trigger.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + getTrigger(com.google.cloud.eventarc.v1.GetTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List triggers.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListTriggersResponse> + listTriggers(com.google.cloud.eventarc.v1.ListTriggersRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListTriggersMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Create a new trigger in a particular project and location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createTrigger(com.google.cloud.eventarc.v1.CreateTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Update a single trigger.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + updateTrigger(com.google.cloud.eventarc.v1.UpdateTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Delete a single trigger.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteTrigger(com.google.cloud.eventarc.v1.DeleteTriggerRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteTriggerMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a single Channel.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + getChannel(com.google.cloud.eventarc.v1.GetChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List channels.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListChannelsResponse> + listChannels(com.google.cloud.eventarc.v1.ListChannelsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListChannelsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Create a new channel in a particular project and location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createChannel(com.google.cloud.eventarc.v1.CreateChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Update a single channel.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + updateChannel(com.google.cloud.eventarc.v1.UpdateChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Delete a single channel.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteChannel(com.google.cloud.eventarc.v1.DeleteChannelRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteChannelMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a single Provider.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + getProvider(com.google.cloud.eventarc.v1.GetProviderRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetProviderMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List providers.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListProvidersResponse> + listProviders(com.google.cloud.eventarc.v1.ListProvidersRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListProvidersMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a single ChannelConnection.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ChannelConnection> + getChannelConnection(com.google.cloud.eventarc.v1.GetChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetChannelConnectionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * List channel connections.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse> + listChannelConnections(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListChannelConnectionsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Create a new ChannelConnection in a particular project and location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + createChannelConnection( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateChannelConnectionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Delete a single ChannelConnection.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteChannelConnection( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteChannelConnectionMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Get a GoogleChannelConfig
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.GoogleChannelConfig> + getGoogleChannelConfig(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetGoogleChannelConfigMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Update a single GoogleChannelConfig
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.eventarc.v1.GoogleChannelConfig> + updateGoogleChannelConfig( + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateGoogleChannelConfigMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_GET_TRIGGER = 0; + private static final int METHODID_LIST_TRIGGERS = 1; + private static final int METHODID_CREATE_TRIGGER = 2; + private static final int METHODID_UPDATE_TRIGGER = 3; + private static final int METHODID_DELETE_TRIGGER = 4; + private static final int METHODID_GET_CHANNEL = 5; + private static final int METHODID_LIST_CHANNELS = 6; + private static final int METHODID_CREATE_CHANNEL = 7; + private static final int METHODID_UPDATE_CHANNEL = 8; + private static final int METHODID_DELETE_CHANNEL = 9; + private static final int METHODID_GET_PROVIDER = 10; + private static final int METHODID_LIST_PROVIDERS = 11; + private static final int METHODID_GET_CHANNEL_CONNECTION = 12; + private static final int METHODID_LIST_CHANNEL_CONNECTIONS = 13; + private static final int METHODID_CREATE_CHANNEL_CONNECTION = 14; + private static final int METHODID_DELETE_CHANNEL_CONNECTION = 15; + private static final int METHODID_GET_GOOGLE_CHANNEL_CONFIG = 16; + private static final int METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG = 17; + + private static final class MethodHandlers + implements io.grpc.stub.ServerCalls.UnaryMethod, + io.grpc.stub.ServerCalls.ServerStreamingMethod, + io.grpc.stub.ServerCalls.ClientStreamingMethod, + io.grpc.stub.ServerCalls.BidiStreamingMethod { + private final EventarcImplBase serviceImpl; + private final int methodId; + + MethodHandlers(EventarcImplBase serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_GET_TRIGGER: + serviceImpl.getTrigger( + (com.google.cloud.eventarc.v1.GetTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_TRIGGERS: + serviceImpl.listTriggers( + (com.google.cloud.eventarc.v1.ListTriggersRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_TRIGGER: + serviceImpl.createTrigger( + (com.google.cloud.eventarc.v1.CreateTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_UPDATE_TRIGGER: + serviceImpl.updateTrigger( + (com.google.cloud.eventarc.v1.UpdateTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_TRIGGER: + serviceImpl.deleteTrigger( + (com.google.cloud.eventarc.v1.DeleteTriggerRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_CHANNEL: + serviceImpl.getChannel( + (com.google.cloud.eventarc.v1.GetChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_LIST_CHANNELS: + serviceImpl.listChannels( + (com.google.cloud.eventarc.v1.ListChannelsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_CHANNEL: + serviceImpl.createChannel( + (com.google.cloud.eventarc.v1.CreateChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_UPDATE_CHANNEL: + serviceImpl.updateChannel( + (com.google.cloud.eventarc.v1.UpdateChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_CHANNEL: + serviceImpl.deleteChannel( + (com.google.cloud.eventarc.v1.DeleteChannelRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_PROVIDER: + serviceImpl.getProvider( + (com.google.cloud.eventarc.v1.GetProviderRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_PROVIDERS: + serviceImpl.listProviders( + (com.google.cloud.eventarc.v1.ListProvidersRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_GET_CHANNEL_CONNECTION: + serviceImpl.getChannelConnection( + (com.google.cloud.eventarc.v1.GetChannelConnectionRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_CHANNEL_CONNECTIONS: + serviceImpl.listChannelConnections( + (com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse>) + responseObserver); + break; + case METHODID_CREATE_CHANNEL_CONNECTION: + serviceImpl.createChannelConnection( + (com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_CHANNEL_CONNECTION: + serviceImpl.deleteChannelConnection( + (com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_GOOGLE_CHANNEL_CONFIG: + serviceImpl.getGoogleChannelConfig( + (com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG: + serviceImpl.updateGoogleChannelConfig( + (com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + default: + throw new AssertionError(); + } + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public io.grpc.stub.StreamObserver invoke( + io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + default: + throw new AssertionError(); + } + } + } + + private abstract static class EventarcBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + EventarcBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("Eventarc"); + } + } + + private static final class EventarcFileDescriptorSupplier extends EventarcBaseDescriptorSupplier { + EventarcFileDescriptorSupplier() {} + } + + private static final class EventarcMethodDescriptorSupplier extends EventarcBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final String methodName; + + EventarcMethodDescriptorSupplier(String methodName) { + this.methodName = methodName; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { + return getServiceDescriptor().findMethodByName(methodName); + } + } + + private static volatile io.grpc.ServiceDescriptor serviceDescriptor; + + public static io.grpc.ServiceDescriptor getServiceDescriptor() { + io.grpc.ServiceDescriptor result = serviceDescriptor; + if (result == null) { + synchronized (EventarcGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new EventarcFileDescriptorSupplier()) + .addMethod(getGetTriggerMethod()) + .addMethod(getListTriggersMethod()) + .addMethod(getCreateTriggerMethod()) + .addMethod(getUpdateTriggerMethod()) + .addMethod(getDeleteTriggerMethod()) + .addMethod(getGetChannelMethod()) + .addMethod(getListChannelsMethod()) + .addMethod(getCreateChannelMethod()) + .addMethod(getUpdateChannelMethod()) + .addMethod(getDeleteChannelMethod()) + .addMethod(getGetProviderMethod()) + .addMethod(getListProvidersMethod()) + .addMethod(getGetChannelConnectionMethod()) + .addMethod(getListChannelConnectionsMethod()) + .addMethod(getCreateChannelConnectionMethod()) + .addMethod(getDeleteChannelConnectionMethod()) + .addMethod(getGetGoogleChannelConfigMethod()) + .addMethod(getUpdateGoogleChannelConfigMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java similarity index 72% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java index 0c8d8d6898af..266631ae236a 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Channel.java @@ -4,6 +4,8 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A representation of the Channel resource.
  * A Channel is a resource on which event providers publish their events.
@@ -13,15 +15,16 @@
  *
  * Protobuf type {@code google.cloud.eventarc.v1.Channel}
  */
-public final class Channel extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class Channel extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Channel)
     ChannelOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use Channel.newBuilder() to construct.
   private Channel(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private Channel() {
     name_ = "";
     uid_ = "";
@@ -33,39 +36,43 @@ private Channel() {
 
   @java.lang.Override
   @SuppressWarnings({"unused"})
-  protected java.lang.Object newInstance(
-      UnusedPrivateParameter unused) {
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
     return new Channel();
   }
 
   @java.lang.Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
-  public static final com.google.protobuf.Descriptors.Descriptor
-      getDescriptor() {
-    return com.google.cloud.eventarc.v1.ChannelProto.internal_static_google_cloud_eventarc_v1_Channel_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.cloud.eventarc.v1.ChannelProto
+        .internal_static_google_cloud_eventarc_v1_Channel_descriptor;
   }
 
   @java.lang.Override
   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return com.google.cloud.eventarc.v1.ChannelProto.internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable
+    return com.google.cloud.eventarc.v1.ChannelProto
+        .internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            com.google.cloud.eventarc.v1.Channel.class, com.google.cloud.eventarc.v1.Channel.Builder.class);
+            com.google.cloud.eventarc.v1.Channel.class,
+            com.google.cloud.eventarc.v1.Channel.Builder.class);
   }
 
   /**
+   *
+   *
    * 
    * State lists all the possible states of a Channel
    * 
* * Protobuf enum {@code google.cloud.eventarc.v1.Channel.State} */ - public enum State - implements com.google.protobuf.ProtocolMessageEnum { + public enum State implements com.google.protobuf.ProtocolMessageEnum { /** + * + * *
      * Default value. This value is unused.
      * 
@@ -74,6 +81,8 @@ public enum State */ STATE_UNSPECIFIED(0), /** + * + * *
      * The PENDING state indicates that a Channel has been created successfully
      * and there is a new activation token available for the subscriber to use
@@ -84,6 +93,8 @@ public enum State
      */
     PENDING(1),
     /**
+     *
+     *
      * 
      * The ACTIVE state indicates that a Channel has been successfully
      * connected with the event provider.
@@ -95,6 +106,8 @@ public enum State
      */
     ACTIVE(2),
     /**
+     *
+     *
      * 
      * The INACTIVE state indicates that the Channel cannot receive events
      * permanently. There are two possible cases this state can happen:
@@ -112,6 +125,8 @@ public enum State
     ;
 
     /**
+     *
+     *
      * 
      * Default value. This value is unused.
      * 
@@ -120,6 +135,8 @@ public enum State */ public static final int STATE_UNSPECIFIED_VALUE = 0; /** + * + * *
      * The PENDING state indicates that a Channel has been created successfully
      * and there is a new activation token available for the subscriber to use
@@ -130,6 +147,8 @@ public enum State
      */
     public static final int PENDING_VALUE = 1;
     /**
+     *
+     *
      * 
      * The ACTIVE state indicates that a Channel has been successfully
      * connected with the event provider.
@@ -141,6 +160,8 @@ public enum State
      */
     public static final int ACTIVE_VALUE = 2;
     /**
+     *
+     *
      * 
      * The INACTIVE state indicates that the Channel cannot receive events
      * permanently. There are two possible cases this state can happen:
@@ -155,7 +176,6 @@ public enum State
      */
     public static final int INACTIVE_VALUE = 3;
 
-
     public final int getNumber() {
       if (this == UNRECOGNIZED) {
         throw new java.lang.IllegalArgumentException(
@@ -180,50 +200,51 @@ public static State valueOf(int value) {
      */
     public static State forNumber(int value) {
       switch (value) {
-        case 0: return STATE_UNSPECIFIED;
-        case 1: return PENDING;
-        case 2: return ACTIVE;
-        case 3: return INACTIVE;
-        default: return null;
+        case 0:
+          return STATE_UNSPECIFIED;
+        case 1:
+          return PENDING;
+        case 2:
+          return ACTIVE;
+        case 3:
+          return INACTIVE;
+        default:
+          return null;
       }
     }
 
-    public static com.google.protobuf.Internal.EnumLiteMap
-        internalGetValueMap() {
+    public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() {
       return internalValueMap;
     }
-    private static final com.google.protobuf.Internal.EnumLiteMap<
-        State> internalValueMap =
-          new com.google.protobuf.Internal.EnumLiteMap() {
-            public State findValueByNumber(int number) {
-              return State.forNumber(number);
-            }
-          };
 
-    public final com.google.protobuf.Descriptors.EnumValueDescriptor
-        getValueDescriptor() {
+    private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap =
+        new com.google.protobuf.Internal.EnumLiteMap() {
+          public State findValueByNumber(int number) {
+            return State.forNumber(number);
+          }
+        };
+
+    public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() {
       if (this == UNRECOGNIZED) {
         throw new java.lang.IllegalStateException(
             "Can't get the descriptor of an unrecognized enum value.");
       }
       return getDescriptor().getValues().get(ordinal());
     }
-    public final com.google.protobuf.Descriptors.EnumDescriptor
-        getDescriptorForType() {
+
+    public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() {
       return getDescriptor();
     }
-    public static final com.google.protobuf.Descriptors.EnumDescriptor
-        getDescriptor() {
+
+    public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() {
       return com.google.cloud.eventarc.v1.Channel.getDescriptor().getEnumTypes().get(0);
     }
 
     private static final State[] VALUES = values();
 
-    public static State valueOf(
-        com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
+    public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
       if (desc.getType() != getDescriptor()) {
-        throw new java.lang.IllegalArgumentException(
-          "EnumValueDescriptor is not for this type.");
+        throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type.");
       }
       if (desc.getIndex() == -1) {
         return UNRECOGNIZED;
@@ -242,12 +263,15 @@ private State(int value) {
 
   private int transportCase_ = 0;
   private java.lang.Object transport_;
+
   public enum TransportCase
-      implements com.google.protobuf.Internal.EnumLite,
+      implements
+          com.google.protobuf.Internal.EnumLite,
           com.google.protobuf.AbstractMessage.InternalOneOfEnum {
     PUBSUB_TOPIC(8),
     TRANSPORT_NOT_SET(0);
     private final int value;
+
     private TransportCase(int value) {
       this.value = value;
     }
@@ -263,25 +287,29 @@ public static TransportCase valueOf(int value) {
 
     public static TransportCase forNumber(int value) {
       switch (value) {
-        case 8: return PUBSUB_TOPIC;
-        case 0: return TRANSPORT_NOT_SET;
-        default: return null;
+        case 8:
+          return PUBSUB_TOPIC;
+        case 0:
+          return TRANSPORT_NOT_SET;
+        default:
+          return null;
       }
     }
+
     public int getNumber() {
       return this.value;
     }
   };
 
-  public TransportCase
-  getTransportCase() {
-    return TransportCase.forNumber(
-        transportCase_);
+  public TransportCase getTransportCase() {
+    return TransportCase.forNumber(transportCase_);
   }
 
   public static final int NAME_FIELD_NUMBER = 1;
   private volatile java.lang.Object name_;
   /**
+   *
+   *
    * 
    * Required. The resource name of the channel. Must be unique within the
    * location on the project and must be in
@@ -289,6 +317,7 @@ public int getNumber() {
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ @java.lang.Override @@ -297,14 +326,15 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The resource name of the channel. Must be unique within the
    * location on the project and must be in
@@ -312,16 +342,15 @@ public java.lang.String getName() {
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -332,6 +361,8 @@ public java.lang.String getName() { public static final int UID_FIELD_NUMBER = 2; private volatile java.lang.Object uid_; /** + * + * *
    * Output only. Server assigned unique identifier for the channel. The value
    * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -339,6 +370,7 @@ public java.lang.String getName() {
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ @java.lang.Override @@ -347,14 +379,15 @@ public java.lang.String getUid() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); uid_ = s; return s; } } /** + * + * *
    * Output only. Server assigned unique identifier for the channel. The value
    * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -362,16 +395,15 @@ public java.lang.String getUid() {
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ @java.lang.Override - public com.google.protobuf.ByteString - getUidBytes() { + public com.google.protobuf.ByteString getUidBytes() { java.lang.Object ref = uid_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); uid_ = b; return b; } else { @@ -382,11 +414,15 @@ public java.lang.String getUid() { public static final int CREATE_TIME_FIELD_NUMBER = 5; private com.google.protobuf.Timestamp createTime_; /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ @java.lang.Override @@ -394,11 +430,15 @@ public boolean hasCreateTime() { return createTime_ != null; } /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ @java.lang.Override @@ -406,11 +446,14 @@ public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { @@ -420,11 +463,15 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { public static final int UPDATE_TIME_FIELD_NUMBER = 6; private com.google.protobuf.Timestamp updateTime_; /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ @java.lang.Override @@ -432,11 +479,15 @@ public boolean hasUpdateTime() { return updateTime_ != null; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ @java.lang.Override @@ -444,11 +495,14 @@ public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { @@ -458,6 +512,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { public static final int PROVIDER_FIELD_NUMBER = 7; private volatile java.lang.Object provider_; /** + * + * *
    * The name of the event provider (e.g. Eventarc SaaS partner) associated
    * with the channel. This provider will be granted permissions to publish
@@ -466,6 +522,7 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
    * 
* * string provider = 7; + * * @return The provider. */ @java.lang.Override @@ -474,14 +531,15 @@ public java.lang.String getProvider() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); provider_ = s; return s; } } /** + * + * *
    * The name of the event provider (e.g. Eventarc SaaS partner) associated
    * with the channel. This provider will be granted permissions to publish
@@ -490,16 +548,15 @@ public java.lang.String getProvider() {
    * 
* * string provider = 7; + * * @return The bytes for provider. */ @java.lang.Override - public com.google.protobuf.ByteString - getProviderBytes() { + public com.google.protobuf.ByteString getProviderBytes() { java.lang.Object ref = provider_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); provider_ = b; return b; } else { @@ -509,6 +566,8 @@ public java.lang.String getProvider() { public static final int PUBSUB_TOPIC_FIELD_NUMBER = 8; /** + * + * *
    * Output only. The name of the Pub/Sub topic created and managed by
    * Eventarc system as a transport for the event delivery. Format:
@@ -516,12 +575,15 @@ public java.lang.String getProvider() {
    * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return Whether the pubsubTopic field is set. */ public boolean hasPubsubTopic() { return transportCase_ == 8; } /** + * + * *
    * Output only. The name of the Pub/Sub topic created and managed by
    * Eventarc system as a transport for the event delivery. Format:
@@ -529,6 +591,7 @@ public boolean hasPubsubTopic() {
    * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The pubsubTopic. */ public java.lang.String getPubsubTopic() { @@ -539,8 +602,7 @@ public java.lang.String getPubsubTopic() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (transportCase_ == 8) { transport_ = s; @@ -549,6 +611,8 @@ public java.lang.String getPubsubTopic() { } } /** + * + * *
    * Output only. The name of the Pub/Sub topic created and managed by
    * Eventarc system as a transport for the event delivery. Format:
@@ -556,18 +620,17 @@ public java.lang.String getPubsubTopic() {
    * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for pubsubTopic. */ - public com.google.protobuf.ByteString - getPubsubTopicBytes() { + public com.google.protobuf.ByteString getPubsubTopicBytes() { java.lang.Object ref = ""; if (transportCase_ == 8) { ref = transport_; } if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (transportCase_ == 8) { transport_ = b; } @@ -580,39 +643,55 @@ public java.lang.String getPubsubTopic() { public static final int STATE_FIELD_NUMBER = 9; private int state_; /** + * + * *
    * Output only. The state of a Channel.
    * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The enum numeric value on the wire for state. */ - @java.lang.Override public int getStateValue() { + @java.lang.Override + public int getStateValue() { return state_; } /** + * + * *
    * Output only. The state of a Channel.
    * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The state. */ - @java.lang.Override public com.google.cloud.eventarc.v1.Channel.State getState() { + @java.lang.Override + public com.google.cloud.eventarc.v1.Channel.State getState() { @SuppressWarnings("deprecation") - com.google.cloud.eventarc.v1.Channel.State result = com.google.cloud.eventarc.v1.Channel.State.valueOf(state_); + com.google.cloud.eventarc.v1.Channel.State result = + com.google.cloud.eventarc.v1.Channel.State.valueOf(state_); return result == null ? com.google.cloud.eventarc.v1.Channel.State.UNRECOGNIZED : result; } public static final int ACTIVATION_TOKEN_FIELD_NUMBER = 10; private volatile java.lang.Object activationToken_; /** + * + * *
    * Output only. The activation token for the channel. The token must be used
    * by the provider to register the channel for publishing.
    * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The activationToken. */ @java.lang.Override @@ -621,30 +700,30 @@ public java.lang.String getActivationToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); activationToken_ = s; return s; } } /** + * + * *
    * Output only. The activation token for the channel. The token must be used
    * by the provider to register the channel for publishing.
    * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for activationToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getActivationTokenBytes() { + public com.google.protobuf.ByteString getActivationTokenBytes() { java.lang.Object ref = activationToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); activationToken_ = b; return b; } else { @@ -655,6 +734,8 @@ public java.lang.String getActivationToken() { public static final int CRYPTO_KEY_NAME_FIELD_NUMBER = 11; private volatile java.lang.Object cryptoKeyName_; /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -662,7 +743,10 @@ public java.lang.String getActivationToken() {
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The cryptoKeyName. */ @java.lang.Override @@ -671,14 +755,15 @@ public java.lang.String getCryptoKeyName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); cryptoKeyName_ = s; return s; } } /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -686,17 +771,18 @@ public java.lang.String getCryptoKeyName() {
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for cryptoKeyName. */ @java.lang.Override - public com.google.protobuf.ByteString - getCryptoKeyNameBytes() { + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { java.lang.Object ref = cryptoKeyName_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); cryptoKeyName_ = b; return b; } else { @@ -705,6 +791,7 @@ public java.lang.String getCryptoKeyName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -716,8 +803,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -761,12 +847,10 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); } if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, getCreateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); } if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getUpdateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(provider_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, provider_); @@ -775,8 +859,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, transport_); } if (state_ != com.google.cloud.eventarc.v1.Channel.State.STATE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(9, state_); + size += com.google.protobuf.CodedOutputStream.computeEnumSize(9, state_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(activationToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, activationToken_); @@ -792,39 +875,31 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.Channel)) { return super.equals(obj); } com.google.cloud.eventarc.v1.Channel other = (com.google.cloud.eventarc.v1.Channel) obj; - if (!getName() - .equals(other.getName())) return false; - if (!getUid() - .equals(other.getUid())) return false; + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { - if (!getCreateTime() - .equals(other.getCreateTime())) return false; + if (!getCreateTime().equals(other.getCreateTime())) return false; } if (hasUpdateTime() != other.hasUpdateTime()) return false; if (hasUpdateTime()) { - if (!getUpdateTime() - .equals(other.getUpdateTime())) return false; + if (!getUpdateTime().equals(other.getUpdateTime())) return false; } - if (!getProvider() - .equals(other.getProvider())) return false; + if (!getProvider().equals(other.getProvider())) return false; if (state_ != other.state_) return false; - if (!getActivationToken() - .equals(other.getActivationToken())) return false; - if (!getCryptoKeyName() - .equals(other.getCryptoKeyName())) return false; + if (!getActivationToken().equals(other.getActivationToken())) return false; + if (!getCryptoKeyName().equals(other.getCryptoKeyName())) return false; if (!getTransportCase().equals(other.getTransportCase())) return false; switch (transportCase_) { case 8: - if (!getPubsubTopic() - .equals(other.getPubsubTopic())) return false; + if (!getPubsubTopic().equals(other.getPubsubTopic())) return false; break; case 0: default: @@ -873,97 +948,103 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.Channel parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.Channel parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Channel parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.Channel parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.cloud.eventarc.v1.Channel parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Channel parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Channel parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Channel parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Channel parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Channel parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Channel parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Channel parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Channel parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Channel parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.Channel prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A representation of the Channel resource.
    * A Channel is a resource on which event providers publish their events.
@@ -973,33 +1054,32 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.cloud.eventarc.v1.Channel}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Channel)
       com.google.cloud.eventarc.v1.ChannelOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return com.google.cloud.eventarc.v1.ChannelProto.internal_static_google_cloud_eventarc_v1_Channel_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.cloud.eventarc.v1.ChannelProto
+          .internal_static_google_cloud_eventarc_v1_Channel_descriptor;
     }
 
     @java.lang.Override
     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return com.google.cloud.eventarc.v1.ChannelProto.internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable
+      return com.google.cloud.eventarc.v1.ChannelProto
+          .internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              com.google.cloud.eventarc.v1.Channel.class, com.google.cloud.eventarc.v1.Channel.Builder.class);
+              com.google.cloud.eventarc.v1.Channel.class,
+              com.google.cloud.eventarc.v1.Channel.Builder.class);
     }
 
     // Construct using com.google.cloud.eventarc.v1.Channel.newBuilder()
-    private Builder() {
-
-    }
+    private Builder() {}
 
-    private Builder(
-        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
-
     }
+
     @java.lang.Override
     public Builder clear() {
       super.clear();
@@ -1033,9 +1113,9 @@ public Builder clear() {
     }
 
     @java.lang.Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return com.google.cloud.eventarc.v1.ChannelProto.internal_static_google_cloud_eventarc_v1_Channel_descriptor;
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.cloud.eventarc.v1.ChannelProto
+          .internal_static_google_cloud_eventarc_v1_Channel_descriptor;
     }
 
     @java.lang.Override
@@ -1083,38 +1163,39 @@ public com.google.cloud.eventarc.v1.Channel buildPartial() {
     public Builder clone() {
       return super.clone();
     }
+
     @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
+
     @java.lang.Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
+
     @java.lang.Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
+
     @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
+
     @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
+
     @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
       if (other instanceof com.google.cloud.eventarc.v1.Channel) {
-        return mergeFrom((com.google.cloud.eventarc.v1.Channel)other);
+        return mergeFrom((com.google.cloud.eventarc.v1.Channel) other);
       } else {
         super.mergeFrom(other);
         return this;
@@ -1153,15 +1234,17 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.Channel other) {
         onChanged();
       }
       switch (other.getTransportCase()) {
-        case PUBSUB_TOPIC: {
-          transportCase_ = 8;
-          transport_ = other.transport_;
-          onChanged();
-          break;
-        }
-        case TRANSPORT_NOT_SET: {
-          break;
-        }
+        case PUBSUB_TOPIC:
+          {
+            transportCase_ = 8;
+            transport_ = other.transport_;
+            onChanged();
+            break;
+          }
+        case TRANSPORT_NOT_SET:
+          {
+            break;
+          }
       }
       this.mergeUnknownFields(other.getUnknownFields());
       onChanged();
@@ -1189,62 +1272,68 @@ public Builder mergeFrom(
             case 0:
               done = true;
               break;
-            case 10: {
-              name_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 10
-            case 18: {
-              uid_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 18
-            case 42: {
-              input.readMessage(
-                  getCreateTimeFieldBuilder().getBuilder(),
-                  extensionRegistry);
-
-              break;
-            } // case 42
-            case 50: {
-              input.readMessage(
-                  getUpdateTimeFieldBuilder().getBuilder(),
-                  extensionRegistry);
-
-              break;
-            } // case 50
-            case 58: {
-              provider_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 58
-            case 66: {
-              java.lang.String s = input.readStringRequireUtf8();
-              transportCase_ = 8;
-              transport_ = s;
-              break;
-            } // case 66
-            case 72: {
-              state_ = input.readEnum();
-
-              break;
-            } // case 72
-            case 82: {
-              activationToken_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 82
-            case 90: {
-              cryptoKeyName_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 90
-            default: {
-              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
-                done = true; // was an endgroup tag
-              }
-              break;
-            } // default:
+            case 10:
+              {
+                name_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 10
+            case 18:
+              {
+                uid_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 18
+            case 42:
+              {
+                input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry);
+
+                break;
+              } // case 42
+            case 50:
+              {
+                input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry);
+
+                break;
+              } // case 50
+            case 58:
+              {
+                provider_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 58
+            case 66:
+              {
+                java.lang.String s = input.readStringRequireUtf8();
+                transportCase_ = 8;
+                transport_ = s;
+                break;
+              } // case 66
+            case 72:
+              {
+                state_ = input.readEnum();
+
+                break;
+              } // case 72
+            case 82:
+              {
+                activationToken_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 82
+            case 90:
+              {
+                cryptoKeyName_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 90
+            default:
+              {
+                if (!super.parseUnknownField(input, extensionRegistry, tag)) {
+                  done = true; // was an endgroup tag
+                }
+                break;
+              } // default:
           } // switch (tag)
         } // while (!done)
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@@ -1254,12 +1343,12 @@ public Builder mergeFrom(
       } // finally
       return this;
     }
+
     private int transportCase_ = 0;
     private java.lang.Object transport_;
-    public TransportCase
-        getTransportCase() {
-      return TransportCase.forNumber(
-          transportCase_);
+
+    public TransportCase getTransportCase() {
+      return TransportCase.forNumber(transportCase_);
     }
 
     public Builder clearTransport() {
@@ -1269,9 +1358,10 @@ public Builder clearTransport() {
       return this;
     }
 
-
     private java.lang.Object name_ = "";
     /**
+     *
+     *
      * 
      * Required. The resource name of the channel. Must be unique within the
      * location on the project and must be in
@@ -1279,13 +1369,13 @@ public Builder clearTransport() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -1294,6 +1384,8 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The resource name of the channel. Must be unique within the
      * location on the project and must be in
@@ -1301,15 +1393,14 @@ public java.lang.String getName() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -1317,6 +1408,8 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The resource name of the channel. Must be unique within the
      * location on the project and must be in
@@ -1324,20 +1417,22 @@ public java.lang.String getName() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The resource name of the channel. Must be unique within the
      * location on the project and must be in
@@ -1345,15 +1440,18 @@ public Builder setName(
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The resource name of the channel. Must be unique within the
      * location on the project and must be in
@@ -1361,16 +1459,16 @@ public Builder clearName() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; @@ -1378,6 +1476,8 @@ public Builder setNameBytes( private java.lang.Object uid_ = ""; /** + * + * *
      * Output only. Server assigned unique identifier for the channel. The value
      * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -1385,13 +1485,13 @@ public Builder setNameBytes(
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ public java.lang.String getUid() { java.lang.Object ref = uid_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); uid_ = s; return s; @@ -1400,6 +1500,8 @@ public java.lang.String getUid() { } } /** + * + * *
      * Output only. Server assigned unique identifier for the channel. The value
      * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -1407,15 +1509,14 @@ public java.lang.String getUid() {
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ - public com.google.protobuf.ByteString - getUidBytes() { + public com.google.protobuf.ByteString getUidBytes() { java.lang.Object ref = uid_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); uid_ = b; return b; } else { @@ -1423,6 +1524,8 @@ public java.lang.String getUid() { } } /** + * + * *
      * Output only. Server assigned unique identifier for the channel. The value
      * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -1430,20 +1533,22 @@ public java.lang.String getUid() {
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The uid to set. * @return This builder for chaining. */ - public Builder setUid( - java.lang.String value) { + public Builder setUid(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + uid_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Server assigned unique identifier for the channel. The value
      * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -1451,15 +1556,18 @@ public Builder setUid(
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearUid() { - + uid_ = getDefaultInstance().getUid(); onChanged(); return this; } /** + * + * *
      * Output only. Server assigned unique identifier for the channel. The value
      * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -1467,16 +1575,16 @@ public Builder clearUid() {
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for uid to set. * @return This builder for chaining. */ - public Builder setUidBytes( - com.google.protobuf.ByteString value) { + public Builder setUidBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; onChanged(); return this; @@ -1484,39 +1592,58 @@ public Builder setUidBytes( private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return createTimeBuilder_ != null || createTime_ != null; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { @@ -1532,14 +1659,17 @@ public Builder setCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setCreateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); onChanged(); @@ -1550,17 +1680,21 @@ public Builder setCreateTime( return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (createTime_ != null) { createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); } else { createTime_ = value; } @@ -1572,11 +1706,15 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearCreateTime() { if (createTimeBuilder_ == null) { @@ -1590,48 +1728,64 @@ public Builder clearCreateTime() { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - + onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { - return createTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { - createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), - getParentForChildren(), - isClean()); + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; @@ -1639,39 +1793,58 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { private com.google.protobuf.Timestamp updateTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ public boolean hasUpdateTime() { return updateTimeBuilder_ != null || updateTime_ != null; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } else { return updateTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { @@ -1687,14 +1860,17 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setUpdateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (updateTimeBuilder_ == null) { updateTime_ = builderForValue.build(); onChanged(); @@ -1705,17 +1881,21 @@ public Builder setUpdateTime( return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { if (updateTime_ != null) { updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); } else { updateTime_ = value; } @@ -1727,11 +1907,15 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearUpdateTime() { if (updateTimeBuilder_ == null) { @@ -1745,48 +1929,64 @@ public Builder clearUpdateTime() { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - + onChanged(); return getUpdateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (updateTimeBuilder_ != null) { return updateTimeBuilder_.getMessageOrBuilder(); } else { - return updateTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getUpdateTimeFieldBuilder() { if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), - getParentForChildren(), - isClean()); + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); updateTime_ = null; } return updateTimeBuilder_; @@ -1794,6 +1994,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { private java.lang.Object provider_ = ""; /** + * + * *
      * The name of the event provider (e.g. Eventarc SaaS partner) associated
      * with the channel. This provider will be granted permissions to publish
@@ -1802,13 +2004,13 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
      * 
* * string provider = 7; + * * @return The provider. */ public java.lang.String getProvider() { java.lang.Object ref = provider_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); provider_ = s; return s; @@ -1817,6 +2019,8 @@ public java.lang.String getProvider() { } } /** + * + * *
      * The name of the event provider (e.g. Eventarc SaaS partner) associated
      * with the channel. This provider will be granted permissions to publish
@@ -1825,15 +2029,14 @@ public java.lang.String getProvider() {
      * 
* * string provider = 7; + * * @return The bytes for provider. */ - public com.google.protobuf.ByteString - getProviderBytes() { + public com.google.protobuf.ByteString getProviderBytes() { java.lang.Object ref = provider_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); provider_ = b; return b; } else { @@ -1841,6 +2044,8 @@ public java.lang.String getProvider() { } } /** + * + * *
      * The name of the event provider (e.g. Eventarc SaaS partner) associated
      * with the channel. This provider will be granted permissions to publish
@@ -1849,20 +2054,22 @@ public java.lang.String getProvider() {
      * 
* * string provider = 7; + * * @param value The provider to set. * @return This builder for chaining. */ - public Builder setProvider( - java.lang.String value) { + public Builder setProvider(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + provider_ = value; onChanged(); return this; } /** + * + * *
      * The name of the event provider (e.g. Eventarc SaaS partner) associated
      * with the channel. This provider will be granted permissions to publish
@@ -1871,15 +2078,18 @@ public Builder setProvider(
      * 
* * string provider = 7; + * * @return This builder for chaining. */ public Builder clearProvider() { - + provider_ = getDefaultInstance().getProvider(); onChanged(); return this; } /** + * + * *
      * The name of the event provider (e.g. Eventarc SaaS partner) associated
      * with the channel. This provider will be granted permissions to publish
@@ -1888,22 +2098,24 @@ public Builder clearProvider() {
      * 
* * string provider = 7; + * * @param value The bytes for provider to set. * @return This builder for chaining. */ - public Builder setProviderBytes( - com.google.protobuf.ByteString value) { + public Builder setProviderBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + provider_ = value; onChanged(); return this; } /** + * + * *
      * Output only. The name of the Pub/Sub topic created and managed by
      * Eventarc system as a transport for the event delivery. Format:
@@ -1911,6 +2123,7 @@ public Builder setProviderBytes(
      * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return Whether the pubsubTopic field is set. */ @java.lang.Override @@ -1918,6 +2131,8 @@ public boolean hasPubsubTopic() { return transportCase_ == 8; } /** + * + * *
      * Output only. The name of the Pub/Sub topic created and managed by
      * Eventarc system as a transport for the event delivery. Format:
@@ -1925,6 +2140,7 @@ public boolean hasPubsubTopic() {
      * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The pubsubTopic. */ @java.lang.Override @@ -1934,8 +2150,7 @@ public java.lang.String getPubsubTopic() { ref = transport_; } if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (transportCase_ == 8) { transport_ = s; @@ -1946,6 +2161,8 @@ public java.lang.String getPubsubTopic() { } } /** + * + * *
      * Output only. The name of the Pub/Sub topic created and managed by
      * Eventarc system as a transport for the event delivery. Format:
@@ -1953,19 +2170,18 @@ public java.lang.String getPubsubTopic() {
      * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for pubsubTopic. */ @java.lang.Override - public com.google.protobuf.ByteString - getPubsubTopicBytes() { + public com.google.protobuf.ByteString getPubsubTopicBytes() { java.lang.Object ref = ""; if (transportCase_ == 8) { ref = transport_; } if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (transportCase_ == 8) { transport_ = b; } @@ -1975,6 +2191,8 @@ public java.lang.String getPubsubTopic() { } } /** + * + * *
      * Output only. The name of the Pub/Sub topic created and managed by
      * Eventarc system as a transport for the event delivery. Format:
@@ -1982,20 +2200,22 @@ public java.lang.String getPubsubTopic() {
      * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The pubsubTopic to set. * @return This builder for chaining. */ - public Builder setPubsubTopic( - java.lang.String value) { + public Builder setPubsubTopic(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - transportCase_ = 8; + throw new NullPointerException(); + } + transportCase_ = 8; transport_ = value; onChanged(); return this; } /** + * + * *
      * Output only. The name of the Pub/Sub topic created and managed by
      * Eventarc system as a transport for the event delivery. Format:
@@ -2003,6 +2223,7 @@ public Builder setPubsubTopic(
      * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearPubsubTopic() { @@ -2014,6 +2235,8 @@ public Builder clearPubsubTopic() { return this; } /** + * + * *
      * Output only. The name of the Pub/Sub topic created and managed by
      * Eventarc system as a transport for the event delivery. Format:
@@ -2021,15 +2244,15 @@ public Builder clearPubsubTopic() {
      * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for pubsubTopic to set. * @return This builder for chaining. */ - public Builder setPubsubTopicBytes( - com.google.protobuf.ByteString value) { + public Builder setPubsubTopicBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); transportCase_ = 8; transport_ = value; onChanged(); @@ -2038,51 +2261,73 @@ public Builder setPubsubTopicBytes( private int state_ = 0; /** + * + * *
      * Output only. The state of a Channel.
      * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The enum numeric value on the wire for state. */ - @java.lang.Override public int getStateValue() { + @java.lang.Override + public int getStateValue() { return state_; } /** + * + * *
      * Output only. The state of a Channel.
      * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @param value The enum numeric value on the wire for state to set. * @return This builder for chaining. */ public Builder setStateValue(int value) { - + state_ = value; onChanged(); return this; } /** + * + * *
      * Output only. The state of a Channel.
      * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The state. */ @java.lang.Override public com.google.cloud.eventarc.v1.Channel.State getState() { @SuppressWarnings("deprecation") - com.google.cloud.eventarc.v1.Channel.State result = com.google.cloud.eventarc.v1.Channel.State.valueOf(state_); + com.google.cloud.eventarc.v1.Channel.State result = + com.google.cloud.eventarc.v1.Channel.State.valueOf(state_); return result == null ? com.google.cloud.eventarc.v1.Channel.State.UNRECOGNIZED : result; } /** + * + * *
      * Output only. The state of a Channel.
      * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @param value The state to set. * @return This builder for chaining. */ @@ -2090,21 +2335,26 @@ public Builder setState(com.google.cloud.eventarc.v1.Channel.State value) { if (value == null) { throw new NullPointerException(); } - + state_ = value.getNumber(); onChanged(); return this; } /** + * + * *
      * Output only. The state of a Channel.
      * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return This builder for chaining. */ public Builder clearState() { - + state_ = 0; onChanged(); return this; @@ -2112,19 +2362,21 @@ public Builder clearState() { private java.lang.Object activationToken_ = ""; /** + * + * *
      * Output only. The activation token for the channel. The token must be used
      * by the provider to register the channel for publishing.
      * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The activationToken. */ public java.lang.String getActivationToken() { java.lang.Object ref = activationToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); activationToken_ = s; return s; @@ -2133,21 +2385,22 @@ public java.lang.String getActivationToken() { } } /** + * + * *
      * Output only. The activation token for the channel. The token must be used
      * by the provider to register the channel for publishing.
      * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for activationToken. */ - public com.google.protobuf.ByteString - getActivationTokenBytes() { + public com.google.protobuf.ByteString getActivationTokenBytes() { java.lang.Object ref = activationToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); activationToken_ = b; return b; } else { @@ -2155,57 +2408,64 @@ public java.lang.String getActivationToken() { } } /** + * + * *
      * Output only. The activation token for the channel. The token must be used
      * by the provider to register the channel for publishing.
      * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The activationToken to set. * @return This builder for chaining. */ - public Builder setActivationToken( - java.lang.String value) { + public Builder setActivationToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + activationToken_ = value; onChanged(); return this; } /** + * + * *
      * Output only. The activation token for the channel. The token must be used
      * by the provider to register the channel for publishing.
      * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearActivationToken() { - + activationToken_ = getDefaultInstance().getActivationToken(); onChanged(); return this; } /** + * + * *
      * Output only. The activation token for the channel. The token must be used
      * by the provider to register the channel for publishing.
      * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for activationToken to set. * @return This builder for chaining. */ - public Builder setActivationTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setActivationTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + activationToken_ = value; onChanged(); return this; @@ -2213,6 +2473,8 @@ public Builder setActivationTokenBytes( private java.lang.Object cryptoKeyName_ = ""; /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -2220,14 +2482,16 @@ public Builder setActivationTokenBytes(
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The cryptoKeyName. */ public java.lang.String getCryptoKeyName() { java.lang.Object ref = cryptoKeyName_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); cryptoKeyName_ = s; return s; @@ -2236,6 +2500,8 @@ public java.lang.String getCryptoKeyName() { } } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -2243,16 +2509,17 @@ public java.lang.String getCryptoKeyName() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for cryptoKeyName. */ - public com.google.protobuf.ByteString - getCryptoKeyNameBytes() { + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { java.lang.Object ref = cryptoKeyName_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); cryptoKeyName_ = b; return b; } else { @@ -2260,6 +2527,8 @@ public java.lang.String getCryptoKeyName() { } } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -2267,21 +2536,25 @@ public java.lang.String getCryptoKeyName() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @param value The cryptoKeyName to set. * @return This builder for chaining. */ - public Builder setCryptoKeyName( - java.lang.String value) { + public Builder setCryptoKeyName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + cryptoKeyName_ = value; onChanged(); return this; } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -2289,16 +2562,21 @@ public Builder setCryptoKeyName(
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearCryptoKeyName() { - + cryptoKeyName_ = getDefaultInstance().getCryptoKeyName(); onChanged(); return this; } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -2306,24 +2584,26 @@ public Builder clearCryptoKeyName() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for cryptoKeyName to set. * @return This builder for chaining. */ - public Builder setCryptoKeyNameBytes( - com.google.protobuf.ByteString value) { + public Builder setCryptoKeyNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + cryptoKeyName_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -2333,12 +2613,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Channel) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Channel) private static final com.google.cloud.eventarc.v1.Channel DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Channel(); } @@ -2347,27 +2627,27 @@ public static com.google.cloud.eventarc.v1.Channel getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Channel parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Channel parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -2382,6 +2662,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.Channel getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java similarity index 69% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java index 50c25bf7a60f..26237fe69691 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnection.java @@ -4,6 +4,8 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A representation of the ChannelConnection resource.
  * A ChannelConnection is a resource which event providers create during the
@@ -13,15 +15,16 @@
  *
  * Protobuf type {@code google.cloud.eventarc.v1.ChannelConnection}
  */
-public final class ChannelConnection extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class ChannelConnection extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ChannelConnection)
     ChannelConnectionOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use ChannelConnection.newBuilder() to construct.
   private ChannelConnection(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private ChannelConnection() {
     name_ = "";
     uid_ = "";
@@ -31,37 +34,41 @@ private ChannelConnection() {
 
   @java.lang.Override
   @SuppressWarnings({"unused"})
-  protected java.lang.Object newInstance(
-      UnusedPrivateParameter unused) {
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
     return new ChannelConnection();
   }
 
   @java.lang.Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
-  public static final com.google.protobuf.Descriptors.Descriptor
-      getDescriptor() {
-    return com.google.cloud.eventarc.v1.ChannelConnectionProto.internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.cloud.eventarc.v1.ChannelConnectionProto
+        .internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor;
   }
 
   @java.lang.Override
   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return com.google.cloud.eventarc.v1.ChannelConnectionProto.internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable
+    return com.google.cloud.eventarc.v1.ChannelConnectionProto
+        .internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            com.google.cloud.eventarc.v1.ChannelConnection.class, com.google.cloud.eventarc.v1.ChannelConnection.Builder.class);
+            com.google.cloud.eventarc.v1.ChannelConnection.class,
+            com.google.cloud.eventarc.v1.ChannelConnection.Builder.class);
   }
 
   public static final int NAME_FIELD_NUMBER = 1;
   private volatile java.lang.Object name_;
   /**
+   *
+   *
    * 
    * Required. The name of the connection.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ @java.lang.Override @@ -70,29 +77,29 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the connection.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -103,12 +110,15 @@ public java.lang.String getName() { public static final int UID_FIELD_NUMBER = 2; private volatile java.lang.Object uid_; /** + * + * *
    * Output only. Server assigned ID of the resource.
    * The server guarantees uniqueness and immutability until deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ @java.lang.Override @@ -117,30 +127,30 @@ public java.lang.String getUid() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); uid_ = s; return s; } } /** + * + * *
    * Output only. Server assigned ID of the resource.
    * The server guarantees uniqueness and immutability until deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ @java.lang.Override - public com.google.protobuf.ByteString - getUidBytes() { + public com.google.protobuf.ByteString getUidBytes() { java.lang.Object ref = uid_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); uid_ = b; return b; } else { @@ -151,6 +161,8 @@ public java.lang.String getUid() { public static final int CHANNEL_FIELD_NUMBER = 5; private volatile java.lang.Object channel_; /** + * + * *
    * Required. The name of the connected subscriber Channel.
    * This is a weak reference to avoid cross project and cross accounts
@@ -158,7 +170,10 @@ public java.lang.String getUid() {
    * `projects/{project}/location/{location}/channels/{channel_id}` format.
    * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The channel. */ @java.lang.Override @@ -167,14 +182,15 @@ public java.lang.String getChannel() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channel_ = s; return s; } } /** + * + * *
    * Required. The name of the connected subscriber Channel.
    * This is a weak reference to avoid cross project and cross accounts
@@ -182,17 +198,18 @@ public java.lang.String getChannel() {
    * `projects/{project}/location/{location}/channels/{channel_id}` format.
    * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for channel. */ @java.lang.Override - public com.google.protobuf.ByteString - getChannelBytes() { + public com.google.protobuf.ByteString getChannelBytes() { java.lang.Object ref = channel_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channel_ = b; return b; } else { @@ -203,11 +220,15 @@ public java.lang.String getChannel() { public static final int CREATE_TIME_FIELD_NUMBER = 6; private com.google.protobuf.Timestamp createTime_; /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ @java.lang.Override @@ -215,11 +236,15 @@ public boolean hasCreateTime() { return createTime_ != null; } /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ @java.lang.Override @@ -227,11 +252,14 @@ public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { @@ -241,11 +269,15 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { public static final int UPDATE_TIME_FIELD_NUMBER = 7; private com.google.protobuf.Timestamp updateTime_; /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ @java.lang.Override @@ -253,11 +285,15 @@ public boolean hasUpdateTime() { return updateTime_ != null; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ @java.lang.Override @@ -265,11 +301,14 @@ public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { @@ -279,6 +318,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { public static final int ACTIVATION_TOKEN_FIELD_NUMBER = 8; private volatile java.lang.Object activationToken_; /** + * + * *
    * Input only. Activation token for the channel. The token will be used
    * during the creation of ChannelConnection to bind the channel with the
@@ -286,6 +327,7 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
    * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return The activationToken. */ @java.lang.Override @@ -294,14 +336,15 @@ public java.lang.String getActivationToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); activationToken_ = s; return s; } } /** + * + * *
    * Input only. Activation token for the channel. The token will be used
    * during the creation of ChannelConnection to bind the channel with the
@@ -309,16 +352,15 @@ public java.lang.String getActivationToken() {
    * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return The bytes for activationToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getActivationTokenBytes() { + public com.google.protobuf.ByteString getActivationTokenBytes() { java.lang.Object ref = activationToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); activationToken_ = b; return b; } else { @@ -327,6 +369,7 @@ public java.lang.String getActivationToken() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -338,8 +381,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -377,12 +419,10 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, channel_); } if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getCreateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); } if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(7, getUpdateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getUpdateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(activationToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, activationToken_); @@ -395,31 +435,26 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ChannelConnection)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ChannelConnection other = (com.google.cloud.eventarc.v1.ChannelConnection) obj; + com.google.cloud.eventarc.v1.ChannelConnection other = + (com.google.cloud.eventarc.v1.ChannelConnection) obj; - if (!getName() - .equals(other.getName())) return false; - if (!getUid() - .equals(other.getUid())) return false; - if (!getChannel() - .equals(other.getChannel())) return false; + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; + if (!getChannel().equals(other.getChannel())) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { - if (!getCreateTime() - .equals(other.getCreateTime())) return false; + if (!getCreateTime().equals(other.getCreateTime())) return false; } if (hasUpdateTime() != other.hasUpdateTime()) return false; if (hasUpdateTime()) { - if (!getUpdateTime() - .equals(other.getUpdateTime())) return false; + if (!getUpdateTime().equals(other.getUpdateTime())) return false; } - if (!getActivationToken() - .equals(other.getActivationToken())) return false; + if (!getActivationToken().equals(other.getActivationToken())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -452,97 +487,104 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ChannelConnection parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ChannelConnection parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ChannelConnection parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ChannelConnection prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A representation of the ChannelConnection resource.
    * A ChannelConnection is a resource which event providers create during the
@@ -552,33 +594,32 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.cloud.eventarc.v1.ChannelConnection}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ChannelConnection)
       com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return com.google.cloud.eventarc.v1.ChannelConnectionProto.internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.cloud.eventarc.v1.ChannelConnectionProto
+          .internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor;
     }
 
     @java.lang.Override
     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return com.google.cloud.eventarc.v1.ChannelConnectionProto.internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable
+      return com.google.cloud.eventarc.v1.ChannelConnectionProto
+          .internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              com.google.cloud.eventarc.v1.ChannelConnection.class, com.google.cloud.eventarc.v1.ChannelConnection.Builder.class);
+              com.google.cloud.eventarc.v1.ChannelConnection.class,
+              com.google.cloud.eventarc.v1.ChannelConnection.Builder.class);
     }
 
     // Construct using com.google.cloud.eventarc.v1.ChannelConnection.newBuilder()
-    private Builder() {
+    private Builder() {}
 
-    }
-
-    private Builder(
-        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
-
     }
+
     @java.lang.Override
     public Builder clear() {
       super.clear();
@@ -606,9 +647,9 @@ public Builder clear() {
     }
 
     @java.lang.Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return com.google.cloud.eventarc.v1.ChannelConnectionProto.internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor;
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.cloud.eventarc.v1.ChannelConnectionProto
+          .internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor;
     }
 
     @java.lang.Override
@@ -627,7 +668,8 @@ public com.google.cloud.eventarc.v1.ChannelConnection build() {
 
     @java.lang.Override
     public com.google.cloud.eventarc.v1.ChannelConnection buildPartial() {
-      com.google.cloud.eventarc.v1.ChannelConnection result = new com.google.cloud.eventarc.v1.ChannelConnection(this);
+      com.google.cloud.eventarc.v1.ChannelConnection result =
+          new com.google.cloud.eventarc.v1.ChannelConnection(this);
       result.name_ = name_;
       result.uid_ = uid_;
       result.channel_ = channel_;
@@ -650,38 +692,39 @@ public com.google.cloud.eventarc.v1.ChannelConnection buildPartial() {
     public Builder clone() {
       return super.clone();
     }
+
     @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
+
     @java.lang.Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
+
     @java.lang.Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
+
     @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
+
     @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
+
     @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
       if (other instanceof com.google.cloud.eventarc.v1.ChannelConnection) {
-        return mergeFrom((com.google.cloud.eventarc.v1.ChannelConnection)other);
+        return mergeFrom((com.google.cloud.eventarc.v1.ChannelConnection) other);
       } else {
         super.mergeFrom(other);
         return this;
@@ -738,46 +781,49 @@ public Builder mergeFrom(
             case 0:
               done = true;
               break;
-            case 10: {
-              name_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 10
-            case 18: {
-              uid_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 18
-            case 42: {
-              channel_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 42
-            case 50: {
-              input.readMessage(
-                  getCreateTimeFieldBuilder().getBuilder(),
-                  extensionRegistry);
-
-              break;
-            } // case 50
-            case 58: {
-              input.readMessage(
-                  getUpdateTimeFieldBuilder().getBuilder(),
-                  extensionRegistry);
-
-              break;
-            } // case 58
-            case 66: {
-              activationToken_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 66
-            default: {
-              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
-                done = true; // was an endgroup tag
-              }
-              break;
-            } // default:
+            case 10:
+              {
+                name_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 10
+            case 18:
+              {
+                uid_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 18
+            case 42:
+              {
+                channel_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 42
+            case 50:
+              {
+                input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry);
+
+                break;
+              } // case 50
+            case 58:
+              {
+                input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry);
+
+                break;
+              } // case 58
+            case 66:
+              {
+                activationToken_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 66
+            default:
+              {
+                if (!super.parseUnknownField(input, extensionRegistry, tag)) {
+                  done = true; // was an endgroup tag
+                }
+                break;
+              } // default:
           } // switch (tag)
         } // while (!done)
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@@ -790,18 +836,20 @@ public Builder mergeFrom(
 
     private java.lang.Object name_ = "";
     /**
+     *
+     *
      * 
      * Required. The name of the connection.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -810,20 +858,21 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the connection.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -831,54 +880,61 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the connection.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the connection.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the connection.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; @@ -886,19 +942,21 @@ public Builder setNameBytes( private java.lang.Object uid_ = ""; /** + * + * *
      * Output only. Server assigned ID of the resource.
      * The server guarantees uniqueness and immutability until deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ public java.lang.String getUid() { java.lang.Object ref = uid_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); uid_ = s; return s; @@ -907,21 +965,22 @@ public java.lang.String getUid() { } } /** + * + * *
      * Output only. Server assigned ID of the resource.
      * The server guarantees uniqueness and immutability until deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ - public com.google.protobuf.ByteString - getUidBytes() { + public com.google.protobuf.ByteString getUidBytes() { java.lang.Object ref = uid_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); uid_ = b; return b; } else { @@ -929,57 +988,64 @@ public java.lang.String getUid() { } } /** + * + * *
      * Output only. Server assigned ID of the resource.
      * The server guarantees uniqueness and immutability until deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The uid to set. * @return This builder for chaining. */ - public Builder setUid( - java.lang.String value) { + public Builder setUid(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + uid_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Server assigned ID of the resource.
      * The server guarantees uniqueness and immutability until deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearUid() { - + uid_ = getDefaultInstance().getUid(); onChanged(); return this; } /** + * + * *
      * Output only. Server assigned ID of the resource.
      * The server guarantees uniqueness and immutability until deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for uid to set. * @return This builder for chaining. */ - public Builder setUidBytes( - com.google.protobuf.ByteString value) { + public Builder setUidBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; onChanged(); return this; @@ -987,6 +1053,8 @@ public Builder setUidBytes( private java.lang.Object channel_ = ""; /** + * + * *
      * Required. The name of the connected subscriber Channel.
      * This is a weak reference to avoid cross project and cross accounts
@@ -994,14 +1062,16 @@ public Builder setUidBytes(
      * `projects/{project}/location/{location}/channels/{channel_id}` format.
      * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The channel. */ public java.lang.String getChannel() { java.lang.Object ref = channel_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channel_ = s; return s; @@ -1010,6 +1080,8 @@ public java.lang.String getChannel() { } } /** + * + * *
      * Required. The name of the connected subscriber Channel.
      * This is a weak reference to avoid cross project and cross accounts
@@ -1017,16 +1089,17 @@ public java.lang.String getChannel() {
      * `projects/{project}/location/{location}/channels/{channel_id}` format.
      * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for channel. */ - public com.google.protobuf.ByteString - getChannelBytes() { + public com.google.protobuf.ByteString getChannelBytes() { java.lang.Object ref = channel_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channel_ = b; return b; } else { @@ -1034,6 +1107,8 @@ public java.lang.String getChannel() { } } /** + * + * *
      * Required. The name of the connected subscriber Channel.
      * This is a weak reference to avoid cross project and cross accounts
@@ -1041,21 +1116,25 @@ public java.lang.String getChannel() {
      * `projects/{project}/location/{location}/channels/{channel_id}` format.
      * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The channel to set. * @return This builder for chaining. */ - public Builder setChannel( - java.lang.String value) { + public Builder setChannel(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + channel_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the connected subscriber Channel.
      * This is a weak reference to avoid cross project and cross accounts
@@ -1063,16 +1142,21 @@ public Builder setChannel(
      * `projects/{project}/location/{location}/channels/{channel_id}` format.
      * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearChannel() { - + channel_ = getDefaultInstance().getChannel(); onChanged(); return this; } /** + * + * *
      * Required. The name of the connected subscriber Channel.
      * This is a weak reference to avoid cross project and cross accounts
@@ -1080,17 +1164,19 @@ public Builder clearChannel() {
      * `projects/{project}/location/{location}/channels/{channel_id}` format.
      * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for channel to set. * @return This builder for chaining. */ - public Builder setChannelBytes( - com.google.protobuf.ByteString value) { + public Builder setChannelBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + channel_ = value; onChanged(); return this; @@ -1098,39 +1184,58 @@ public Builder setChannelBytes( private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return createTimeBuilder_ != null || createTime_ != null; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { @@ -1146,14 +1251,17 @@ public Builder setCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setCreateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); onChanged(); @@ -1164,17 +1272,21 @@ public Builder setCreateTime( return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (createTime_ != null) { createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); } else { createTime_ = value; } @@ -1186,11 +1298,15 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearCreateTime() { if (createTimeBuilder_ == null) { @@ -1204,48 +1320,64 @@ public Builder clearCreateTime() { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - + onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { - return createTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { - createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), - getParentForChildren(), - isClean()); + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; @@ -1253,39 +1385,58 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { private com.google.protobuf.Timestamp updateTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ public boolean hasUpdateTime() { return updateTimeBuilder_ != null || updateTime_ != null; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } else { return updateTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { @@ -1301,14 +1452,17 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setUpdateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (updateTimeBuilder_ == null) { updateTime_ = builderForValue.build(); onChanged(); @@ -1319,17 +1473,21 @@ public Builder setUpdateTime( return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { if (updateTime_ != null) { updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); } else { updateTime_ = value; } @@ -1341,11 +1499,15 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearUpdateTime() { if (updateTimeBuilder_ == null) { @@ -1359,48 +1521,64 @@ public Builder clearUpdateTime() { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - + onChanged(); return getUpdateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (updateTimeBuilder_ != null) { return updateTimeBuilder_.getMessageOrBuilder(); } else { - return updateTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getUpdateTimeFieldBuilder() { if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), - getParentForChildren(), - isClean()); + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); updateTime_ = null; } return updateTimeBuilder_; @@ -1408,6 +1586,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { private java.lang.Object activationToken_ = ""; /** + * + * *
      * Input only. Activation token for the channel. The token will be used
      * during the creation of ChannelConnection to bind the channel with the
@@ -1415,13 +1595,13 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
      * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return The activationToken. */ public java.lang.String getActivationToken() { java.lang.Object ref = activationToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); activationToken_ = s; return s; @@ -1430,6 +1610,8 @@ public java.lang.String getActivationToken() { } } /** + * + * *
      * Input only. Activation token for the channel. The token will be used
      * during the creation of ChannelConnection to bind the channel with the
@@ -1437,15 +1619,14 @@ public java.lang.String getActivationToken() {
      * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return The bytes for activationToken. */ - public com.google.protobuf.ByteString - getActivationTokenBytes() { + public com.google.protobuf.ByteString getActivationTokenBytes() { java.lang.Object ref = activationToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); activationToken_ = b; return b; } else { @@ -1453,6 +1634,8 @@ public java.lang.String getActivationToken() { } } /** + * + * *
      * Input only. Activation token for the channel. The token will be used
      * during the creation of ChannelConnection to bind the channel with the
@@ -1460,20 +1643,22 @@ public java.lang.String getActivationToken() {
      * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @param value The activationToken to set. * @return This builder for chaining. */ - public Builder setActivationToken( - java.lang.String value) { + public Builder setActivationToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + activationToken_ = value; onChanged(); return this; } /** + * + * *
      * Input only. Activation token for the channel. The token will be used
      * during the creation of ChannelConnection to bind the channel with the
@@ -1481,15 +1666,18 @@ public Builder setActivationToken(
      * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearActivationToken() { - + activationToken_ = getDefaultInstance().getActivationToken(); onChanged(); return this; } /** + * + * *
      * Input only. Activation token for the channel. The token will be used
      * during the creation of ChannelConnection to bind the channel with the
@@ -1497,23 +1685,23 @@ public Builder clearActivationToken() {
      * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @param value The bytes for activationToken to set. * @return This builder for chaining. */ - public Builder setActivationTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setActivationTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + activationToken_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1523,12 +1711,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ChannelConnection) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ChannelConnection) private static final com.google.cloud.eventarc.v1.ChannelConnection DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ChannelConnection(); } @@ -1537,27 +1725,27 @@ public static com.google.cloud.eventarc.v1.ChannelConnection getDefaultInstance( return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ChannelConnection parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ChannelConnection parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1572,6 +1760,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ChannelConnection getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java new file mode 100644 index 000000000000..c45b41d8b083 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionName.java @@ -0,0 +1,231 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class ChannelConnectionName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_CHANNEL_CONNECTION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/channelConnections/{channel_connection}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String channelConnection; + + @Deprecated + protected ChannelConnectionName() { + project = null; + location = null; + channelConnection = null; + } + + private ChannelConnectionName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + channelConnection = Preconditions.checkNotNull(builder.getChannelConnection()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getChannelConnection() { + return channelConnection; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static ChannelConnectionName of( + String project, String location, String channelConnection) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setChannelConnection(channelConnection) + .build(); + } + + public static String format(String project, String location, String channelConnection) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setChannelConnection(channelConnection) + .build() + .toString(); + } + + public static ChannelConnectionName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_CHANNEL_CONNECTION.validatedMatch( + formattedString, "ChannelConnectionName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), matchMap.get("location"), matchMap.get("channel_connection")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List values) { + List list = new ArrayList<>(values.size()); + for (ChannelConnectionName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_CHANNEL_CONNECTION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (channelConnection != null) { + fieldMapBuilder.put("channel_connection", channelConnection); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_CHANNEL_CONNECTION.instantiate( + "project", project, "location", location, "channel_connection", channelConnection); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + ChannelConnectionName that = ((ChannelConnectionName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.channelConnection, that.channelConnection); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(channelConnection); + return h; + } + + /** + * Builder for projects/{project}/locations/{location}/channelConnections/{channel_connection}. + */ + public static class Builder { + private String project; + private String location; + private String channelConnection; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getChannelConnection() { + return channelConnection; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setChannelConnection(String channelConnection) { + this.channelConnection = channelConnection; + return this; + } + + private Builder(ChannelConnectionName channelConnectionName) { + this.project = channelConnectionName.project; + this.location = channelConnectionName.location; + this.channelConnection = channelConnectionName.channelConnection; + } + + public ChannelConnectionName build() { + return new ChannelConnectionName(this); + } + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java similarity index 79% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java index 6274b42a413c..10fc0dc94580 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionOrBuilder.java @@ -3,53 +3,66 @@ package com.google.cloud.eventarc.v1; -public interface ChannelConnectionOrBuilder extends +public interface ChannelConnectionOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ChannelConnection) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the connection.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the connection.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * Output only. Server assigned ID of the resource.
    * The server guarantees uniqueness and immutability until deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ java.lang.String getUid(); /** + * + * *
    * Output only. Server assigned ID of the resource.
    * The server guarantees uniqueness and immutability until deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ - com.google.protobuf.ByteString - getUidBytes(); + com.google.protobuf.ByteString getUidBytes(); /** + * + * *
    * Required. The name of the connected subscriber Channel.
    * This is a weak reference to avoid cross project and cross accounts
@@ -57,11 +70,16 @@ public interface ChannelConnectionOrBuilder extends
    * `projects/{project}/location/{location}/channels/{channel_id}` format.
    * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The channel. */ java.lang.String getChannel(); /** + * + * *
    * Required. The name of the connected subscriber Channel.
    * This is a weak reference to avoid cross project and cross accounts
@@ -69,67 +87,93 @@ public interface ChannelConnectionOrBuilder extends
    * `projects/{project}/location/{location}/channels/{channel_id}` format.
    * 
* - * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string channel = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for channel. */ - com.google.protobuf.ByteString - getChannelBytes(); + com.google.protobuf.ByteString getChannelBytes(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ boolean hasCreateTime(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ com.google.protobuf.Timestamp getCreateTime(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ boolean hasUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ com.google.protobuf.Timestamp getUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); /** + * + * *
    * Input only. Activation token for the channel. The token will be used
    * during the creation of ChannelConnection to bind the channel with the
@@ -137,10 +181,13 @@ public interface ChannelConnectionOrBuilder extends
    * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return The activationToken. */ java.lang.String getActivationToken(); /** + * + * *
    * Input only. Activation token for the channel. The token will be used
    * during the creation of ChannelConnection to bind the channel with the
@@ -148,8 +195,8 @@ public interface ChannelConnectionOrBuilder extends
    * 
* * string activation_token = 8 [(.google.api.field_behavior) = INPUT_ONLY]; + * * @return The bytes for activationToken. */ - com.google.protobuf.ByteString - getActivationTokenBytes(); + com.google.protobuf.ByteString getActivationTokenBytes(); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java new file mode 100644 index 000000000000..6805c2edfd02 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java @@ -0,0 +1,79 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel_connection.proto + +package com.google.cloud.eventarc.v1; + +public final class ChannelConnectionProto { + private ChannelConnectionProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n1google/cloud/eventarc/v1/channel_conne" + + "ction.proto\022\030google.cloud.eventarc.v1\032\037g" + + "oogle/api/field_behavior.proto\032\031google/a" + + "pi/resource.proto\032\037google/protobuf/times" + + "tamp.proto\"\247\003\n\021ChannelConnection\022\021\n\004name" + + "\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 \001(\tB\003\340A\003\0228\n\007channel" + + "\030\005 \001(\tB\'\340A\002\372A!\n\037eventarc.googleapis.com/" + + "Channel\0224\n\013create_time\030\006 \001(\0132\032.google.pr" + + "otobuf.TimestampB\003\340A\003\0224\n\013update_time\030\007 \001" + + "(\0132\032.google.protobuf.TimestampB\003\340A\003\022\035\n\020a" + + "ctivation_token\030\010 \001(\tB\003\340A\004:\247\001\352A\243\001\n)event" + + "arc.googleapis.com/ChannelConnection\022Opr" + + "ojects/{project}/locations/{location}/ch" + + "annelConnections/{channel_connection}*\022c" + + "hannelConnections2\021channelConnectionB\316\001\n" + + "\034com.google.cloud.eventarc.v1B\026ChannelCo" + + "nnectionProtoP\001Z@google.golang.org/genpr" + + "oto/googleapis/cloud/eventarc/v1;eventar" + + "c\252\002\030Google.Cloud.Eventarc.V1\312\002\030Google\\Cl" + + "oud\\Eventarc\\V1\352\002\033Google::Cloud::Eventar" + + "c::V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor, + new java.lang.String[] { + "Name", "Uid", "Channel", "CreateTime", "UpdateTime", "ActivationToken", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java new file mode 100644 index 000000000000..fbc904bb8f84 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelName.java @@ -0,0 +1,223 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class ChannelName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_CHANNEL = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/channels/{channel}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String channel; + + @Deprecated + protected ChannelName() { + project = null; + location = null; + channel = null; + } + + private ChannelName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + channel = Preconditions.checkNotNull(builder.getChannel()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getChannel() { + return channel; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static ChannelName of(String project, String location, String channel) { + return newBuilder().setProject(project).setLocation(location).setChannel(channel).build(); + } + + public static String format(String project, String location, String channel) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setChannel(channel) + .build() + .toString(); + } + + public static ChannelName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_CHANNEL.validatedMatch( + formattedString, "ChannelName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("channel")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List values) { + List list = new ArrayList<>(values.size()); + for (ChannelName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_CHANNEL.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (channel != null) { + fieldMapBuilder.put("channel", channel); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_CHANNEL.instantiate( + "project", project, "location", location, "channel", channel); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + ChannelName that = ((ChannelName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.channel, that.channel); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(channel); + return h; + } + + /** Builder for projects/{project}/locations/{location}/channels/{channel}. */ + public static class Builder { + private String project; + private String location; + private String channel; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getChannel() { + return channel; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setChannel(String channel) { + this.channel = channel; + return this; + } + + private Builder(ChannelName channelName) { + this.project = channelName.project; + this.location = channelName.location; + this.channel = channelName.channel; + } + + public ChannelName build() { + return new ChannelName(this); + } + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java similarity index 81% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java index df7b314924be..e8c777175ab1 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface ChannelOrBuilder extends +public interface ChannelOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Channel) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The resource name of the channel. Must be unique within the
    * location on the project and must be in
@@ -15,10 +18,13 @@ public interface ChannelOrBuilder extends
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The resource name of the channel. Must be unique within the
    * location on the project and must be in
@@ -26,12 +32,14 @@ public interface ChannelOrBuilder extends
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * Output only. Server assigned unique identifier for the channel. The value
    * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -39,10 +47,13 @@ public interface ChannelOrBuilder extends
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ java.lang.String getUid(); /** + * + * *
    * Output only. Server assigned unique identifier for the channel. The value
    * is a UUID4 string and guaranteed to remain unchanged until the resource is
@@ -50,66 +61,90 @@ public interface ChannelOrBuilder extends
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ - com.google.protobuf.ByteString - getUidBytes(); + com.google.protobuf.ByteString getUidBytes(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ boolean hasCreateTime(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ com.google.protobuf.Timestamp getCreateTime(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ boolean hasUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ com.google.protobuf.Timestamp getUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); /** + * + * *
    * The name of the event provider (e.g. Eventarc SaaS partner) associated
    * with the channel. This provider will be granted permissions to publish
@@ -118,10 +153,13 @@ public interface ChannelOrBuilder extends
    * 
* * string provider = 7; + * * @return The provider. */ java.lang.String getProvider(); /** + * + * *
    * The name of the event provider (e.g. Eventarc SaaS partner) associated
    * with the channel. This provider will be granted permissions to publish
@@ -130,12 +168,14 @@ public interface ChannelOrBuilder extends
    * 
* * string provider = 7; + * * @return The bytes for provider. */ - com.google.protobuf.ByteString - getProviderBytes(); + com.google.protobuf.ByteString getProviderBytes(); /** + * + * *
    * Output only. The name of the Pub/Sub topic created and managed by
    * Eventarc system as a transport for the event delivery. Format:
@@ -143,10 +183,13 @@ public interface ChannelOrBuilder extends
    * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return Whether the pubsubTopic field is set. */ boolean hasPubsubTopic(); /** + * + * *
    * Output only. The name of the Pub/Sub topic created and managed by
    * Eventarc system as a transport for the event delivery. Format:
@@ -154,10 +197,13 @@ public interface ChannelOrBuilder extends
    * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The pubsubTopic. */ java.lang.String getPubsubTopic(); /** + * + * *
    * Output only. The name of the Pub/Sub topic created and managed by
    * Eventarc system as a transport for the event delivery. Format:
@@ -165,53 +211,70 @@ public interface ChannelOrBuilder extends
    * 
* * string pubsub_topic = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for pubsubTopic. */ - com.google.protobuf.ByteString - getPubsubTopicBytes(); + com.google.protobuf.ByteString getPubsubTopicBytes(); /** + * + * *
    * Output only. The state of a Channel.
    * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The enum numeric value on the wire for state. */ int getStateValue(); /** + * + * *
    * Output only. The state of a Channel.
    * 
* - * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.cloud.eventarc.v1.Channel.State state = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The state. */ com.google.cloud.eventarc.v1.Channel.State getState(); /** + * + * *
    * Output only. The activation token for the channel. The token must be used
    * by the provider to register the channel for publishing.
    * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The activationToken. */ java.lang.String getActivationToken(); /** + * + * *
    * Output only. The activation token for the channel. The token must be used
    * by the provider to register the channel for publishing.
    * 
* * string activation_token = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for activationToken. */ - com.google.protobuf.ByteString - getActivationTokenBytes(); + com.google.protobuf.ByteString getActivationTokenBytes(); /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -219,11 +282,16 @@ public interface ChannelOrBuilder extends
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The cryptoKeyName. */ java.lang.String getCryptoKeyName(); /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -231,11 +299,13 @@ public interface ChannelOrBuilder extends
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 11 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for cryptoKeyName. */ - com.google.protobuf.ByteString - getCryptoKeyNameBytes(); + com.google.protobuf.ByteString getCryptoKeyNameBytes(); public com.google.cloud.eventarc.v1.Channel.TransportCase getTransportCase(); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java new file mode 100644 index 000000000000..dc19885e1acb --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java @@ -0,0 +1,91 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/channel.proto + +package com.google.cloud.eventarc.v1; + +public final class ChannelProto { + private ChannelProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Channel_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n&google/cloud/eventarc/v1/channel.proto" + + "\022\030google.cloud.eventarc.v1\032\037google/api/f" + + "ield_behavior.proto\032\031google/api/resource" + + ".proto\032\037google/protobuf/timestamp.proto\"" + + "\262\004\n\007Channel\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 " + + "\001(\tB\003\340A\003\0224\n\013create_time\030\005 \001(\0132\032.google.p" + + "rotobuf.TimestampB\003\340A\003\0224\n\013update_time\030\006 " + + "\001(\0132\032.google.protobuf.TimestampB\003\340A\003\022\020\n\010" + + "provider\030\007 \001(\t\022\033\n\014pubsub_topic\030\010 \001(\tB\003\340A" + + "\003H\000\022;\n\005state\030\t \001(\0162\'.google.cloud.eventa" + + "rc.v1.Channel.StateB\003\340A\003\022\035\n\020activation_t" + + "oken\030\n \001(\tB\003\340A\003\022B\n\017crypto_key_name\030\013 \001(\t" + + "B)\340A\001\372A#\n!cloudkms.googleapis.com/Crypto" + + "Key\"E\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n\007P" + + "ENDING\020\001\022\n\n\006ACTIVE\020\002\022\014\n\010INACTIVE\020\003:s\352Ap\n" + + "\037eventarc.googleapis.com/Channel\022:projec" + + "ts/{project}/locations/{location}/channe" + + "ls/{channel}*\010channels2\007channelB\013\n\ttrans" + + "portB\304\001\n\034com.google.cloud.eventarc.v1B\014C" + + "hannelProtoP\001Z@google.golang.org/genprot" + + "o/googleapis/cloud/eventarc/v1;eventarc\252" + + "\002\030Google.Cloud.Eventarc.V1\312\002\030Google\\Clou" + + "d\\Eventarc\\V1\352\002\033Google::Cloud::Eventarc:" + + ":V1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_Channel_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_Channel_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "CreateTime", + "UpdateTime", + "Provider", + "PubsubTopic", + "State", + "ActivationToken", + "CryptoKeyName", + "Transport", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java similarity index 70% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java index 005bc657a2c1..b11971c143b2 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRun.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * Represents a Cloud Run destination.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.CloudRun} */ -public final class CloudRun extends - com.google.protobuf.GeneratedMessageV3 implements +public final class CloudRun extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CloudRun) CloudRunOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use CloudRun.newBuilder() to construct. private CloudRun(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private CloudRun() { service_ = ""; path_ = ""; @@ -27,32 +30,35 @@ private CloudRun() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new CloudRun(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CloudRun.class, com.google.cloud.eventarc.v1.CloudRun.Builder.class); + com.google.cloud.eventarc.v1.CloudRun.class, + com.google.cloud.eventarc.v1.CloudRun.Builder.class); } public static final int SERVICE_FIELD_NUMBER = 1; private volatile java.lang.Object service_; /** + * + * *
    * Required. The name of the Cloud Run service being addressed. See
    * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -60,7 +66,10 @@ protected java.lang.Object newInstance(
    * can be addressed.
    * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The service. */ @java.lang.Override @@ -69,14 +78,15 @@ public java.lang.String getService() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); service_ = s; return s; } } /** + * + * *
    * Required. The name of the Cloud Run service being addressed. See
    * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -84,17 +94,18 @@ public java.lang.String getService() {
    * can be addressed.
    * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for service. */ @java.lang.Override - public com.google.protobuf.ByteString - getServiceBytes() { + public com.google.protobuf.ByteString getServiceBytes() { java.lang.Object ref = service_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); service_ = b; return b; } else { @@ -105,6 +116,8 @@ public java.lang.String getService() { public static final int PATH_FIELD_NUMBER = 2; private volatile java.lang.Object path_; /** + * + * *
    * Optional. The relative path on the Cloud Run service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -112,6 +125,7 @@ public java.lang.String getService() {
    * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The path. */ @java.lang.Override @@ -120,14 +134,15 @@ public java.lang.String getPath() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); path_ = s; return s; } } /** + * + * *
    * Optional. The relative path on the Cloud Run service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -135,16 +150,15 @@ public java.lang.String getPath() {
    * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for path. */ @java.lang.Override - public com.google.protobuf.ByteString - getPathBytes() { + public com.google.protobuf.ByteString getPathBytes() { java.lang.Object ref = path_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); path_ = b; return b; } else { @@ -155,11 +169,14 @@ public java.lang.String getPath() { public static final int REGION_FIELD_NUMBER = 3; private volatile java.lang.Object region_; /** + * + * *
    * Required. The region the Cloud Run service is deployed in.
    * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The region. */ @java.lang.Override @@ -168,29 +185,29 @@ public java.lang.String getRegion() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); region_ = s; return s; } } /** + * + * *
    * Required. The region the Cloud Run service is deployed in.
    * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for region. */ @java.lang.Override - public com.google.protobuf.ByteString - getRegionBytes() { + public com.google.protobuf.ByteString getRegionBytes() { java.lang.Object ref = region_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); region_ = b; return b; } else { @@ -199,6 +216,7 @@ public java.lang.String getRegion() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -210,8 +228,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, service_); } @@ -247,19 +264,16 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.CloudRun)) { return super.equals(obj); } com.google.cloud.eventarc.v1.CloudRun other = (com.google.cloud.eventarc.v1.CloudRun) obj; - if (!getService() - .equals(other.getService())) return false; - if (!getPath() - .equals(other.getPath())) return false; - if (!getRegion() - .equals(other.getRegion())) return false; + if (!getService().equals(other.getService())) return false; + if (!getPath().equals(other.getPath())) return false; + if (!getRegion().equals(other.getRegion())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -282,130 +296,135 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.CloudRun parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CloudRun parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CloudRun parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CloudRun parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CloudRun parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.CloudRun prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Represents a Cloud Run destination.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.CloudRun} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CloudRun) com.google.cloud.eventarc.v1.CloudRunOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CloudRun.class, com.google.cloud.eventarc.v1.CloudRun.Builder.class); + com.google.cloud.eventarc.v1.CloudRun.class, + com.google.cloud.eventarc.v1.CloudRun.Builder.class); } // Construct using com.google.cloud.eventarc.v1.CloudRun.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -419,9 +438,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; } @java.lang.Override @@ -440,7 +459,8 @@ public com.google.cloud.eventarc.v1.CloudRun build() { @java.lang.Override public com.google.cloud.eventarc.v1.CloudRun buildPartial() { - com.google.cloud.eventarc.v1.CloudRun result = new com.google.cloud.eventarc.v1.CloudRun(this); + com.google.cloud.eventarc.v1.CloudRun result = + new com.google.cloud.eventarc.v1.CloudRun(this); result.service_ = service_; result.path_ = path_; result.region_ = region_; @@ -452,38 +472,39 @@ public com.google.cloud.eventarc.v1.CloudRun buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.CloudRun) { - return mergeFrom((com.google.cloud.eventarc.v1.CloudRun)other); + return mergeFrom((com.google.cloud.eventarc.v1.CloudRun) other); } else { super.mergeFrom(other); return this; @@ -530,27 +551,31 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - service_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: { - path_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: { - region_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + service_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + path_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + region_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -563,6 +588,8 @@ public Builder mergeFrom( private java.lang.Object service_ = ""; /** + * + * *
      * Required. The name of the Cloud Run service being addressed. See
      * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -570,14 +597,16 @@ public Builder mergeFrom(
      * can be addressed.
      * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The service. */ public java.lang.String getService() { java.lang.Object ref = service_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); service_ = s; return s; @@ -586,6 +615,8 @@ public java.lang.String getService() { } } /** + * + * *
      * Required. The name of the Cloud Run service being addressed. See
      * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -593,16 +624,17 @@ public java.lang.String getService() {
      * can be addressed.
      * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for service. */ - public com.google.protobuf.ByteString - getServiceBytes() { + public com.google.protobuf.ByteString getServiceBytes() { java.lang.Object ref = service_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); service_ = b; return b; } else { @@ -610,6 +642,8 @@ public java.lang.String getService() { } } /** + * + * *
      * Required. The name of the Cloud Run service being addressed. See
      * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -617,21 +651,25 @@ public java.lang.String getService() {
      * can be addressed.
      * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The service to set. * @return This builder for chaining. */ - public Builder setService( - java.lang.String value) { + public Builder setService(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + service_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the Cloud Run service being addressed. See
      * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -639,16 +677,21 @@ public Builder setService(
      * can be addressed.
      * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearService() { - + service_ = getDefaultInstance().getService(); onChanged(); return this; } /** + * + * *
      * Required. The name of the Cloud Run service being addressed. See
      * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -656,17 +699,19 @@ public Builder clearService() {
      * can be addressed.
      * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for service to set. * @return This builder for chaining. */ - public Builder setServiceBytes( - com.google.protobuf.ByteString value) { + public Builder setServiceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + service_ = value; onChanged(); return this; @@ -674,6 +719,8 @@ public Builder setServiceBytes( private java.lang.Object path_ = ""; /** + * + * *
      * Optional. The relative path on the Cloud Run service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -681,13 +728,13 @@ public Builder setServiceBytes(
      * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The path. */ public java.lang.String getPath() { java.lang.Object ref = path_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); path_ = s; return s; @@ -696,6 +743,8 @@ public java.lang.String getPath() { } } /** + * + * *
      * Optional. The relative path on the Cloud Run service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -703,15 +752,14 @@ public java.lang.String getPath() {
      * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for path. */ - public com.google.protobuf.ByteString - getPathBytes() { + public com.google.protobuf.ByteString getPathBytes() { java.lang.Object ref = path_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); path_ = b; return b; } else { @@ -719,6 +767,8 @@ public java.lang.String getPath() { } } /** + * + * *
      * Optional. The relative path on the Cloud Run service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -726,20 +776,22 @@ public java.lang.String getPath() {
      * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The path to set. * @return This builder for chaining. */ - public Builder setPath( - java.lang.String value) { + public Builder setPath(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + path_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The relative path on the Cloud Run service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -747,15 +799,18 @@ public Builder setPath(
      * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return This builder for chaining. */ public Builder clearPath() { - + path_ = getDefaultInstance().getPath(); onChanged(); return this; } /** + * + * *
      * Optional. The relative path on the Cloud Run service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -763,16 +818,16 @@ public Builder clearPath() {
      * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The bytes for path to set. * @return This builder for chaining. */ - public Builder setPathBytes( - com.google.protobuf.ByteString value) { + public Builder setPathBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + path_ = value; onChanged(); return this; @@ -780,18 +835,20 @@ public Builder setPathBytes( private java.lang.Object region_ = ""; /** + * + * *
      * Required. The region the Cloud Run service is deployed in.
      * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The region. */ public java.lang.String getRegion() { java.lang.Object ref = region_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); region_ = s; return s; @@ -800,20 +857,21 @@ public java.lang.String getRegion() { } } /** + * + * *
      * Required. The region the Cloud Run service is deployed in.
      * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for region. */ - public com.google.protobuf.ByteString - getRegionBytes() { + public com.google.protobuf.ByteString getRegionBytes() { java.lang.Object ref = region_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); region_ = b; return b; } else { @@ -821,61 +879,68 @@ public java.lang.String getRegion() { } } /** + * + * *
      * Required. The region the Cloud Run service is deployed in.
      * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The region to set. * @return This builder for chaining. */ - public Builder setRegion( - java.lang.String value) { + public Builder setRegion(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + region_ = value; onChanged(); return this; } /** + * + * *
      * Required. The region the Cloud Run service is deployed in.
      * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearRegion() { - + region_ = getDefaultInstance().getRegion(); onChanged(); return this; } /** + * + * *
      * Required. The region the Cloud Run service is deployed in.
      * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for region to set. * @return This builder for chaining. */ - public Builder setRegionBytes( - com.google.protobuf.ByteString value) { + public Builder setRegionBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + region_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -885,12 +950,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CloudRun) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CloudRun) private static final com.google.cloud.eventarc.v1.CloudRun DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CloudRun(); } @@ -899,27 +964,27 @@ public static com.google.cloud.eventarc.v1.CloudRun getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CloudRun parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CloudRun parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -934,6 +999,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.CloudRun getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java similarity index 79% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java index aed2831d21bd..9a60b601fa4f 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CloudRunOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface CloudRunOrBuilder extends +public interface CloudRunOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CloudRun) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the Cloud Run service being addressed. See
    * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -15,11 +18,16 @@ public interface CloudRunOrBuilder extends
    * can be addressed.
    * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The service. */ java.lang.String getService(); /** + * + * *
    * Required. The name of the Cloud Run service being addressed. See
    * https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services.
@@ -27,13 +35,17 @@ public interface CloudRunOrBuilder extends
    * can be addressed.
    * 
* - * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string service = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for service. */ - com.google.protobuf.ByteString - getServiceBytes(); + com.google.protobuf.ByteString getServiceBytes(); /** + * + * *
    * Optional. The relative path on the Cloud Run service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -41,10 +53,13 @@ public interface CloudRunOrBuilder extends
    * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The path. */ java.lang.String getPath(); /** + * + * *
    * Optional. The relative path on the Cloud Run service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -52,28 +67,33 @@ public interface CloudRunOrBuilder extends
    * 
* * string path = 2 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for path. */ - com.google.protobuf.ByteString - getPathBytes(); + com.google.protobuf.ByteString getPathBytes(); /** + * + * *
    * Required. The region the Cloud Run service is deployed in.
    * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The region. */ java.lang.String getRegion(); /** + * + * *
    * Required. The region the Cloud Run service is deployed in.
    * 
* * string region = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for region. */ - com.google.protobuf.ByteString - getRegionBytes(); + com.google.protobuf.ByteString getRegionBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java similarity index 64% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java index d57a76796b40..d01746ca171d 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequest.java @@ -4,21 +4,25 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the CreateChannelConnection method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelConnectionRequest} */ -public final class CreateChannelConnectionRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class CreateChannelConnectionRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CreateChannelConnectionRequest) CreateChannelConnectionRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use CreateChannelConnectionRequest.newBuilder() to construct. - private CreateChannelConnectionRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + private CreateChannelConnectionRequest( + com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private CreateChannelConnectionRequest() { parent_ = ""; channelConnectionId_ = ""; @@ -26,37 +30,43 @@ private CreateChannelConnectionRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new CreateChannelConnectionRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.Builder.class); + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent collection in which to add this channel connection.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -65,29 +75,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent collection in which to add this channel connection.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -98,11 +110,16 @@ public java.lang.String getParent() { public static final int CHANNEL_CONNECTION_FIELD_NUMBER = 2; private com.google.cloud.eventarc.v1.ChannelConnection channelConnection_; /** + * + * *
    * Required. Channel connection to create.
    * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the channelConnection field is set. */ @java.lang.Override @@ -110,23 +127,34 @@ public boolean hasChannelConnection() { return channelConnection_ != null; } /** + * + * *
    * Required. Channel connection to create.
    * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The channelConnection. */ @java.lang.Override public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection() { - return channelConnection_ == null ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() : channelConnection_; + return channelConnection_ == null + ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() + : channelConnection_; } /** + * + * *
    * Required. Channel connection to create.
    * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionOrBuilder() { @@ -136,11 +164,14 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect public static final int CHANNEL_CONNECTION_ID_FIELD_NUMBER = 3; private volatile java.lang.Object channelConnectionId_; /** + * + * *
    * Required. The user-provided ID to be assigned to the channel connection.
    * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The channelConnectionId. */ @java.lang.Override @@ -149,29 +180,29 @@ public java.lang.String getChannelConnectionId() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channelConnectionId_ = s; return s; } } /** + * + * *
    * Required. The user-provided ID to be assigned to the channel connection.
    * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for channelConnectionId. */ @java.lang.Override - public com.google.protobuf.ByteString - getChannelConnectionIdBytes() { + public com.google.protobuf.ByteString getChannelConnectionIdBytes() { java.lang.Object ref = channelConnectionId_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channelConnectionId_ = b; return b; } else { @@ -180,6 +211,7 @@ public java.lang.String getChannelConnectionId() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -191,8 +223,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -215,8 +246,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (channelConnection_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getChannelConnection()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getChannelConnection()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channelConnectionId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, channelConnectionId_); @@ -229,22 +259,20 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.CreateChannelConnectionRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest other = (com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) obj; + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest other = + (com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) obj; - if (!getParent() - .equals(other.getParent())) return false; + if (!getParent().equals(other.getParent())) return false; if (hasChannelConnection() != other.hasChannelConnection()) return false; if (hasChannelConnection()) { - if (!getChannelConnection() - .equals(other.getChannelConnection())) return false; + if (!getChannelConnection().equals(other.getChannelConnection())) return false; } - if (!getChannelConnectionId() - .equals(other.getChannelConnectionId())) return false; + if (!getChannelConnectionId().equals(other.getChannelConnectionId())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -270,129 +298,136 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.cloud.eventarc.v1.CreateChannelConnectionRequest prototype) { + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the CreateChannelConnection method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelConnectionRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CreateChannelConnectionRequest) com.google.cloud.eventarc.v1.CreateChannelConnectionRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.Builder.class); + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -410,9 +445,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; } @java.lang.Override @@ -431,7 +466,8 @@ public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest buildPartial() { - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest result = new com.google.cloud.eventarc.v1.CreateChannelConnectionRequest(this); + com.google.cloud.eventarc.v1.CreateChannelConnectionRequest result = + new com.google.cloud.eventarc.v1.CreateChannelConnectionRequest(this); result.parent_ = parent_; if (channelConnectionBuilder_ == null) { result.channelConnection_ = channelConnection_; @@ -447,38 +483,39 @@ public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest buildPartial( public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.CreateChannelConnectionRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) other); } else { super.mergeFrom(other); return this; @@ -486,7 +523,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.CreateChannelConnectionRequest other) { - if (other == com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -524,29 +562,32 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); + case 10: + { + parent_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 18: { - input.readMessage( - getChannelConnectionFieldBuilder().getBuilder(), - extensionRegistry); + break; + } // case 10 + case 18: + { + input.readMessage( + getChannelConnectionFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 18 - case 26: { - channelConnectionId_ = input.readStringRequireUtf8(); + break; + } // case 18 + case 26: + { + channelConnectionId_ = input.readStringRequireUtf8(); - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -559,18 +600,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent collection in which to add this channel connection.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -579,20 +624,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection in which to add this channel connection.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -600,54 +648,67 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection in which to add this channel connection.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent collection in which to add this channel connection.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent collection in which to add this channel connection.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; @@ -655,39 +716,58 @@ public Builder setParentBytes( private com.google.cloud.eventarc.v1.ChannelConnection channelConnection_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.ChannelConnection, com.google.cloud.eventarc.v1.ChannelConnection.Builder, com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> channelConnectionBuilder_; + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + channelConnectionBuilder_; /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the channelConnection field is set. */ public boolean hasChannelConnection() { return channelConnectionBuilder_ != null || channelConnection_ != null; } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The channelConnection. */ public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection() { if (channelConnectionBuilder_ == null) { - return channelConnection_ == null ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() : channelConnection_; + return channelConnection_ == null + ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() + : channelConnection_; } else { return channelConnectionBuilder_.getMessage(); } } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setChannelConnection(com.google.cloud.eventarc.v1.ChannelConnection value) { if (channelConnectionBuilder_ == null) { @@ -703,11 +783,15 @@ public Builder setChannelConnection(com.google.cloud.eventarc.v1.ChannelConnecti return this; } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setChannelConnection( com.google.cloud.eventarc.v1.ChannelConnection.Builder builderForValue) { @@ -721,17 +805,23 @@ public Builder setChannelConnection( return this; } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder mergeChannelConnection(com.google.cloud.eventarc.v1.ChannelConnection value) { if (channelConnectionBuilder_ == null) { if (channelConnection_ != null) { channelConnection_ = - com.google.cloud.eventarc.v1.ChannelConnection.newBuilder(channelConnection_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.ChannelConnection.newBuilder(channelConnection_) + .mergeFrom(value) + .buildPartial(); } else { channelConnection_ = value; } @@ -743,11 +833,15 @@ public Builder mergeChannelConnection(com.google.cloud.eventarc.v1.ChannelConnec return this; } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder clearChannelConnection() { if (channelConnectionBuilder_ == null) { @@ -761,48 +855,64 @@ public Builder clearChannelConnection() { return this; } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.ChannelConnection.Builder getChannelConnectionBuilder() { - + onChanged(); return getChannelConnectionFieldBuilder().getBuilder(); } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionOrBuilder() { if (channelConnectionBuilder_ != null) { return channelConnectionBuilder_.getMessageOrBuilder(); } else { - return channelConnection_ == null ? - com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() : channelConnection_; + return channelConnection_ == null + ? com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance() + : channelConnection_; } } /** + * + * *
      * Required. Channel connection to create.
      * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.ChannelConnection, com.google.cloud.eventarc.v1.ChannelConnection.Builder, com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> getChannelConnectionFieldBuilder() { if (channelConnectionBuilder_ == null) { - channelConnectionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.ChannelConnection, com.google.cloud.eventarc.v1.ChannelConnection.Builder, com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>( - getChannelConnection(), - getParentForChildren(), - isClean()); + channelConnectionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>( + getChannelConnection(), getParentForChildren(), isClean()); channelConnection_ = null; } return channelConnectionBuilder_; @@ -810,18 +920,20 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect private java.lang.Object channelConnectionId_ = ""; /** + * + * *
      * Required. The user-provided ID to be assigned to the channel connection.
      * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The channelConnectionId. */ public java.lang.String getChannelConnectionId() { java.lang.Object ref = channelConnectionId_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channelConnectionId_ = s; return s; @@ -830,20 +942,21 @@ public java.lang.String getChannelConnectionId() { } } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel connection.
      * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for channelConnectionId. */ - public com.google.protobuf.ByteString - getChannelConnectionIdBytes() { + public com.google.protobuf.ByteString getChannelConnectionIdBytes() { java.lang.Object ref = channelConnectionId_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channelConnectionId_ = b; return b; } else { @@ -851,61 +964,68 @@ public java.lang.String getChannelConnectionId() { } } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel connection.
      * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The channelConnectionId to set. * @return This builder for chaining. */ - public Builder setChannelConnectionId( - java.lang.String value) { + public Builder setChannelConnectionId(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + channelConnectionId_ = value; onChanged(); return this; } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel connection.
      * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearChannelConnectionId() { - + channelConnectionId_ = getDefaultInstance().getChannelConnectionId(); onChanged(); return this; } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel connection.
      * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for channelConnectionId to set. * @return This builder for chaining. */ - public Builder setChannelConnectionIdBytes( - com.google.protobuf.ByteString value) { + public Builder setChannelConnectionIdBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + channelConnectionId_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -915,12 +1035,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CreateChannelConnectionRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CreateChannelConnectionRequest) private static final com.google.cloud.eventarc.v1.CreateChannelConnectionRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CreateChannelConnectionRequest(); } @@ -929,27 +1049,27 @@ public static com.google.cloud.eventarc.v1.CreateChannelConnectionRequest getDef return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateChannelConnectionRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateChannelConnectionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -964,6 +1084,4 @@ public com.google.protobuf.Parser getParserForTy public com.google.cloud.eventarc.v1.CreateChannelConnectionRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java similarity index 64% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java index 17c804f7885a..b7307d4dd89b 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelConnectionRequestOrBuilder.java @@ -3,74 +3,103 @@ package com.google.cloud.eventarc.v1; -public interface CreateChannelConnectionRequestOrBuilder extends +public interface CreateChannelConnectionRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CreateChannelConnectionRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent collection in which to add this channel connection.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent collection in which to add this channel connection.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * Required. Channel connection to create.
    * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the channelConnection field is set. */ boolean hasChannelConnection(); /** + * + * *
    * Required. Channel connection to create.
    * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The channelConnection. */ com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection(); /** + * + * *
    * Required. Channel connection to create.
    * 
* - * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.ChannelConnection channel_connection = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionOrBuilder(); /** + * + * *
    * Required. The user-provided ID to be assigned to the channel connection.
    * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The channelConnectionId. */ java.lang.String getChannelConnectionId(); /** + * + * *
    * Required. The user-provided ID to be assigned to the channel connection.
    * 
* * string channel_connection_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for channelConnectionId. */ - com.google.protobuf.ByteString - getChannelConnectionIdBytes(); + com.google.protobuf.ByteString getChannelConnectionIdBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java similarity index 66% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java index 29fa7d003d4e..0cb3b61286be 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the CreateChannel method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelRequest} */ -public final class CreateChannelRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class CreateChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CreateChannelRequest) CreateChannelRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use CreateChannelRequest.newBuilder() to construct. private CreateChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private CreateChannelRequest() { parent_ = ""; channelId_ = ""; @@ -26,37 +29,43 @@ private CreateChannelRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new CreateChannelRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CreateChannelRequest.class, com.google.cloud.eventarc.v1.CreateChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.CreateChannelRequest.class, + com.google.cloud.eventarc.v1.CreateChannelRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent collection in which to add this channel.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -65,29 +74,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent collection in which to add this channel.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -98,11 +109,15 @@ public java.lang.String getParent() { public static final int CHANNEL_FIELD_NUMBER = 2; private com.google.cloud.eventarc.v1.Channel channel_; /** + * + * *
    * Required. The channel to create.
    * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the channel field is set. */ @java.lang.Override @@ -110,11 +125,15 @@ public boolean hasChannel() { return channel_ != null; } /** + * + * *
    * Required. The channel to create.
    * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The channel. */ @java.lang.Override @@ -122,11 +141,14 @@ public com.google.cloud.eventarc.v1.Channel getChannel() { return channel_ == null ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; } /** + * + * *
    * Required. The channel to create.
    * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { @@ -136,11 +158,14 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { public static final int CHANNEL_ID_FIELD_NUMBER = 3; private volatile java.lang.Object channelId_; /** + * + * *
    * Required. The user-provided ID to be assigned to the channel.
    * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The channelId. */ @java.lang.Override @@ -149,29 +174,29 @@ public java.lang.String getChannelId() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channelId_ = s; return s; } } /** + * + * *
    * Required. The user-provided ID to be assigned to the channel.
    * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for channelId. */ @java.lang.Override - public com.google.protobuf.ByteString - getChannelIdBytes() { + public com.google.protobuf.ByteString getChannelIdBytes() { java.lang.Object ref = channelId_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channelId_ = b; return b; } else { @@ -182,12 +207,15 @@ public java.lang.String getChannelId() { public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; private boolean validateOnly_; /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -196,6 +224,7 @@ public boolean getValidateOnly() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -207,8 +236,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -234,15 +262,13 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (channel_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getChannel()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getChannel()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channelId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, channelId_); } if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, validateOnly_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -252,24 +278,21 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.CreateChannelRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.CreateChannelRequest other = (com.google.cloud.eventarc.v1.CreateChannelRequest) obj; + com.google.cloud.eventarc.v1.CreateChannelRequest other = + (com.google.cloud.eventarc.v1.CreateChannelRequest) obj; - if (!getParent() - .equals(other.getParent())) return false; + if (!getParent().equals(other.getParent())) return false; if (hasChannel() != other.hasChannel()) return false; if (hasChannel()) { - if (!getChannel() - .equals(other.getChannel())) return false; + if (!getChannel().equals(other.getChannel())) return false; } - if (!getChannelId() - .equals(other.getChannelId())) return false; - if (getValidateOnly() - != other.getValidateOnly()) return false; + if (!getChannelId().equals(other.getChannelId())) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -290,137 +313,142 @@ public int hashCode() { hash = (37 * hash) + CHANNEL_ID_FIELD_NUMBER; hash = (53 * hash) + getChannelId().hashCode(); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getValidateOnly()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CreateChannelRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateChannelRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.CreateChannelRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the CreateChannel method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.CreateChannelRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CreateChannelRequest) com.google.cloud.eventarc.v1.CreateChannelRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CreateChannelRequest.class, com.google.cloud.eventarc.v1.CreateChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.CreateChannelRequest.class, + com.google.cloud.eventarc.v1.CreateChannelRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.CreateChannelRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -440,9 +468,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; } @java.lang.Override @@ -461,7 +489,8 @@ public com.google.cloud.eventarc.v1.CreateChannelRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.CreateChannelRequest buildPartial() { - com.google.cloud.eventarc.v1.CreateChannelRequest result = new com.google.cloud.eventarc.v1.CreateChannelRequest(this); + com.google.cloud.eventarc.v1.CreateChannelRequest result = + new com.google.cloud.eventarc.v1.CreateChannelRequest(this); result.parent_ = parent_; if (channelBuilder_ == null) { result.channel_ = channel_; @@ -478,38 +507,39 @@ public com.google.cloud.eventarc.v1.CreateChannelRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.CreateChannelRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.CreateChannelRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.CreateChannelRequest) other); } else { super.mergeFrom(other); return this; @@ -517,7 +547,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.CreateChannelRequest other) { - if (other == com.google.cloud.eventarc.v1.CreateChannelRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.CreateChannelRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -558,34 +589,37 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); + case 10: + { + parent_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 18: { - input.readMessage( - getChannelFieldBuilder().getBuilder(), - extensionRegistry); + break; + } // case 10 + case 18: + { + input.readMessage(getChannelFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 18 - case 26: { - channelId_ = input.readStringRequireUtf8(); + break; + } // case 18 + case 26: + { + channelId_ = input.readStringRequireUtf8(); - break; - } // case 26 - case 32: { - validateOnly_ = input.readBool(); + break; + } // case 26 + case 32: + { + validateOnly_ = input.readBool(); - break; - } // case 32 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -598,18 +632,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent collection in which to add this channel.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -618,20 +656,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection in which to add this channel.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -639,54 +680,67 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection in which to add this channel.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent collection in which to add this channel.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent collection in which to add this channel.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; @@ -694,39 +748,58 @@ public Builder setParentBytes( private com.google.cloud.eventarc.v1.Channel channel_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder> channelBuilder_; + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + channelBuilder_; /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the channel field is set. */ public boolean hasChannel() { return channelBuilder_ != null || channel_ != null; } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The channel. */ public com.google.cloud.eventarc.v1.Channel getChannel() { if (channelBuilder_ == null) { - return channel_ == null ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; } else { return channelBuilder_.getMessage(); } } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setChannel(com.google.cloud.eventarc.v1.Channel value) { if (channelBuilder_ == null) { @@ -742,14 +815,17 @@ public Builder setChannel(com.google.cloud.eventarc.v1.Channel value) { return this; } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ - public Builder setChannel( - com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + public Builder setChannel(com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { if (channelBuilder_ == null) { channel_ = builderForValue.build(); onChanged(); @@ -760,17 +836,23 @@ public Builder setChannel( return this; } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder mergeChannel(com.google.cloud.eventarc.v1.Channel value) { if (channelBuilder_ == null) { if (channel_ != null) { channel_ = - com.google.cloud.eventarc.v1.Channel.newBuilder(channel_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.Channel.newBuilder(channel_) + .mergeFrom(value) + .buildPartial(); } else { channel_ = value; } @@ -782,11 +864,15 @@ public Builder mergeChannel(com.google.cloud.eventarc.v1.Channel value) { return this; } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder clearChannel() { if (channelBuilder_ == null) { @@ -800,48 +886,64 @@ public Builder clearChannel() { return this; } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.Channel.Builder getChannelBuilder() { - + onChanged(); return getChannelFieldBuilder().getBuilder(); } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { if (channelBuilder_ != null) { return channelBuilder_.getMessageOrBuilder(); } else { - return channel_ == null ? - com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; } } /** + * + * *
      * Required. The channel to create.
      * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder> + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> getChannelFieldBuilder() { if (channelBuilder_ == null) { - channelBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder>( - getChannel(), - getParentForChildren(), - isClean()); + channelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder>( + getChannel(), getParentForChildren(), isClean()); channel_ = null; } return channelBuilder_; @@ -849,18 +951,20 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { private java.lang.Object channelId_ = ""; /** + * + * *
      * Required. The user-provided ID to be assigned to the channel.
      * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The channelId. */ public java.lang.String getChannelId() { java.lang.Object ref = channelId_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channelId_ = s; return s; @@ -869,20 +973,21 @@ public java.lang.String getChannelId() { } } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel.
      * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for channelId. */ - public com.google.protobuf.ByteString - getChannelIdBytes() { + public com.google.protobuf.ByteString getChannelIdBytes() { java.lang.Object ref = channelId_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channelId_ = b; return b; } else { @@ -890,67 +995,77 @@ public java.lang.String getChannelId() { } } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel.
      * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The channelId to set. * @return This builder for chaining. */ - public Builder setChannelId( - java.lang.String value) { + public Builder setChannelId(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + channelId_ = value; onChanged(); return this; } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel.
      * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearChannelId() { - + channelId_ = getDefaultInstance().getChannelId(); onChanged(); return this; } /** + * + * *
      * Required. The user-provided ID to be assigned to the channel.
      * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for channelId to set. * @return This builder for chaining. */ - public Builder setChannelIdBytes( - com.google.protobuf.ByteString value) { + public Builder setChannelIdBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + channelId_ = value; onChanged(); return this; } - private boolean validateOnly_ ; + private boolean validateOnly_; /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -958,39 +1073,45 @@ public boolean getValidateOnly() { return validateOnly_; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The validateOnly to set. * @return This builder for chaining. */ public Builder setValidateOnly(boolean value) { - + validateOnly_ = value; onChanged(); return this; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValidateOnly() { - + validateOnly_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1000,12 +1121,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CreateChannelRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CreateChannelRequest) private static final com.google.cloud.eventarc.v1.CreateChannelRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CreateChannelRequest(); } @@ -1014,27 +1135,27 @@ public static com.google.cloud.eventarc.v1.CreateChannelRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateChannelRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1049,6 +1170,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.CreateChannelRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java index 4faa49245010..9b5bf3873b2c 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateChannelRequestOrBuilder.java @@ -3,84 +3,113 @@ package com.google.cloud.eventarc.v1; -public interface CreateChannelRequestOrBuilder extends +public interface CreateChannelRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CreateChannelRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent collection in which to add this channel.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent collection in which to add this channel.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * Required. The channel to create.
    * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the channel field is set. */ boolean hasChannel(); /** + * + * *
    * Required. The channel to create.
    * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The channel. */ com.google.cloud.eventarc.v1.Channel getChannel(); /** + * + * *
    * Required. The channel to create.
    * 
* - * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Channel channel = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder(); /** + * + * *
    * Required. The user-provided ID to be assigned to the channel.
    * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The channelId. */ java.lang.String getChannelId(); /** + * + * *
    * Required. The user-provided ID to be assigned to the channel.
    * 
* * string channel_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for channelId. */ - com.google.protobuf.ByteString - getChannelIdBytes(); + com.google.protobuf.ByteString getChannelIdBytes(); /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ boolean getValidateOnly(); diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java similarity index 66% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java index 4a49b3ae3af2..a5231f65375c 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the CreateTrigger method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.CreateTriggerRequest} */ -public final class CreateTriggerRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class CreateTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.CreateTriggerRequest) CreateTriggerRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use CreateTriggerRequest.newBuilder() to construct. private CreateTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private CreateTriggerRequest() { parent_ = ""; triggerId_ = ""; @@ -26,37 +29,43 @@ private CreateTriggerRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new CreateTriggerRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CreateTriggerRequest.class, com.google.cloud.eventarc.v1.CreateTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.CreateTriggerRequest.class, + com.google.cloud.eventarc.v1.CreateTriggerRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent collection in which to add this trigger.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -65,29 +74,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent collection in which to add this trigger.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -98,11 +109,15 @@ public java.lang.String getParent() { public static final int TRIGGER_FIELD_NUMBER = 2; private com.google.cloud.eventarc.v1.Trigger trigger_; /** + * + * *
    * Required. The trigger to create.
    * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the trigger field is set. */ @java.lang.Override @@ -110,11 +125,15 @@ public boolean hasTrigger() { return trigger_ != null; } /** + * + * *
    * Required. The trigger to create.
    * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The trigger. */ @java.lang.Override @@ -122,11 +141,14 @@ public com.google.cloud.eventarc.v1.Trigger getTrigger() { return trigger_ == null ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; } /** + * + * *
    * Required. The trigger to create.
    * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { @@ -136,11 +158,14 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { public static final int TRIGGER_ID_FIELD_NUMBER = 3; private volatile java.lang.Object triggerId_; /** + * + * *
    * Required. The user-provided ID to be assigned to the trigger.
    * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The triggerId. */ @java.lang.Override @@ -149,29 +174,29 @@ public java.lang.String getTriggerId() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); triggerId_ = s; return s; } } /** + * + * *
    * Required. The user-provided ID to be assigned to the trigger.
    * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for triggerId. */ @java.lang.Override - public com.google.protobuf.ByteString - getTriggerIdBytes() { + public com.google.protobuf.ByteString getTriggerIdBytes() { java.lang.Object ref = triggerId_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); triggerId_ = b; return b; } else { @@ -182,12 +207,15 @@ public java.lang.String getTriggerId() { public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; private boolean validateOnly_; /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -196,6 +224,7 @@ public boolean getValidateOnly() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -207,8 +236,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -234,15 +262,13 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (trigger_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getTrigger()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getTrigger()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, triggerId_); } if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, validateOnly_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -252,24 +278,21 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.CreateTriggerRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.CreateTriggerRequest other = (com.google.cloud.eventarc.v1.CreateTriggerRequest) obj; + com.google.cloud.eventarc.v1.CreateTriggerRequest other = + (com.google.cloud.eventarc.v1.CreateTriggerRequest) obj; - if (!getParent() - .equals(other.getParent())) return false; + if (!getParent().equals(other.getParent())) return false; if (hasTrigger() != other.hasTrigger()) return false; if (hasTrigger()) { - if (!getTrigger() - .equals(other.getTrigger())) return false; + if (!getTrigger().equals(other.getTrigger())) return false; } - if (!getTriggerId() - .equals(other.getTriggerId())) return false; - if (getValidateOnly() - != other.getValidateOnly()) return false; + if (!getTriggerId().equals(other.getTriggerId())) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -290,137 +313,142 @@ public int hashCode() { hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; hash = (53 * hash) + getTriggerId().hashCode(); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getValidateOnly()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.CreateTriggerRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.CreateTriggerRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the CreateTrigger method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.CreateTriggerRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.CreateTriggerRequest) com.google.cloud.eventarc.v1.CreateTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.CreateTriggerRequest.class, com.google.cloud.eventarc.v1.CreateTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.CreateTriggerRequest.class, + com.google.cloud.eventarc.v1.CreateTriggerRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.CreateTriggerRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -440,9 +468,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; } @java.lang.Override @@ -461,7 +489,8 @@ public com.google.cloud.eventarc.v1.CreateTriggerRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.CreateTriggerRequest buildPartial() { - com.google.cloud.eventarc.v1.CreateTriggerRequest result = new com.google.cloud.eventarc.v1.CreateTriggerRequest(this); + com.google.cloud.eventarc.v1.CreateTriggerRequest result = + new com.google.cloud.eventarc.v1.CreateTriggerRequest(this); result.parent_ = parent_; if (triggerBuilder_ == null) { result.trigger_ = trigger_; @@ -478,38 +507,39 @@ public com.google.cloud.eventarc.v1.CreateTriggerRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.CreateTriggerRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.CreateTriggerRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.CreateTriggerRequest) other); } else { super.mergeFrom(other); return this; @@ -517,7 +547,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.CreateTriggerRequest other) { - if (other == com.google.cloud.eventarc.v1.CreateTriggerRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.CreateTriggerRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -558,34 +589,37 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); + case 10: + { + parent_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 18: { - input.readMessage( - getTriggerFieldBuilder().getBuilder(), - extensionRegistry); + break; + } // case 10 + case 18: + { + input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 18 - case 26: { - triggerId_ = input.readStringRequireUtf8(); + break; + } // case 18 + case 26: + { + triggerId_ = input.readStringRequireUtf8(); - break; - } // case 26 - case 32: { - validateOnly_ = input.readBool(); + break; + } // case 26 + case 32: + { + validateOnly_ = input.readBool(); - break; - } // case 32 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -598,18 +632,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent collection in which to add this trigger.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -618,20 +656,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection in which to add this trigger.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -639,54 +680,67 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection in which to add this trigger.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent collection in which to add this trigger.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent collection in which to add this trigger.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; @@ -694,39 +748,58 @@ public Builder setParentBytes( private com.google.cloud.eventarc.v1.Trigger trigger_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder> triggerBuilder_; + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + triggerBuilder_; /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the trigger field is set. */ public boolean hasTrigger() { return triggerBuilder_ != null || trigger_ != null; } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The trigger. */ public com.google.cloud.eventarc.v1.Trigger getTrigger() { if (triggerBuilder_ == null) { - return trigger_ == null ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; } else { return triggerBuilder_.getMessage(); } } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger value) { if (triggerBuilder_ == null) { @@ -742,14 +815,17 @@ public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger value) { return this; } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ - public Builder setTrigger( - com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { if (triggerBuilder_ == null) { trigger_ = builderForValue.build(); onChanged(); @@ -760,17 +836,23 @@ public Builder setTrigger( return this; } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder mergeTrigger(com.google.cloud.eventarc.v1.Trigger value) { if (triggerBuilder_ == null) { if (trigger_ != null) { trigger_ = - com.google.cloud.eventarc.v1.Trigger.newBuilder(trigger_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.Trigger.newBuilder(trigger_) + .mergeFrom(value) + .buildPartial(); } else { trigger_ = value; } @@ -782,11 +864,15 @@ public Builder mergeTrigger(com.google.cloud.eventarc.v1.Trigger value) { return this; } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder clearTrigger() { if (triggerBuilder_ == null) { @@ -800,48 +886,64 @@ public Builder clearTrigger() { return this; } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.Trigger.Builder getTriggerBuilder() { - + onChanged(); return getTriggerFieldBuilder().getBuilder(); } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { if (triggerBuilder_ != null) { return triggerBuilder_.getMessageOrBuilder(); } else { - return trigger_ == null ? - com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; } } /** + * + * *
      * Required. The trigger to create.
      * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder> + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> getTriggerFieldBuilder() { if (triggerBuilder_ == null) { - triggerBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder>( - getTrigger(), - getParentForChildren(), - isClean()); + triggerBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder>( + getTrigger(), getParentForChildren(), isClean()); trigger_ = null; } return triggerBuilder_; @@ -849,18 +951,20 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { private java.lang.Object triggerId_ = ""; /** + * + * *
      * Required. The user-provided ID to be assigned to the trigger.
      * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The triggerId. */ public java.lang.String getTriggerId() { java.lang.Object ref = triggerId_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); triggerId_ = s; return s; @@ -869,20 +973,21 @@ public java.lang.String getTriggerId() { } } /** + * + * *
      * Required. The user-provided ID to be assigned to the trigger.
      * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for triggerId. */ - public com.google.protobuf.ByteString - getTriggerIdBytes() { + public com.google.protobuf.ByteString getTriggerIdBytes() { java.lang.Object ref = triggerId_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); triggerId_ = b; return b; } else { @@ -890,67 +995,77 @@ public java.lang.String getTriggerId() { } } /** + * + * *
      * Required. The user-provided ID to be assigned to the trigger.
      * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The triggerId to set. * @return This builder for chaining. */ - public Builder setTriggerId( - java.lang.String value) { + public Builder setTriggerId(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + triggerId_ = value; onChanged(); return this; } /** + * + * *
      * Required. The user-provided ID to be assigned to the trigger.
      * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearTriggerId() { - + triggerId_ = getDefaultInstance().getTriggerId(); onChanged(); return this; } /** + * + * *
      * Required. The user-provided ID to be assigned to the trigger.
      * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for triggerId to set. * @return This builder for chaining. */ - public Builder setTriggerIdBytes( - com.google.protobuf.ByteString value) { + public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + triggerId_ = value; onChanged(); return this; } - private boolean validateOnly_ ; + private boolean validateOnly_; /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -958,39 +1073,45 @@ public boolean getValidateOnly() { return validateOnly_; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The validateOnly to set. * @return This builder for chaining. */ public Builder setValidateOnly(boolean value) { - + validateOnly_ = value; onChanged(); return this; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValidateOnly() { - + validateOnly_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1000,12 +1121,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.CreateTriggerRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.CreateTriggerRequest) private static final com.google.cloud.eventarc.v1.CreateTriggerRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.CreateTriggerRequest(); } @@ -1014,27 +1135,27 @@ public static com.google.cloud.eventarc.v1.CreateTriggerRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1049,6 +1170,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.CreateTriggerRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java index 12004f367fa3..7f8c4876e4eb 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/CreateTriggerRequestOrBuilder.java @@ -3,84 +3,113 @@ package com.google.cloud.eventarc.v1; -public interface CreateTriggerRequestOrBuilder extends +public interface CreateTriggerRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.CreateTriggerRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent collection in which to add this trigger.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent collection in which to add this trigger.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * Required. The trigger to create.
    * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the trigger field is set. */ boolean hasTrigger(); /** + * + * *
    * Required. The trigger to create.
    * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The trigger. */ com.google.cloud.eventarc.v1.Trigger getTrigger(); /** + * + * *
    * Required. The trigger to create.
    * 
* - * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * .google.cloud.eventarc.v1.Trigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; + * */ com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder(); /** + * + * *
    * Required. The user-provided ID to be assigned to the trigger.
    * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The triggerId. */ java.lang.String getTriggerId(); /** + * + * *
    * Required. The user-provided ID to be assigned to the trigger.
    * 
* * string trigger_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for triggerId. */ - com.google.protobuf.ByteString - getTriggerIdBytes(); + com.google.protobuf.ByteString getTriggerIdBytes(); /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ boolean getValidateOnly(); diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java similarity index 62% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java index 72dbfeec512e..655a0aa1ebbc 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequest.java @@ -4,58 +4,68 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the DeleteChannelConnection method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelConnectionRequest} */ -public final class DeleteChannelConnectionRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class DeleteChannelConnectionRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) DeleteChannelConnectionRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use DeleteChannelConnectionRequest.newBuilder() to construct. - private DeleteChannelConnectionRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + private DeleteChannelConnectionRequest( + com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private DeleteChannelConnectionRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new DeleteChannelConnectionRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.Builder.class); + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the channel connection to delete.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +74,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the channel connection to delete.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -95,6 +107,7 @@ public java.lang.String getName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -106,8 +119,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -131,15 +143,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest other = (com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) obj; + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest other = + (com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -159,129 +171,136 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest prototype) { + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the DeleteChannelConnection method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelConnectionRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) com.google.cloud.eventarc.v1.DeleteChannelConnectionRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.Builder.class); + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -291,9 +310,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; } @java.lang.Override @@ -312,7 +331,8 @@ public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest buildPartial() { - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest result = new com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest(this); + com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest result = + new com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest(this); result.name_ = name_; onBuilt(); return result; @@ -322,38 +342,39 @@ public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest buildPartial( public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) other); } else { super.mergeFrom(other); return this; @@ -361,7 +382,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest other) { - if (other == com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.getDefaultInstance()) + return this; if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); @@ -392,17 +414,19 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -415,18 +439,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the channel connection to delete.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -435,20 +463,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel connection to delete.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -456,61 +487,74 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel connection to delete.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the channel connection to delete.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the channel connection to delete.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -520,12 +564,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) private static final com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest(); } @@ -534,27 +578,27 @@ public static com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest getDef return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteChannelConnectionRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteChannelConnectionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -569,6 +613,4 @@ public com.google.protobuf.Parser getParserForTy public com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java similarity index 59% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java index 77b929997c24..400c3ebba06f 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelConnectionRequestOrBuilder.java @@ -3,27 +3,37 @@ package com.google.cloud.eventarc.v1; -public interface DeleteChannelConnectionRequestOrBuilder extends +public interface DeleteChannelConnectionRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.DeleteChannelConnectionRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the channel connection to delete.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the channel connection to delete.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java similarity index 65% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java index 4c316aace397..34166829217c 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequest.java @@ -4,58 +4,67 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the DeleteChannel method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelRequest} */ -public final class DeleteChannelRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class DeleteChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.DeleteChannelRequest) DeleteChannelRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use DeleteChannelRequest.newBuilder() to construct. private DeleteChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private DeleteChannelRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new DeleteChannelRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.DeleteChannelRequest.class, com.google.cloud.eventarc.v1.DeleteChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.DeleteChannelRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the channel to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +73,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the channel to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -97,12 +108,15 @@ public java.lang.String getName() { public static final int VALIDATE_ONLY_FIELD_NUMBER = 2; private boolean validateOnly_; /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -111,6 +125,7 @@ public boolean getValidateOnly() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -122,8 +137,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -143,8 +157,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(2, validateOnly_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, validateOnly_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -154,17 +167,16 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.DeleteChannelRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.DeleteChannelRequest other = (com.google.cloud.eventarc.v1.DeleteChannelRequest) obj; + com.google.cloud.eventarc.v1.DeleteChannelRequest other = + (com.google.cloud.eventarc.v1.DeleteChannelRequest) obj; - if (!getName() - .equals(other.getName())) return false; - if (getValidateOnly() - != other.getValidateOnly()) return false; + if (!getName().equals(other.getName())) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -179,137 +191,142 @@ public int hashCode() { hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getValidateOnly()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteChannelRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.DeleteChannelRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the DeleteChannel method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.DeleteChannelRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.DeleteChannelRequest) com.google.cloud.eventarc.v1.DeleteChannelRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.DeleteChannelRequest.class, com.google.cloud.eventarc.v1.DeleteChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.DeleteChannelRequest.class, + com.google.cloud.eventarc.v1.DeleteChannelRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.DeleteChannelRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -321,9 +338,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; } @java.lang.Override @@ -342,7 +359,8 @@ public com.google.cloud.eventarc.v1.DeleteChannelRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.DeleteChannelRequest buildPartial() { - com.google.cloud.eventarc.v1.DeleteChannelRequest result = new com.google.cloud.eventarc.v1.DeleteChannelRequest(this); + com.google.cloud.eventarc.v1.DeleteChannelRequest result = + new com.google.cloud.eventarc.v1.DeleteChannelRequest(this); result.name_ = name_; result.validateOnly_ = validateOnly_; onBuilt(); @@ -353,38 +371,39 @@ public com.google.cloud.eventarc.v1.DeleteChannelRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.DeleteChannelRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.DeleteChannelRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.DeleteChannelRequest) other); } else { super.mergeFrom(other); return this; @@ -392,7 +411,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.DeleteChannelRequest other) { - if (other == com.google.cloud.eventarc.v1.DeleteChannelRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.DeleteChannelRequest.getDefaultInstance()) + return this; if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); @@ -426,22 +446,25 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: { - validateOnly_ = input.readBool(); - - break; - } // case 16 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + validateOnly_ = input.readBool(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -454,18 +477,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the channel to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -474,20 +501,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -495,67 +525,83 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the channel to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the channel to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } - private boolean validateOnly_ ; + private boolean validateOnly_; /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -563,39 +609,45 @@ public boolean getValidateOnly() { return validateOnly_; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The validateOnly to set. * @return This builder for chaining. */ public Builder setValidateOnly(boolean value) { - + validateOnly_ = value; onChanged(); return this; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValidateOnly() { - + validateOnly_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -605,12 +657,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.DeleteChannelRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.DeleteChannelRequest) private static final com.google.cloud.eventarc.v1.DeleteChannelRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.DeleteChannelRequest(); } @@ -619,27 +671,27 @@ public static com.google.cloud.eventarc.v1.DeleteChannelRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteChannelRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -654,6 +706,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.DeleteChannelRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java similarity index 67% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java index d96ef997d187..179fafc8a6b1 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteChannelRequestOrBuilder.java @@ -3,37 +3,50 @@ package com.google.cloud.eventarc.v1; -public interface DeleteChannelRequestOrBuilder extends +public interface DeleteChannelRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.DeleteChannelRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the channel to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the channel to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ boolean getValidateOnly(); diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java similarity index 68% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java index a98f9602a916..5ae99cdf8435 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the DeleteTrigger method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.DeleteTriggerRequest} */ -public final class DeleteTriggerRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class DeleteTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.DeleteTriggerRequest) DeleteTriggerRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use DeleteTriggerRequest.newBuilder() to construct. private DeleteTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private DeleteTriggerRequest() { name_ = ""; etag_ = ""; @@ -26,37 +29,43 @@ private DeleteTriggerRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new DeleteTriggerRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, com.google.cloud.eventarc.v1.DeleteTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, + com.google.cloud.eventarc.v1.DeleteTriggerRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the trigger to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -65,29 +74,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the trigger to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -98,12 +109,15 @@ public java.lang.String getName() { public static final int ETAG_FIELD_NUMBER = 2; private volatile java.lang.Object etag_; /** + * + * *
    * If provided, the trigger will only be deleted if the etag matches the
    * current etag on the resource.
    * 
* * string etag = 2; + * * @return The etag. */ @java.lang.Override @@ -112,30 +126,30 @@ public java.lang.String getEtag() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); etag_ = s; return s; } } /** + * + * *
    * If provided, the trigger will only be deleted if the etag matches the
    * current etag on the resource.
    * 
* * string etag = 2; + * * @return The bytes for etag. */ @java.lang.Override - public com.google.protobuf.ByteString - getEtagBytes() { + public com.google.protobuf.ByteString getEtagBytes() { java.lang.Object ref = etag_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); etag_ = b; return b; } else { @@ -146,12 +160,15 @@ public java.lang.String getEtag() { public static final int ALLOW_MISSING_FIELD_NUMBER = 3; private boolean allowMissing_; /** + * + * *
    * If set to true, and the trigger is not found, the request will succeed
    * but no action will be taken on the server.
    * 
* * bool allow_missing = 3; + * * @return The allowMissing. */ @java.lang.Override @@ -162,12 +179,15 @@ public boolean getAllowMissing() { public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; private boolean validateOnly_; /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -176,6 +196,7 @@ public boolean getValidateOnly() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -187,8 +208,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -217,12 +237,10 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, etag_); } if (allowMissing_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(3, allowMissing_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowMissing_); } if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, validateOnly_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -232,21 +250,18 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.DeleteTriggerRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.DeleteTriggerRequest other = (com.google.cloud.eventarc.v1.DeleteTriggerRequest) obj; + com.google.cloud.eventarc.v1.DeleteTriggerRequest other = + (com.google.cloud.eventarc.v1.DeleteTriggerRequest) obj; - if (!getName() - .equals(other.getName())) return false; - if (!getEtag() - .equals(other.getEtag())) return false; - if (getAllowMissing() - != other.getAllowMissing()) return false; - if (getValidateOnly() - != other.getValidateOnly()) return false; + if (!getName().equals(other.getName())) return false; + if (!getEtag().equals(other.getEtag())) return false; + if (getAllowMissing() != other.getAllowMissing()) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -263,140 +278,144 @@ public int hashCode() { hash = (37 * hash) + ETAG_FIELD_NUMBER; hash = (53 * hash) + getEtag().hashCode(); hash = (37 * hash) + ALLOW_MISSING_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getAllowMissing()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowMissing()); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getValidateOnly()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.DeleteTriggerRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.DeleteTriggerRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the DeleteTrigger method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.DeleteTriggerRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.DeleteTriggerRequest) com.google.cloud.eventarc.v1.DeleteTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, com.google.cloud.eventarc.v1.DeleteTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, + com.google.cloud.eventarc.v1.DeleteTriggerRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.DeleteTriggerRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -412,9 +431,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; } @java.lang.Override @@ -433,7 +452,8 @@ public com.google.cloud.eventarc.v1.DeleteTriggerRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.DeleteTriggerRequest buildPartial() { - com.google.cloud.eventarc.v1.DeleteTriggerRequest result = new com.google.cloud.eventarc.v1.DeleteTriggerRequest(this); + com.google.cloud.eventarc.v1.DeleteTriggerRequest result = + new com.google.cloud.eventarc.v1.DeleteTriggerRequest(this); result.name_ = name_; result.etag_ = etag_; result.allowMissing_ = allowMissing_; @@ -446,38 +466,39 @@ public com.google.cloud.eventarc.v1.DeleteTriggerRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.DeleteTriggerRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.DeleteTriggerRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.DeleteTriggerRequest) other); } else { super.mergeFrom(other); return this; @@ -485,7 +506,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.DeleteTriggerRequest other) { - if (other == com.google.cloud.eventarc.v1.DeleteTriggerRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.DeleteTriggerRequest.getDefaultInstance()) + return this; if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); @@ -526,32 +548,37 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: { - etag_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 24: { - allowMissing_ = input.readBool(); - - break; - } // case 24 - case 32: { - validateOnly_ = input.readBool(); - - break; - } // case 32 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + allowMissing_ = input.readBool(); + + break; + } // case 24 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -564,18 +591,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the trigger to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -584,20 +615,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the trigger to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -605,54 +639,67 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the trigger to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the trigger to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the trigger to be deleted.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; @@ -660,19 +707,21 @@ public Builder setNameBytes( private java.lang.Object etag_ = ""; /** + * + * *
      * If provided, the trigger will only be deleted if the etag matches the
      * current etag on the resource.
      * 
* * string etag = 2; + * * @return The etag. */ public java.lang.String getEtag() { java.lang.Object ref = etag_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); etag_ = s; return s; @@ -681,21 +730,22 @@ public java.lang.String getEtag() { } } /** + * + * *
      * If provided, the trigger will only be deleted if the etag matches the
      * current etag on the resource.
      * 
* * string etag = 2; + * * @return The bytes for etag. */ - public com.google.protobuf.ByteString - getEtagBytes() { + public com.google.protobuf.ByteString getEtagBytes() { java.lang.Object ref = etag_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); etag_ = b; return b; } else { @@ -703,70 +753,80 @@ public java.lang.String getEtag() { } } /** + * + * *
      * If provided, the trigger will only be deleted if the etag matches the
      * current etag on the resource.
      * 
* * string etag = 2; + * * @param value The etag to set. * @return This builder for chaining. */ - public Builder setEtag( - java.lang.String value) { + public Builder setEtag(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + etag_ = value; onChanged(); return this; } /** + * + * *
      * If provided, the trigger will only be deleted if the etag matches the
      * current etag on the resource.
      * 
* * string etag = 2; + * * @return This builder for chaining. */ public Builder clearEtag() { - + etag_ = getDefaultInstance().getEtag(); onChanged(); return this; } /** + * + * *
      * If provided, the trigger will only be deleted if the etag matches the
      * current etag on the resource.
      * 
* * string etag = 2; + * * @param value The bytes for etag to set. * @return This builder for chaining. */ - public Builder setEtagBytes( - com.google.protobuf.ByteString value) { + public Builder setEtagBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + etag_ = value; onChanged(); return this; } - private boolean allowMissing_ ; + private boolean allowMissing_; /** + * + * *
      * If set to true, and the trigger is not found, the request will succeed
      * but no action will be taken on the server.
      * 
* * bool allow_missing = 3; + * * @return The allowMissing. */ @java.lang.Override @@ -774,45 +834,54 @@ public boolean getAllowMissing() { return allowMissing_; } /** + * + * *
      * If set to true, and the trigger is not found, the request will succeed
      * but no action will be taken on the server.
      * 
* * bool allow_missing = 3; + * * @param value The allowMissing to set. * @return This builder for chaining. */ public Builder setAllowMissing(boolean value) { - + allowMissing_ = value; onChanged(); return this; } /** + * + * *
      * If set to true, and the trigger is not found, the request will succeed
      * but no action will be taken on the server.
      * 
* * bool allow_missing = 3; + * * @return This builder for chaining. */ public Builder clearAllowMissing() { - + allowMissing_ = false; onChanged(); return this; } - private boolean validateOnly_ ; + private boolean validateOnly_; /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -820,39 +889,45 @@ public boolean getValidateOnly() { return validateOnly_; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The validateOnly to set. * @return This builder for chaining. */ public Builder setValidateOnly(boolean value) { - + validateOnly_ = value; onChanged(); return this; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValidateOnly() { - + validateOnly_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -862,12 +937,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.DeleteTriggerRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.DeleteTriggerRequest) private static final com.google.cloud.eventarc.v1.DeleteTriggerRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.DeleteTriggerRequest(); } @@ -876,27 +951,27 @@ public static com.google.cloud.eventarc.v1.DeleteTriggerRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -911,6 +986,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.DeleteTriggerRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java similarity index 75% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java index 581bbf02fb6f..ca7294c41912 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DeleteTriggerRequestOrBuilder.java @@ -3,70 +3,91 @@ package com.google.cloud.eventarc.v1; -public interface DeleteTriggerRequestOrBuilder extends +public interface DeleteTriggerRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.DeleteTriggerRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the trigger to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the trigger to be deleted.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * If provided, the trigger will only be deleted if the etag matches the
    * current etag on the resource.
    * 
* * string etag = 2; + * * @return The etag. */ java.lang.String getEtag(); /** + * + * *
    * If provided, the trigger will only be deleted if the etag matches the
    * current etag on the resource.
    * 
* * string etag = 2; + * * @return The bytes for etag. */ - com.google.protobuf.ByteString - getEtagBytes(); + com.google.protobuf.ByteString getEtagBytes(); /** + * + * *
    * If set to true, and the trigger is not found, the request will succeed
    * but no action will be taken on the server.
    * 
* * bool allow_missing = 3; + * * @return The allowMissing. */ boolean getAllowMissing(); /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ boolean getValidateOnly(); diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java index ae8611218a47..bcee182c9a41 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Destination.java @@ -4,53 +4,58 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * Represents a target of an invocation over HTTP.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.Destination} */ -public final class Destination extends - com.google.protobuf.GeneratedMessageV3 implements +public final class Destination extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Destination) DestinationOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use Destination.newBuilder() to construct. private Destination(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private Destination() { - } + + private Destination() {} @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Destination(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Destination_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Destination.class, com.google.cloud.eventarc.v1.Destination.Builder.class); + com.google.cloud.eventarc.v1.Destination.class, + com.google.cloud.eventarc.v1.Destination.Builder.class); } private int descriptorCase_ = 0; private java.lang.Object descriptor_; + public enum DescriptorCase - implements com.google.protobuf.Internal.EnumLite, + implements + com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { CLOUD_RUN(1), CLOUD_FUNCTION(2), @@ -58,6 +63,7 @@ public enum DescriptorCase WORKFLOW(4), DESCRIPTOR_NOT_SET(0); private final int value; + private DescriptorCase(int value) { this.value = value; } @@ -73,33 +79,41 @@ public static DescriptorCase valueOf(int value) { public static DescriptorCase forNumber(int value) { switch (value) { - case 1: return CLOUD_RUN; - case 2: return CLOUD_FUNCTION; - case 3: return GKE; - case 4: return WORKFLOW; - case 0: return DESCRIPTOR_NOT_SET; - default: return null; + case 1: + return CLOUD_RUN; + case 2: + return CLOUD_FUNCTION; + case 3: + return GKE; + case 4: + return WORKFLOW; + case 0: + return DESCRIPTOR_NOT_SET; + default: + return null; } } + public int getNumber() { return this.value; } }; - public DescriptorCase - getDescriptorCase() { - return DescriptorCase.forNumber( - descriptorCase_); + public DescriptorCase getDescriptorCase() { + return DescriptorCase.forNumber(descriptorCase_); } public static final int CLOUD_RUN_FIELD_NUMBER = 1; /** + * + * *
    * Cloud Run fully-managed resource that receives the events. The resource
    * should be in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * * @return Whether the cloudRun field is set. */ @java.lang.Override @@ -107,22 +121,27 @@ public boolean hasCloudRun() { return descriptorCase_ == 1; } /** + * + * *
    * Cloud Run fully-managed resource that receives the events. The resource
    * should be in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * * @return The cloudRun. */ @java.lang.Override public com.google.cloud.eventarc.v1.CloudRun getCloudRun() { if (descriptorCase_ == 1) { - return (com.google.cloud.eventarc.v1.CloudRun) descriptor_; + return (com.google.cloud.eventarc.v1.CloudRun) descriptor_; } return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance(); } /** + * + * *
    * Cloud Run fully-managed resource that receives the events. The resource
    * should be in the same project as the trigger.
@@ -133,31 +152,37 @@ public com.google.cloud.eventarc.v1.CloudRun getCloudRun() {
   @java.lang.Override
   public com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder() {
     if (descriptorCase_ == 1) {
-       return (com.google.cloud.eventarc.v1.CloudRun) descriptor_;
+      return (com.google.cloud.eventarc.v1.CloudRun) descriptor_;
     }
     return com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance();
   }
 
   public static final int CLOUD_FUNCTION_FIELD_NUMBER = 2;
   /**
+   *
+   *
    * 
    * The Cloud Function resource name. Only Cloud Functions V2 is supported.
    * Format: `projects/{project}/locations/{location}/functions/{function}`
    * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return Whether the cloudFunction field is set. */ public boolean hasCloudFunction() { return descriptorCase_ == 2; } /** + * + * *
    * The Cloud Function resource name. Only Cloud Functions V2 is supported.
    * Format: `projects/{project}/locations/{location}/functions/{function}`
    * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return The cloudFunction. */ public java.lang.String getCloudFunction() { @@ -168,8 +193,7 @@ public java.lang.String getCloudFunction() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (descriptorCase_ == 2) { descriptor_ = s; @@ -178,24 +202,25 @@ public java.lang.String getCloudFunction() { } } /** + * + * *
    * The Cloud Function resource name. Only Cloud Functions V2 is supported.
    * Format: `projects/{project}/locations/{location}/functions/{function}`
    * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return The bytes for cloudFunction. */ - public com.google.protobuf.ByteString - getCloudFunctionBytes() { + public com.google.protobuf.ByteString getCloudFunctionBytes() { java.lang.Object ref = ""; if (descriptorCase_ == 2) { ref = descriptor_; } if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (descriptorCase_ == 2) { descriptor_ = b; } @@ -207,12 +232,15 @@ public java.lang.String getCloudFunction() { public static final int GKE_FIELD_NUMBER = 3; /** + * + * *
    * A GKE service capable of receiving events. The service should be running
    * in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.GKE gke = 3; + * * @return Whether the gke field is set. */ @java.lang.Override @@ -220,22 +248,27 @@ public boolean hasGke() { return descriptorCase_ == 3; } /** + * + * *
    * A GKE service capable of receiving events. The service should be running
    * in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.GKE gke = 3; + * * @return The gke. */ @java.lang.Override public com.google.cloud.eventarc.v1.GKE getGke() { if (descriptorCase_ == 3) { - return (com.google.cloud.eventarc.v1.GKE) descriptor_; + return (com.google.cloud.eventarc.v1.GKE) descriptor_; } return com.google.cloud.eventarc.v1.GKE.getDefaultInstance(); } /** + * + * *
    * A GKE service capable of receiving events. The service should be running
    * in the same project as the trigger.
@@ -246,13 +279,15 @@ public com.google.cloud.eventarc.v1.GKE getGke() {
   @java.lang.Override
   public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() {
     if (descriptorCase_ == 3) {
-       return (com.google.cloud.eventarc.v1.GKE) descriptor_;
+      return (com.google.cloud.eventarc.v1.GKE) descriptor_;
     }
     return com.google.cloud.eventarc.v1.GKE.getDefaultInstance();
   }
 
   public static final int WORKFLOW_FIELD_NUMBER = 4;
   /**
+   *
+   *
    * 
    * The resource name of the Workflow whose Executions are triggered by
    * the events. The Workflow resource should be deployed in the same project
@@ -261,12 +296,15 @@ public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() {
    * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return Whether the workflow field is set. */ public boolean hasWorkflow() { return descriptorCase_ == 4; } /** + * + * *
    * The resource name of the Workflow whose Executions are triggered by
    * the events. The Workflow resource should be deployed in the same project
@@ -275,6 +313,7 @@ public boolean hasWorkflow() {
    * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return The workflow. */ public java.lang.String getWorkflow() { @@ -285,8 +324,7 @@ public java.lang.String getWorkflow() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (descriptorCase_ == 4) { descriptor_ = s; @@ -295,6 +333,8 @@ public java.lang.String getWorkflow() { } } /** + * + * *
    * The resource name of the Workflow whose Executions are triggered by
    * the events. The Workflow resource should be deployed in the same project
@@ -303,18 +343,17 @@ public java.lang.String getWorkflow() {
    * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return The bytes for workflow. */ - public com.google.protobuf.ByteString - getWorkflowBytes() { + public com.google.protobuf.ByteString getWorkflowBytes() { java.lang.Object ref = ""; if (descriptorCase_ == 4) { ref = descriptor_; } if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (descriptorCase_ == 4) { descriptor_ = b; } @@ -325,6 +364,7 @@ public java.lang.String getWorkflow() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -336,8 +376,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (descriptorCase_ == 1) { output.writeMessage(1, (com.google.cloud.eventarc.v1.CloudRun) descriptor_); } @@ -360,15 +399,17 @@ public int getSerializedSize() { size = 0; if (descriptorCase_ == 1) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, (com.google.cloud.eventarc.v1.CloudRun) descriptor_); + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.eventarc.v1.CloudRun) descriptor_); } if (descriptorCase_ == 2) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, descriptor_); } if (descriptorCase_ == 3) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, (com.google.cloud.eventarc.v1.GKE) descriptor_); + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 3, (com.google.cloud.eventarc.v1.GKE) descriptor_); } if (descriptorCase_ == 4) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, descriptor_); @@ -381,7 +422,7 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.Destination)) { return super.equals(obj); @@ -391,20 +432,16 @@ public boolean equals(final java.lang.Object obj) { if (!getDescriptorCase().equals(other.getDescriptorCase())) return false; switch (descriptorCase_) { case 1: - if (!getCloudRun() - .equals(other.getCloudRun())) return false; + if (!getCloudRun().equals(other.getCloudRun())) return false; break; case 2: - if (!getCloudFunction() - .equals(other.getCloudFunction())) return false; + if (!getCloudFunction().equals(other.getCloudFunction())) return false; break; case 3: - if (!getGke() - .equals(other.getGke())) return false; + if (!getGke().equals(other.getGke())) return false; break; case 4: - if (!getWorkflow() - .equals(other.getWorkflow())) return false; + if (!getWorkflow().equals(other.getWorkflow())) return false; break; case 0: default: @@ -445,130 +482,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.Destination parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.Destination parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Destination parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Destination parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.Destination parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.Destination parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Destination parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Destination parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.Destination prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Represents a target of an invocation over HTTP.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.Destination} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Destination) com.google.cloud.eventarc.v1.DestinationOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Destination_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Destination.class, com.google.cloud.eventarc.v1.Destination.Builder.class); + com.google.cloud.eventarc.v1.Destination.class, + com.google.cloud.eventarc.v1.Destination.Builder.class); } // Construct using com.google.cloud.eventarc.v1.Destination.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -584,9 +627,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Destination_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Destination_descriptor; } @java.lang.Override @@ -605,7 +648,8 @@ public com.google.cloud.eventarc.v1.Destination build() { @java.lang.Override public com.google.cloud.eventarc.v1.Destination buildPartial() { - com.google.cloud.eventarc.v1.Destination result = new com.google.cloud.eventarc.v1.Destination(this); + com.google.cloud.eventarc.v1.Destination result = + new com.google.cloud.eventarc.v1.Destination(this); if (descriptorCase_ == 1) { if (cloudRunBuilder_ == null) { result.descriptor_ = descriptor_; @@ -635,38 +679,39 @@ public com.google.cloud.eventarc.v1.Destination buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.Destination) { - return mergeFrom((com.google.cloud.eventarc.v1.Destination)other); + return mergeFrom((com.google.cloud.eventarc.v1.Destination) other); } else { super.mergeFrom(other); return this; @@ -676,29 +721,34 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.cloud.eventarc.v1.Destination other) { if (other == com.google.cloud.eventarc.v1.Destination.getDefaultInstance()) return this; switch (other.getDescriptorCase()) { - case CLOUD_RUN: { - mergeCloudRun(other.getCloudRun()); - break; - } - case CLOUD_FUNCTION: { - descriptorCase_ = 2; - descriptor_ = other.descriptor_; - onChanged(); - break; - } - case GKE: { - mergeGke(other.getGke()); - break; - } - case WORKFLOW: { - descriptorCase_ = 4; - descriptor_ = other.descriptor_; - onChanged(); - break; - } - case DESCRIPTOR_NOT_SET: { - break; - } + case CLOUD_RUN: + { + mergeCloudRun(other.getCloudRun()); + break; + } + case CLOUD_FUNCTION: + { + descriptorCase_ = 2; + descriptor_ = other.descriptor_; + onChanged(); + break; + } + case GKE: + { + mergeGke(other.getGke()); + break; + } + case WORKFLOW: + { + descriptorCase_ = 4; + descriptor_ = other.descriptor_; + onChanged(); + break; + } + case DESCRIPTOR_NOT_SET: + { + break; + } } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); @@ -726,38 +776,39 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - input.readMessage( - getCloudRunFieldBuilder().getBuilder(), - extensionRegistry); - descriptorCase_ = 1; - break; - } // case 10 - case 18: { - java.lang.String s = input.readStringRequireUtf8(); - descriptorCase_ = 2; - descriptor_ = s; - break; - } // case 18 - case 26: { - input.readMessage( - getGkeFieldBuilder().getBuilder(), - extensionRegistry); - descriptorCase_ = 3; - break; - } // case 26 - case 34: { - java.lang.String s = input.readStringRequireUtf8(); - descriptorCase_ = 4; - descriptor_ = s; - break; - } // case 34 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + input.readMessage(getCloudRunFieldBuilder().getBuilder(), extensionRegistry); + descriptorCase_ = 1; + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + descriptorCase_ = 2; + descriptor_ = s; + break; + } // case 18 + case 26: + { + input.readMessage(getGkeFieldBuilder().getBuilder(), extensionRegistry); + descriptorCase_ = 3; + break; + } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + descriptorCase_ = 4; + descriptor_ = s; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -767,12 +818,12 @@ public Builder mergeFrom( } // finally return this; } + private int descriptorCase_ = 0; private java.lang.Object descriptor_; - public DescriptorCase - getDescriptorCase() { - return DescriptorCase.forNumber( - descriptorCase_); + + public DescriptorCase getDescriptorCase() { + return DescriptorCase.forNumber(descriptorCase_); } public Builder clearDescriptor() { @@ -782,16 +833,21 @@ public Builder clearDescriptor() { return this; } - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.CloudRun, com.google.cloud.eventarc.v1.CloudRun.Builder, com.google.cloud.eventarc.v1.CloudRunOrBuilder> cloudRunBuilder_; + com.google.cloud.eventarc.v1.CloudRun, + com.google.cloud.eventarc.v1.CloudRun.Builder, + com.google.cloud.eventarc.v1.CloudRunOrBuilder> + cloudRunBuilder_; /** + * + * *
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
      * 
* * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * * @return Whether the cloudRun field is set. */ @java.lang.Override @@ -799,12 +855,15 @@ public boolean hasCloudRun() { return descriptorCase_ == 1; } /** + * + * *
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
      * 
* * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * * @return The cloudRun. */ @java.lang.Override @@ -822,6 +881,8 @@ public com.google.cloud.eventarc.v1.CloudRun getCloudRun() { } } /** + * + * *
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -843,6 +904,8 @@ public Builder setCloudRun(com.google.cloud.eventarc.v1.CloudRun value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -850,8 +913,7 @@ public Builder setCloudRun(com.google.cloud.eventarc.v1.CloudRun value) {
      *
      * .google.cloud.eventarc.v1.CloudRun cloud_run = 1;
      */
-    public Builder setCloudRun(
-        com.google.cloud.eventarc.v1.CloudRun.Builder builderForValue) {
+    public Builder setCloudRun(com.google.cloud.eventarc.v1.CloudRun.Builder builderForValue) {
       if (cloudRunBuilder_ == null) {
         descriptor_ = builderForValue.build();
         onChanged();
@@ -862,6 +924,8 @@ public Builder setCloudRun(
       return this;
     }
     /**
+     *
+     *
      * 
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -871,10 +935,13 @@ public Builder setCloudRun(
      */
     public Builder mergeCloudRun(com.google.cloud.eventarc.v1.CloudRun value) {
       if (cloudRunBuilder_ == null) {
-        if (descriptorCase_ == 1 &&
-            descriptor_ != com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance()) {
-          descriptor_ = com.google.cloud.eventarc.v1.CloudRun.newBuilder((com.google.cloud.eventarc.v1.CloudRun) descriptor_)
-              .mergeFrom(value).buildPartial();
+        if (descriptorCase_ == 1
+            && descriptor_ != com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance()) {
+          descriptor_ =
+              com.google.cloud.eventarc.v1.CloudRun.newBuilder(
+                      (com.google.cloud.eventarc.v1.CloudRun) descriptor_)
+                  .mergeFrom(value)
+                  .buildPartial();
         } else {
           descriptor_ = value;
         }
@@ -890,6 +957,8 @@ public Builder mergeCloudRun(com.google.cloud.eventarc.v1.CloudRun value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -914,6 +983,8 @@ public Builder clearCloudRun() {
       return this;
     }
     /**
+     *
+     *
      * 
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -925,6 +996,8 @@ public com.google.cloud.eventarc.v1.CloudRun.Builder getCloudRunBuilder() {
       return getCloudRunFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -944,6 +1017,8 @@ public com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder() {
       }
     }
     /**
+     *
+     *
      * 
      * Cloud Run fully-managed resource that receives the events. The resource
      * should be in the same project as the trigger.
@@ -952,31 +1027,40 @@ public com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder() {
      * .google.cloud.eventarc.v1.CloudRun cloud_run = 1;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.cloud.eventarc.v1.CloudRun, com.google.cloud.eventarc.v1.CloudRun.Builder, com.google.cloud.eventarc.v1.CloudRunOrBuilder> 
+            com.google.cloud.eventarc.v1.CloudRun,
+            com.google.cloud.eventarc.v1.CloudRun.Builder,
+            com.google.cloud.eventarc.v1.CloudRunOrBuilder>
         getCloudRunFieldBuilder() {
       if (cloudRunBuilder_ == null) {
         if (!(descriptorCase_ == 1)) {
           descriptor_ = com.google.cloud.eventarc.v1.CloudRun.getDefaultInstance();
         }
-        cloudRunBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.cloud.eventarc.v1.CloudRun, com.google.cloud.eventarc.v1.CloudRun.Builder, com.google.cloud.eventarc.v1.CloudRunOrBuilder>(
+        cloudRunBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.cloud.eventarc.v1.CloudRun,
+                com.google.cloud.eventarc.v1.CloudRun.Builder,
+                com.google.cloud.eventarc.v1.CloudRunOrBuilder>(
                 (com.google.cloud.eventarc.v1.CloudRun) descriptor_,
                 getParentForChildren(),
                 isClean());
         descriptor_ = null;
       }
       descriptorCase_ = 1;
-      onChanged();;
+      onChanged();
+      ;
       return cloudRunBuilder_;
     }
 
     /**
+     *
+     *
      * 
      * The Cloud Function resource name. Only Cloud Functions V2 is supported.
      * Format: `projects/{project}/locations/{location}/functions/{function}`
      * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return Whether the cloudFunction field is set. */ @java.lang.Override @@ -984,12 +1068,15 @@ public boolean hasCloudFunction() { return descriptorCase_ == 2; } /** + * + * *
      * The Cloud Function resource name. Only Cloud Functions V2 is supported.
      * Format: `projects/{project}/locations/{location}/functions/{function}`
      * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return The cloudFunction. */ @java.lang.Override @@ -999,8 +1086,7 @@ public java.lang.String getCloudFunction() { ref = descriptor_; } if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (descriptorCase_ == 2) { descriptor_ = s; @@ -1011,25 +1097,26 @@ public java.lang.String getCloudFunction() { } } /** + * + * *
      * The Cloud Function resource name. Only Cloud Functions V2 is supported.
      * Format: `projects/{project}/locations/{location}/functions/{function}`
      * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return The bytes for cloudFunction. */ @java.lang.Override - public com.google.protobuf.ByteString - getCloudFunctionBytes() { + public com.google.protobuf.ByteString getCloudFunctionBytes() { java.lang.Object ref = ""; if (descriptorCase_ == 2) { ref = descriptor_; } if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (descriptorCase_ == 2) { descriptor_ = b; } @@ -1039,32 +1126,37 @@ public java.lang.String getCloudFunction() { } } /** + * + * *
      * The Cloud Function resource name. Only Cloud Functions V2 is supported.
      * Format: `projects/{project}/locations/{location}/functions/{function}`
      * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @param value The cloudFunction to set. * @return This builder for chaining. */ - public Builder setCloudFunction( - java.lang.String value) { + public Builder setCloudFunction(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - descriptorCase_ = 2; + throw new NullPointerException(); + } + descriptorCase_ = 2; descriptor_ = value; onChanged(); return this; } /** + * + * *
      * The Cloud Function resource name. Only Cloud Functions V2 is supported.
      * Format: `projects/{project}/locations/{location}/functions/{function}`
      * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return This builder for chaining. */ public Builder clearCloudFunction() { @@ -1076,21 +1168,23 @@ public Builder clearCloudFunction() { return this; } /** + * + * *
      * The Cloud Function resource name. Only Cloud Functions V2 is supported.
      * Format: `projects/{project}/locations/{location}/functions/{function}`
      * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @param value The bytes for cloudFunction to set. * @return This builder for chaining. */ - public Builder setCloudFunctionBytes( - com.google.protobuf.ByteString value) { + public Builder setCloudFunctionBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); descriptorCase_ = 2; descriptor_ = value; onChanged(); @@ -1098,14 +1192,20 @@ public Builder setCloudFunctionBytes( } private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.GKE, com.google.cloud.eventarc.v1.GKE.Builder, com.google.cloud.eventarc.v1.GKEOrBuilder> gkeBuilder_; + com.google.cloud.eventarc.v1.GKE, + com.google.cloud.eventarc.v1.GKE.Builder, + com.google.cloud.eventarc.v1.GKEOrBuilder> + gkeBuilder_; /** + * + * *
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
      * 
* * .google.cloud.eventarc.v1.GKE gke = 3; + * * @return Whether the gke field is set. */ @java.lang.Override @@ -1113,12 +1213,15 @@ public boolean hasGke() { return descriptorCase_ == 3; } /** + * + * *
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
      * 
* * .google.cloud.eventarc.v1.GKE gke = 3; + * * @return The gke. */ @java.lang.Override @@ -1136,6 +1239,8 @@ public com.google.cloud.eventarc.v1.GKE getGke() { } } /** + * + * *
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1157,6 +1262,8 @@ public Builder setGke(com.google.cloud.eventarc.v1.GKE value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1164,8 +1271,7 @@ public Builder setGke(com.google.cloud.eventarc.v1.GKE value) {
      *
      * .google.cloud.eventarc.v1.GKE gke = 3;
      */
-    public Builder setGke(
-        com.google.cloud.eventarc.v1.GKE.Builder builderForValue) {
+    public Builder setGke(com.google.cloud.eventarc.v1.GKE.Builder builderForValue) {
       if (gkeBuilder_ == null) {
         descriptor_ = builderForValue.build();
         onChanged();
@@ -1176,6 +1282,8 @@ public Builder setGke(
       return this;
     }
     /**
+     *
+     *
      * 
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1185,10 +1293,17 @@ public Builder setGke(
      */
     public Builder mergeGke(com.google.cloud.eventarc.v1.GKE value) {
       if (gkeBuilder_ == null) {
-        if (descriptorCase_ == 3 &&
-            descriptor_ != com.google.cloud.eventarc.v1.GKE.getDefaultInstance()) {
-          descriptor_ = com.google.cloud.eventarc.v1.GKE.newBuilder((com.google.cloud.eventarc.v1.GKE) descriptor_)
-              .mergeFrom(value).buildPartial();
+        if (descriptorCase_ == 3
+            && descriptor_ != com.google.cloud.eventarc.v1.GKE.getDefaultInstance()) {
+          descriptor_ =
+              com.google
+                  .cloud
+                  .eventarc
+                  .v1
+                  .GKE
+                  .newBuilder((com.google.cloud.eventarc.v1.GKE) descriptor_)
+                  .mergeFrom(value)
+                  .buildPartial();
         } else {
           descriptor_ = value;
         }
@@ -1204,6 +1319,8 @@ public Builder mergeGke(com.google.cloud.eventarc.v1.GKE value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1228,6 +1345,8 @@ public Builder clearGke() {
       return this;
     }
     /**
+     *
+     *
      * 
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1239,6 +1358,8 @@ public com.google.cloud.eventarc.v1.GKE.Builder getGkeBuilder() {
       return getGkeFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1258,6 +1379,8 @@ public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() {
       }
     }
     /**
+     *
+     *
      * 
      * A GKE service capable of receiving events. The service should be running
      * in the same project as the trigger.
@@ -1266,25 +1389,31 @@ public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() {
      * .google.cloud.eventarc.v1.GKE gke = 3;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.cloud.eventarc.v1.GKE, com.google.cloud.eventarc.v1.GKE.Builder, com.google.cloud.eventarc.v1.GKEOrBuilder> 
+            com.google.cloud.eventarc.v1.GKE,
+            com.google.cloud.eventarc.v1.GKE.Builder,
+            com.google.cloud.eventarc.v1.GKEOrBuilder>
         getGkeFieldBuilder() {
       if (gkeBuilder_ == null) {
         if (!(descriptorCase_ == 3)) {
           descriptor_ = com.google.cloud.eventarc.v1.GKE.getDefaultInstance();
         }
-        gkeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.cloud.eventarc.v1.GKE, com.google.cloud.eventarc.v1.GKE.Builder, com.google.cloud.eventarc.v1.GKEOrBuilder>(
-                (com.google.cloud.eventarc.v1.GKE) descriptor_,
-                getParentForChildren(),
-                isClean());
+        gkeBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.cloud.eventarc.v1.GKE,
+                com.google.cloud.eventarc.v1.GKE.Builder,
+                com.google.cloud.eventarc.v1.GKEOrBuilder>(
+                (com.google.cloud.eventarc.v1.GKE) descriptor_, getParentForChildren(), isClean());
         descriptor_ = null;
       }
       descriptorCase_ = 3;
-      onChanged();;
+      onChanged();
+      ;
       return gkeBuilder_;
     }
 
     /**
+     *
+     *
      * 
      * The resource name of the Workflow whose Executions are triggered by
      * the events. The Workflow resource should be deployed in the same project
@@ -1293,6 +1422,7 @@ public com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder() {
      * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return Whether the workflow field is set. */ @java.lang.Override @@ -1300,6 +1430,8 @@ public boolean hasWorkflow() { return descriptorCase_ == 4; } /** + * + * *
      * The resource name of the Workflow whose Executions are triggered by
      * the events. The Workflow resource should be deployed in the same project
@@ -1308,6 +1440,7 @@ public boolean hasWorkflow() {
      * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return The workflow. */ @java.lang.Override @@ -1317,8 +1450,7 @@ public java.lang.String getWorkflow() { ref = descriptor_; } if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (descriptorCase_ == 4) { descriptor_ = s; @@ -1329,6 +1461,8 @@ public java.lang.String getWorkflow() { } } /** + * + * *
      * The resource name of the Workflow whose Executions are triggered by
      * the events. The Workflow resource should be deployed in the same project
@@ -1337,19 +1471,18 @@ public java.lang.String getWorkflow() {
      * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return The bytes for workflow. */ @java.lang.Override - public com.google.protobuf.ByteString - getWorkflowBytes() { + public com.google.protobuf.ByteString getWorkflowBytes() { java.lang.Object ref = ""; if (descriptorCase_ == 4) { ref = descriptor_; } if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (descriptorCase_ == 4) { descriptor_ = b; } @@ -1359,6 +1492,8 @@ public java.lang.String getWorkflow() { } } /** + * + * *
      * The resource name of the Workflow whose Executions are triggered by
      * the events. The Workflow resource should be deployed in the same project
@@ -1367,20 +1502,22 @@ public java.lang.String getWorkflow() {
      * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @param value The workflow to set. * @return This builder for chaining. */ - public Builder setWorkflow( - java.lang.String value) { + public Builder setWorkflow(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - descriptorCase_ = 4; + throw new NullPointerException(); + } + descriptorCase_ = 4; descriptor_ = value; onChanged(); return this; } /** + * + * *
      * The resource name of the Workflow whose Executions are triggered by
      * the events. The Workflow resource should be deployed in the same project
@@ -1389,6 +1526,7 @@ public Builder setWorkflow(
      * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return This builder for chaining. */ public Builder clearWorkflow() { @@ -1400,6 +1538,8 @@ public Builder clearWorkflow() { return this; } /** + * + * *
      * The resource name of the Workflow whose Executions are triggered by
      * the events. The Workflow resource should be deployed in the same project
@@ -1408,23 +1548,23 @@ public Builder clearWorkflow() {
      * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @param value The bytes for workflow to set. * @return This builder for chaining. */ - public Builder setWorkflowBytes( - com.google.protobuf.ByteString value) { + public Builder setWorkflowBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); descriptorCase_ = 4; descriptor_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1434,12 +1574,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Destination) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Destination) private static final com.google.cloud.eventarc.v1.Destination DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Destination(); } @@ -1448,27 +1588,27 @@ public static com.google.cloud.eventarc.v1.Destination getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Destination parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Destination parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1483,6 +1623,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.Destination getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java similarity index 93% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java index d69af304f154..48f27e3bbc57 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DestinationOrBuilder.java @@ -3,31 +3,40 @@ package com.google.cloud.eventarc.v1; -public interface DestinationOrBuilder extends +public interface DestinationOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Destination) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Cloud Run fully-managed resource that receives the events. The resource
    * should be in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * * @return Whether the cloudRun field is set. */ boolean hasCloudRun(); /** + * + * *
    * Cloud Run fully-managed resource that receives the events. The resource
    * should be in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.CloudRun cloud_run = 1; + * * @return The cloudRun. */ com.google.cloud.eventarc.v1.CloudRun getCloudRun(); /** + * + * *
    * Cloud Run fully-managed resource that receives the events. The resource
    * should be in the same project as the trigger.
@@ -38,58 +47,74 @@ public interface DestinationOrBuilder extends
   com.google.cloud.eventarc.v1.CloudRunOrBuilder getCloudRunOrBuilder();
 
   /**
+   *
+   *
    * 
    * The Cloud Function resource name. Only Cloud Functions V2 is supported.
    * Format: `projects/{project}/locations/{location}/functions/{function}`
    * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return Whether the cloudFunction field is set. */ boolean hasCloudFunction(); /** + * + * *
    * The Cloud Function resource name. Only Cloud Functions V2 is supported.
    * Format: `projects/{project}/locations/{location}/functions/{function}`
    * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return The cloudFunction. */ java.lang.String getCloudFunction(); /** + * + * *
    * The Cloud Function resource name. Only Cloud Functions V2 is supported.
    * Format: `projects/{project}/locations/{location}/functions/{function}`
    * 
* * string cloud_function = 2 [(.google.api.resource_reference) = { ... } + * * @return The bytes for cloudFunction. */ - com.google.protobuf.ByteString - getCloudFunctionBytes(); + com.google.protobuf.ByteString getCloudFunctionBytes(); /** + * + * *
    * A GKE service capable of receiving events. The service should be running
    * in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.GKE gke = 3; + * * @return Whether the gke field is set. */ boolean hasGke(); /** + * + * *
    * A GKE service capable of receiving events. The service should be running
    * in the same project as the trigger.
    * 
* * .google.cloud.eventarc.v1.GKE gke = 3; + * * @return The gke. */ com.google.cloud.eventarc.v1.GKE getGke(); /** + * + * *
    * A GKE service capable of receiving events. The service should be running
    * in the same project as the trigger.
@@ -100,6 +125,8 @@ public interface DestinationOrBuilder extends
   com.google.cloud.eventarc.v1.GKEOrBuilder getGkeOrBuilder();
 
   /**
+   *
+   *
    * 
    * The resource name of the Workflow whose Executions are triggered by
    * the events. The Workflow resource should be deployed in the same project
@@ -108,10 +135,13 @@ public interface DestinationOrBuilder extends
    * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return Whether the workflow field is set. */ boolean hasWorkflow(); /** + * + * *
    * The resource name of the Workflow whose Executions are triggered by
    * the events. The Workflow resource should be deployed in the same project
@@ -120,10 +150,13 @@ public interface DestinationOrBuilder extends
    * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return The workflow. */ java.lang.String getWorkflow(); /** + * + * *
    * The resource name of the Workflow whose Executions are triggered by
    * the events. The Workflow resource should be deployed in the same project
@@ -132,10 +165,10 @@ public interface DestinationOrBuilder extends
    * 
* * string workflow = 4 [(.google.api.resource_reference) = { ... } + * * @return The bytes for workflow. */ - com.google.protobuf.ByteString - getWorkflowBytes(); + com.google.protobuf.ByteString getWorkflowBytes(); public com.google.cloud.eventarc.v1.Destination.DescriptorCase getDescriptorCase(); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java new file mode 100644 index 000000000000..b9a996bec5fc --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java @@ -0,0 +1,99 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/discovery.proto + +package com.google.cloud.eventarc.v1; + +public final class DiscoveryProto { + private DiscoveryProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Provider_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_EventType_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n(google/cloud/eventarc/v1/discovery.pro" + + "to\022\030google.cloud.eventarc.v1\032\037google/api" + + "/field_behavior.proto\032\031google/api/resour" + + "ce.proto\"\361\001\n\010Provider\022\021\n\004name\030\001 \001(\tB\003\340A\003" + + "\022\031\n\014display_name\030\002 \001(\tB\003\340A\003\022=\n\013event_typ" + + "es\030\003 \003(\0132#.google.cloud.eventarc.v1.Even" + + "tTypeB\003\340A\003:x\352Au\n eventarc.googleapis.com" + + "/Provider\022 * Filters events based on exact matches on the CloudEvents attributes. *
* * Protobuf type {@code google.cloud.eventarc.v1.EventFilter} */ -public final class EventFilter extends - com.google.protobuf.GeneratedMessageV3 implements +public final class EventFilter extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.EventFilter) EventFilterOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use EventFilter.newBuilder() to construct. private EventFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private EventFilter() { attribute_ = ""; value_ = ""; @@ -27,32 +30,35 @@ private EventFilter() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new EventFilter(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.EventFilter.class, com.google.cloud.eventarc.v1.EventFilter.Builder.class); + com.google.cloud.eventarc.v1.EventFilter.class, + com.google.cloud.eventarc.v1.EventFilter.Builder.class); } public static final int ATTRIBUTE_FIELD_NUMBER = 1; private volatile java.lang.Object attribute_; /** + * + * *
    * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
    * are supported for filtering.
@@ -60,6 +66,7 @@ protected java.lang.Object newInstance(
    * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The attribute. */ @java.lang.Override @@ -68,14 +75,15 @@ public java.lang.String getAttribute() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); attribute_ = s; return s; } } /** + * + * *
    * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
    * are supported for filtering.
@@ -83,16 +91,15 @@ public java.lang.String getAttribute() {
    * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for attribute. */ @java.lang.Override - public com.google.protobuf.ByteString - getAttributeBytes() { + public com.google.protobuf.ByteString getAttributeBytes() { java.lang.Object ref = attribute_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); attribute_ = b; return b; } else { @@ -103,11 +110,14 @@ public java.lang.String getAttribute() { public static final int VALUE_FIELD_NUMBER = 2; private volatile java.lang.Object value_; /** + * + * *
    * Required. The value for the attribute.
    * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The value. */ @java.lang.Override @@ -116,29 +126,29 @@ public java.lang.String getValue() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); value_ = s; return s; } } /** + * + * *
    * Required. The value for the attribute.
    * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for value. */ @java.lang.Override - public com.google.protobuf.ByteString - getValueBytes() { + public com.google.protobuf.ByteString getValueBytes() { java.lang.Object ref = value_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); value_ = b; return b; } else { @@ -149,6 +159,8 @@ public java.lang.String getValue() { public static final int OPERATOR_FIELD_NUMBER = 3; private volatile java.lang.Object operator_; /** + * + * *
    * Optional. The operator used for matching the events with the value of the
    * filter. If not specified, only events that have an exact key-value pair
@@ -157,6 +169,7 @@ public java.lang.String getValue() {
    * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The operator. */ @java.lang.Override @@ -165,14 +178,15 @@ public java.lang.String getOperator() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); operator_ = s; return s; } } /** + * + * *
    * Optional. The operator used for matching the events with the value of the
    * filter. If not specified, only events that have an exact key-value pair
@@ -181,16 +195,15 @@ public java.lang.String getOperator() {
    * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for operator. */ @java.lang.Override - public com.google.protobuf.ByteString - getOperatorBytes() { + public com.google.protobuf.ByteString getOperatorBytes() { java.lang.Object ref = operator_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); operator_ = b; return b; } else { @@ -199,6 +212,7 @@ public java.lang.String getOperator() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -210,8 +224,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(attribute_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, attribute_); } @@ -247,19 +260,16 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.EventFilter)) { return super.equals(obj); } com.google.cloud.eventarc.v1.EventFilter other = (com.google.cloud.eventarc.v1.EventFilter) obj; - if (!getAttribute() - .equals(other.getAttribute())) return false; - if (!getValue() - .equals(other.getValue())) return false; - if (!getOperator() - .equals(other.getOperator())) return false; + if (!getAttribute().equals(other.getAttribute())) return false; + if (!getValue().equals(other.getValue())) return false; + if (!getOperator().equals(other.getOperator())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -282,130 +292,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.EventFilter parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.EventFilter parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.EventFilter parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.EventFilter parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.EventFilter parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.EventFilter parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.EventFilter prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Filters events based on exact matches on the CloudEvents attributes.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.EventFilter} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.EventFilter) com.google.cloud.eventarc.v1.EventFilterOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.EventFilter.class, com.google.cloud.eventarc.v1.EventFilter.Builder.class); + com.google.cloud.eventarc.v1.EventFilter.class, + com.google.cloud.eventarc.v1.EventFilter.Builder.class); } // Construct using com.google.cloud.eventarc.v1.EventFilter.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -419,9 +435,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; } @java.lang.Override @@ -440,7 +456,8 @@ public com.google.cloud.eventarc.v1.EventFilter build() { @java.lang.Override public com.google.cloud.eventarc.v1.EventFilter buildPartial() { - com.google.cloud.eventarc.v1.EventFilter result = new com.google.cloud.eventarc.v1.EventFilter(this); + com.google.cloud.eventarc.v1.EventFilter result = + new com.google.cloud.eventarc.v1.EventFilter(this); result.attribute_ = attribute_; result.value_ = value_; result.operator_ = operator_; @@ -452,38 +469,39 @@ public com.google.cloud.eventarc.v1.EventFilter buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.EventFilter) { - return mergeFrom((com.google.cloud.eventarc.v1.EventFilter)other); + return mergeFrom((com.google.cloud.eventarc.v1.EventFilter) other); } else { super.mergeFrom(other); return this; @@ -530,27 +548,31 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - attribute_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: { - value_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: { - operator_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + attribute_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + value_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + operator_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -563,6 +585,8 @@ public Builder mergeFrom( private java.lang.Object attribute_ = ""; /** + * + * *
      * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
      * are supported for filtering.
@@ -570,13 +594,13 @@ public Builder mergeFrom(
      * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The attribute. */ public java.lang.String getAttribute() { java.lang.Object ref = attribute_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); attribute_ = s; return s; @@ -585,6 +609,8 @@ public java.lang.String getAttribute() { } } /** + * + * *
      * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
      * are supported for filtering.
@@ -592,15 +618,14 @@ public java.lang.String getAttribute() {
      * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for attribute. */ - public com.google.protobuf.ByteString - getAttributeBytes() { + public com.google.protobuf.ByteString getAttributeBytes() { java.lang.Object ref = attribute_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); attribute_ = b; return b; } else { @@ -608,6 +633,8 @@ public java.lang.String getAttribute() { } } /** + * + * *
      * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
      * are supported for filtering.
@@ -615,20 +642,22 @@ public java.lang.String getAttribute() {
      * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The attribute to set. * @return This builder for chaining. */ - public Builder setAttribute( - java.lang.String value) { + public Builder setAttribute(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + attribute_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
      * are supported for filtering.
@@ -636,15 +665,18 @@ public Builder setAttribute(
      * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearAttribute() { - + attribute_ = getDefaultInstance().getAttribute(); onChanged(); return this; } /** + * + * *
      * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
      * are supported for filtering.
@@ -652,16 +684,16 @@ public Builder clearAttribute() {
      * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for attribute to set. * @return This builder for chaining. */ - public Builder setAttributeBytes( - com.google.protobuf.ByteString value) { + public Builder setAttributeBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + attribute_ = value; onChanged(); return this; @@ -669,18 +701,20 @@ public Builder setAttributeBytes( private java.lang.Object value_ = ""; /** + * + * *
      * Required. The value for the attribute.
      * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The value. */ public java.lang.String getValue() { java.lang.Object ref = value_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); value_ = s; return s; @@ -689,20 +723,21 @@ public java.lang.String getValue() { } } /** + * + * *
      * Required. The value for the attribute.
      * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for value. */ - public com.google.protobuf.ByteString - getValueBytes() { + public com.google.protobuf.ByteString getValueBytes() { java.lang.Object ref = value_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); value_ = b; return b; } else { @@ -710,54 +745,61 @@ public java.lang.String getValue() { } } /** + * + * *
      * Required. The value for the attribute.
      * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The value to set. * @return This builder for chaining. */ - public Builder setValue( - java.lang.String value) { + public Builder setValue(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + value_ = value; onChanged(); return this; } /** + * + * *
      * Required. The value for the attribute.
      * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValue() { - + value_ = getDefaultInstance().getValue(); onChanged(); return this; } /** + * + * *
      * Required. The value for the attribute.
      * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for value to set. * @return This builder for chaining. */ - public Builder setValueBytes( - com.google.protobuf.ByteString value) { + public Builder setValueBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + value_ = value; onChanged(); return this; @@ -765,6 +807,8 @@ public Builder setValueBytes( private java.lang.Object operator_ = ""; /** + * + * *
      * Optional. The operator used for matching the events with the value of the
      * filter. If not specified, only events that have an exact key-value pair
@@ -773,13 +817,13 @@ public Builder setValueBytes(
      * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The operator. */ public java.lang.String getOperator() { java.lang.Object ref = operator_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); operator_ = s; return s; @@ -788,6 +832,8 @@ public java.lang.String getOperator() { } } /** + * + * *
      * Optional. The operator used for matching the events with the value of the
      * filter. If not specified, only events that have an exact key-value pair
@@ -796,15 +842,14 @@ public java.lang.String getOperator() {
      * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for operator. */ - public com.google.protobuf.ByteString - getOperatorBytes() { + public com.google.protobuf.ByteString getOperatorBytes() { java.lang.Object ref = operator_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); operator_ = b; return b; } else { @@ -812,6 +857,8 @@ public java.lang.String getOperator() { } } /** + * + * *
      * Optional. The operator used for matching the events with the value of the
      * filter. If not specified, only events that have an exact key-value pair
@@ -820,20 +867,22 @@ public java.lang.String getOperator() {
      * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The operator to set. * @return This builder for chaining. */ - public Builder setOperator( - java.lang.String value) { + public Builder setOperator(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + operator_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The operator used for matching the events with the value of the
      * filter. If not specified, only events that have an exact key-value pair
@@ -842,15 +891,18 @@ public Builder setOperator(
      * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return This builder for chaining. */ public Builder clearOperator() { - + operator_ = getDefaultInstance().getOperator(); onChanged(); return this; } /** + * + * *
      * Optional. The operator used for matching the events with the value of the
      * filter. If not specified, only events that have an exact key-value pair
@@ -859,23 +911,23 @@ public Builder clearOperator() {
      * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The bytes for operator to set. * @return This builder for chaining. */ - public Builder setOperatorBytes( - com.google.protobuf.ByteString value) { + public Builder setOperatorBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + operator_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -885,12 +937,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.EventFilter) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.EventFilter) private static final com.google.cloud.eventarc.v1.EventFilter DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.EventFilter(); } @@ -899,27 +951,27 @@ public static com.google.cloud.eventarc.v1.EventFilter getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public EventFilter parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventFilter parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -934,6 +986,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.EventFilter getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java similarity index 88% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java index 457e3bd09f55..94cfa4013be5 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventFilterOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface EventFilterOrBuilder extends +public interface EventFilterOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.EventFilter) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
    * are supported for filtering.
@@ -15,10 +18,13 @@ public interface EventFilterOrBuilder extends
    * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The attribute. */ java.lang.String getAttribute(); /** + * + * *
    * Required. The name of a CloudEvents attribute. Currently, only a subset of attributes
    * are supported for filtering.
@@ -26,32 +32,39 @@ public interface EventFilterOrBuilder extends
    * 
* * string attribute = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for attribute. */ - com.google.protobuf.ByteString - getAttributeBytes(); + com.google.protobuf.ByteString getAttributeBytes(); /** + * + * *
    * Required. The value for the attribute.
    * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The value. */ java.lang.String getValue(); /** + * + * *
    * Required. The value for the attribute.
    * 
* * string value = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for value. */ - com.google.protobuf.ByteString - getValueBytes(); + com.google.protobuf.ByteString getValueBytes(); /** + * + * *
    * Optional. The operator used for matching the events with the value of the
    * filter. If not specified, only events that have an exact key-value pair
@@ -60,10 +73,13 @@ public interface EventFilterOrBuilder extends
    * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The operator. */ java.lang.String getOperator(); /** + * + * *
    * Optional. The operator used for matching the events with the value of the
    * filter. If not specified, only events that have an exact key-value pair
@@ -72,8 +88,8 @@ public interface EventFilterOrBuilder extends
    * 
* * string operator = 3 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for operator. */ - com.google.protobuf.ByteString - getOperatorBytes(); + com.google.protobuf.ByteString getOperatorBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java similarity index 70% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java index 6611e703fd94..05a576e912ee 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventType.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A representation of the event type resource.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.EventType} */ -public final class EventType extends - com.google.protobuf.GeneratedMessageV3 implements +public final class EventType extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.EventType) EventTypeOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use EventType.newBuilder() to construct. private EventType(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private EventType() { type_ = ""; description_ = ""; @@ -28,32 +31,35 @@ private EventType() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new EventType(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_EventType_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.EventType.class, com.google.cloud.eventarc.v1.EventType.Builder.class); + com.google.cloud.eventarc.v1.EventType.class, + com.google.cloud.eventarc.v1.EventType.Builder.class); } public static final int TYPE_FIELD_NUMBER = 1; private volatile java.lang.Object type_; /** + * + * *
    * Output only. The full name of the event type (for example,
    * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -64,6 +70,7 @@ protected java.lang.Object newInstance(
    * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The type. */ @java.lang.Override @@ -72,14 +79,15 @@ public java.lang.String getType() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } } /** + * + * *
    * Output only. The full name of the event type (for example,
    * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -90,16 +98,15 @@ public java.lang.String getType() {
    * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for type. */ @java.lang.Override - public com.google.protobuf.ByteString - getTypeBytes() { + public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); type_ = b; return b; } else { @@ -110,12 +117,15 @@ public java.lang.String getType() { public static final int DESCRIPTION_FIELD_NUMBER = 2; private volatile java.lang.Object description_; /** + * + * *
    * Output only. Human friendly description of what the event type is about.
    * For example "Bucket created in Cloud Storage".
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The description. */ @java.lang.Override @@ -124,30 +134,30 @@ public java.lang.String getDescription() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); description_ = s; return s; } } /** + * + * *
    * Output only. Human friendly description of what the event type is about.
    * For example "Bucket created in Cloud Storage".
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for description. */ @java.lang.Override - public com.google.protobuf.ByteString - getDescriptionBytes() { + public com.google.protobuf.ByteString getDescriptionBytes() { java.lang.Object ref = description_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); description_ = b; return b; } else { @@ -158,56 +168,77 @@ public java.lang.String getDescription() { public static final int FILTERING_ATTRIBUTES_FIELD_NUMBER = 3; private java.util.List filteringAttributes_; /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - public java.util.List getFilteringAttributesList() { + public java.util.List + getFilteringAttributesList() { return filteringAttributes_; } /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - public java.util.List + public java.util.List getFilteringAttributesOrBuilderList() { return filteringAttributes_; } /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public int getFilteringAttributesCount() { return filteringAttributes_.size(); } /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(int index) { return filteringAttributes_.get(index); } /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesOrBuilder( @@ -218,6 +249,8 @@ public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttr public static final int EVENT_SCHEMA_URI_FIELD_NUMBER = 4; private volatile java.lang.Object eventSchemaUri_; /** + * + * *
    * Output only. URI for the event schema.
    * For example
@@ -225,6 +258,7 @@ public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttr
    * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The eventSchemaUri. */ @java.lang.Override @@ -233,14 +267,15 @@ public java.lang.String getEventSchemaUri() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); eventSchemaUri_ = s; return s; } } /** + * + * *
    * Output only. URI for the event schema.
    * For example
@@ -248,16 +283,15 @@ public java.lang.String getEventSchemaUri() {
    * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for eventSchemaUri. */ @java.lang.Override - public com.google.protobuf.ByteString - getEventSchemaUriBytes() { + public com.google.protobuf.ByteString getEventSchemaUriBytes() { java.lang.Object ref = eventSchemaUri_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); eventSchemaUri_ = b; return b; } else { @@ -266,6 +300,7 @@ public java.lang.String getEventSchemaUri() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -277,8 +312,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, type_); } @@ -307,8 +341,8 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); } for (int i = 0; i < filteringAttributes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, filteringAttributes_.get(i)); + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, filteringAttributes_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(eventSchemaUri_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, eventSchemaUri_); @@ -321,21 +355,17 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.EventType)) { return super.equals(obj); } com.google.cloud.eventarc.v1.EventType other = (com.google.cloud.eventarc.v1.EventType) obj; - if (!getType() - .equals(other.getType())) return false; - if (!getDescription() - .equals(other.getDescription())) return false; - if (!getFilteringAttributesList() - .equals(other.getFilteringAttributesList())) return false; - if (!getEventSchemaUri() - .equals(other.getEventSchemaUri())) return false; + if (!getType().equals(other.getType())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (!getFilteringAttributesList().equals(other.getFilteringAttributesList())) return false; + if (!getEventSchemaUri().equals(other.getEventSchemaUri())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -362,130 +392,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.EventType parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.EventType parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventType parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventType parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventType parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.EventType parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.EventType parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.EventType prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A representation of the event type resource.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.EventType} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.EventType) com.google.cloud.eventarc.v1.EventTypeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_EventType_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.EventType.class, com.google.cloud.eventarc.v1.EventType.Builder.class); + com.google.cloud.eventarc.v1.EventType.class, + com.google.cloud.eventarc.v1.EventType.Builder.class); } // Construct using com.google.cloud.eventarc.v1.EventType.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -506,9 +542,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_EventType_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_EventType_descriptor; } @java.lang.Override @@ -527,7 +563,8 @@ public com.google.cloud.eventarc.v1.EventType build() { @java.lang.Override public com.google.cloud.eventarc.v1.EventType buildPartial() { - com.google.cloud.eventarc.v1.EventType result = new com.google.cloud.eventarc.v1.EventType(this); + com.google.cloud.eventarc.v1.EventType result = + new com.google.cloud.eventarc.v1.EventType(this); int from_bitField0_ = bitField0_; result.type_ = type_; result.description_ = description_; @@ -549,38 +586,39 @@ public com.google.cloud.eventarc.v1.EventType buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.EventType) { - return mergeFrom((com.google.cloud.eventarc.v1.EventType)other); + return mergeFrom((com.google.cloud.eventarc.v1.EventType) other); } else { super.mergeFrom(other); return this; @@ -615,9 +653,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.EventType other) { filteringAttributesBuilder_ = null; filteringAttributes_ = other.filteringAttributes_; bitField0_ = (bitField0_ & ~0x00000001); - filteringAttributesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getFilteringAttributesFieldBuilder() : null; + filteringAttributesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getFilteringAttributesFieldBuilder() + : null; } else { filteringAttributesBuilder_.addAllMessages(other.filteringAttributes_); } @@ -653,40 +692,45 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - type_ = input.readStringRequireUtf8(); + case 10: + { + type_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 18: { - description_ = input.readStringRequireUtf8(); + break; + } // case 10 + case 18: + { + description_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - com.google.cloud.eventarc.v1.FilteringAttribute m = - input.readMessage( - com.google.cloud.eventarc.v1.FilteringAttribute.parser(), - extensionRegistry); - if (filteringAttributesBuilder_ == null) { - ensureFilteringAttributesIsMutable(); - filteringAttributes_.add(m); - } else { - filteringAttributesBuilder_.addMessage(m); - } - break; - } // case 26 - case 34: { - eventSchemaUri_ = input.readStringRequireUtf8(); + break; + } // case 18 + case 26: + { + com.google.cloud.eventarc.v1.FilteringAttribute m = + input.readMessage( + com.google.cloud.eventarc.v1.FilteringAttribute.parser(), + extensionRegistry); + if (filteringAttributesBuilder_ == null) { + ensureFilteringAttributesIsMutable(); + filteringAttributes_.add(m); + } else { + filteringAttributesBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + eventSchemaUri_ = input.readStringRequireUtf8(); - break; - } // case 34 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -696,10 +740,13 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.lang.Object type_ = ""; /** + * + * *
      * Output only. The full name of the event type (for example,
      * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -710,13 +757,13 @@ public Builder mergeFrom(
      * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The type. */ public java.lang.String getType() { java.lang.Object ref = type_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; @@ -725,6 +772,8 @@ public java.lang.String getType() { } } /** + * + * *
      * Output only. The full name of the event type (for example,
      * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -735,15 +784,14 @@ public java.lang.String getType() {
      * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for type. */ - public com.google.protobuf.ByteString - getTypeBytes() { + public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); type_ = b; return b; } else { @@ -751,6 +799,8 @@ public java.lang.String getType() { } } /** + * + * *
      * Output only. The full name of the event type (for example,
      * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -761,20 +811,22 @@ public java.lang.String getType() {
      * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The type to set. * @return This builder for chaining. */ - public Builder setType( - java.lang.String value) { + public Builder setType(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + type_ = value; onChanged(); return this; } /** + * + * *
      * Output only. The full name of the event type (for example,
      * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -785,15 +837,18 @@ public Builder setType(
      * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearType() { - + type_ = getDefaultInstance().getType(); onChanged(); return this; } /** + * + * *
      * Output only. The full name of the event type (for example,
      * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -804,16 +859,16 @@ public Builder clearType() {
      * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for type to set. * @return This builder for chaining. */ - public Builder setTypeBytes( - com.google.protobuf.ByteString value) { + public Builder setTypeBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + type_ = value; onChanged(); return this; @@ -821,19 +876,21 @@ public Builder setTypeBytes( private java.lang.Object description_ = ""; /** + * + * *
      * Output only. Human friendly description of what the event type is about.
      * For example "Bucket created in Cloud Storage".
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The description. */ public java.lang.String getDescription() { java.lang.Object ref = description_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); description_ = s; return s; @@ -842,21 +899,22 @@ public java.lang.String getDescription() { } } /** + * + * *
      * Output only. Human friendly description of what the event type is about.
      * For example "Bucket created in Cloud Storage".
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for description. */ - public com.google.protobuf.ByteString - getDescriptionBytes() { + public com.google.protobuf.ByteString getDescriptionBytes() { java.lang.Object ref = description_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); description_ = b; return b; } else { @@ -864,82 +922,100 @@ public java.lang.String getDescription() { } } /** + * + * *
      * Output only. Human friendly description of what the event type is about.
      * For example "Bucket created in Cloud Storage".
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The description to set. * @return This builder for chaining. */ - public Builder setDescription( - java.lang.String value) { + public Builder setDescription(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + description_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Human friendly description of what the event type is about.
      * For example "Bucket created in Cloud Storage".
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearDescription() { - + description_ = getDefaultInstance().getDescription(); onChanged(); return this; } /** + * + * *
      * Output only. Human friendly description of what the event type is about.
      * For example "Bucket created in Cloud Storage".
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for description to set. * @return This builder for chaining. */ - public Builder setDescriptionBytes( - com.google.protobuf.ByteString value) { + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; onChanged(); return this; } private java.util.List filteringAttributes_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureFilteringAttributesIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { - filteringAttributes_ = new java.util.ArrayList(filteringAttributes_); + filteringAttributes_ = + new java.util.ArrayList( + filteringAttributes_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.FilteringAttribute, com.google.cloud.eventarc.v1.FilteringAttribute.Builder, com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder> filteringAttributesBuilder_; + com.google.cloud.eventarc.v1.FilteringAttribute, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder, + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder> + filteringAttributesBuilder_; /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public java.util.List getFilteringAttributesList() { + public java.util.List + getFilteringAttributesList() { if (filteringAttributesBuilder_ == null) { return java.util.Collections.unmodifiableList(filteringAttributes_); } else { @@ -947,11 +1023,15 @@ public java.util.List getFilter } } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public int getFilteringAttributesCount() { if (filteringAttributesBuilder_ == null) { @@ -961,11 +1041,15 @@ public int getFilteringAttributesCount() { } } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(int index) { if (filteringAttributesBuilder_ == null) { @@ -975,11 +1059,15 @@ public com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(in } } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setFilteringAttributes( int index, com.google.cloud.eventarc.v1.FilteringAttribute value) { @@ -996,11 +1084,15 @@ public Builder setFilteringAttributes( return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setFilteringAttributes( int index, com.google.cloud.eventarc.v1.FilteringAttribute.Builder builderForValue) { @@ -1014,11 +1106,15 @@ public Builder setFilteringAttributes( return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFilteringAttributes(com.google.cloud.eventarc.v1.FilteringAttribute value) { if (filteringAttributesBuilder_ == null) { @@ -1034,11 +1130,15 @@ public Builder addFilteringAttributes(com.google.cloud.eventarc.v1.FilteringAttr return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFilteringAttributes( int index, com.google.cloud.eventarc.v1.FilteringAttribute value) { @@ -1055,11 +1155,15 @@ public Builder addFilteringAttributes( return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFilteringAttributes( com.google.cloud.eventarc.v1.FilteringAttribute.Builder builderForValue) { @@ -1073,11 +1177,15 @@ public Builder addFilteringAttributes( return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFilteringAttributes( int index, com.google.cloud.eventarc.v1.FilteringAttribute.Builder builderForValue) { @@ -1091,18 +1199,21 @@ public Builder addFilteringAttributes( return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addAllFilteringAttributes( java.lang.Iterable values) { if (filteringAttributesBuilder_ == null) { ensureFilteringAttributesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, filteringAttributes_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, filteringAttributes_); onChanged(); } else { filteringAttributesBuilder_.addAllMessages(values); @@ -1110,11 +1221,15 @@ public Builder addAllFilteringAttributes( return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearFilteringAttributes() { if (filteringAttributesBuilder_ == null) { @@ -1127,11 +1242,15 @@ public Builder clearFilteringAttributes() { return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder removeFilteringAttributes(int index) { if (filteringAttributesBuilder_ == null) { @@ -1144,39 +1263,52 @@ public Builder removeFilteringAttributes(int index) { return this; } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.FilteringAttribute.Builder getFilteringAttributesBuilder( int index) { return getFilteringAttributesFieldBuilder().getBuilder(index); } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesOrBuilder( int index) { if (filteringAttributesBuilder_ == null) { - return filteringAttributes_.get(index); } else { + return filteringAttributes_.get(index); + } else { return filteringAttributesBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public java.util.List - getFilteringAttributesOrBuilderList() { + public java.util.List + getFilteringAttributesOrBuilderList() { if (filteringAttributesBuilder_ != null) { return filteringAttributesBuilder_.getMessageOrBuilderList(); } else { @@ -1184,45 +1316,63 @@ public com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttr } } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.FilteringAttribute.Builder addFilteringAttributesBuilder() { - return getFilteringAttributesFieldBuilder().addBuilder( - com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()); + return getFilteringAttributesFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()); } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.FilteringAttribute.Builder addFilteringAttributesBuilder( int index) { - return getFilteringAttributesFieldBuilder().addBuilder( - index, com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()); + return getFilteringAttributesFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()); } /** + * + * *
      * Output only. Filtering attributes for the event type.
      * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public java.util.List - getFilteringAttributesBuilderList() { + public java.util.List + getFilteringAttributesBuilderList() { return getFilteringAttributesFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.FilteringAttribute, com.google.cloud.eventarc.v1.FilteringAttribute.Builder, com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder> + com.google.cloud.eventarc.v1.FilteringAttribute, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder, + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder> getFilteringAttributesFieldBuilder() { if (filteringAttributesBuilder_ == null) { - filteringAttributesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.FilteringAttribute, com.google.cloud.eventarc.v1.FilteringAttribute.Builder, com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder>( + filteringAttributesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.FilteringAttribute, + com.google.cloud.eventarc.v1.FilteringAttribute.Builder, + com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder>( filteringAttributes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), @@ -1234,6 +1384,8 @@ public com.google.cloud.eventarc.v1.FilteringAttribute.Builder addFilteringAttri private java.lang.Object eventSchemaUri_ = ""; /** + * + * *
      * Output only. URI for the event schema.
      * For example
@@ -1241,13 +1393,13 @@ public com.google.cloud.eventarc.v1.FilteringAttribute.Builder addFilteringAttri
      * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The eventSchemaUri. */ public java.lang.String getEventSchemaUri() { java.lang.Object ref = eventSchemaUri_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); eventSchemaUri_ = s; return s; @@ -1256,6 +1408,8 @@ public java.lang.String getEventSchemaUri() { } } /** + * + * *
      * Output only. URI for the event schema.
      * For example
@@ -1263,15 +1417,14 @@ public java.lang.String getEventSchemaUri() {
      * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for eventSchemaUri. */ - public com.google.protobuf.ByteString - getEventSchemaUriBytes() { + public com.google.protobuf.ByteString getEventSchemaUriBytes() { java.lang.Object ref = eventSchemaUri_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); eventSchemaUri_ = b; return b; } else { @@ -1279,6 +1432,8 @@ public java.lang.String getEventSchemaUri() { } } /** + * + * *
      * Output only. URI for the event schema.
      * For example
@@ -1286,20 +1441,22 @@ public java.lang.String getEventSchemaUri() {
      * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The eventSchemaUri to set. * @return This builder for chaining. */ - public Builder setEventSchemaUri( - java.lang.String value) { + public Builder setEventSchemaUri(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + eventSchemaUri_ = value; onChanged(); return this; } /** + * + * *
      * Output only. URI for the event schema.
      * For example
@@ -1307,15 +1464,18 @@ public Builder setEventSchemaUri(
      * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearEventSchemaUri() { - + eventSchemaUri_ = getDefaultInstance().getEventSchemaUri(); onChanged(); return this; } /** + * + * *
      * Output only. URI for the event schema.
      * For example
@@ -1323,23 +1483,23 @@ public Builder clearEventSchemaUri() {
      * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for eventSchemaUri to set. * @return This builder for chaining. */ - public Builder setEventSchemaUriBytes( - com.google.protobuf.ByteString value) { + public Builder setEventSchemaUriBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + eventSchemaUri_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1349,12 +1509,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.EventType) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.EventType) private static final com.google.cloud.eventarc.v1.EventType DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.EventType(); } @@ -1363,27 +1523,27 @@ public static com.google.cloud.eventarc.v1.EventType getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public EventType parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EventType parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1398,6 +1558,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.EventType getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java similarity index 75% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java index 0431a02a4e45..f38b59f1e83d 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventTypeOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface EventTypeOrBuilder extends +public interface EventTypeOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.EventType) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Output only. The full name of the event type (for example,
    * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -18,10 +21,13 @@ public interface EventTypeOrBuilder extends
    * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The type. */ java.lang.String getType(); /** + * + * *
    * Output only. The full name of the event type (for example,
    * "google.cloud.storage.object.v1.finalized"). In the form of
@@ -32,78 +38,104 @@ public interface EventTypeOrBuilder extends
    * 
* * string type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for type. */ - com.google.protobuf.ByteString - getTypeBytes(); + com.google.protobuf.ByteString getTypeBytes(); /** + * + * *
    * Output only. Human friendly description of what the event type is about.
    * For example "Bucket created in Cloud Storage".
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The description. */ java.lang.String getDescription(); /** + * + * *
    * Output only. Human friendly description of what the event type is about.
    * For example "Bucket created in Cloud Storage".
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for description. */ - com.google.protobuf.ByteString - getDescriptionBytes(); + com.google.protobuf.ByteString getDescriptionBytes(); /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - java.util.List - getFilteringAttributesList(); + java.util.List getFilteringAttributesList(); /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.eventarc.v1.FilteringAttribute getFilteringAttributes(int index); /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ int getFilteringAttributesCount(); /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - java.util.List + java.util.List getFilteringAttributesOrBuilderList(); /** + * + * *
    * Output only. Filtering attributes for the event type.
    * 
* - * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.FilteringAttribute filtering_attributes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesOrBuilder( int index); /** + * + * *
    * Output only. URI for the event schema.
    * For example
@@ -111,10 +143,13 @@ com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesO
    * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The eventSchemaUri. */ java.lang.String getEventSchemaUri(); /** + * + * *
    * Output only. URI for the event schema.
    * For example
@@ -122,8 +157,8 @@ com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder getFilteringAttributesO
    * 
* * string event_schema_uri = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for eventSchemaUri. */ - com.google.protobuf.ByteString - getEventSchemaUriBytes(); + com.google.protobuf.ByteString getEventSchemaUriBytes(); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java new file mode 100644 index 000000000000..73ff5edf199a --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcProto.java @@ -0,0 +1,545 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/eventarc.proto + +package com.google.cloud.eventarc.v1; + +public final class EventarcProto { + private EventarcProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n\'google/cloud/eventarc/v1/eventarc.prot" + + "o\022\030google.cloud.eventarc.v1\032\034google/api/" + + "annotations.proto\032\027google/api/client.pro" + + "to\032\037google/api/field_behavior.proto\032\031goo" + + "gle/api/resource.proto\032&google/cloud/eve" + + "ntarc/v1/channel.proto\0321google/cloud/eve" + + "ntarc/v1/channel_connection.proto\032(googl" + + "e/cloud/eventarc/v1/discovery.proto\0324goo" + + "gle/cloud/eventarc/v1/google_channel_con" + + "fig.proto\032&google/cloud/eventarc/v1/trig" + + "ger.proto\032#google/longrunning/operations" + + ".proto\032 google/protobuf/field_mask.proto" + + "\032\037google/protobuf/timestamp.proto\"J\n\021Get" + + "TriggerRequest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037ev" + + "entarc.googleapis.com/Trigger\"\227\001\n\023ListTr" + + "iggersRequest\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037e" + + "ventarc.googleapis.com/Trigger\022\021\n\tpage_s" + + "ize\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\022\020\n\010order_b" + + "y\030\004 \001(\t\022\016\n\006filter\030\005 \001(\t\"y\n\024ListTriggersR" + + "esponse\0223\n\010triggers\030\001 \003(\0132!.google.cloud" + + ".eventarc.v1.Trigger\022\027\n\017next_page_token\030" + + "\002 \001(\t\022\023\n\013unreachable\030\003 \003(\t\"\275\001\n\024CreateTri" + + "ggerRequest\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037eve" + + "ntarc.googleapis.com/Trigger\0227\n\007trigger\030" + + "\002 \001(\0132!.google.cloud.eventarc.v1.Trigger" + + "B\003\340A\002\022\027\n\ntrigger_id\030\003 \001(\tB\003\340A\002\022\032\n\rvalida" + + "te_only\030\004 \001(\010B\003\340A\002\"\256\001\n\024UpdateTriggerRequ" + + "est\0222\n\007trigger\030\001 \001(\0132!.google.cloud.even" + + "tarc.v1.Trigger\022/\n\013update_mask\030\002 \001(\0132\032.g" + + "oogle.protobuf.FieldMask\022\025\n\rallow_missin" + + "g\030\003 \001(\010\022\032\n\rvalidate_only\030\004 \001(\010B\003\340A\002\"\216\001\n\024" + + "DeleteTriggerRequest\0225\n\004name\030\001 \001(\tB\'\340A\002\372" + + "A!\n\037eventarc.googleapis.com/Trigger\022\014\n\004e" + + "tag\030\002 \001(\t\022\025\n\rallow_missing\030\003 \001(\010\022\032\n\rvali" + + "date_only\030\004 \001(\010B\003\340A\002\"J\n\021GetChannelReques" + + "t\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037eventarc.google" + + "apis.com/Channel\"\207\001\n\023ListChannelsRequest" + + "\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037eventarc.googl" + + "eapis.com/Channel\022\021\n\tpage_size\030\002 \001(\005\022\022\n\n" + + "page_token\030\003 \001(\t\022\020\n\010order_by\030\004 \001(\t\"y\n\024Li" + + "stChannelsResponse\0223\n\010channels\030\001 \003(\0132!.g" + + "oogle.cloud.eventarc.v1.Channel\022\027\n\017next_" + + "page_token\030\002 \001(\t\022\023\n\013unreachable\030\003 \003(\t\"\275\001" + + "\n\024CreateChannelRequest\0227\n\006parent\030\001 \001(\tB\'" + + "\340A\002\372A!\022\037eventarc.googleapis.com/Channel\022" + + "7\n\007channel\030\002 \001(\0132!.google.cloud.eventarc" + + ".v1.ChannelB\003\340A\002\022\027\n\nchannel_id\030\003 \001(\tB\003\340A" + + "\002\022\032\n\rvalidate_only\030\004 \001(\010B\003\340A\002\"\227\001\n\024Update" + + "ChannelRequest\0222\n\007channel\030\001 \001(\0132!.google" + + ".cloud.eventarc.v1.Channel\022/\n\013update_mas" + + "k\030\002 \001(\0132\032.google.protobuf.FieldMask\022\032\n\rv" + + "alidate_only\030\003 \001(\010B\003\340A\002\"i\n\024DeleteChannel" + + "Request\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037eventarc." + + "googleapis.com/Channel\022\032\n\rvalidate_only\030" + + "\002 \001(\010B\003\340A\002\"L\n\022GetProviderRequest\0226\n\004name" + + "\030\001 \001(\tB(\340A\002\372A\"\n eventarc.googleapis.com/" + + "Provider\"\231\001\n\024ListProvidersRequest\0228\n\006par" + + "ent\030\001 \001(\tB(\340A\002\372A\"\022 eventarc.googleapis.c" + + "om/Provider\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_t" + + "oken\030\003 \001(\t\022\020\n\010order_by\030\004 \001(\t\022\016\n\006filter\030\005" + + " \001(\t\"|\n\025ListProvidersResponse\0225\n\tprovide" + + "rs\030\001 \003(\0132\".google.cloud.eventarc.v1.Prov" + + "ider\022\027\n\017next_page_token\030\002 \001(\t\022\023\n\013unreach" + + "able\030\003 \003(\t\"^\n\033GetChannelConnectionReques" + + "t\022?\n\004name\030\001 \001(\tB1\340A\002\372A+\n)eventarc.google" + + "apis.com/ChannelConnection\"\211\001\n\035ListChann" + + "elConnectionsRequest\022A\n\006parent\030\001 \001(\tB1\340A" + + "\002\372A+\022)eventarc.googleapis.com/ChannelCon" + + "nection\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_token" + + "\030\003 \001(\t\"\230\001\n\036ListChannelConnectionsRespons" + + "e\022H\n\023channel_connections\030\001 \003(\0132+.google." + + "cloud.eventarc.v1.ChannelConnection\022\027\n\017n" + + "ext_page_token\030\002 \001(\t\022\023\n\013unreachable\030\003 \003(" + + "\t\"\325\001\n\036CreateChannelConnectionRequest\022A\n\006" + + "parent\030\001 \001(\tB1\340A\002\372A+\022)eventarc.googleapi" + + "s.com/ChannelConnection\022L\n\022channel_conne" + + "ction\030\002 \001(\0132+.google.cloud.eventarc.v1.C" + + "hannelConnectionB\003\340A\002\022\"\n\025channel_connect" + + "ion_id\030\003 \001(\tB\003\340A\002\"a\n\036DeleteChannelConnec" + + "tionRequest\022?\n\004name\030\001 \001(\tB1\340A\002\372A+\n)event" + + "arc.googleapis.com/ChannelConnection\"\246\001\n" + + " UpdateGoogleChannelConfigRequest\022Q\n\025goo" + + "gle_channel_config\030\001 \001(\0132-.google.cloud." + + "eventarc.v1.GoogleChannelConfigB\003\340A\002\022/\n\013" + + "update_mask\030\002 \001(\0132\032.google.protobuf.Fiel" + + "dMask\"b\n\035GetGoogleChannelConfigRequest\022A" + + "\n\004name\030\001 \001(\tB3\340A\002\372A-\n+eventarc.googleapi" + + "s.com/GoogleChannelConfig\"\200\002\n\021OperationM" + + "etadata\0224\n\013create_time\030\001 \001(\0132\032.google.pr" + + "otobuf.TimestampB\003\340A\003\0221\n\010end_time\030\002 \001(\0132" + + "\032.google.protobuf.TimestampB\003\340A\003\022\023\n\006targ" + + "et\030\003 \001(\tB\003\340A\003\022\021\n\004verb\030\004 \001(\tB\003\340A\003\022\033\n\016stat" + + "us_message\030\005 \001(\tB\003\340A\003\022#\n\026requested_cance" + + "llation\030\006 \001(\010B\003\340A\003\022\030\n\013api_version\030\007 \001(\tB" + + "\003\340A\0032\317\035\n\010Eventarc\022\231\001\n\nGetTrigger\022+.googl" + + "e.cloud.eventarc.v1.GetTriggerRequest\032!." + + "google.cloud.eventarc.v1.Trigger\";\202\323\344\223\002." + + "\022,/v1/{name=projects/*/locations/*/trigg" + + "ers/*}\332A\004name\022\254\001\n\014ListTriggers\022-.google." + + "cloud.eventarc.v1.ListTriggersRequest\032.." + + "google.cloud.eventarc.v1.ListTriggersRes" + + "ponse\"=\202\323\344\223\002.\022,/v1/{parent=projects/*/lo" + + "cations/*}/triggers\332A\006parent\022\330\001\n\rCreateT" + + "rigger\022..google.cloud.eventarc.v1.Create" + + "TriggerRequest\032\035.google.longrunning.Oper" + + "ation\"x\202\323\344\223\0027\",/v1/{parent=projects/*/lo" + + "cations/*}/triggers:\007trigger\332A\031parent,tr" + + "igger,trigger_id\312A\034\n\007Trigger\022\021OperationM" + + "etadata\022\351\001\n\rUpdateTrigger\022..google.cloud" + + ".eventarc.v1.UpdateTriggerRequest\032\035.goog" + + "le.longrunning.Operation\"\210\001\202\323\344\223\002?24/v1/{" + + "trigger.name=projects/*/locations/*/trig" + + "gers/*}:\007trigger\332A!trigger,update_mask,a" + + "llow_missing\312A\034\n\007Trigger\022\021OperationMetad" + + "ata\022\310\001\n\rDeleteTrigger\022..google.cloud.eve" + + "ntarc.v1.DeleteTriggerRequest\032\035.google.l" + + "ongrunning.Operation\"h\202\323\344\223\002.*,/v1/{name=" + + "projects/*/locations/*/triggers/*}\332A\022nam" + + "e,allow_missing\312A\034\n\007Trigger\022\021OperationMe" + + "tadata\022\231\001\n\nGetChannel\022+.google.cloud.eve" + + "ntarc.v1.GetChannelRequest\032!.google.clou" + + "d.eventarc.v1.Channel\";\202\323\344\223\002.\022,/v1/{name" + + "=projects/*/locations/*/channels/*}\332A\004na" + + "me\022\254\001\n\014ListChannels\022-.google.cloud.event" + + "arc.v1.ListChannelsRequest\032..google.clou" + + "d.eventarc.v1.ListChannelsResponse\"=\202\323\344\223" + + "\002.\022,/v1/{parent=projects/*/locations/*}/" + + "channels\332A\006parent\022\330\001\n\rCreateChannel\022..go" + + "ogle.cloud.eventarc.v1.CreateChannelRequ" + + "est\032\035.google.longrunning.Operation\"x\202\323\344\223" + + "\0027\",/v1/{parent=projects/*/locations/*}/" + + "channels:\007channel\332A\031parent,channel,chann" + + "el_id\312A\034\n\007Channel\022\021OperationMetadata\022\332\001\n" + + "\rUpdateChannel\022..google.cloud.eventarc.v" + + "1.UpdateChannelRequest\032\035.google.longrunn" + + "ing.Operation\"z\202\323\344\223\002?24/v1/{channel.name" + + "=projects/*/locations/*/channels/*}:\007cha" + + "nnel\332A\023channel,update_mask\312A\034\n\007Channel\022\021" + + "OperationMetadata\022\272\001\n\rDeleteChannel\022..go" + + "ogle.cloud.eventarc.v1.DeleteChannelRequ" + + "est\032\035.google.longrunning.Operation\"Z\202\323\344\223" + + "\002.*,/v1/{name=projects/*/locations/*/cha" + + "nnels/*}\332A\004name\312A\034\n\007Channel\022\021OperationMe" + + "tadata\022\235\001\n\013GetProvider\022,.google.cloud.ev" + + "entarc.v1.GetProviderRequest\032\".google.cl" + + "oud.eventarc.v1.Provider\"<\202\323\344\223\002/\022-/v1/{n" + + "ame=projects/*/locations/*/providers/*}\332" + + "A\004name\022\260\001\n\rListProviders\022..google.cloud." + + "eventarc.v1.ListProvidersRequest\032/.googl" + + "e.cloud.eventarc.v1.ListProvidersRespons" + + "e\">\202\323\344\223\002/\022-/v1/{parent=projects/*/locati" + + "ons/*}/providers\332A\006parent\022\301\001\n\024GetChannel" + + "Connection\0225.google.cloud.eventarc.v1.Ge" + + "tChannelConnectionRequest\032+.google.cloud" + + ".eventarc.v1.ChannelConnection\"E\202\323\344\223\0028\0226" + + "/v1/{name=projects/*/locations/*/channel" + + "Connections/*}\332A\004name\022\324\001\n\026ListChannelCon" + + "nections\0227.google.cloud.eventarc.v1.List" + + "ChannelConnectionsRequest\0328.google.cloud" + + ".eventarc.v1.ListChannelConnectionsRespo" + + "nse\"G\202\323\344\223\0028\0226/v1/{parent=projects/*/loca" + + "tions/*}/channelConnections\332A\006parent\022\242\002\n" + + "\027CreateChannelConnection\0228.google.cloud." + + "eventarc.v1.CreateChannelConnectionReque" + + "st\032\035.google.longrunning.Operation\"\255\001\202\323\344\223" + + "\002L\"6/v1/{parent=projects/*/locations/*}/" + + "channelConnections:\022channel_connection\332A" + + "/parent,channel_connection,channel_conne" + + "ction_id\312A&\n\021ChannelConnection\022\021Operatio" + + "nMetadata\022\342\001\n\027DeleteChannelConnection\0228." + + "google.cloud.eventarc.v1.DeleteChannelCo" + + "nnectionRequest\032\035.google.longrunning.Ope" + + "ration\"n\202\323\344\223\0028*6/v1/{name=projects/*/loc" + + "ations/*/channelConnections/*}\332A\004name\312A&" + + "\n\021ChannelConnection\022\021OperationMetadata\022\306" + + "\001\n\026GetGoogleChannelConfig\0227.google.cloud" + + ".eventarc.v1.GetGoogleChannelConfigReque" + + "st\032-.google.cloud.eventarc.v1.GoogleChan" + + "nelConfig\"D\202\323\344\223\0027\0225/v1/{name=projects/*/" + + "locations/*/googleChannelConfig}\332A\004name\022" + + "\227\002\n\031UpdateGoogleChannelConfig\022:.google.c" + + "loud.eventarc.v1.UpdateGoogleChannelConf" + + "igRequest\032-.google.cloud.eventarc.v1.Goo" + + "gleChannelConfig\"\216\001\202\323\344\223\002d2K/v1/{google_c" + + "hannel_config.name=projects/*/locations/" + + "*/googleChannelConfig}:\025google_channel_c" + + "onfig\332A!google_channel_config,update_mas" + + "k\032K\312A\027eventarc.googleapis.com\322A.https://" + + "www.googleapis.com/auth/cloud-platformB\305" + + "\001\n\034com.google.cloud.eventarc.v1B\rEventar" + + "cProtoP\001Z@google.golang.org/genproto/goo" + + "gleapis/cloud/eventarc/v1;eventarc\252\002\030Goo" + + "gle.Cloud.Eventarc.V1\312\002\030Google\\Cloud\\Eve" + + "ntarc\\V1\352\002\033Google::Cloud::Eventarc::V1b\006" + + "proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.eventarc.v1.ChannelProto.getDescriptor(), + com.google.cloud.eventarc.v1.ChannelConnectionProto.getDescriptor(), + com.google.cloud.eventarc.v1.DiscoveryProto.getDescriptor(), + com.google.cloud.eventarc.v1.GoogleChannelConfigProto.getDescriptor(), + com.google.cloud.eventarc.v1.TriggerProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "OrderBy", "Filter", + }); + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor, + new java.lang.String[] { + "Triggers", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor, + new java.lang.String[] { + "Parent", "Trigger", "TriggerId", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor, + new java.lang.String[] { + "Trigger", "UpdateMask", "AllowMissing", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor, + new java.lang.String[] { + "Name", "Etag", "AllowMissing", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor = + getDescriptor().getMessageTypes().get(7); + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "OrderBy", + }); + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor = + getDescriptor().getMessageTypes().get(8); + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor, + new java.lang.String[] { + "Channels", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(9); + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor, + new java.lang.String[] { + "Parent", "Channel", "ChannelId", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor, + new java.lang.String[] { + "Channel", "UpdateMask", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor = + getDescriptor().getMessageTypes().get(11); + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor, + new java.lang.String[] { + "Name", "ValidateOnly", + }); + internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor = + getDescriptor().getMessageTypes().get(12); + internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor = + getDescriptor().getMessageTypes().get(13); + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "OrderBy", "Filter", + }); + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor = + getDescriptor().getMessageTypes().get(14); + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor, + new java.lang.String[] { + "Providers", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor = + getDescriptor().getMessageTypes().get(15); + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor = + getDescriptor().getMessageTypes().get(16); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor = + getDescriptor().getMessageTypes().get(17); + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor, + new java.lang.String[] { + "ChannelConnections", "NextPageToken", "Unreachable", + }); + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor = + getDescriptor().getMessageTypes().get(18); + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor, + new java.lang.String[] { + "Parent", "ChannelConnection", "ChannelConnectionId", + }); + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor = + getDescriptor().getMessageTypes().get(19); + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor = + getDescriptor().getMessageTypes().get(20); + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor, + new java.lang.String[] { + "GoogleChannelConfig", "UpdateMask", + }); + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor = + getDescriptor().getMessageTypes().get(21); + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor = + getDescriptor().getMessageTypes().get(22); + internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor, + new java.lang.String[] { + "CreateTime", + "EndTime", + "Target", + "Verb", + "StatusMessage", + "RequestedCancellation", + "ApiVersion", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resourceReference); + registry.add(com.google.longrunning.OperationsProto.operationInfo); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.eventarc.v1.ChannelProto.getDescriptor(); + com.google.cloud.eventarc.v1.ChannelConnectionProto.getDescriptor(); + com.google.cloud.eventarc.v1.DiscoveryProto.getDescriptor(); + com.google.cloud.eventarc.v1.GoogleChannelConfigProto.getDescriptor(); + com.google.cloud.eventarc.v1.TriggerProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java similarity index 72% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java index ed854fe4426d..d3e9c3eb1e15 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttribute.java @@ -4,6 +4,8 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A representation of the FilteringAttribute resource.
  * Filtering attributes are per event type.
@@ -11,15 +13,16 @@
  *
  * Protobuf type {@code google.cloud.eventarc.v1.FilteringAttribute}
  */
-public final class FilteringAttribute extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class FilteringAttribute extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.FilteringAttribute)
     FilteringAttributeOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use FilteringAttribute.newBuilder() to construct.
   private FilteringAttribute(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private FilteringAttribute() {
     attribute_ = "";
     description_ = "";
@@ -27,37 +30,41 @@ private FilteringAttribute() {
 
   @java.lang.Override
   @SuppressWarnings({"unused"})
-  protected java.lang.Object newInstance(
-      UnusedPrivateParameter unused) {
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
     return new FilteringAttribute();
   }
 
   @java.lang.Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
-  public static final com.google.protobuf.Descriptors.Descriptor
-      getDescriptor() {
-    return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.cloud.eventarc.v1.DiscoveryProto
+        .internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor;
   }
 
   @java.lang.Override
   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable
+    return com.google.cloud.eventarc.v1.DiscoveryProto
+        .internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            com.google.cloud.eventarc.v1.FilteringAttribute.class, com.google.cloud.eventarc.v1.FilteringAttribute.Builder.class);
+            com.google.cloud.eventarc.v1.FilteringAttribute.class,
+            com.google.cloud.eventarc.v1.FilteringAttribute.Builder.class);
   }
 
   public static final int ATTRIBUTE_FIELD_NUMBER = 1;
   private volatile java.lang.Object attribute_;
   /**
+   *
+   *
    * 
    * Output only. Attribute used for filtering the event type.
    * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The attribute. */ @java.lang.Override @@ -66,29 +73,29 @@ public java.lang.String getAttribute() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); attribute_ = s; return s; } } /** + * + * *
    * Output only. Attribute used for filtering the event type.
    * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for attribute. */ @java.lang.Override - public com.google.protobuf.ByteString - getAttributeBytes() { + public com.google.protobuf.ByteString getAttributeBytes() { java.lang.Object ref = attribute_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); attribute_ = b; return b; } else { @@ -99,11 +106,14 @@ public java.lang.String getAttribute() { public static final int DESCRIPTION_FIELD_NUMBER = 2; private volatile java.lang.Object description_; /** + * + * *
    * Output only. Description of the purpose of the attribute.
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The description. */ @java.lang.Override @@ -112,29 +122,29 @@ public java.lang.String getDescription() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); description_ = s; return s; } } /** + * + * *
    * Output only. Description of the purpose of the attribute.
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for description. */ @java.lang.Override - public com.google.protobuf.ByteString - getDescriptionBytes() { + public com.google.protobuf.ByteString getDescriptionBytes() { java.lang.Object ref = description_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); description_ = b; return b; } else { @@ -145,12 +155,15 @@ public java.lang.String getDescription() { public static final int REQUIRED_FIELD_NUMBER = 3; private boolean required_; /** + * + * *
    * Output only. If true, the triggers for this provider should always specify a filter
    * on these attributes. Trigger creation will fail otherwise.
    * 
* * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The required. */ @java.lang.Override @@ -161,12 +174,15 @@ public boolean getRequired() { public static final int PATH_PATTERN_SUPPORTED_FIELD_NUMBER = 4; private boolean pathPatternSupported_; /** + * + * *
    * Output only. If true, the attribute accepts matching expressions in the Eventarc
    * PathPattern format.
    * 
* * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The pathPatternSupported. */ @java.lang.Override @@ -175,6 +191,7 @@ public boolean getPathPatternSupported() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -186,8 +203,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(attribute_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, attribute_); } @@ -216,12 +232,10 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); } if (required_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(3, required_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, required_); } if (pathPatternSupported_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, pathPatternSupported_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, pathPatternSupported_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -231,21 +245,18 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.FilteringAttribute)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.FilteringAttribute other = (com.google.cloud.eventarc.v1.FilteringAttribute) obj; + com.google.cloud.eventarc.v1.FilteringAttribute other = + (com.google.cloud.eventarc.v1.FilteringAttribute) obj; - if (!getAttribute() - .equals(other.getAttribute())) return false; - if (!getDescription() - .equals(other.getDescription())) return false; - if (getRequired() - != other.getRequired()) return false; - if (getPathPatternSupported() - != other.getPathPatternSupported()) return false; + if (!getAttribute().equals(other.getAttribute())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (getRequired() != other.getRequired()) return false; + if (getPathPatternSupported() != other.getPathPatternSupported()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -262,107 +273,112 @@ public int hashCode() { hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getDescription().hashCode(); hash = (37 * hash) + REQUIRED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getRequired()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getRequired()); hash = (37 * hash) + PATH_PATTERN_SUPPORTED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getPathPatternSupported()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPathPatternSupported()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.FilteringAttribute parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.FilteringAttribute parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.FilteringAttribute parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.FilteringAttribute prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A representation of the FilteringAttribute resource.
    * Filtering attributes are per event type.
@@ -370,33 +386,32 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.cloud.eventarc.v1.FilteringAttribute}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.FilteringAttribute)
       com.google.cloud.eventarc.v1.FilteringAttributeOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.cloud.eventarc.v1.DiscoveryProto
+          .internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor;
     }
 
     @java.lang.Override
     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable
+      return com.google.cloud.eventarc.v1.DiscoveryProto
+          .internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              com.google.cloud.eventarc.v1.FilteringAttribute.class, com.google.cloud.eventarc.v1.FilteringAttribute.Builder.class);
+              com.google.cloud.eventarc.v1.FilteringAttribute.class,
+              com.google.cloud.eventarc.v1.FilteringAttribute.Builder.class);
     }
 
     // Construct using com.google.cloud.eventarc.v1.FilteringAttribute.newBuilder()
-    private Builder() {
+    private Builder() {}
 
-    }
-
-    private Builder(
-        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
-
     }
+
     @java.lang.Override
     public Builder clear() {
       super.clear();
@@ -412,9 +427,9 @@ public Builder clear() {
     }
 
     @java.lang.Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor;
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.cloud.eventarc.v1.DiscoveryProto
+          .internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor;
     }
 
     @java.lang.Override
@@ -433,7 +448,8 @@ public com.google.cloud.eventarc.v1.FilteringAttribute build() {
 
     @java.lang.Override
     public com.google.cloud.eventarc.v1.FilteringAttribute buildPartial() {
-      com.google.cloud.eventarc.v1.FilteringAttribute result = new com.google.cloud.eventarc.v1.FilteringAttribute(this);
+      com.google.cloud.eventarc.v1.FilteringAttribute result =
+          new com.google.cloud.eventarc.v1.FilteringAttribute(this);
       result.attribute_ = attribute_;
       result.description_ = description_;
       result.required_ = required_;
@@ -446,38 +462,39 @@ public com.google.cloud.eventarc.v1.FilteringAttribute buildPartial() {
     public Builder clone() {
       return super.clone();
     }
+
     @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
+
     @java.lang.Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
+
     @java.lang.Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
+
     @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
+
     @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
+
     @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
       if (other instanceof com.google.cloud.eventarc.v1.FilteringAttribute) {
-        return mergeFrom((com.google.cloud.eventarc.v1.FilteringAttribute)other);
+        return mergeFrom((com.google.cloud.eventarc.v1.FilteringAttribute) other);
       } else {
         super.mergeFrom(other);
         return this;
@@ -485,7 +502,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) {
     }
 
     public Builder mergeFrom(com.google.cloud.eventarc.v1.FilteringAttribute other) {
-      if (other == com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance()) return this;
+      if (other == com.google.cloud.eventarc.v1.FilteringAttribute.getDefaultInstance())
+        return this;
       if (!other.getAttribute().isEmpty()) {
         attribute_ = other.attribute_;
         onChanged();
@@ -526,32 +544,37 @@ public Builder mergeFrom(
             case 0:
               done = true;
               break;
-            case 10: {
-              attribute_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 10
-            case 18: {
-              description_ = input.readStringRequireUtf8();
-
-              break;
-            } // case 18
-            case 24: {
-              required_ = input.readBool();
-
-              break;
-            } // case 24
-            case 32: {
-              pathPatternSupported_ = input.readBool();
-
-              break;
-            } // case 32
-            default: {
-              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
-                done = true; // was an endgroup tag
-              }
-              break;
-            } // default:
+            case 10:
+              {
+                attribute_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 10
+            case 18:
+              {
+                description_ = input.readStringRequireUtf8();
+
+                break;
+              } // case 18
+            case 24:
+              {
+                required_ = input.readBool();
+
+                break;
+              } // case 24
+            case 32:
+              {
+                pathPatternSupported_ = input.readBool();
+
+                break;
+              } // case 32
+            default:
+              {
+                if (!super.parseUnknownField(input, extensionRegistry, tag)) {
+                  done = true; // was an endgroup tag
+                }
+                break;
+              } // default:
           } // switch (tag)
         } // while (!done)
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@@ -564,18 +587,20 @@ public Builder mergeFrom(
 
     private java.lang.Object attribute_ = "";
     /**
+     *
+     *
      * 
      * Output only. Attribute used for filtering the event type.
      * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The attribute. */ public java.lang.String getAttribute() { java.lang.Object ref = attribute_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); attribute_ = s; return s; @@ -584,20 +609,21 @@ public java.lang.String getAttribute() { } } /** + * + * *
      * Output only. Attribute used for filtering the event type.
      * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for attribute. */ - public com.google.protobuf.ByteString - getAttributeBytes() { + public com.google.protobuf.ByteString getAttributeBytes() { java.lang.Object ref = attribute_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); attribute_ = b; return b; } else { @@ -605,54 +631,61 @@ public java.lang.String getAttribute() { } } /** + * + * *
      * Output only. Attribute used for filtering the event type.
      * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The attribute to set. * @return This builder for chaining. */ - public Builder setAttribute( - java.lang.String value) { + public Builder setAttribute(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + attribute_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Attribute used for filtering the event type.
      * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearAttribute() { - + attribute_ = getDefaultInstance().getAttribute(); onChanged(); return this; } /** + * + * *
      * Output only. Attribute used for filtering the event type.
      * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for attribute to set. * @return This builder for chaining. */ - public Builder setAttributeBytes( - com.google.protobuf.ByteString value) { + public Builder setAttributeBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + attribute_ = value; onChanged(); return this; @@ -660,18 +693,20 @@ public Builder setAttributeBytes( private java.lang.Object description_ = ""; /** + * + * *
      * Output only. Description of the purpose of the attribute.
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The description. */ public java.lang.String getDescription() { java.lang.Object ref = description_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); description_ = s; return s; @@ -680,20 +715,21 @@ public java.lang.String getDescription() { } } /** + * + * *
      * Output only. Description of the purpose of the attribute.
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for description. */ - public com.google.protobuf.ByteString - getDescriptionBytes() { + public com.google.protobuf.ByteString getDescriptionBytes() { java.lang.Object ref = description_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); description_ = b; return b; } else { @@ -701,67 +737,77 @@ public java.lang.String getDescription() { } } /** + * + * *
      * Output only. Description of the purpose of the attribute.
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The description to set. * @return This builder for chaining. */ - public Builder setDescription( - java.lang.String value) { + public Builder setDescription(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + description_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Description of the purpose of the attribute.
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearDescription() { - + description_ = getDefaultInstance().getDescription(); onChanged(); return this; } /** + * + * *
      * Output only. Description of the purpose of the attribute.
      * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for description to set. * @return This builder for chaining. */ - public Builder setDescriptionBytes( - com.google.protobuf.ByteString value) { + public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + description_ = value; onChanged(); return this; } - private boolean required_ ; + private boolean required_; /** + * + * *
      * Output only. If true, the triggers for this provider should always specify a filter
      * on these attributes. Trigger creation will fail otherwise.
      * 
* * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The required. */ @java.lang.Override @@ -769,45 +815,54 @@ public boolean getRequired() { return required_; } /** + * + * *
      * Output only. If true, the triggers for this provider should always specify a filter
      * on these attributes. Trigger creation will fail otherwise.
      * 
* * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The required to set. * @return This builder for chaining. */ public Builder setRequired(boolean value) { - + required_ = value; onChanged(); return this; } /** + * + * *
      * Output only. If true, the triggers for this provider should always specify a filter
      * on these attributes. Trigger creation will fail otherwise.
      * 
* * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearRequired() { - + required_ = false; onChanged(); return this; } - private boolean pathPatternSupported_ ; + private boolean pathPatternSupported_; /** + * + * *
      * Output only. If true, the attribute accepts matching expressions in the Eventarc
      * PathPattern format.
      * 
* * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The pathPatternSupported. */ @java.lang.Override @@ -815,39 +870,45 @@ public boolean getPathPatternSupported() { return pathPatternSupported_; } /** + * + * *
      * Output only. If true, the attribute accepts matching expressions in the Eventarc
      * PathPattern format.
      * 
* * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The pathPatternSupported to set. * @return This builder for chaining. */ public Builder setPathPatternSupported(boolean value) { - + pathPatternSupported_ = value; onChanged(); return this; } /** + * + * *
      * Output only. If true, the attribute accepts matching expressions in the Eventarc
      * PathPattern format.
      * 
* * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearPathPatternSupported() { - + pathPatternSupported_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -857,12 +918,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.FilteringAttribute) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.FilteringAttribute) private static final com.google.cloud.eventarc.v1.FilteringAttribute DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.FilteringAttribute(); } @@ -871,27 +932,27 @@ public static com.google.cloud.eventarc.v1.FilteringAttribute getDefaultInstance return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public FilteringAttribute parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FilteringAttribute parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -906,6 +967,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.FilteringAttribute getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java similarity index 88% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java index 1824a8018b64..b38ffd0f5efc 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/FilteringAttributeOrBuilder.java @@ -3,68 +3,85 @@ package com.google.cloud.eventarc.v1; -public interface FilteringAttributeOrBuilder extends +public interface FilteringAttributeOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.FilteringAttribute) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Output only. Attribute used for filtering the event type.
    * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The attribute. */ java.lang.String getAttribute(); /** + * + * *
    * Output only. Attribute used for filtering the event type.
    * 
* * string attribute = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for attribute. */ - com.google.protobuf.ByteString - getAttributeBytes(); + com.google.protobuf.ByteString getAttributeBytes(); /** + * + * *
    * Output only. Description of the purpose of the attribute.
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The description. */ java.lang.String getDescription(); /** + * + * *
    * Output only. Description of the purpose of the attribute.
    * 
* * string description = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for description. */ - com.google.protobuf.ByteString - getDescriptionBytes(); + com.google.protobuf.ByteString getDescriptionBytes(); /** + * + * *
    * Output only. If true, the triggers for this provider should always specify a filter
    * on these attributes. Trigger creation will fail otherwise.
    * 
* * bool required = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The required. */ boolean getRequired(); /** + * + * *
    * Output only. If true, the attribute accepts matching expressions in the Eventarc
    * PathPattern format.
    * 
* * bool path_pattern_supported = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The pathPatternSupported. */ boolean getPathPatternSupported(); diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java index c34c6b4b0502..d87d33fc5a0b 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKE.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * Represents a GKE destination.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.GKE} */ -public final class GKE extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GKE extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GKE) GKEOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GKE.newBuilder() to construct. private GKE(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GKE() { cluster_ = ""; location_ = ""; @@ -29,25 +32,25 @@ private GKE() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GKE(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_GKE_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.eventarc.v1.GKE.class, com.google.cloud.eventarc.v1.GKE.Builder.class); } @@ -55,12 +58,15 @@ protected java.lang.Object newInstance( public static final int CLUSTER_FIELD_NUMBER = 1; private volatile java.lang.Object cluster_; /** + * + * *
    * Required. The name of the cluster the GKE service is running in. The cluster must be
    * running in the same project as the trigger being created.
    * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The cluster. */ @java.lang.Override @@ -69,30 +75,30 @@ public java.lang.String getCluster() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); cluster_ = s; return s; } } /** + * + * *
    * Required. The name of the cluster the GKE service is running in. The cluster must be
    * running in the same project as the trigger being created.
    * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for cluster. */ @java.lang.Override - public com.google.protobuf.ByteString - getClusterBytes() { + public com.google.protobuf.ByteString getClusterBytes() { java.lang.Object ref = cluster_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); cluster_ = b; return b; } else { @@ -103,6 +109,8 @@ public java.lang.String getCluster() { public static final int LOCATION_FIELD_NUMBER = 2; private volatile java.lang.Object location_; /** + * + * *
    * Required. The name of the Google Compute Engine in which the cluster resides, which
    * can either be compute zone (for example, us-central1-a) for the zonal
@@ -110,6 +118,7 @@ public java.lang.String getCluster() {
    * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The location. */ @java.lang.Override @@ -118,14 +127,15 @@ public java.lang.String getLocation() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); location_ = s; return s; } } /** + * + * *
    * Required. The name of the Google Compute Engine in which the cluster resides, which
    * can either be compute zone (for example, us-central1-a) for the zonal
@@ -133,16 +143,15 @@ public java.lang.String getLocation() {
    * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for location. */ @java.lang.Override - public com.google.protobuf.ByteString - getLocationBytes() { + public com.google.protobuf.ByteString getLocationBytes() { java.lang.Object ref = location_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); location_ = b; return b; } else { @@ -153,11 +162,14 @@ public java.lang.String getLocation() { public static final int NAMESPACE_FIELD_NUMBER = 3; private volatile java.lang.Object namespace_; /** + * + * *
    * Required. The namespace the GKE service is running in.
    * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The namespace. */ @java.lang.Override @@ -166,29 +178,29 @@ public java.lang.String getNamespace() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); namespace_ = s; return s; } } /** + * + * *
    * Required. The namespace the GKE service is running in.
    * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for namespace. */ @java.lang.Override - public com.google.protobuf.ByteString - getNamespaceBytes() { + public com.google.protobuf.ByteString getNamespaceBytes() { java.lang.Object ref = namespace_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); namespace_ = b; return b; } else { @@ -199,11 +211,14 @@ public java.lang.String getNamespace() { public static final int SERVICE_FIELD_NUMBER = 4; private volatile java.lang.Object service_; /** + * + * *
    * Required. Name of the GKE service.
    * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The service. */ @java.lang.Override @@ -212,29 +227,29 @@ public java.lang.String getService() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); service_ = s; return s; } } /** + * + * *
    * Required. Name of the GKE service.
    * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for service. */ @java.lang.Override - public com.google.protobuf.ByteString - getServiceBytes() { + public com.google.protobuf.ByteString getServiceBytes() { java.lang.Object ref = service_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); service_ = b; return b; } else { @@ -245,6 +260,8 @@ public java.lang.String getService() { public static final int PATH_FIELD_NUMBER = 5; private volatile java.lang.Object path_; /** + * + * *
    * Optional. The relative path on the GKE service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -252,6 +269,7 @@ public java.lang.String getService() {
    * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The path. */ @java.lang.Override @@ -260,14 +278,15 @@ public java.lang.String getPath() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); path_ = s; return s; } } /** + * + * *
    * Optional. The relative path on the GKE service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -275,16 +294,15 @@ public java.lang.String getPath() {
    * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for path. */ @java.lang.Override - public com.google.protobuf.ByteString - getPathBytes() { + public com.google.protobuf.ByteString getPathBytes() { java.lang.Object ref = path_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); path_ = b; return b; } else { @@ -293,6 +311,7 @@ public java.lang.String getPath() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -304,8 +323,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cluster_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, cluster_); } @@ -353,23 +371,18 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GKE)) { return super.equals(obj); } com.google.cloud.eventarc.v1.GKE other = (com.google.cloud.eventarc.v1.GKE) obj; - if (!getCluster() - .equals(other.getCluster())) return false; - if (!getLocation() - .equals(other.getLocation())) return false; - if (!getNamespace() - .equals(other.getNamespace())) return false; - if (!getService() - .equals(other.getService())) return false; - if (!getPath() - .equals(other.getPath())) return false; + if (!getCluster().equals(other.getCluster())) return false; + if (!getLocation().equals(other.getLocation())) return false; + if (!getNamespace().equals(other.getNamespace())) return false; + if (!getService().equals(other.getService())) return false; + if (!getPath().equals(other.getPath())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -396,130 +409,135 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.GKE parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.GKE parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GKE parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GKE parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.cloud.eventarc.v1.GKE parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GKE parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GKE parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GKE parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GKE parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GKE parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GKE parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GKE parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GKE parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GKE parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.GKE prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Represents a GKE destination.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.GKE} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GKE) com.google.cloud.eventarc.v1.GKEOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_GKE_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GKE.class, com.google.cloud.eventarc.v1.GKE.Builder.class); + com.google.cloud.eventarc.v1.GKE.class, + com.google.cloud.eventarc.v1.GKE.Builder.class); } // Construct using com.google.cloud.eventarc.v1.GKE.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -537,9 +555,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_GKE_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_GKE_descriptor; } @java.lang.Override @@ -572,38 +590,39 @@ public com.google.cloud.eventarc.v1.GKE buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.GKE) { - return mergeFrom((com.google.cloud.eventarc.v1.GKE)other); + return mergeFrom((com.google.cloud.eventarc.v1.GKE) other); } else { super.mergeFrom(other); return this; @@ -658,37 +677,43 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - cluster_ = input.readStringRequireUtf8(); + case 10: + { + cluster_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 18: { - location_ = input.readStringRequireUtf8(); + break; + } // case 10 + case 18: + { + location_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - namespace_ = input.readStringRequireUtf8(); + break; + } // case 18 + case 26: + { + namespace_ = input.readStringRequireUtf8(); - break; - } // case 26 - case 34: { - service_ = input.readStringRequireUtf8(); + break; + } // case 26 + case 34: + { + service_ = input.readStringRequireUtf8(); - break; - } // case 34 - case 42: { - path_ = input.readStringRequireUtf8(); + break; + } // case 34 + case 42: + { + path_ = input.readStringRequireUtf8(); - break; - } // case 42 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -701,19 +726,21 @@ public Builder mergeFrom( private java.lang.Object cluster_ = ""; /** + * + * *
      * Required. The name of the cluster the GKE service is running in. The cluster must be
      * running in the same project as the trigger being created.
      * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The cluster. */ public java.lang.String getCluster() { java.lang.Object ref = cluster_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); cluster_ = s; return s; @@ -722,21 +749,22 @@ public java.lang.String getCluster() { } } /** + * + * *
      * Required. The name of the cluster the GKE service is running in. The cluster must be
      * running in the same project as the trigger being created.
      * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for cluster. */ - public com.google.protobuf.ByteString - getClusterBytes() { + public com.google.protobuf.ByteString getClusterBytes() { java.lang.Object ref = cluster_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); cluster_ = b; return b; } else { @@ -744,57 +772,64 @@ public java.lang.String getCluster() { } } /** + * + * *
      * Required. The name of the cluster the GKE service is running in. The cluster must be
      * running in the same project as the trigger being created.
      * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The cluster to set. * @return This builder for chaining. */ - public Builder setCluster( - java.lang.String value) { + public Builder setCluster(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + cluster_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the cluster the GKE service is running in. The cluster must be
      * running in the same project as the trigger being created.
      * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearCluster() { - + cluster_ = getDefaultInstance().getCluster(); onChanged(); return this; } /** + * + * *
      * Required. The name of the cluster the GKE service is running in. The cluster must be
      * running in the same project as the trigger being created.
      * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for cluster to set. * @return This builder for chaining. */ - public Builder setClusterBytes( - com.google.protobuf.ByteString value) { + public Builder setClusterBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + cluster_ = value; onChanged(); return this; @@ -802,6 +837,8 @@ public Builder setClusterBytes( private java.lang.Object location_ = ""; /** + * + * *
      * Required. The name of the Google Compute Engine in which the cluster resides, which
      * can either be compute zone (for example, us-central1-a) for the zonal
@@ -809,13 +846,13 @@ public Builder setClusterBytes(
      * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The location. */ public java.lang.String getLocation() { java.lang.Object ref = location_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); location_ = s; return s; @@ -824,6 +861,8 @@ public java.lang.String getLocation() { } } /** + * + * *
      * Required. The name of the Google Compute Engine in which the cluster resides, which
      * can either be compute zone (for example, us-central1-a) for the zonal
@@ -831,15 +870,14 @@ public java.lang.String getLocation() {
      * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for location. */ - public com.google.protobuf.ByteString - getLocationBytes() { + public com.google.protobuf.ByteString getLocationBytes() { java.lang.Object ref = location_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); location_ = b; return b; } else { @@ -847,6 +885,8 @@ public java.lang.String getLocation() { } } /** + * + * *
      * Required. The name of the Google Compute Engine in which the cluster resides, which
      * can either be compute zone (for example, us-central1-a) for the zonal
@@ -854,20 +894,22 @@ public java.lang.String getLocation() {
      * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The location to set. * @return This builder for chaining. */ - public Builder setLocation( - java.lang.String value) { + public Builder setLocation(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + location_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the Google Compute Engine in which the cluster resides, which
      * can either be compute zone (for example, us-central1-a) for the zonal
@@ -875,15 +917,18 @@ public Builder setLocation(
      * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearLocation() { - + location_ = getDefaultInstance().getLocation(); onChanged(); return this; } /** + * + * *
      * Required. The name of the Google Compute Engine in which the cluster resides, which
      * can either be compute zone (for example, us-central1-a) for the zonal
@@ -891,16 +936,16 @@ public Builder clearLocation() {
      * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for location to set. * @return This builder for chaining. */ - public Builder setLocationBytes( - com.google.protobuf.ByteString value) { + public Builder setLocationBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + location_ = value; onChanged(); return this; @@ -908,18 +953,20 @@ public Builder setLocationBytes( private java.lang.Object namespace_ = ""; /** + * + * *
      * Required. The namespace the GKE service is running in.
      * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The namespace. */ public java.lang.String getNamespace() { java.lang.Object ref = namespace_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); namespace_ = s; return s; @@ -928,20 +975,21 @@ public java.lang.String getNamespace() { } } /** + * + * *
      * Required. The namespace the GKE service is running in.
      * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for namespace. */ - public com.google.protobuf.ByteString - getNamespaceBytes() { + public com.google.protobuf.ByteString getNamespaceBytes() { java.lang.Object ref = namespace_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); namespace_ = b; return b; } else { @@ -949,54 +997,61 @@ public java.lang.String getNamespace() { } } /** + * + * *
      * Required. The namespace the GKE service is running in.
      * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The namespace to set. * @return This builder for chaining. */ - public Builder setNamespace( - java.lang.String value) { + public Builder setNamespace(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + namespace_ = value; onChanged(); return this; } /** + * + * *
      * Required. The namespace the GKE service is running in.
      * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearNamespace() { - + namespace_ = getDefaultInstance().getNamespace(); onChanged(); return this; } /** + * + * *
      * Required. The namespace the GKE service is running in.
      * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for namespace to set. * @return This builder for chaining. */ - public Builder setNamespaceBytes( - com.google.protobuf.ByteString value) { + public Builder setNamespaceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + namespace_ = value; onChanged(); return this; @@ -1004,18 +1059,20 @@ public Builder setNamespaceBytes( private java.lang.Object service_ = ""; /** + * + * *
      * Required. Name of the GKE service.
      * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The service. */ public java.lang.String getService() { java.lang.Object ref = service_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); service_ = s; return s; @@ -1024,20 +1081,21 @@ public java.lang.String getService() { } } /** + * + * *
      * Required. Name of the GKE service.
      * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for service. */ - public com.google.protobuf.ByteString - getServiceBytes() { + public com.google.protobuf.ByteString getServiceBytes() { java.lang.Object ref = service_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); service_ = b; return b; } else { @@ -1045,54 +1103,61 @@ public java.lang.String getService() { } } /** + * + * *
      * Required. Name of the GKE service.
      * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The service to set. * @return This builder for chaining. */ - public Builder setService( - java.lang.String value) { + public Builder setService(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + service_ = value; onChanged(); return this; } /** + * + * *
      * Required. Name of the GKE service.
      * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearService() { - + service_ = getDefaultInstance().getService(); onChanged(); return this; } /** + * + * *
      * Required. Name of the GKE service.
      * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for service to set. * @return This builder for chaining. */ - public Builder setServiceBytes( - com.google.protobuf.ByteString value) { + public Builder setServiceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + service_ = value; onChanged(); return this; @@ -1100,6 +1165,8 @@ public Builder setServiceBytes( private java.lang.Object path_ = ""; /** + * + * *
      * Optional. The relative path on the GKE service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -1107,13 +1174,13 @@ public Builder setServiceBytes(
      * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The path. */ public java.lang.String getPath() { java.lang.Object ref = path_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); path_ = s; return s; @@ -1122,6 +1189,8 @@ public java.lang.String getPath() { } } /** + * + * *
      * Optional. The relative path on the GKE service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -1129,15 +1198,14 @@ public java.lang.String getPath() {
      * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for path. */ - public com.google.protobuf.ByteString - getPathBytes() { + public com.google.protobuf.ByteString getPathBytes() { java.lang.Object ref = path_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); path_ = b; return b; } else { @@ -1145,6 +1213,8 @@ public java.lang.String getPath() { } } /** + * + * *
      * Optional. The relative path on the GKE service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -1152,20 +1222,22 @@ public java.lang.String getPath() {
      * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The path to set. * @return This builder for chaining. */ - public Builder setPath( - java.lang.String value) { + public Builder setPath(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + path_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The relative path on the GKE service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -1173,15 +1245,18 @@ public Builder setPath(
      * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return This builder for chaining. */ public Builder clearPath() { - + path_ = getDefaultInstance().getPath(); onChanged(); return this; } /** + * + * *
      * Optional. The relative path on the GKE service the events should be sent to.
      * The value must conform to the definition of a URI path segment (section 3.3
@@ -1189,23 +1264,23 @@ public Builder clearPath() {
      * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The bytes for path to set. * @return This builder for chaining. */ - public Builder setPathBytes( - com.google.protobuf.ByteString value) { + public Builder setPathBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + path_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1215,12 +1290,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GKE) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GKE) private static final com.google.cloud.eventarc.v1.GKE DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GKE(); } @@ -1229,27 +1304,27 @@ public static com.google.cloud.eventarc.v1.GKE getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GKE parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GKE parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1264,6 +1339,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.GKE getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java similarity index 88% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java index 147c500d83a8..e37ff46b7a6f 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GKEOrBuilder.java @@ -3,33 +3,41 @@ package com.google.cloud.eventarc.v1; -public interface GKEOrBuilder extends +public interface GKEOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GKE) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the cluster the GKE service is running in. The cluster must be
    * running in the same project as the trigger being created.
    * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The cluster. */ java.lang.String getCluster(); /** + * + * *
    * Required. The name of the cluster the GKE service is running in. The cluster must be
    * running in the same project as the trigger being created.
    * 
* * string cluster = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for cluster. */ - com.google.protobuf.ByteString - getClusterBytes(); + com.google.protobuf.ByteString getClusterBytes(); /** + * + * *
    * Required. The name of the Google Compute Engine in which the cluster resides, which
    * can either be compute zone (for example, us-central1-a) for the zonal
@@ -37,10 +45,13 @@ public interface GKEOrBuilder extends
    * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The location. */ java.lang.String getLocation(); /** + * + * *
    * Required. The name of the Google Compute Engine in which the cluster resides, which
    * can either be compute zone (for example, us-central1-a) for the zonal
@@ -48,52 +59,64 @@ public interface GKEOrBuilder extends
    * 
* * string location = 2 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for location. */ - com.google.protobuf.ByteString - getLocationBytes(); + com.google.protobuf.ByteString getLocationBytes(); /** + * + * *
    * Required. The namespace the GKE service is running in.
    * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The namespace. */ java.lang.String getNamespace(); /** + * + * *
    * Required. The namespace the GKE service is running in.
    * 
* * string namespace = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for namespace. */ - com.google.protobuf.ByteString - getNamespaceBytes(); + com.google.protobuf.ByteString getNamespaceBytes(); /** + * + * *
    * Required. Name of the GKE service.
    * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The service. */ java.lang.String getService(); /** + * + * *
    * Required. Name of the GKE service.
    * 
* * string service = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for service. */ - com.google.protobuf.ByteString - getServiceBytes(); + com.google.protobuf.ByteString getServiceBytes(); /** + * + * *
    * Optional. The relative path on the GKE service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -101,10 +124,13 @@ public interface GKEOrBuilder extends
    * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The path. */ java.lang.String getPath(); /** + * + * *
    * Optional. The relative path on the GKE service the events should be sent to.
    * The value must conform to the definition of a URI path segment (section 3.3
@@ -112,8 +138,8 @@ public interface GKEOrBuilder extends
    * 
* * string path = 5 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for path. */ - com.google.protobuf.ByteString - getPathBytes(); + com.google.protobuf.ByteString getPathBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java similarity index 63% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java index 459190c2a324..2a4d29010c76 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequest.java @@ -4,58 +4,67 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the GetChannelConnection method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetChannelConnectionRequest} */ -public final class GetChannelConnectionRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetChannelConnectionRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetChannelConnectionRequest) GetChannelConnectionRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetChannelConnectionRequest.newBuilder() to construct. private GetChannelConnectionRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GetChannelConnectionRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GetChannelConnectionRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, com.google.cloud.eventarc.v1.GetChannelConnectionRequest.Builder.class); + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the channel connection to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +73,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the channel connection to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -95,6 +106,7 @@ public java.lang.String getName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -106,8 +118,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -131,15 +142,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GetChannelConnectionRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.GetChannelConnectionRequest other = (com.google.cloud.eventarc.v1.GetChannelConnectionRequest) obj; + com.google.cloud.eventarc.v1.GetChannelConnectionRequest other = + (com.google.cloud.eventarc.v1.GetChannelConnectionRequest) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -159,129 +170,136 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.cloud.eventarc.v1.GetChannelConnectionRequest prototype) { + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.GetChannelConnectionRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the GetChannelConnection method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetChannelConnectionRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetChannelConnectionRequest) com.google.cloud.eventarc.v1.GetChannelConnectionRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, com.google.cloud.eventarc.v1.GetChannelConnectionRequest.Builder.class); + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, + com.google.cloud.eventarc.v1.GetChannelConnectionRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.GetChannelConnectionRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -291,9 +309,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor; } @java.lang.Override @@ -312,7 +330,8 @@ public com.google.cloud.eventarc.v1.GetChannelConnectionRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.GetChannelConnectionRequest buildPartial() { - com.google.cloud.eventarc.v1.GetChannelConnectionRequest result = new com.google.cloud.eventarc.v1.GetChannelConnectionRequest(this); + com.google.cloud.eventarc.v1.GetChannelConnectionRequest result = + new com.google.cloud.eventarc.v1.GetChannelConnectionRequest(this); result.name_ = name_; onBuilt(); return result; @@ -322,38 +341,39 @@ public com.google.cloud.eventarc.v1.GetChannelConnectionRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.GetChannelConnectionRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.GetChannelConnectionRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.GetChannelConnectionRequest) other); } else { super.mergeFrom(other); return this; @@ -361,7 +381,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.GetChannelConnectionRequest other) { - if (other == com.google.cloud.eventarc.v1.GetChannelConnectionRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.GetChannelConnectionRequest.getDefaultInstance()) + return this; if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); @@ -392,17 +413,19 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -415,18 +438,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the channel connection to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -435,20 +462,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel connection to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -456,61 +486,74 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel connection to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the channel connection to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the channel connection to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -520,12 +563,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetChannelConnectionRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetChannelConnectionRequest) private static final com.google.cloud.eventarc.v1.GetChannelConnectionRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetChannelConnectionRequest(); } @@ -534,27 +577,27 @@ public static com.google.cloud.eventarc.v1.GetChannelConnectionRequest getDefaul return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetChannelConnectionRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetChannelConnectionRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -569,6 +612,4 @@ public com.google.protobuf.Parser getParserForType( public com.google.cloud.eventarc.v1.GetChannelConnectionRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java similarity index 58% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java index fef9c2f47b62..d4d7af9c2b63 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelConnectionRequestOrBuilder.java @@ -3,27 +3,37 @@ package com.google.cloud.eventarc.v1; -public interface GetChannelConnectionRequestOrBuilder extends +public interface GetChannelConnectionRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetChannelConnectionRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the channel connection to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the channel connection to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java similarity index 63% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java index d6b1f04c0296..3f021f550e6d 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequest.java @@ -4,58 +4,67 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the GetChannel method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetChannelRequest} */ -public final class GetChannelRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetChannelRequest) GetChannelRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetChannelRequest.newBuilder() to construct. private GetChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GetChannelRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GetChannelRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetChannelRequest.class, com.google.cloud.eventarc.v1.GetChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.GetChannelRequest.class, + com.google.cloud.eventarc.v1.GetChannelRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the channel to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +73,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the channel to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -95,6 +106,7 @@ public java.lang.String getName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -106,8 +118,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -131,15 +142,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GetChannelRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.GetChannelRequest other = (com.google.cloud.eventarc.v1.GetChannelRequest) obj; + com.google.cloud.eventarc.v1.GetChannelRequest other = + (com.google.cloud.eventarc.v1.GetChannelRequest) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -158,130 +169,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetChannelRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetChannelRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.GetChannelRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the GetChannel method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetChannelRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetChannelRequest) com.google.cloud.eventarc.v1.GetChannelRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetChannelRequest.class, com.google.cloud.eventarc.v1.GetChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.GetChannelRequest.class, + com.google.cloud.eventarc.v1.GetChannelRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.GetChannelRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -291,9 +308,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor; } @java.lang.Override @@ -312,7 +329,8 @@ public com.google.cloud.eventarc.v1.GetChannelRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.GetChannelRequest buildPartial() { - com.google.cloud.eventarc.v1.GetChannelRequest result = new com.google.cloud.eventarc.v1.GetChannelRequest(this); + com.google.cloud.eventarc.v1.GetChannelRequest result = + new com.google.cloud.eventarc.v1.GetChannelRequest(this); result.name_ = name_; onBuilt(); return result; @@ -322,38 +340,39 @@ public com.google.cloud.eventarc.v1.GetChannelRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.GetChannelRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.GetChannelRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.GetChannelRequest) other); } else { super.mergeFrom(other); return this; @@ -392,17 +411,19 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -415,18 +436,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the channel to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -435,20 +460,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -456,61 +484,74 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the channel to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the channel to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the channel to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -520,12 +561,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetChannelRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetChannelRequest) private static final com.google.cloud.eventarc.v1.GetChannelRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetChannelRequest(); } @@ -534,27 +575,27 @@ public static com.google.cloud.eventarc.v1.GetChannelRequest getDefaultInstance( return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetChannelRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -569,6 +610,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.GetChannelRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java similarity index 58% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java index 0b3700fc4fb5..7ef7adbc9d9b 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetChannelRequestOrBuilder.java @@ -3,27 +3,37 @@ package com.google.cloud.eventarc.v1; -public interface GetChannelRequestOrBuilder extends +public interface GetChannelRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetChannelRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the channel to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the channel to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java similarity index 63% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java index 0647861c6865..303d8a5f17d5 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequest.java @@ -4,58 +4,67 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the GetGoogleChannelConfig method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetGoogleChannelConfigRequest} */ -public final class GetGoogleChannelConfigRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetGoogleChannelConfigRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) GetGoogleChannelConfigRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetGoogleChannelConfigRequest.newBuilder() to construct. private GetGoogleChannelConfigRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GetGoogleChannelConfigRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GetGoogleChannelConfigRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.Builder.class); + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the config to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +73,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the config to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -95,6 +106,7 @@ public java.lang.String getName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -106,8 +118,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -131,15 +142,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest other = (com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) obj; + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest other = + (com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -159,129 +170,136 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest prototype) { + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the GetGoogleChannelConfig method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetGoogleChannelConfigRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.Builder.class); + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -291,9 +309,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor; } @java.lang.Override @@ -312,7 +330,8 @@ public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest buildPartial() { - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest result = new com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest(this); + com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest result = + new com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest(this); result.name_ = name_; onBuilt(); return result; @@ -322,38 +341,39 @@ public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest buildPartial() public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) other); } else { super.mergeFrom(other); return this; @@ -361,7 +381,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest other) { - if (other == com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.getDefaultInstance()) + return this; if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); @@ -392,17 +413,19 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -415,18 +438,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the config to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -435,20 +462,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the config to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -456,61 +486,74 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the config to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the config to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the config to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -520,12 +563,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) private static final com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest(); } @@ -534,27 +577,27 @@ public static com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest getDefa return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetGoogleChannelConfigRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetGoogleChannelConfigRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -569,6 +612,4 @@ public com.google.protobuf.Parser getParserForTyp public com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java similarity index 57% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java index 79f46dcd7710..03cf042137ee 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetGoogleChannelConfigRequestOrBuilder.java @@ -3,27 +3,37 @@ package com.google.cloud.eventarc.v1; -public interface GetGoogleChannelConfigRequestOrBuilder extends +public interface GetGoogleChannelConfigRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the config to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the config to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java similarity index 63% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java index ad342b02fe07..eeeafdd8963b 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequest.java @@ -4,58 +4,67 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the GetProvider method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetProviderRequest} */ -public final class GetProviderRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetProviderRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetProviderRequest) GetProviderRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetProviderRequest.newBuilder() to construct. private GetProviderRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GetProviderRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GetProviderRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetProviderRequest.class, com.google.cloud.eventarc.v1.GetProviderRequest.Builder.class); + com.google.cloud.eventarc.v1.GetProviderRequest.class, + com.google.cloud.eventarc.v1.GetProviderRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the provider to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +73,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the provider to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -95,6 +106,7 @@ public java.lang.String getName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -106,8 +118,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -131,15 +142,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GetProviderRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.GetProviderRequest other = (com.google.cloud.eventarc.v1.GetProviderRequest) obj; + com.google.cloud.eventarc.v1.GetProviderRequest other = + (com.google.cloud.eventarc.v1.GetProviderRequest) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -158,130 +169,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetProviderRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetProviderRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetProviderRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.GetProviderRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the GetProvider method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetProviderRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetProviderRequest) com.google.cloud.eventarc.v1.GetProviderRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetProviderRequest.class, com.google.cloud.eventarc.v1.GetProviderRequest.Builder.class); + com.google.cloud.eventarc.v1.GetProviderRequest.class, + com.google.cloud.eventarc.v1.GetProviderRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.GetProviderRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -291,9 +308,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor; } @java.lang.Override @@ -312,7 +329,8 @@ public com.google.cloud.eventarc.v1.GetProviderRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.GetProviderRequest buildPartial() { - com.google.cloud.eventarc.v1.GetProviderRequest result = new com.google.cloud.eventarc.v1.GetProviderRequest(this); + com.google.cloud.eventarc.v1.GetProviderRequest result = + new com.google.cloud.eventarc.v1.GetProviderRequest(this); result.name_ = name_; onBuilt(); return result; @@ -322,38 +340,39 @@ public com.google.cloud.eventarc.v1.GetProviderRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.GetProviderRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.GetProviderRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.GetProviderRequest) other); } else { super.mergeFrom(other); return this; @@ -361,7 +380,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.GetProviderRequest other) { - if (other == com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance()) + return this; if (!other.getName().isEmpty()) { name_ = other.name_; onChanged(); @@ -392,17 +412,19 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -415,18 +437,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the provider to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -435,20 +461,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the provider to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -456,61 +485,74 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the provider to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the provider to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the provider to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -520,12 +562,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetProviderRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetProviderRequest) private static final com.google.cloud.eventarc.v1.GetProviderRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetProviderRequest(); } @@ -534,27 +576,27 @@ public static com.google.cloud.eventarc.v1.GetProviderRequest getDefaultInstance return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetProviderRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetProviderRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -569,6 +611,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.GetProviderRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java similarity index 58% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java index b8eee96440c1..2eb45d220e5f 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetProviderRequestOrBuilder.java @@ -3,27 +3,37 @@ package com.google.cloud.eventarc.v1; -public interface GetProviderRequestOrBuilder extends +public interface GetProviderRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetProviderRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the provider to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the provider to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java similarity index 63% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java index c9b671166ce1..24b740eef108 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequest.java @@ -4,58 +4,67 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the GetTrigger method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetTriggerRequest} */ -public final class GetTriggerRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GetTriggerRequest) GetTriggerRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetTriggerRequest.newBuilder() to construct. private GetTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GetTriggerRequest() { name_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new GetTriggerRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetTriggerRequest.class, com.google.cloud.eventarc.v1.GetTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.GetTriggerRequest.class, + com.google.cloud.eventarc.v1.GetTriggerRequest.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The name of the trigger to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ @java.lang.Override @@ -64,29 +73,31 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The name of the trigger to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -95,6 +106,7 @@ public java.lang.String getName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -106,8 +118,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -131,15 +142,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GetTriggerRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.GetTriggerRequest other = (com.google.cloud.eventarc.v1.GetTriggerRequest) obj; + com.google.cloud.eventarc.v1.GetTriggerRequest other = + (com.google.cloud.eventarc.v1.GetTriggerRequest) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -158,130 +169,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GetTriggerRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GetTriggerRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.GetTriggerRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the GetTrigger method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.GetTriggerRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GetTriggerRequest) com.google.cloud.eventarc.v1.GetTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.GetTriggerRequest.class, com.google.cloud.eventarc.v1.GetTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.GetTriggerRequest.class, + com.google.cloud.eventarc.v1.GetTriggerRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.GetTriggerRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -291,9 +308,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor; } @java.lang.Override @@ -312,7 +329,8 @@ public com.google.cloud.eventarc.v1.GetTriggerRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.GetTriggerRequest buildPartial() { - com.google.cloud.eventarc.v1.GetTriggerRequest result = new com.google.cloud.eventarc.v1.GetTriggerRequest(this); + com.google.cloud.eventarc.v1.GetTriggerRequest result = + new com.google.cloud.eventarc.v1.GetTriggerRequest(this); result.name_ = name_; onBuilt(); return result; @@ -322,38 +340,39 @@ public com.google.cloud.eventarc.v1.GetTriggerRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.GetTriggerRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.GetTriggerRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.GetTriggerRequest) other); } else { super.mergeFrom(other); return this; @@ -392,17 +411,19 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -415,18 +436,22 @@ public Builder mergeFrom( private java.lang.Object name_ = ""; /** + * + * *
      * Required. The name of the trigger to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -435,20 +460,23 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the trigger to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -456,61 +484,74 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The name of the trigger to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The name of the trigger to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The name of the trigger to get.
      * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -520,12 +561,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GetTriggerRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GetTriggerRequest) private static final com.google.cloud.eventarc.v1.GetTriggerRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GetTriggerRequest(); } @@ -534,27 +575,27 @@ public static com.google.cloud.eventarc.v1.GetTriggerRequest getDefaultInstance( return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -569,6 +610,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.GetTriggerRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java similarity index 58% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java index 6542458b87d4..996876ae2f36 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GetTriggerRequestOrBuilder.java @@ -3,27 +3,37 @@ package com.google.cloud.eventarc.v1; -public interface GetTriggerRequestOrBuilder extends +public interface GetTriggerRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GetTriggerRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The name of the trigger to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The name of the trigger to get.
    * 
* - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java similarity index 68% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java index 9517d0a2fd10..ba608dce91b9 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfig.java @@ -4,6 +4,8 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A GoogleChannelConfig is a resource that stores the custom settings
  * respected by Eventarc first-party triggers in the matching region.
@@ -14,15 +16,16 @@
  *
  * Protobuf type {@code google.cloud.eventarc.v1.GoogleChannelConfig}
  */
-public final class GoogleChannelConfig extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class GoogleChannelConfig extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.GoogleChannelConfig)
     GoogleChannelConfigOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use GoogleChannelConfig.newBuilder() to construct.
   private GoogleChannelConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private GoogleChannelConfig() {
     name_ = "";
     cryptoKeyName_ = "";
@@ -30,38 +33,42 @@ private GoogleChannelConfig() {
 
   @java.lang.Override
   @SuppressWarnings({"unused"})
-  protected java.lang.Object newInstance(
-      UnusedPrivateParameter unused) {
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
     return new GoogleChannelConfig();
   }
 
   @java.lang.Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
-  public static final com.google.protobuf.Descriptors.Descriptor
-      getDescriptor() {
-    return com.google.cloud.eventarc.v1.GoogleChannelConfigProto.internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.cloud.eventarc.v1.GoogleChannelConfigProto
+        .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor;
   }
 
   @java.lang.Override
   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return com.google.cloud.eventarc.v1.GoogleChannelConfigProto.internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable
+    return com.google.cloud.eventarc.v1.GoogleChannelConfigProto
+        .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            com.google.cloud.eventarc.v1.GoogleChannelConfig.class, com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder.class);
+            com.google.cloud.eventarc.v1.GoogleChannelConfig.class,
+            com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder.class);
   }
 
   public static final int NAME_FIELD_NUMBER = 1;
   private volatile java.lang.Object name_;
   /**
+   *
+   *
    * 
    * Required. The resource name of the config. Must be in the format of,
    * `projects/{project}/locations/{location}/googleChannelConfig`.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ @java.lang.Override @@ -70,30 +77,30 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The resource name of the config. Must be in the format of,
    * `projects/{project}/locations/{location}/googleChannelConfig`.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -104,11 +111,15 @@ public java.lang.String getName() { public static final int UPDATE_TIME_FIELD_NUMBER = 6; private com.google.protobuf.Timestamp updateTime_; /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ @java.lang.Override @@ -116,11 +127,15 @@ public boolean hasUpdateTime() { return updateTime_ != null; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ @java.lang.Override @@ -128,11 +143,14 @@ public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { @@ -142,6 +160,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { public static final int CRYPTO_KEY_NAME_FIELD_NUMBER = 7; private volatile java.lang.Object cryptoKeyName_; /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -149,7 +169,10 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The cryptoKeyName. */ @java.lang.Override @@ -158,14 +181,15 @@ public java.lang.String getCryptoKeyName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); cryptoKeyName_ = s; return s; } } /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -173,17 +197,18 @@ public java.lang.String getCryptoKeyName() {
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for cryptoKeyName. */ @java.lang.Override - public com.google.protobuf.ByteString - getCryptoKeyNameBytes() { + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { java.lang.Object ref = cryptoKeyName_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); cryptoKeyName_ = b; return b; } else { @@ -192,6 +217,7 @@ public java.lang.String getCryptoKeyName() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -203,8 +229,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -227,8 +252,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getUpdateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(cryptoKeyName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, cryptoKeyName_); @@ -241,22 +265,20 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.GoogleChannelConfig)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.GoogleChannelConfig other = (com.google.cloud.eventarc.v1.GoogleChannelConfig) obj; + com.google.cloud.eventarc.v1.GoogleChannelConfig other = + (com.google.cloud.eventarc.v1.GoogleChannelConfig) obj; - if (!getName() - .equals(other.getName())) return false; + if (!getName().equals(other.getName())) return false; if (hasUpdateTime() != other.hasUpdateTime()) return false; if (hasUpdateTime()) { - if (!getUpdateTime() - .equals(other.getUpdateTime())) return false; + if (!getUpdateTime().equals(other.getUpdateTime())) return false; } - if (!getCryptoKeyName() - .equals(other.getCryptoKeyName())) return false; + if (!getCryptoKeyName().equals(other.getCryptoKeyName())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -281,97 +303,104 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.GoogleChannelConfig parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.GoogleChannelConfig prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A GoogleChannelConfig is a resource that stores the custom settings
    * respected by Eventarc first-party triggers in the matching region.
@@ -382,33 +411,32 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.cloud.eventarc.v1.GoogleChannelConfig}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.GoogleChannelConfig)
       com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return com.google.cloud.eventarc.v1.GoogleChannelConfigProto.internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.cloud.eventarc.v1.GoogleChannelConfigProto
+          .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor;
     }
 
     @java.lang.Override
     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return com.google.cloud.eventarc.v1.GoogleChannelConfigProto.internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable
+      return com.google.cloud.eventarc.v1.GoogleChannelConfigProto
+          .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              com.google.cloud.eventarc.v1.GoogleChannelConfig.class, com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder.class);
+              com.google.cloud.eventarc.v1.GoogleChannelConfig.class,
+              com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder.class);
     }
 
     // Construct using com.google.cloud.eventarc.v1.GoogleChannelConfig.newBuilder()
-    private Builder() {
-
-    }
+    private Builder() {}
 
-    private Builder(
-        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
-
     }
+
     @java.lang.Override
     public Builder clear() {
       super.clear();
@@ -426,9 +454,9 @@ public Builder clear() {
     }
 
     @java.lang.Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return com.google.cloud.eventarc.v1.GoogleChannelConfigProto.internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor;
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.cloud.eventarc.v1.GoogleChannelConfigProto
+          .internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor;
     }
 
     @java.lang.Override
@@ -447,7 +475,8 @@ public com.google.cloud.eventarc.v1.GoogleChannelConfig build() {
 
     @java.lang.Override
     public com.google.cloud.eventarc.v1.GoogleChannelConfig buildPartial() {
-      com.google.cloud.eventarc.v1.GoogleChannelConfig result = new com.google.cloud.eventarc.v1.GoogleChannelConfig(this);
+      com.google.cloud.eventarc.v1.GoogleChannelConfig result =
+          new com.google.cloud.eventarc.v1.GoogleChannelConfig(this);
       result.name_ = name_;
       if (updateTimeBuilder_ == null) {
         result.updateTime_ = updateTime_;
@@ -463,38 +492,39 @@ public com.google.cloud.eventarc.v1.GoogleChannelConfig buildPartial() {
     public Builder clone() {
       return super.clone();
     }
+
     @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
+
     @java.lang.Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
+
     @java.lang.Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
+
     @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
+
     @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
+
     @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
       if (other instanceof com.google.cloud.eventarc.v1.GoogleChannelConfig) {
-        return mergeFrom((com.google.cloud.eventarc.v1.GoogleChannelConfig)other);
+        return mergeFrom((com.google.cloud.eventarc.v1.GoogleChannelConfig) other);
       } else {
         super.mergeFrom(other);
         return this;
@@ -502,7 +532,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) {
     }
 
     public Builder mergeFrom(com.google.cloud.eventarc.v1.GoogleChannelConfig other) {
-      if (other == com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance()) return this;
+      if (other == com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance())
+        return this;
       if (!other.getName().isEmpty()) {
         name_ = other.name_;
         onChanged();
@@ -540,29 +571,31 @@ public Builder mergeFrom(
             case 0:
               done = true;
               break;
-            case 10: {
-              name_ = input.readStringRequireUtf8();
+            case 10:
+              {
+                name_ = input.readStringRequireUtf8();
 
-              break;
-            } // case 10
-            case 50: {
-              input.readMessage(
-                  getUpdateTimeFieldBuilder().getBuilder(),
-                  extensionRegistry);
+                break;
+              } // case 10
+            case 50:
+              {
+                input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry);
 
-              break;
-            } // case 50
-            case 58: {
-              cryptoKeyName_ = input.readStringRequireUtf8();
+                break;
+              } // case 50
+            case 58:
+              {
+                cryptoKeyName_ = input.readStringRequireUtf8();
 
-              break;
-            } // case 58
-            default: {
-              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
-                done = true; // was an endgroup tag
-              }
-              break;
-            } // default:
+                break;
+              } // case 58
+            default:
+              {
+                if (!super.parseUnknownField(input, extensionRegistry, tag)) {
+                  done = true; // was an endgroup tag
+                }
+                break;
+              } // default:
           } // switch (tag)
         } // while (!done)
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@@ -575,19 +608,21 @@ public Builder mergeFrom(
 
     private java.lang.Object name_ = "";
     /**
+     *
+     *
      * 
      * Required. The resource name of the config. Must be in the format of,
      * `projects/{project}/locations/{location}/googleChannelConfig`.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -596,21 +631,22 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The resource name of the config. Must be in the format of,
      * `projects/{project}/locations/{location}/googleChannelConfig`.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -618,57 +654,64 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The resource name of the config. Must be in the format of,
      * `projects/{project}/locations/{location}/googleChannelConfig`.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The resource name of the config. Must be in the format of,
      * `projects/{project}/locations/{location}/googleChannelConfig`.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The resource name of the config. Must be in the format of,
      * `projects/{project}/locations/{location}/googleChannelConfig`.
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; @@ -676,39 +719,58 @@ public Builder setNameBytes( private com.google.protobuf.Timestamp updateTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ public boolean hasUpdateTime() { return updateTimeBuilder_ != null || updateTime_ != null; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } else { return updateTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { @@ -724,14 +786,17 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setUpdateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (updateTimeBuilder_ == null) { updateTime_ = builderForValue.build(); onChanged(); @@ -742,17 +807,21 @@ public Builder setUpdateTime( return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { if (updateTime_ != null) { updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); } else { updateTime_ = value; } @@ -764,11 +833,15 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearUpdateTime() { if (updateTimeBuilder_ == null) { @@ -782,48 +855,64 @@ public Builder clearUpdateTime() { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - + onChanged(); return getUpdateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (updateTimeBuilder_ != null) { return updateTimeBuilder_.getMessageOrBuilder(); } else { - return updateTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getUpdateTimeFieldBuilder() { if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), - getParentForChildren(), - isClean()); + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); updateTime_ = null; } return updateTimeBuilder_; @@ -831,6 +920,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { private java.lang.Object cryptoKeyName_ = ""; /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -838,14 +929,16 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The cryptoKeyName. */ public java.lang.String getCryptoKeyName() { java.lang.Object ref = cryptoKeyName_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); cryptoKeyName_ = s; return s; @@ -854,6 +947,8 @@ public java.lang.String getCryptoKeyName() { } } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -861,16 +956,17 @@ public java.lang.String getCryptoKeyName() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for cryptoKeyName. */ - public com.google.protobuf.ByteString - getCryptoKeyNameBytes() { + public com.google.protobuf.ByteString getCryptoKeyNameBytes() { java.lang.Object ref = cryptoKeyName_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); cryptoKeyName_ = b; return b; } else { @@ -878,6 +974,8 @@ public java.lang.String getCryptoKeyName() { } } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -885,21 +983,25 @@ public java.lang.String getCryptoKeyName() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @param value The cryptoKeyName to set. * @return This builder for chaining. */ - public Builder setCryptoKeyName( - java.lang.String value) { + public Builder setCryptoKeyName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + cryptoKeyName_ = value; onChanged(); return this; } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -907,16 +1009,21 @@ public Builder setCryptoKeyName(
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearCryptoKeyName() { - + cryptoKeyName_ = getDefaultInstance().getCryptoKeyName(); onChanged(); return this; } /** + * + * *
      * Optional. Resource name of a KMS crypto key (managed by the user) used to
      * encrypt/decrypt their event data.
@@ -924,24 +1031,26 @@ public Builder clearCryptoKeyName() {
      * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
      * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for cryptoKeyName to set. * @return This builder for chaining. */ - public Builder setCryptoKeyNameBytes( - com.google.protobuf.ByteString value) { + public Builder setCryptoKeyNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + cryptoKeyName_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -951,12 +1060,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.GoogleChannelConfig) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.GoogleChannelConfig) private static final com.google.cloud.eventarc.v1.GoogleChannelConfig DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.GoogleChannelConfig(); } @@ -965,27 +1074,27 @@ public static com.google.cloud.eventarc.v1.GoogleChannelConfig getDefaultInstanc return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GoogleChannelConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GoogleChannelConfig parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1000,6 +1109,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.GoogleChannelConfig getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java new file mode 100644 index 000000000000..fe98fea92bf3 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigName.java @@ -0,0 +1,193 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class GoogleChannelConfigName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/googleChannelConfig"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + + @Deprecated + protected GoogleChannelConfigName() { + project = null; + location = null; + } + + private GoogleChannelConfigName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static GoogleChannelConfigName of(String project, String location) { + return newBuilder().setProject(project).setLocation(location).build(); + } + + public static String format(String project, String location) { + return newBuilder().setProject(project).setLocation(location).build().toString(); + } + + public static GoogleChannelConfigName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION.validatedMatch( + formattedString, "GoogleChannelConfigName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List values) { + List list = new ArrayList<>(values.size()); + for (GoogleChannelConfigName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION.instantiate("project", project, "location", location); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + GoogleChannelConfigName that = ((GoogleChannelConfigName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + return h; + } + + /** Builder for projects/{project}/locations/{location}/googleChannelConfig. */ + public static class Builder { + private String project; + private String location; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + private Builder(GoogleChannelConfigName googleChannelConfigName) { + this.project = googleChannelConfigName.project; + this.location = googleChannelConfigName.location; + } + + public GoogleChannelConfigName build() { + return new GoogleChannelConfigName(this); + } + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java similarity index 76% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java index 907d3d60cb8b..fb7fb79f570e 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigOrBuilder.java @@ -3,60 +3,79 @@ package com.google.cloud.eventarc.v1; -public interface GoogleChannelConfigOrBuilder extends +public interface GoogleChannelConfigOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.GoogleChannelConfig) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The resource name of the config. Must be in the format of,
    * `projects/{project}/locations/{location}/googleChannelConfig`.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The resource name of the config. Must be in the format of,
    * `projects/{project}/locations/{location}/googleChannelConfig`.
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ boolean hasUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ com.google.protobuf.Timestamp getUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -64,11 +83,16 @@ public interface GoogleChannelConfigOrBuilder extends
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The cryptoKeyName. */ java.lang.String getCryptoKeyName(); /** + * + * *
    * Optional. Resource name of a KMS crypto key (managed by the user) used to
    * encrypt/decrypt their event data.
@@ -76,9 +100,11 @@ public interface GoogleChannelConfigOrBuilder extends
    * `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
    * 
* - * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string crypto_key_name = 7 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for cryptoKeyName. */ - com.google.protobuf.ByteString - getCryptoKeyNameBytes(); + com.google.protobuf.ByteString getCryptoKeyNameBytes(); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java new file mode 100644 index 000000000000..e3251d428f4a --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java @@ -0,0 +1,80 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/google_channel_config.proto + +package com.google.cloud.eventarc.v1; + +public final class GoogleChannelConfigProto { + private GoogleChannelConfigProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n4google/cloud/eventarc/v1/google_channe" + + "l_config.proto\022\030google.cloud.eventarc.v1" + + "\032\037google/api/field_behavior.proto\032\031googl" + + "e/api/resource.proto\032\037google/protobuf/ti" + + "mestamp.proto\"\247\002\n\023GoogleChannelConfig\022\021\n" + + "\004name\030\001 \001(\tB\003\340A\002\0224\n\013update_time\030\006 \001(\0132\032." + + "google.protobuf.TimestampB\003\340A\003\022B\n\017crypto" + + "_key_name\030\007 \001(\tB)\340A\001\372A#\n!cloudkms.google" + + "apis.com/CryptoKey:\202\001\352A\177\n+eventarc.googl" + + "eapis.com/GoogleChannelConfig\022;projects/" + + "{project}/locations/{location}/googleCha" + + "nnelConfig2\023googleChannelConfigB\313\002\n\034com." + + "google.cloud.eventarc.v1B\030GoogleChannelC" + + "onfigProtoP\001Z@google.golang.org/genproto" + + "/googleapis/cloud/eventarc/v1;eventarc\252\002" + + "\030Google.Cloud.Eventarc.V1\312\002\030Google\\Cloud" + + "\\Eventarc\\V1\352\002\033Google::Cloud::Eventarc::" + + "V1\352Ax\n!cloudkms.googleapis.com/CryptoKey" + + "\022Sprojects/{project}/locations/{location" + + "}/keyRings/{key_ring}/cryptoKeys/{crypto" + + "_key}b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor, + new java.lang.String[] { + "Name", "UpdateTime", "CryptoKeyName", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceDefinition); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java similarity index 68% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java index 11c2dc7fd8c9..c02d631972e3 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the ListChannelConnections method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsRequest} */ -public final class ListChannelConnectionsRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListChannelConnectionsRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelConnectionsRequest) ListChannelConnectionsRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListChannelConnectionsRequest.newBuilder() to construct. private ListChannelConnectionsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListChannelConnectionsRequest() { parent_ = ""; pageToken_ = ""; @@ -26,37 +29,43 @@ private ListChannelConnectionsRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListChannelConnectionsRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.Builder.class); + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent collection from which to list channel connections.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -65,29 +74,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent collection from which to list channel connections.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -98,12 +109,15 @@ public java.lang.String getParent() { public static final int PAGE_SIZE_FIELD_NUMBER = 2; private int pageSize_; /** + * + * *
    * The maximum number of channel connections to return on each page.
    * Note: The service may send fewer responses.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -114,6 +128,8 @@ public int getPageSize() { public static final int PAGE_TOKEN_FIELD_NUMBER = 3; private volatile java.lang.Object pageToken_; /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -122,6 +138,7 @@ public int getPageSize() {
    * 
* * string page_token = 3; + * * @return The pageToken. */ @java.lang.Override @@ -130,14 +147,15 @@ public java.lang.String getPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; } } /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -146,16 +164,15 @@ public java.lang.String getPageToken() {
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -164,6 +181,7 @@ public java.lang.String getPageToken() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -175,8 +193,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -199,8 +216,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, pageSize_); + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); @@ -213,19 +229,17 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest other = (com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) obj; + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest other = + (com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) obj; - if (!getParent() - .equals(other.getParent())) return false; - if (getPageSize() - != other.getPageSize()) return false; - if (!getPageToken() - .equals(other.getPageToken())) return false; + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -249,129 +263,136 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest prototype) { + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the ListChannelConnections method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelConnectionsRequest) com.google.cloud.eventarc.v1.ListChannelConnectionsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.Builder.class); + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -385,9 +406,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor; } @java.lang.Override @@ -406,7 +427,8 @@ public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest buildPartial() { - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest result = new com.google.cloud.eventarc.v1.ListChannelConnectionsRequest(this); + com.google.cloud.eventarc.v1.ListChannelConnectionsRequest result = + new com.google.cloud.eventarc.v1.ListChannelConnectionsRequest(this); result.parent_ = parent_; result.pageSize_ = pageSize_; result.pageToken_ = pageToken_; @@ -418,38 +440,39 @@ public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest buildPartial() public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.ListChannelConnectionsRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) other); } else { super.mergeFrom(other); return this; @@ -457,7 +480,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest other) { - if (other == com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -495,27 +519,31 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: { - pageSize_ = input.readInt32(); - - break; - } // case 16 - case 26: { - pageToken_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -528,18 +556,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent collection from which to list channel connections.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -548,20 +580,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection from which to list channel connections.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -569,67 +604,83 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection from which to list channel connections.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent collection from which to list channel connections.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent collection from which to list channel connections.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; } - private int pageSize_ ; + private int pageSize_; /** + * + * *
      * The maximum number of channel connections to return on each page.
      * Note: The service may send fewer responses.
      * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -637,32 +688,38 @@ public int getPageSize() { return pageSize_; } /** + * + * *
      * The maximum number of channel connections to return on each page.
      * Note: The service may send fewer responses.
      * 
* * int32 page_size = 2; + * * @param value The pageSize to set. * @return This builder for chaining. */ public Builder setPageSize(int value) { - + pageSize_ = value; onChanged(); return this; } /** + * + * *
      * The maximum number of channel connections to return on each page.
      * Note: The service may send fewer responses.
      * 
* * int32 page_size = 2; + * * @return This builder for chaining. */ public Builder clearPageSize() { - + pageSize_ = 0; onChanged(); return this; @@ -670,6 +727,8 @@ public Builder clearPageSize() { private java.lang.Object pageToken_ = ""; /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -678,13 +737,13 @@ public Builder clearPageSize() {
      * 
* * string page_token = 3; + * * @return The pageToken. */ public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; @@ -693,6 +752,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -701,15 +762,14 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -717,6 +777,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -725,20 +787,22 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @param value The pageToken to set. * @return This builder for chaining. */ - public Builder setPageToken( - java.lang.String value) { + public Builder setPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + pageToken_ = value; onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -747,15 +811,18 @@ public Builder setPageToken(
      * 
* * string page_token = 3; + * * @return This builder for chaining. */ public Builder clearPageToken() { - + pageToken_ = getDefaultInstance().getPageToken(); onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -764,23 +831,23 @@ public Builder clearPageToken() {
      * 
* * string page_token = 3; + * * @param value The bytes for pageToken to set. * @return This builder for chaining. */ - public Builder setPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -790,12 +857,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelConnectionsRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelConnectionsRequest) private static final com.google.cloud.eventarc.v1.ListChannelConnectionsRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelConnectionsRequest(); } @@ -804,27 +871,27 @@ public static com.google.cloud.eventarc.v1.ListChannelConnectionsRequest getDefa return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListChannelConnectionsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelConnectionsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -839,6 +906,4 @@ public com.google.protobuf.Parser getParserForTyp public com.google.cloud.eventarc.v1.ListChannelConnectionsRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java similarity index 76% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java index d31663213e9b..9b20106effd6 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsRequestOrBuilder.java @@ -3,42 +3,57 @@ package com.google.cloud.eventarc.v1; -public interface ListChannelConnectionsRequestOrBuilder extends +public interface ListChannelConnectionsRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelConnectionsRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent collection from which to list channel connections.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent collection from which to list channel connections.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * The maximum number of channel connections to return on each page.
    * Note: The service may send fewer responses.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ int getPageSize(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -47,10 +62,13 @@ public interface ListChannelConnectionsRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The pageToken. */ java.lang.String getPageToken(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannelConnections` call to retrieve the subsequent page.
@@ -59,8 +77,8 @@ public interface ListChannelConnectionsRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - com.google.protobuf.ByteString - getPageTokenBytes(); + com.google.protobuf.ByteString getPageTokenBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java similarity index 75% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java index 42a3a0f333d5..522c65628eca 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponse.java @@ -4,21 +4,25 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The response message for the `ListChannelConnections` method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsResponse} */ -public final class ListChannelConnectionsResponse extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListChannelConnectionsResponse extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelConnectionsResponse) ListChannelConnectionsResponseOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListChannelConnectionsResponse.newBuilder() to construct. - private ListChannelConnectionsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + private ListChannelConnectionsResponse( + com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListChannelConnectionsResponse() { channelConnections_ = java.util.Collections.emptyList(); nextPageToken_ = ""; @@ -27,32 +31,35 @@ private ListChannelConnectionsResponse() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListChannelConnectionsResponse(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.Builder.class); + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.Builder.class); } public static final int CHANNEL_CONNECTIONS_FIELD_NUMBER = 1; private java.util.List channelConnections_; /** + * + * *
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -61,10 +68,13 @@ protected java.lang.Object newInstance(
    * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
    */
   @java.lang.Override
-  public java.util.List getChannelConnectionsList() {
+  public java.util.List
+      getChannelConnectionsList() {
     return channelConnections_;
   }
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -73,11 +83,13 @@ public java.util.List getChannel
    * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
    */
   @java.lang.Override
-  public java.util.List 
+  public java.util.List
       getChannelConnectionsOrBuilderList() {
     return channelConnections_;
   }
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -90,6 +102,8 @@ public int getChannelConnectionsCount() {
     return channelConnections_.size();
   }
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -102,6 +116,8 @@ public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnections(int
     return channelConnections_.get(index);
   }
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -118,6 +134,8 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect
   public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2;
   private volatile java.lang.Object nextPageToken_;
   /**
+   *
+   *
    * 
    * A page token that can be sent to `ListChannelConnections` to request the
    * next page.
@@ -125,6 +143,7 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ @java.lang.Override @@ -133,14 +152,15 @@ public java.lang.String getNextPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; } } /** + * + * *
    * A page token that can be sent to `ListChannelConnections` to request the
    * next page.
@@ -148,16 +168,15 @@ public java.lang.String getNextPageToken() {
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -168,34 +187,42 @@ public java.lang.String getNextPageToken() { public static final int UNREACHABLE_FIELD_NUMBER = 3; private com.google.protobuf.LazyStringList unreachable_; /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_; } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -203,20 +230,23 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -228,8 +258,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < channelConnections_.size(); i++) { output.writeMessage(1, channelConnections_.get(i)); } @@ -249,8 +278,8 @@ public int getSerializedSize() { size = 0; for (int i = 0; i < channelConnections_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, channelConnections_.get(i)); + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, channelConnections_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); @@ -271,19 +300,17 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsResponse)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListChannelConnectionsResponse other = (com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) obj; + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse other = + (com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) obj; - if (!getChannelConnectionsList() - .equals(other.getChannelConnectionsList())) return false; - if (!getNextPageToken() - .equals(other.getNextPageToken())) return false; - if (!getUnreachableList() - .equals(other.getUnreachableList())) return false; + if (!getChannelConnectionsList().equals(other.getChannelConnectionsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -311,129 +338,136 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(com.google.cloud.eventarc.v1.ListChannelConnectionsResponse prototype) { + + public static Builder newBuilder( + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The response message for the `ListChannelConnections` method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelConnectionsResponse} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelConnectionsResponse) com.google.cloud.eventarc.v1.ListChannelConnectionsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.Builder.class); + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -452,9 +486,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor; } @java.lang.Override @@ -473,7 +507,8 @@ public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse buildPartial() { - com.google.cloud.eventarc.v1.ListChannelConnectionsResponse result = new com.google.cloud.eventarc.v1.ListChannelConnectionsResponse(this); + com.google.cloud.eventarc.v1.ListChannelConnectionsResponse result = + new com.google.cloud.eventarc.v1.ListChannelConnectionsResponse(this); int from_bitField0_ = bitField0_; if (channelConnectionsBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { @@ -498,38 +533,39 @@ public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse buildPartial( public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) { - return mergeFrom((com.google.cloud.eventarc.v1.ListChannelConnectionsResponse)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelConnectionsResponse) other); } else { super.mergeFrom(other); return this; @@ -537,7 +573,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelConnectionsResponse other) { - if (other == com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.getDefaultInstance()) + return this; if (channelConnectionsBuilder_ == null) { if (!other.channelConnections_.isEmpty()) { if (channelConnections_.isEmpty()) { @@ -556,9 +593,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelConnectionsResp channelConnectionsBuilder_ = null; channelConnections_ = other.channelConnections_; bitField0_ = (bitField0_ & ~0x00000001); - channelConnectionsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getChannelConnectionsFieldBuilder() : null; + channelConnectionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getChannelConnectionsFieldBuilder() + : null; } else { channelConnectionsBuilder_.addAllMessages(other.channelConnections_); } @@ -604,36 +642,39 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - com.google.cloud.eventarc.v1.ChannelConnection m = - input.readMessage( - com.google.cloud.eventarc.v1.ChannelConnection.parser(), - extensionRegistry); - if (channelConnectionsBuilder_ == null) { - ensureChannelConnectionsIsMutable(); - channelConnections_.add(m); - } else { - channelConnectionsBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: { - nextPageToken_ = input.readStringRequireUtf8(); + case 10: + { + com.google.cloud.eventarc.v1.ChannelConnection m = + input.readMessage( + com.google.cloud.eventarc.v1.ChannelConnection.parser(), extensionRegistry); + if (channelConnectionsBuilder_ == null) { + ensureChannelConnectionsIsMutable(); + channelConnections_.add(m); + } else { + channelConnectionsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - ensureUnreachableIsMutable(); - unreachable_.add(s); - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -643,21 +684,30 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.util.List channelConnections_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureChannelConnectionsIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { - channelConnections_ = new java.util.ArrayList(channelConnections_); + channelConnections_ = + new java.util.ArrayList( + channelConnections_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.ChannelConnection, com.google.cloud.eventarc.v1.ChannelConnection.Builder, com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> channelConnectionsBuilder_; + com.google.cloud.eventarc.v1.ChannelConnection, + com.google.cloud.eventarc.v1.ChannelConnection.Builder, + com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> + channelConnectionsBuilder_; /** + * + * *
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -665,7 +715,8 @@ private void ensureChannelConnectionsIsMutable() {
      *
      * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
      */
-    public java.util.List getChannelConnectionsList() {
+    public java.util.List
+        getChannelConnectionsList() {
       if (channelConnectionsBuilder_ == null) {
         return java.util.Collections.unmodifiableList(channelConnections_);
       } else {
@@ -673,6 +724,8 @@ public java.util.List getChannel
       }
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -688,6 +741,8 @@ public int getChannelConnectionsCount() {
       }
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -703,6 +758,8 @@ public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnections(int
       }
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -725,6 +782,8 @@ public Builder setChannelConnections(
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -744,6 +803,8 @@ public Builder setChannelConnections(
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -765,6 +826,8 @@ public Builder addChannelConnections(com.google.cloud.eventarc.v1.ChannelConnect
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -787,6 +850,8 @@ public Builder addChannelConnections(
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -806,6 +871,8 @@ public Builder addChannelConnections(
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -825,6 +892,8 @@ public Builder addChannelConnections(
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -836,8 +905,7 @@ public Builder addAllChannelConnections(
         java.lang.Iterable values) {
       if (channelConnectionsBuilder_ == null) {
         ensureChannelConnectionsIsMutable();
-        com.google.protobuf.AbstractMessageLite.Builder.addAll(
-            values, channelConnections_);
+        com.google.protobuf.AbstractMessageLite.Builder.addAll(values, channelConnections_);
         onChanged();
       } else {
         channelConnectionsBuilder_.addAllMessages(values);
@@ -845,6 +913,8 @@ public Builder addAllChannelConnections(
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -863,6 +933,8 @@ public Builder clearChannelConnections() {
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -881,6 +953,8 @@ public Builder removeChannelConnections(int index) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -893,6 +967,8 @@ public com.google.cloud.eventarc.v1.ChannelConnection.Builder getChannelConnecti
       return getChannelConnectionsFieldBuilder().getBuilder(index);
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -903,11 +979,14 @@ public com.google.cloud.eventarc.v1.ChannelConnection.Builder getChannelConnecti
     public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrBuilder(
         int index) {
       if (channelConnectionsBuilder_ == null) {
-        return channelConnections_.get(index);  } else {
+        return channelConnections_.get(index);
+      } else {
         return channelConnectionsBuilder_.getMessageOrBuilder(index);
       }
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -915,8 +994,8 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect
      *
      * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
      */
-    public java.util.List 
-         getChannelConnectionsOrBuilderList() {
+    public java.util.List
+        getChannelConnectionsOrBuilderList() {
       if (channelConnectionsBuilder_ != null) {
         return channelConnectionsBuilder_.getMessageOrBuilderList();
       } else {
@@ -924,6 +1003,8 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect
       }
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -932,10 +1013,12 @@ public com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnect
      * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
      */
     public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnectionsBuilder() {
-      return getChannelConnectionsFieldBuilder().addBuilder(
-          com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance());
+      return getChannelConnectionsFieldBuilder()
+          .addBuilder(com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance());
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -945,10 +1028,12 @@ public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnecti
      */
     public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnectionsBuilder(
         int index) {
-      return getChannelConnectionsFieldBuilder().addBuilder(
-          index, com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance());
+      return getChannelConnectionsFieldBuilder()
+          .addBuilder(index, com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance());
     }
     /**
+     *
+     *
      * 
      * The requested channel connections, up to the number specified in
      * `page_size`.
@@ -956,16 +1041,22 @@ public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnecti
      *
      * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
      */
-    public java.util.List 
-         getChannelConnectionsBuilderList() {
+    public java.util.List
+        getChannelConnectionsBuilderList() {
       return getChannelConnectionsFieldBuilder().getBuilderList();
     }
+
     private com.google.protobuf.RepeatedFieldBuilderV3<
-        com.google.cloud.eventarc.v1.ChannelConnection, com.google.cloud.eventarc.v1.ChannelConnection.Builder, com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder> 
+            com.google.cloud.eventarc.v1.ChannelConnection,
+            com.google.cloud.eventarc.v1.ChannelConnection.Builder,
+            com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>
         getChannelConnectionsFieldBuilder() {
       if (channelConnectionsBuilder_ == null) {
-        channelConnectionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
-            com.google.cloud.eventarc.v1.ChannelConnection, com.google.cloud.eventarc.v1.ChannelConnection.Builder, com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>(
+        channelConnectionsBuilder_ =
+            new com.google.protobuf.RepeatedFieldBuilderV3<
+                com.google.cloud.eventarc.v1.ChannelConnection,
+                com.google.cloud.eventarc.v1.ChannelConnection.Builder,
+                com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder>(
                 channelConnections_,
                 ((bitField0_ & 0x00000001) != 0),
                 getParentForChildren(),
@@ -977,6 +1068,8 @@ public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnecti
 
     private java.lang.Object nextPageToken_ = "";
     /**
+     *
+     *
      * 
      * A page token that can be sent to `ListChannelConnections` to request the
      * next page.
@@ -984,13 +1077,13 @@ public com.google.cloud.eventarc.v1.ChannelConnection.Builder addChannelConnecti
      * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; @@ -999,6 +1092,8 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListChannelConnections` to request the
      * next page.
@@ -1006,15 +1101,14 @@ public java.lang.String getNextPageToken() {
      * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -1022,6 +1116,8 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListChannelConnections` to request the
      * next page.
@@ -1029,20 +1125,22 @@ public java.lang.String getNextPageToken() {
      * 
* * string next_page_token = 2; + * * @param value The nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageToken( - java.lang.String value) { + public Builder setNextPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + nextPageToken_ = value; onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListChannelConnections` to request the
      * next page.
@@ -1050,15 +1148,18 @@ public Builder setNextPageToken(
      * 
* * string next_page_token = 2; + * * @return This builder for chaining. */ public Builder clearNextPageToken() { - + nextPageToken_ = getDefaultInstance().getNextPageToken(); onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListChannelConnections` to request the
      * next page.
@@ -1066,57 +1167,67 @@ public Builder clearNextPageToken() {
      * 
* * string next_page_token = 2; + * * @param value The bytes for nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; onChanged(); return this; } - private com.google.protobuf.LazyStringList unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensureUnreachableIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); bitField0_ |= 0x00000002; - } + } } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_.getUnmodifiableView(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -1124,80 +1235,90 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index to set the value at. * @param value The unreachable to set. * @return This builder for chaining. */ - public Builder setUnreachable( - int index, java.lang.String value) { + public Builder setUnreachable(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.set(index, value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachable( - java.lang.String value) { + public Builder addUnreachable(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param values The unreachable to add. * @return This builder for chaining. */ - public Builder addAllUnreachable( - java.lang.Iterable values) { + public Builder addAllUnreachable(java.lang.Iterable values) { ensureUnreachableIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, unreachable_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return This builder for chaining. */ public Builder clearUnreachable() { @@ -1207,28 +1328,30 @@ public Builder clearUnreachable() { return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The bytes of the unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachableBytes( - com.google.protobuf.ByteString value) { + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1238,12 +1361,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelConnectionsResponse) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelConnectionsResponse) private static final com.google.cloud.eventarc.v1.ListChannelConnectionsResponse DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelConnectionsResponse(); } @@ -1252,27 +1375,27 @@ public static com.google.cloud.eventarc.v1.ListChannelConnectionsResponse getDef return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListChannelConnectionsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelConnectionsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1287,6 +1410,4 @@ public com.google.protobuf.Parser getParserForTy public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java similarity index 87% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java index 00a9f2fbdc5f..85f002375b86 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelConnectionsResponseOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface ListChannelConnectionsResponseOrBuilder extends +public interface ListChannelConnectionsResponseOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelConnectionsResponse) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -15,9 +18,10 @@ public interface ListChannelConnectionsResponseOrBuilder extends
    *
    * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
    */
-  java.util.List 
-      getChannelConnectionsList();
+  java.util.List getChannelConnectionsList();
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -27,6 +31,8 @@ public interface ListChannelConnectionsResponseOrBuilder extends
    */
   com.google.cloud.eventarc.v1.ChannelConnection getChannelConnections(int index);
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -36,6 +42,8 @@ public interface ListChannelConnectionsResponseOrBuilder extends
    */
   int getChannelConnectionsCount();
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -43,9 +51,11 @@ public interface ListChannelConnectionsResponseOrBuilder extends
    *
    * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
    */
-  java.util.List 
+  java.util.List
       getChannelConnectionsOrBuilderList();
   /**
+   *
+   *
    * 
    * The requested channel connections, up to the number specified in
    * `page_size`.
@@ -53,10 +63,11 @@ public interface ListChannelConnectionsResponseOrBuilder extends
    *
    * repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;
    */
-  com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrBuilder(
-      int index);
+  com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrBuilder(int index);
 
   /**
+   *
+   *
    * 
    * A page token that can be sent to `ListChannelConnections` to request the
    * next page.
@@ -64,10 +75,13 @@ com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrB
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ java.lang.String getNextPageToken(); /** + * + * *
    * A page token that can be sent to `ListChannelConnections` to request the
    * next page.
@@ -75,49 +89,59 @@ com.google.cloud.eventarc.v1.ChannelConnectionOrBuilder getChannelConnectionsOrB
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - com.google.protobuf.ByteString - getNextPageTokenBytes(); + com.google.protobuf.ByteString getNextPageTokenBytes(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - java.util.List - getUnreachableList(); + java.util.List getUnreachableList(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ int getUnreachableCount(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ java.lang.String getUnreachable(int index); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - com.google.protobuf.ByteString - getUnreachableBytes(int index); + com.google.protobuf.ByteString getUnreachableBytes(int index); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java similarity index 70% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java index 2271d6a2f164..27f7f643b7ca 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the ListChannels method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsRequest} */ -public final class ListChannelsRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListChannelsRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelsRequest) ListChannelsRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListChannelsRequest.newBuilder() to construct. private ListChannelsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListChannelsRequest() { parent_ = ""; pageToken_ = ""; @@ -27,37 +30,43 @@ private ListChannelsRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListChannelsRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelsRequest.class, com.google.cloud.eventarc.v1.ListChannelsRequest.Builder.class); + com.google.cloud.eventarc.v1.ListChannelsRequest.class, + com.google.cloud.eventarc.v1.ListChannelsRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent collection to list channels on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -66,29 +75,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent collection to list channels on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -99,12 +110,15 @@ public java.lang.String getParent() { public static final int PAGE_SIZE_FIELD_NUMBER = 2; private int pageSize_; /** + * + * *
    * The maximum number of channels to return on each page.
    * Note: The service may send fewer.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -115,6 +129,8 @@ public int getPageSize() { public static final int PAGE_TOKEN_FIELD_NUMBER = 3; private volatile java.lang.Object pageToken_; /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannels` call to retrieve the subsequent page.
@@ -123,6 +139,7 @@ public int getPageSize() {
    * 
* * string page_token = 3; + * * @return The pageToken. */ @java.lang.Override @@ -131,14 +148,15 @@ public java.lang.String getPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; } } /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannels` call to retrieve the subsequent page.
@@ -147,16 +165,15 @@ public java.lang.String getPageToken() {
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -167,6 +184,8 @@ public java.lang.String getPageToken() { public static final int ORDER_BY_FIELD_NUMBER = 4; private volatile java.lang.Object orderBy_; /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -175,6 +194,7 @@ public java.lang.String getPageToken() {
    * 
* * string order_by = 4; + * * @return The orderBy. */ @java.lang.Override @@ -183,14 +203,15 @@ public java.lang.String getOrderBy() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); orderBy_ = s; return s; } } /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -199,16 +220,15 @@ public java.lang.String getOrderBy() {
    * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ @java.lang.Override - public com.google.protobuf.ByteString - getOrderByBytes() { + public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); orderBy_ = b; return b; } else { @@ -217,6 +237,7 @@ public java.lang.String getOrderBy() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -228,8 +249,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -255,8 +275,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, pageSize_); + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); @@ -272,21 +291,18 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelsRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListChannelsRequest other = (com.google.cloud.eventarc.v1.ListChannelsRequest) obj; - - if (!getParent() - .equals(other.getParent())) return false; - if (getPageSize() - != other.getPageSize()) return false; - if (!getPageToken() - .equals(other.getPageToken())) return false; - if (!getOrderBy() - .equals(other.getOrderBy())) return false; + com.google.cloud.eventarc.v1.ListChannelsRequest other = + (com.google.cloud.eventarc.v1.ListChannelsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -311,130 +327,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelsRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelsRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListChannelsRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the ListChannels method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelsRequest) com.google.cloud.eventarc.v1.ListChannelsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelsRequest.class, com.google.cloud.eventarc.v1.ListChannelsRequest.Builder.class); + com.google.cloud.eventarc.v1.ListChannelsRequest.class, + com.google.cloud.eventarc.v1.ListChannelsRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListChannelsRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -450,9 +472,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor; } @java.lang.Override @@ -471,7 +493,8 @@ public com.google.cloud.eventarc.v1.ListChannelsRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListChannelsRequest buildPartial() { - com.google.cloud.eventarc.v1.ListChannelsRequest result = new com.google.cloud.eventarc.v1.ListChannelsRequest(this); + com.google.cloud.eventarc.v1.ListChannelsRequest result = + new com.google.cloud.eventarc.v1.ListChannelsRequest(this); result.parent_ = parent_; result.pageSize_ = pageSize_; result.pageToken_ = pageToken_; @@ -484,38 +507,39 @@ public com.google.cloud.eventarc.v1.ListChannelsRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListChannelsRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.ListChannelsRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelsRequest) other); } else { super.mergeFrom(other); return this; @@ -523,7 +547,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelsRequest other) { - if (other == com.google.cloud.eventarc.v1.ListChannelsRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListChannelsRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -565,32 +590,37 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); + case 10: + { + parent_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 16: { - pageSize_ = input.readInt32(); + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); - break; - } // case 16 - case 26: { - pageToken_ = input.readStringRequireUtf8(); + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); - break; - } // case 26 - case 34: { - orderBy_ = input.readStringRequireUtf8(); + break; + } // case 26 + case 34: + { + orderBy_ = input.readStringRequireUtf8(); - break; - } // case 34 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -603,18 +633,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent collection to list channels on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -623,20 +657,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection to list channels on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -644,67 +681,83 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection to list channels on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent collection to list channels on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent collection to list channels on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; } - private int pageSize_ ; + private int pageSize_; /** + * + * *
      * The maximum number of channels to return on each page.
      * Note: The service may send fewer.
      * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -712,32 +765,38 @@ public int getPageSize() { return pageSize_; } /** + * + * *
      * The maximum number of channels to return on each page.
      * Note: The service may send fewer.
      * 
* * int32 page_size = 2; + * * @param value The pageSize to set. * @return This builder for chaining. */ public Builder setPageSize(int value) { - + pageSize_ = value; onChanged(); return this; } /** + * + * *
      * The maximum number of channels to return on each page.
      * Note: The service may send fewer.
      * 
* * int32 page_size = 2; + * * @return This builder for chaining. */ public Builder clearPageSize() { - + pageSize_ = 0; onChanged(); return this; @@ -745,6 +804,8 @@ public Builder clearPageSize() { private java.lang.Object pageToken_ = ""; /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannels` call to retrieve the subsequent page.
@@ -753,13 +814,13 @@ public Builder clearPageSize() {
      * 
* * string page_token = 3; + * * @return The pageToken. */ public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; @@ -768,6 +829,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannels` call to retrieve the subsequent page.
@@ -776,15 +839,14 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -792,6 +854,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannels` call to retrieve the subsequent page.
@@ -800,20 +864,22 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @param value The pageToken to set. * @return This builder for chaining. */ - public Builder setPageToken( - java.lang.String value) { + public Builder setPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + pageToken_ = value; onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannels` call to retrieve the subsequent page.
@@ -822,15 +888,18 @@ public Builder setPageToken(
      * 
* * string page_token = 3; + * * @return This builder for chaining. */ public Builder clearPageToken() { - + pageToken_ = getDefaultInstance().getPageToken(); onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListChannels` call to retrieve the subsequent page.
@@ -839,16 +908,16 @@ public Builder clearPageToken() {
      * 
* * string page_token = 3; + * * @param value The bytes for pageToken to set. * @return This builder for chaining. */ - public Builder setPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; onChanged(); return this; @@ -856,6 +925,8 @@ public Builder setPageTokenBytes( private java.lang.Object orderBy_ = ""; /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -864,13 +935,13 @@ public Builder setPageTokenBytes(
      * 
* * string order_by = 4; + * * @return The orderBy. */ public java.lang.String getOrderBy() { java.lang.Object ref = orderBy_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); orderBy_ = s; return s; @@ -879,6 +950,8 @@ public java.lang.String getOrderBy() { } } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -887,15 +960,14 @@ public java.lang.String getOrderBy() {
      * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ - public com.google.protobuf.ByteString - getOrderByBytes() { + public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); orderBy_ = b; return b; } else { @@ -903,6 +975,8 @@ public java.lang.String getOrderBy() { } } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -911,20 +985,22 @@ public java.lang.String getOrderBy() {
      * 
* * string order_by = 4; + * * @param value The orderBy to set. * @return This builder for chaining. */ - public Builder setOrderBy( - java.lang.String value) { + public Builder setOrderBy(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + orderBy_ = value; onChanged(); return this; } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -933,15 +1009,18 @@ public Builder setOrderBy(
      * 
* * string order_by = 4; + * * @return This builder for chaining. */ public Builder clearOrderBy() { - + orderBy_ = getDefaultInstance().getOrderBy(); onChanged(); return this; } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -950,23 +1029,23 @@ public Builder clearOrderBy() {
      * 
* * string order_by = 4; + * * @param value The bytes for orderBy to set. * @return This builder for chaining. */ - public Builder setOrderByBytes( - com.google.protobuf.ByteString value) { + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -976,12 +1055,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelsRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelsRequest) private static final com.google.cloud.eventarc.v1.ListChannelsRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelsRequest(); } @@ -990,27 +1069,27 @@ public static com.google.cloud.eventarc.v1.ListChannelsRequest getDefaultInstanc return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListChannelsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1025,6 +1104,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ListChannelsRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java similarity index 80% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java index 87b27490e879..eb2dbeb8bb62 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsRequestOrBuilder.java @@ -3,42 +3,57 @@ package com.google.cloud.eventarc.v1; -public interface ListChannelsRequestOrBuilder extends +public interface ListChannelsRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelsRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent collection to list channels on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent collection to list channels on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * The maximum number of channels to return on each page.
    * Note: The service may send fewer.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ int getPageSize(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannels` call to retrieve the subsequent page.
@@ -47,10 +62,13 @@ public interface ListChannelsRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The pageToken. */ java.lang.String getPageToken(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListChannels` call to retrieve the subsequent page.
@@ -59,12 +77,14 @@ public interface ListChannelsRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - com.google.protobuf.ByteString - getPageTokenBytes(); + com.google.protobuf.ByteString getPageTokenBytes(); /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -73,10 +93,13 @@ public interface ListChannelsRequestOrBuilder extends
    * 
* * string order_by = 4; + * * @return The orderBy. */ java.lang.String getOrderBy(); /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -85,8 +108,8 @@ public interface ListChannelsRequestOrBuilder extends
    * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ - com.google.protobuf.ByteString - getOrderByBytes(); + com.google.protobuf.ByteString getOrderByBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java index 3e88f9518e79..cb4397245eca 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponse.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The response message for the `ListChannels` method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsResponse} */ -public final class ListChannelsResponse extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListChannelsResponse extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListChannelsResponse) ListChannelsResponseOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListChannelsResponse.newBuilder() to construct. private ListChannelsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListChannelsResponse() { channels_ = java.util.Collections.emptyList(); nextPageToken_ = ""; @@ -27,32 +30,35 @@ private ListChannelsResponse() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListChannelsResponse(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelsResponse.class, com.google.cloud.eventarc.v1.ListChannelsResponse.Builder.class); + com.google.cloud.eventarc.v1.ListChannelsResponse.class, + com.google.cloud.eventarc.v1.ListChannelsResponse.Builder.class); } public static final int CHANNELS_FIELD_NUMBER = 1; private java.util.List channels_; /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -64,6 +70,8 @@ public java.util.List getChannelsList() { return channels_; } /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -71,11 +79,13 @@ public java.util.List getChannelsList() { * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ @java.lang.Override - public java.util.List + public java.util.List getChannelsOrBuilderList() { return channels_; } /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -87,6 +97,8 @@ public int getChannelsCount() { return channels_.size(); } /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -98,6 +110,8 @@ public com.google.cloud.eventarc.v1.Channel getChannels(int index) { return channels_.get(index); } /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -105,20 +119,22 @@ public com.google.cloud.eventarc.v1.Channel getChannels(int index) { * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ @java.lang.Override - public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder(int index) { return channels_.get(index); } public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; private volatile java.lang.Object nextPageToken_; /** + * + * *
    * A page token that can be sent to `ListChannels` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ @java.lang.Override @@ -127,30 +143,30 @@ public java.lang.String getNextPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; } } /** + * + * *
    * A page token that can be sent to `ListChannels` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -161,34 +177,42 @@ public java.lang.String getNextPageToken() { public static final int UNREACHABLE_FIELD_NUMBER = 3; private com.google.protobuf.LazyStringList unreachable_; /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_; } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -196,20 +220,23 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -221,8 +248,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < channels_.size(); i++) { output.writeMessage(1, channels_.get(i)); } @@ -242,8 +268,7 @@ public int getSerializedSize() { size = 0; for (int i = 0; i < channels_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, channels_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, channels_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); @@ -264,19 +289,17 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListChannelsResponse)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListChannelsResponse other = (com.google.cloud.eventarc.v1.ListChannelsResponse) obj; + com.google.cloud.eventarc.v1.ListChannelsResponse other = + (com.google.cloud.eventarc.v1.ListChannelsResponse) obj; - if (!getChannelsList() - .equals(other.getChannelsList())) return false; - if (!getNextPageToken() - .equals(other.getNextPageToken())) return false; - if (!getUnreachableList() - .equals(other.getUnreachableList())) return false; + if (!getChannelsList().equals(other.getChannelsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -304,129 +327,135 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListChannelsResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListChannelsResponse parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListChannelsResponse prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The response message for the `ListChannels` method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListChannelsResponse} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListChannelsResponse) com.google.cloud.eventarc.v1.ListChannelsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListChannelsResponse.class, com.google.cloud.eventarc.v1.ListChannelsResponse.Builder.class); + com.google.cloud.eventarc.v1.ListChannelsResponse.class, + com.google.cloud.eventarc.v1.ListChannelsResponse.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListChannelsResponse.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -445,9 +474,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor; } @java.lang.Override @@ -466,7 +495,8 @@ public com.google.cloud.eventarc.v1.ListChannelsResponse build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListChannelsResponse buildPartial() { - com.google.cloud.eventarc.v1.ListChannelsResponse result = new com.google.cloud.eventarc.v1.ListChannelsResponse(this); + com.google.cloud.eventarc.v1.ListChannelsResponse result = + new com.google.cloud.eventarc.v1.ListChannelsResponse(this); int from_bitField0_ = bitField0_; if (channelsBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { @@ -491,38 +521,39 @@ public com.google.cloud.eventarc.v1.ListChannelsResponse buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListChannelsResponse) { - return mergeFrom((com.google.cloud.eventarc.v1.ListChannelsResponse)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListChannelsResponse) other); } else { super.mergeFrom(other); return this; @@ -530,7 +561,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelsResponse other) { - if (other == com.google.cloud.eventarc.v1.ListChannelsResponse.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListChannelsResponse.getDefaultInstance()) + return this; if (channelsBuilder_ == null) { if (!other.channels_.isEmpty()) { if (channels_.isEmpty()) { @@ -549,9 +581,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.ListChannelsResponse other channelsBuilder_ = null; channels_ = other.channels_; bitField0_ = (bitField0_ & ~0x00000001); - channelsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getChannelsFieldBuilder() : null; + channelsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getChannelsFieldBuilder() + : null; } else { channelsBuilder_.addAllMessages(other.channels_); } @@ -597,36 +630,39 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - com.google.cloud.eventarc.v1.Channel m = - input.readMessage( - com.google.cloud.eventarc.v1.Channel.parser(), - extensionRegistry); - if (channelsBuilder_ == null) { - ensureChannelsIsMutable(); - channels_.add(m); - } else { - channelsBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: { - nextPageToken_ = input.readStringRequireUtf8(); + case 10: + { + com.google.cloud.eventarc.v1.Channel m = + input.readMessage( + com.google.cloud.eventarc.v1.Channel.parser(), extensionRegistry); + if (channelsBuilder_ == null) { + ensureChannelsIsMutable(); + channels_.add(m); + } else { + channelsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - ensureUnreachableIsMutable(); - unreachable_.add(s); - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -636,21 +672,28 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.util.List channels_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureChannelsIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { channels_ = new java.util.ArrayList(channels_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder> channelsBuilder_; + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + channelsBuilder_; /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -665,6 +708,8 @@ public java.util.List getChannelsList() { } } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -679,6 +724,8 @@ public int getChannelsCount() { } } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -693,14 +740,15 @@ public com.google.cloud.eventarc.v1.Channel getChannels(int index) { } } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public Builder setChannels( - int index, com.google.cloud.eventarc.v1.Channel value) { + public Builder setChannels(int index, com.google.cloud.eventarc.v1.Channel value) { if (channelsBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -714,6 +762,8 @@ public Builder setChannels( return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -732,6 +782,8 @@ public Builder setChannels( return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -752,14 +804,15 @@ public Builder addChannels(com.google.cloud.eventarc.v1.Channel value) { return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public Builder addChannels( - int index, com.google.cloud.eventarc.v1.Channel value) { + public Builder addChannels(int index, com.google.cloud.eventarc.v1.Channel value) { if (channelsBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -773,14 +826,15 @@ public Builder addChannels( return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public Builder addChannels( - com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + public Builder addChannels(com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { if (channelsBuilder_ == null) { ensureChannelsIsMutable(); channels_.add(builderForValue.build()); @@ -791,6 +845,8 @@ public Builder addChannels( return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -809,6 +865,8 @@ public Builder addChannels( return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -819,8 +877,7 @@ public Builder addAllChannels( java.lang.Iterable values) { if (channelsBuilder_ == null) { ensureChannelsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, channels_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, channels_); onChanged(); } else { channelsBuilder_.addAllMessages(values); @@ -828,6 +885,8 @@ public Builder addAllChannels( return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -845,6 +904,8 @@ public Builder clearChannels() { return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -862,39 +923,44 @@ public Builder removeChannels(int index) { return this; } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public com.google.cloud.eventarc.v1.Channel.Builder getChannelsBuilder( - int index) { + public com.google.cloud.eventarc.v1.Channel.Builder getChannelsBuilder(int index) { return getChannelsFieldBuilder().getBuilder(index); } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder(int index) { if (channelsBuilder_ == null) { - return channels_.get(index); } else { + return channels_.get(index); + } else { return channelsBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public java.util.List - getChannelsOrBuilderList() { + public java.util.List + getChannelsOrBuilderList() { if (channelsBuilder_ != null) { return channelsBuilder_.getMessageOrBuilderList(); } else { @@ -902,6 +968,8 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder( } } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
@@ -909,42 +977,47 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder( * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ public com.google.cloud.eventarc.v1.Channel.Builder addChannelsBuilder() { - return getChannelsFieldBuilder().addBuilder( - com.google.cloud.eventarc.v1.Channel.getDefaultInstance()); + return getChannelsFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.Channel.getDefaultInstance()); } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public com.google.cloud.eventarc.v1.Channel.Builder addChannelsBuilder( - int index) { - return getChannelsFieldBuilder().addBuilder( - index, com.google.cloud.eventarc.v1.Channel.getDefaultInstance()); + public com.google.cloud.eventarc.v1.Channel.Builder addChannelsBuilder(int index) { + return getChannelsFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.Channel.getDefaultInstance()); } /** + * + * *
      * The requested channels, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - public java.util.List - getChannelsBuilderList() { + public java.util.List getChannelsBuilderList() { return getChannelsFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder> + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> getChannelsFieldBuilder() { if (channelsBuilder_ == null) { - channelsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder>( - channels_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); + channelsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder>( + channels_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); channels_ = null; } return channelsBuilder_; @@ -952,19 +1025,21 @@ public com.google.cloud.eventarc.v1.Channel.Builder addChannelsBuilder( private java.lang.Object nextPageToken_ = ""; /** + * + * *
      * A page token that can be sent to `ListChannels` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; @@ -973,21 +1048,22 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListChannels` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -995,98 +1071,115 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListChannels` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @param value The nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageToken( - java.lang.String value) { + public Builder setNextPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + nextPageToken_ = value; onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListChannels` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return This builder for chaining. */ public Builder clearNextPageToken() { - + nextPageToken_ = getDefaultInstance().getNextPageToken(); onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListChannels` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @param value The bytes for nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; onChanged(); return this; } - private com.google.protobuf.LazyStringList unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensureUnreachableIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); bitField0_ |= 0x00000002; - } + } } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_.getUnmodifiableView(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -1094,80 +1187,90 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index to set the value at. * @param value The unreachable to set. * @return This builder for chaining. */ - public Builder setUnreachable( - int index, java.lang.String value) { + public Builder setUnreachable(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.set(index, value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachable( - java.lang.String value) { + public Builder addUnreachable(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param values The unreachable to add. * @return This builder for chaining. */ - public Builder addAllUnreachable( - java.lang.Iterable values) { + public Builder addAllUnreachable(java.lang.Iterable values) { ensureUnreachableIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, unreachable_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return This builder for chaining. */ public Builder clearUnreachable() { @@ -1177,28 +1280,30 @@ public Builder clearUnreachable() { return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The bytes of the unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachableBytes( - com.google.protobuf.ByteString value) { + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1208,12 +1313,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListChannelsResponse) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListChannelsResponse) private static final com.google.cloud.eventarc.v1.ListChannelsResponse DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListChannelsResponse(); } @@ -1222,27 +1327,27 @@ public static com.google.cloud.eventarc.v1.ListChannelsResponse getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListChannelsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListChannelsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1257,6 +1362,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ListChannelsResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java similarity index 85% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java index 5d6c013dfe7a..dbf77f33dac4 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListChannelsResponseOrBuilder.java @@ -3,20 +3,24 @@ package com.google.cloud.eventarc.v1; -public interface ListChannelsResponseOrBuilder extends +public interface ListChannelsResponseOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListChannelsResponse) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - java.util.List - getChannelsList(); + java.util.List getChannelsList(); /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -25,6 +29,8 @@ public interface ListChannelsResponseOrBuilder extends */ com.google.cloud.eventarc.v1.Channel getChannels(int index); /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
@@ -33,84 +39,102 @@ public interface ListChannelsResponseOrBuilder extends */ int getChannelsCount(); /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - java.util.List + java.util.List getChannelsOrBuilderList(); /** + * + * *
    * The requested channels, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Channel channels = 1; */ - com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder( - int index); + com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelsOrBuilder(int index); /** + * + * *
    * A page token that can be sent to `ListChannels` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ java.lang.String getNextPageToken(); /** + * + * *
    * A page token that can be sent to `ListChannels` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - com.google.protobuf.ByteString - getNextPageTokenBytes(); + com.google.protobuf.ByteString getNextPageTokenBytes(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - java.util.List - getUnreachableList(); + java.util.List getUnreachableList(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ int getUnreachableCount(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ java.lang.String getUnreachable(int index); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - com.google.protobuf.ByteString - getUnreachableBytes(int index); + com.google.protobuf.ByteString getUnreachableBytes(int index); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java similarity index 71% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java index 5620c5c6674a..6f0f328f2576 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the ListProviders method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersRequest} */ -public final class ListProvidersRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListProvidersRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListProvidersRequest) ListProvidersRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListProvidersRequest.newBuilder() to construct. private ListProvidersRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListProvidersRequest() { parent_ = ""; pageToken_ = ""; @@ -28,37 +31,43 @@ private ListProvidersRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListProvidersRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListProvidersRequest.class, com.google.cloud.eventarc.v1.ListProvidersRequest.Builder.class); + com.google.cloud.eventarc.v1.ListProvidersRequest.class, + com.google.cloud.eventarc.v1.ListProvidersRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent of the provider to get.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -67,29 +76,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent of the provider to get.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -100,11 +111,14 @@ public java.lang.String getParent() { public static final int PAGE_SIZE_FIELD_NUMBER = 2; private int pageSize_; /** + * + * *
    * The maximum number of providers to return on each page.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -115,6 +129,8 @@ public int getPageSize() { public static final int PAGE_TOKEN_FIELD_NUMBER = 3; private volatile java.lang.Object pageToken_; /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListProviders` call to retrieve the subsequent page.
@@ -123,6 +139,7 @@ public int getPageSize() {
    * 
* * string page_token = 3; + * * @return The pageToken. */ @java.lang.Override @@ -131,14 +148,15 @@ public java.lang.String getPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; } } /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListProviders` call to retrieve the subsequent page.
@@ -147,16 +165,15 @@ public java.lang.String getPageToken() {
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -167,6 +184,8 @@ public java.lang.String getPageToken() { public static final int ORDER_BY_FIELD_NUMBER = 4; private volatile java.lang.Object orderBy_; /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting oder is ascending. To
@@ -175,6 +194,7 @@ public java.lang.String getPageToken() {
    * 
* * string order_by = 4; + * * @return The orderBy. */ @java.lang.Override @@ -183,14 +203,15 @@ public java.lang.String getOrderBy() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); orderBy_ = s; return s; } } /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting oder is ascending. To
@@ -199,16 +220,15 @@ public java.lang.String getOrderBy() {
    * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ @java.lang.Override - public com.google.protobuf.ByteString - getOrderByBytes() { + public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); orderBy_ = b; return b; } else { @@ -219,11 +239,14 @@ public java.lang.String getOrderBy() { public static final int FILTER_FIELD_NUMBER = 5; private volatile java.lang.Object filter_; /** + * + * *
    * The filter field that the list request will filter on.
    * 
* * string filter = 5; + * * @return The filter. */ @java.lang.Override @@ -232,29 +255,29 @@ public java.lang.String getFilter() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); filter_ = s; return s; } } /** + * + * *
    * The filter field that the list request will filter on.
    * 
* * string filter = 5; + * * @return The bytes for filter. */ @java.lang.Override - public com.google.protobuf.ByteString - getFilterBytes() { + public com.google.protobuf.ByteString getFilterBytes() { java.lang.Object ref = filter_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); filter_ = b; return b; } else { @@ -263,6 +286,7 @@ public java.lang.String getFilter() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -274,8 +298,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -304,8 +327,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, pageSize_); + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); @@ -324,23 +346,19 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListProvidersRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListProvidersRequest other = (com.google.cloud.eventarc.v1.ListProvidersRequest) obj; - - if (!getParent() - .equals(other.getParent())) return false; - if (getPageSize() - != other.getPageSize()) return false; - if (!getPageToken() - .equals(other.getPageToken())) return false; - if (!getOrderBy() - .equals(other.getOrderBy())) return false; - if (!getFilter() - .equals(other.getFilter())) return false; + com.google.cloud.eventarc.v1.ListProvidersRequest other = + (com.google.cloud.eventarc.v1.ListProvidersRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getFilter().equals(other.getFilter())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -368,129 +386,135 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListProvidersRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListProvidersRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListProvidersRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the ListProviders method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListProvidersRequest) com.google.cloud.eventarc.v1.ListProvidersRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListProvidersRequest.class, com.google.cloud.eventarc.v1.ListProvidersRequest.Builder.class); + com.google.cloud.eventarc.v1.ListProvidersRequest.class, + com.google.cloud.eventarc.v1.ListProvidersRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListProvidersRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -508,9 +532,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor; } @java.lang.Override @@ -529,7 +553,8 @@ public com.google.cloud.eventarc.v1.ListProvidersRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListProvidersRequest buildPartial() { - com.google.cloud.eventarc.v1.ListProvidersRequest result = new com.google.cloud.eventarc.v1.ListProvidersRequest(this); + com.google.cloud.eventarc.v1.ListProvidersRequest result = + new com.google.cloud.eventarc.v1.ListProvidersRequest(this); result.parent_ = parent_; result.pageSize_ = pageSize_; result.pageToken_ = pageToken_; @@ -543,38 +568,39 @@ public com.google.cloud.eventarc.v1.ListProvidersRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListProvidersRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.ListProvidersRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListProvidersRequest) other); } else { super.mergeFrom(other); return this; @@ -582,7 +608,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListProvidersRequest other) { - if (other == com.google.cloud.eventarc.v1.ListProvidersRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListProvidersRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -628,37 +655,43 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); + case 10: + { + parent_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 16: { - pageSize_ = input.readInt32(); + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); - break; - } // case 16 - case 26: { - pageToken_ = input.readStringRequireUtf8(); + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); - break; - } // case 26 - case 34: { - orderBy_ = input.readStringRequireUtf8(); + break; + } // case 26 + case 34: + { + orderBy_ = input.readStringRequireUtf8(); - break; - } // case 34 - case 42: { - filter_ = input.readStringRequireUtf8(); + break; + } // case 34 + case 42: + { + filter_ = input.readStringRequireUtf8(); - break; - } // case 42 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -671,18 +704,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent of the provider to get.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -691,20 +728,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent of the provider to get.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -712,66 +752,82 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent of the provider to get.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent of the provider to get.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent of the provider to get.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; } - private int pageSize_ ; + private int pageSize_; /** + * + * *
      * The maximum number of providers to return on each page.
      * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -779,30 +835,36 @@ public int getPageSize() { return pageSize_; } /** + * + * *
      * The maximum number of providers to return on each page.
      * 
* * int32 page_size = 2; + * * @param value The pageSize to set. * @return This builder for chaining. */ public Builder setPageSize(int value) { - + pageSize_ = value; onChanged(); return this; } /** + * + * *
      * The maximum number of providers to return on each page.
      * 
* * int32 page_size = 2; + * * @return This builder for chaining. */ public Builder clearPageSize() { - + pageSize_ = 0; onChanged(); return this; @@ -810,6 +872,8 @@ public Builder clearPageSize() { private java.lang.Object pageToken_ = ""; /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListProviders` call to retrieve the subsequent page.
@@ -818,13 +882,13 @@ public Builder clearPageSize() {
      * 
* * string page_token = 3; + * * @return The pageToken. */ public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; @@ -833,6 +897,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListProviders` call to retrieve the subsequent page.
@@ -841,15 +907,14 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -857,6 +922,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListProviders` call to retrieve the subsequent page.
@@ -865,20 +932,22 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @param value The pageToken to set. * @return This builder for chaining. */ - public Builder setPageToken( - java.lang.String value) { + public Builder setPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + pageToken_ = value; onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListProviders` call to retrieve the subsequent page.
@@ -887,15 +956,18 @@ public Builder setPageToken(
      * 
* * string page_token = 3; + * * @return This builder for chaining. */ public Builder clearPageToken() { - + pageToken_ = getDefaultInstance().getPageToken(); onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListProviders` call to retrieve the subsequent page.
@@ -904,16 +976,16 @@ public Builder clearPageToken() {
      * 
* * string page_token = 3; + * * @param value The bytes for pageToken to set. * @return This builder for chaining. */ - public Builder setPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; onChanged(); return this; @@ -921,6 +993,8 @@ public Builder setPageTokenBytes( private java.lang.Object orderBy_ = ""; /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting oder is ascending. To
@@ -929,13 +1003,13 @@ public Builder setPageTokenBytes(
      * 
* * string order_by = 4; + * * @return The orderBy. */ public java.lang.String getOrderBy() { java.lang.Object ref = orderBy_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); orderBy_ = s; return s; @@ -944,6 +1018,8 @@ public java.lang.String getOrderBy() { } } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting oder is ascending. To
@@ -952,15 +1028,14 @@ public java.lang.String getOrderBy() {
      * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ - public com.google.protobuf.ByteString - getOrderByBytes() { + public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); orderBy_ = b; return b; } else { @@ -968,6 +1043,8 @@ public java.lang.String getOrderBy() { } } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting oder is ascending. To
@@ -976,20 +1053,22 @@ public java.lang.String getOrderBy() {
      * 
* * string order_by = 4; + * * @param value The orderBy to set. * @return This builder for chaining. */ - public Builder setOrderBy( - java.lang.String value) { + public Builder setOrderBy(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + orderBy_ = value; onChanged(); return this; } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting oder is ascending. To
@@ -998,15 +1077,18 @@ public Builder setOrderBy(
      * 
* * string order_by = 4; + * * @return This builder for chaining. */ public Builder clearOrderBy() { - + orderBy_ = getDefaultInstance().getOrderBy(); onChanged(); return this; } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting oder is ascending. To
@@ -1015,16 +1097,16 @@ public Builder clearOrderBy() {
      * 
* * string order_by = 4; + * * @param value The bytes for orderBy to set. * @return This builder for chaining. */ - public Builder setOrderByBytes( - com.google.protobuf.ByteString value) { + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; onChanged(); return this; @@ -1032,18 +1114,20 @@ public Builder setOrderByBytes( private java.lang.Object filter_ = ""; /** + * + * *
      * The filter field that the list request will filter on.
      * 
* * string filter = 5; + * * @return The filter. */ public java.lang.String getFilter() { java.lang.Object ref = filter_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); filter_ = s; return s; @@ -1052,20 +1136,21 @@ public java.lang.String getFilter() { } } /** + * + * *
      * The filter field that the list request will filter on.
      * 
* * string filter = 5; + * * @return The bytes for filter. */ - public com.google.protobuf.ByteString - getFilterBytes() { + public com.google.protobuf.ByteString getFilterBytes() { java.lang.Object ref = filter_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); filter_ = b; return b; } else { @@ -1073,61 +1158,68 @@ public java.lang.String getFilter() { } } /** + * + * *
      * The filter field that the list request will filter on.
      * 
* * string filter = 5; + * * @param value The filter to set. * @return This builder for chaining. */ - public Builder setFilter( - java.lang.String value) { + public Builder setFilter(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + filter_ = value; onChanged(); return this; } /** + * + * *
      * The filter field that the list request will filter on.
      * 
* * string filter = 5; + * * @return This builder for chaining. */ public Builder clearFilter() { - + filter_ = getDefaultInstance().getFilter(); onChanged(); return this; } /** + * + * *
      * The filter field that the list request will filter on.
      * 
* * string filter = 5; + * * @param value The bytes for filter to set. * @return This builder for chaining. */ - public Builder setFilterBytes( - com.google.protobuf.ByteString value) { + public Builder setFilterBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1137,12 +1229,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListProvidersRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListProvidersRequest) private static final com.google.cloud.eventarc.v1.ListProvidersRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListProvidersRequest(); } @@ -1151,27 +1243,27 @@ public static com.google.cloud.eventarc.v1.ListProvidersRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListProvidersRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListProvidersRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1186,6 +1278,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ListProvidersRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java similarity index 80% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java index c9c894382579..dd8c303cedd8 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersRequestOrBuilder.java @@ -3,41 +3,56 @@ package com.google.cloud.eventarc.v1; -public interface ListProvidersRequestOrBuilder extends +public interface ListProvidersRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListProvidersRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent of the provider to get.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent of the provider to get.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * The maximum number of providers to return on each page.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ int getPageSize(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListProviders` call to retrieve the subsequent page.
@@ -46,10 +61,13 @@ public interface ListProvidersRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The pageToken. */ java.lang.String getPageToken(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListProviders` call to retrieve the subsequent page.
@@ -58,12 +76,14 @@ public interface ListProvidersRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - com.google.protobuf.ByteString - getPageTokenBytes(); + com.google.protobuf.ByteString getPageTokenBytes(); /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting oder is ascending. To
@@ -72,10 +92,13 @@ public interface ListProvidersRequestOrBuilder extends
    * 
* * string order_by = 4; + * * @return The orderBy. */ java.lang.String getOrderBy(); /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting oder is ascending. To
@@ -84,28 +107,33 @@ public interface ListProvidersRequestOrBuilder extends
    * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ - com.google.protobuf.ByteString - getOrderByBytes(); + com.google.protobuf.ByteString getOrderByBytes(); /** + * + * *
    * The filter field that the list request will filter on.
    * 
* * string filter = 5; + * * @return The filter. */ java.lang.String getFilter(); /** + * + * *
    * The filter field that the list request will filter on.
    * 
* * string filter = 5; + * * @return The bytes for filter. */ - com.google.protobuf.ByteString - getFilterBytes(); + com.google.protobuf.ByteString getFilterBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java index cf6f38954142..5c480c7b659c 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponse.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The response message for the `ListProviders` method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersResponse} */ -public final class ListProvidersResponse extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListProvidersResponse extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListProvidersResponse) ListProvidersResponseOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListProvidersResponse.newBuilder() to construct. private ListProvidersResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListProvidersResponse() { providers_ = java.util.Collections.emptyList(); nextPageToken_ = ""; @@ -27,32 +30,35 @@ private ListProvidersResponse() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListProvidersResponse(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListProvidersResponse.class, com.google.cloud.eventarc.v1.ListProvidersResponse.Builder.class); + com.google.cloud.eventarc.v1.ListProvidersResponse.class, + com.google.cloud.eventarc.v1.ListProvidersResponse.Builder.class); } public static final int PROVIDERS_FIELD_NUMBER = 1; private java.util.List providers_; /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -64,6 +70,8 @@ public java.util.List getProvidersList() return providers_; } /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -71,11 +79,13 @@ public java.util.List getProvidersList() * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ @java.lang.Override - public java.util.List + public java.util.List getProvidersOrBuilderList() { return providers_; } /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -87,6 +97,8 @@ public int getProvidersCount() { return providers_.size(); } /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -98,6 +110,8 @@ public com.google.cloud.eventarc.v1.Provider getProviders(int index) { return providers_.get(index); } /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -105,20 +119,22 @@ public com.google.cloud.eventarc.v1.Provider getProviders(int index) { * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ @java.lang.Override - public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder(int index) { return providers_.get(index); } public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; private volatile java.lang.Object nextPageToken_; /** + * + * *
    * A page token that can be sent to `ListProviders` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ @java.lang.Override @@ -127,30 +143,30 @@ public java.lang.String getNextPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; } } /** + * + * *
    * A page token that can be sent to `ListProviders` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -161,34 +177,42 @@ public java.lang.String getNextPageToken() { public static final int UNREACHABLE_FIELD_NUMBER = 3; private com.google.protobuf.LazyStringList unreachable_; /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_; } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -196,20 +220,23 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -221,8 +248,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < providers_.size(); i++) { output.writeMessage(1, providers_.get(i)); } @@ -242,8 +268,7 @@ public int getSerializedSize() { size = 0; for (int i = 0; i < providers_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, providers_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, providers_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); @@ -264,19 +289,17 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListProvidersResponse)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListProvidersResponse other = (com.google.cloud.eventarc.v1.ListProvidersResponse) obj; + com.google.cloud.eventarc.v1.ListProvidersResponse other = + (com.google.cloud.eventarc.v1.ListProvidersResponse) obj; - if (!getProvidersList() - .equals(other.getProvidersList())) return false; - if (!getNextPageToken() - .equals(other.getNextPageToken())) return false; - if (!getUnreachableList() - .equals(other.getUnreachableList())) return false; + if (!getProvidersList().equals(other.getProvidersList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -304,129 +327,135 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListProvidersResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListProvidersResponse parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListProvidersResponse prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The response message for the `ListProviders` method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListProvidersResponse} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListProvidersResponse) com.google.cloud.eventarc.v1.ListProvidersResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListProvidersResponse.class, com.google.cloud.eventarc.v1.ListProvidersResponse.Builder.class); + com.google.cloud.eventarc.v1.ListProvidersResponse.class, + com.google.cloud.eventarc.v1.ListProvidersResponse.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListProvidersResponse.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -445,9 +474,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor; } @java.lang.Override @@ -466,7 +495,8 @@ public com.google.cloud.eventarc.v1.ListProvidersResponse build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListProvidersResponse buildPartial() { - com.google.cloud.eventarc.v1.ListProvidersResponse result = new com.google.cloud.eventarc.v1.ListProvidersResponse(this); + com.google.cloud.eventarc.v1.ListProvidersResponse result = + new com.google.cloud.eventarc.v1.ListProvidersResponse(this); int from_bitField0_ = bitField0_; if (providersBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { @@ -491,38 +521,39 @@ public com.google.cloud.eventarc.v1.ListProvidersResponse buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListProvidersResponse) { - return mergeFrom((com.google.cloud.eventarc.v1.ListProvidersResponse)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListProvidersResponse) other); } else { super.mergeFrom(other); return this; @@ -530,7 +561,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListProvidersResponse other) { - if (other == com.google.cloud.eventarc.v1.ListProvidersResponse.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListProvidersResponse.getDefaultInstance()) + return this; if (providersBuilder_ == null) { if (!other.providers_.isEmpty()) { if (providers_.isEmpty()) { @@ -549,9 +581,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.ListProvidersResponse othe providersBuilder_ = null; providers_ = other.providers_; bitField0_ = (bitField0_ & ~0x00000001); - providersBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getProvidersFieldBuilder() : null; + providersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getProvidersFieldBuilder() + : null; } else { providersBuilder_.addAllMessages(other.providers_); } @@ -597,36 +630,39 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - com.google.cloud.eventarc.v1.Provider m = - input.readMessage( - com.google.cloud.eventarc.v1.Provider.parser(), - extensionRegistry); - if (providersBuilder_ == null) { - ensureProvidersIsMutable(); - providers_.add(m); - } else { - providersBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: { - nextPageToken_ = input.readStringRequireUtf8(); + case 10: + { + com.google.cloud.eventarc.v1.Provider m = + input.readMessage( + com.google.cloud.eventarc.v1.Provider.parser(), extensionRegistry); + if (providersBuilder_ == null) { + ensureProvidersIsMutable(); + providers_.add(m); + } else { + providersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - ensureUnreachableIsMutable(); - unreachable_.add(s); - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -636,21 +672,28 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.util.List providers_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureProvidersIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { providers_ = new java.util.ArrayList(providers_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Provider, com.google.cloud.eventarc.v1.Provider.Builder, com.google.cloud.eventarc.v1.ProviderOrBuilder> providersBuilder_; + com.google.cloud.eventarc.v1.Provider, + com.google.cloud.eventarc.v1.Provider.Builder, + com.google.cloud.eventarc.v1.ProviderOrBuilder> + providersBuilder_; /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -665,6 +708,8 @@ public java.util.List getProvidersList() } } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -679,6 +724,8 @@ public int getProvidersCount() { } } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -693,14 +740,15 @@ public com.google.cloud.eventarc.v1.Provider getProviders(int index) { } } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public Builder setProviders( - int index, com.google.cloud.eventarc.v1.Provider value) { + public Builder setProviders(int index, com.google.cloud.eventarc.v1.Provider value) { if (providersBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -714,6 +762,8 @@ public Builder setProviders( return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -732,6 +782,8 @@ public Builder setProviders( return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -752,14 +804,15 @@ public Builder addProviders(com.google.cloud.eventarc.v1.Provider value) { return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public Builder addProviders( - int index, com.google.cloud.eventarc.v1.Provider value) { + public Builder addProviders(int index, com.google.cloud.eventarc.v1.Provider value) { if (providersBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -773,14 +826,15 @@ public Builder addProviders( return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public Builder addProviders( - com.google.cloud.eventarc.v1.Provider.Builder builderForValue) { + public Builder addProviders(com.google.cloud.eventarc.v1.Provider.Builder builderForValue) { if (providersBuilder_ == null) { ensureProvidersIsMutable(); providers_.add(builderForValue.build()); @@ -791,6 +845,8 @@ public Builder addProviders( return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -809,6 +865,8 @@ public Builder addProviders( return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -819,8 +877,7 @@ public Builder addAllProviders( java.lang.Iterable values) { if (providersBuilder_ == null) { ensureProvidersIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, providers_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, providers_); onChanged(); } else { providersBuilder_.addAllMessages(values); @@ -828,6 +885,8 @@ public Builder addAllProviders( return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -845,6 +904,8 @@ public Builder clearProviders() { return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -862,39 +923,44 @@ public Builder removeProviders(int index) { return this; } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public com.google.cloud.eventarc.v1.Provider.Builder getProvidersBuilder( - int index) { + public com.google.cloud.eventarc.v1.Provider.Builder getProvidersBuilder(int index) { return getProvidersFieldBuilder().getBuilder(index); } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder(int index) { if (providersBuilder_ == null) { - return providers_.get(index); } else { + return providers_.get(index); + } else { return providersBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public java.util.List - getProvidersOrBuilderList() { + public java.util.List + getProvidersOrBuilderList() { if (providersBuilder_ != null) { return providersBuilder_.getMessageOrBuilderList(); } else { @@ -902,6 +968,8 @@ public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder( } } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
@@ -909,42 +977,47 @@ public com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder( * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ public com.google.cloud.eventarc.v1.Provider.Builder addProvidersBuilder() { - return getProvidersFieldBuilder().addBuilder( - com.google.cloud.eventarc.v1.Provider.getDefaultInstance()); + return getProvidersFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.Provider.getDefaultInstance()); } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public com.google.cloud.eventarc.v1.Provider.Builder addProvidersBuilder( - int index) { - return getProvidersFieldBuilder().addBuilder( - index, com.google.cloud.eventarc.v1.Provider.getDefaultInstance()); + public com.google.cloud.eventarc.v1.Provider.Builder addProvidersBuilder(int index) { + return getProvidersFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.Provider.getDefaultInstance()); } /** + * + * *
      * The requested providers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - public java.util.List - getProvidersBuilderList() { + public java.util.List getProvidersBuilderList() { return getProvidersFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Provider, com.google.cloud.eventarc.v1.Provider.Builder, com.google.cloud.eventarc.v1.ProviderOrBuilder> + com.google.cloud.eventarc.v1.Provider, + com.google.cloud.eventarc.v1.Provider.Builder, + com.google.cloud.eventarc.v1.ProviderOrBuilder> getProvidersFieldBuilder() { if (providersBuilder_ == null) { - providersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Provider, com.google.cloud.eventarc.v1.Provider.Builder, com.google.cloud.eventarc.v1.ProviderOrBuilder>( - providers_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); + providersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Provider, + com.google.cloud.eventarc.v1.Provider.Builder, + com.google.cloud.eventarc.v1.ProviderOrBuilder>( + providers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); providers_ = null; } return providersBuilder_; @@ -952,19 +1025,21 @@ public com.google.cloud.eventarc.v1.Provider.Builder addProvidersBuilder( private java.lang.Object nextPageToken_ = ""; /** + * + * *
      * A page token that can be sent to `ListProviders` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; @@ -973,21 +1048,22 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListProviders` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -995,98 +1071,115 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListProviders` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @param value The nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageToken( - java.lang.String value) { + public Builder setNextPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + nextPageToken_ = value; onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListProviders` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return This builder for chaining. */ public Builder clearNextPageToken() { - + nextPageToken_ = getDefaultInstance().getNextPageToken(); onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListProviders` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @param value The bytes for nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; onChanged(); return this; } - private com.google.protobuf.LazyStringList unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensureUnreachableIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); bitField0_ |= 0x00000002; - } + } } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_.getUnmodifiableView(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -1094,80 +1187,90 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index to set the value at. * @param value The unreachable to set. * @return This builder for chaining. */ - public Builder setUnreachable( - int index, java.lang.String value) { + public Builder setUnreachable(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.set(index, value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachable( - java.lang.String value) { + public Builder addUnreachable(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param values The unreachable to add. * @return This builder for chaining. */ - public Builder addAllUnreachable( - java.lang.Iterable values) { + public Builder addAllUnreachable(java.lang.Iterable values) { ensureUnreachableIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, unreachable_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return This builder for chaining. */ public Builder clearUnreachable() { @@ -1177,28 +1280,30 @@ public Builder clearUnreachable() { return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The bytes of the unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachableBytes( - com.google.protobuf.ByteString value) { + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1208,12 +1313,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListProvidersResponse) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListProvidersResponse) private static final com.google.cloud.eventarc.v1.ListProvidersResponse DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListProvidersResponse(); } @@ -1222,27 +1327,27 @@ public static com.google.cloud.eventarc.v1.ListProvidersResponse getDefaultInsta return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListProvidersResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListProvidersResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1257,6 +1362,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ListProvidersResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java similarity index 85% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java index 98b107eb7879..7bac1c1e5f5e 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListProvidersResponseOrBuilder.java @@ -3,20 +3,24 @@ package com.google.cloud.eventarc.v1; -public interface ListProvidersResponseOrBuilder extends +public interface ListProvidersResponseOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListProvidersResponse) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - java.util.List - getProvidersList(); + java.util.List getProvidersList(); /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -25,6 +29,8 @@ public interface ListProvidersResponseOrBuilder extends */ com.google.cloud.eventarc.v1.Provider getProviders(int index); /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
@@ -33,84 +39,102 @@ public interface ListProvidersResponseOrBuilder extends */ int getProvidersCount(); /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - java.util.List + java.util.List getProvidersOrBuilderList(); /** + * + * *
    * The requested providers, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Provider providers = 1; */ - com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder( - int index); + com.google.cloud.eventarc.v1.ProviderOrBuilder getProvidersOrBuilder(int index); /** + * + * *
    * A page token that can be sent to `ListProviders` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ java.lang.String getNextPageToken(); /** + * + * *
    * A page token that can be sent to `ListProviders` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - com.google.protobuf.ByteString - getNextPageTokenBytes(); + com.google.protobuf.ByteString getNextPageTokenBytes(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - java.util.List - getUnreachableList(); + java.util.List getUnreachableList(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ int getUnreachableCount(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ java.lang.String getUnreachable(int index); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - com.google.protobuf.ByteString - getUnreachableBytes(int index); + com.google.protobuf.ByteString getUnreachableBytes(int index); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java similarity index 72% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java index 2f2cbe1e4a6d..3909eef431de 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequest.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the ListTriggers method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersRequest} */ -public final class ListTriggersRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListTriggersRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListTriggersRequest) ListTriggersRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListTriggersRequest.newBuilder() to construct. private ListTriggersRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListTriggersRequest() { parent_ = ""; pageToken_ = ""; @@ -28,37 +31,43 @@ private ListTriggersRequest() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListTriggersRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListTriggersRequest.class, com.google.cloud.eventarc.v1.ListTriggersRequest.Builder.class); + com.google.cloud.eventarc.v1.ListTriggersRequest.class, + com.google.cloud.eventarc.v1.ListTriggersRequest.Builder.class); } public static final int PARENT_FIELD_NUMBER = 1; private volatile java.lang.Object parent_; /** + * + * *
    * Required. The parent collection to list triggers on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ @java.lang.Override @@ -67,29 +76,31 @@ public java.lang.String getParent() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; } } /** + * + * *
    * Required. The parent collection to list triggers on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ @java.lang.Override - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -100,12 +111,15 @@ public java.lang.String getParent() { public static final int PAGE_SIZE_FIELD_NUMBER = 2; private int pageSize_; /** + * + * *
    * The maximum number of triggers to return on each page.
    * Note: The service may send fewer.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -116,6 +130,8 @@ public int getPageSize() { public static final int PAGE_TOKEN_FIELD_NUMBER = 3; private volatile java.lang.Object pageToken_; /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListTriggers` call to retrieve the subsequent page.
@@ -124,6 +140,7 @@ public int getPageSize() {
    * 
* * string page_token = 3; + * * @return The pageToken. */ @java.lang.Override @@ -132,14 +149,15 @@ public java.lang.String getPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; } } /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListTriggers` call to retrieve the subsequent page.
@@ -148,16 +166,15 @@ public java.lang.String getPageToken() {
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -168,6 +185,8 @@ public java.lang.String getPageToken() { public static final int ORDER_BY_FIELD_NUMBER = 4; private volatile java.lang.Object orderBy_; /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -176,6 +195,7 @@ public java.lang.String getPageToken() {
    * 
* * string order_by = 4; + * * @return The orderBy. */ @java.lang.Override @@ -184,14 +204,15 @@ public java.lang.String getOrderBy() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); orderBy_ = s; return s; } } /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -200,16 +221,15 @@ public java.lang.String getOrderBy() {
    * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ @java.lang.Override - public com.google.protobuf.ByteString - getOrderByBytes() { + public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); orderBy_ = b; return b; } else { @@ -220,6 +240,8 @@ public java.lang.String getOrderBy() { public static final int FILTER_FIELD_NUMBER = 5; private volatile java.lang.Object filter_; /** + * + * *
    * Filter field. Used to filter the Triggers to be listed. Possible filters
    * are described in https://google.aip.dev/160. For example, using
@@ -227,6 +249,7 @@ public java.lang.String getOrderBy() {
    * 
* * string filter = 5; + * * @return The filter. */ @java.lang.Override @@ -235,14 +258,15 @@ public java.lang.String getFilter() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); filter_ = s; return s; } } /** + * + * *
    * Filter field. Used to filter the Triggers to be listed. Possible filters
    * are described in https://google.aip.dev/160. For example, using
@@ -250,16 +274,15 @@ public java.lang.String getFilter() {
    * 
* * string filter = 5; + * * @return The bytes for filter. */ @java.lang.Override - public com.google.protobuf.ByteString - getFilterBytes() { + public com.google.protobuf.ByteString getFilterBytes() { java.lang.Object ref = filter_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); filter_ = b; return b; } else { @@ -268,6 +291,7 @@ public java.lang.String getFilter() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -279,8 +303,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); } @@ -309,8 +332,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); } if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(2, pageSize_); + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); @@ -329,23 +351,19 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListTriggersRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListTriggersRequest other = (com.google.cloud.eventarc.v1.ListTriggersRequest) obj; - - if (!getParent() - .equals(other.getParent())) return false; - if (getPageSize() - != other.getPageSize()) return false; - if (!getPageToken() - .equals(other.getPageToken())) return false; - if (!getOrderBy() - .equals(other.getOrderBy())) return false; - if (!getFilter() - .equals(other.getFilter())) return false; + com.google.cloud.eventarc.v1.ListTriggersRequest other = + (com.google.cloud.eventarc.v1.ListTriggersRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!getOrderBy().equals(other.getOrderBy())) return false; + if (!getFilter().equals(other.getFilter())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -372,130 +390,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListTriggersRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListTriggersRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListTriggersRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the ListTriggers method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListTriggersRequest) com.google.cloud.eventarc.v1.ListTriggersRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListTriggersRequest.class, com.google.cloud.eventarc.v1.ListTriggersRequest.Builder.class); + com.google.cloud.eventarc.v1.ListTriggersRequest.class, + com.google.cloud.eventarc.v1.ListTriggersRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListTriggersRequest.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -513,9 +537,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor; } @java.lang.Override @@ -534,7 +558,8 @@ public com.google.cloud.eventarc.v1.ListTriggersRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListTriggersRequest buildPartial() { - com.google.cloud.eventarc.v1.ListTriggersRequest result = new com.google.cloud.eventarc.v1.ListTriggersRequest(this); + com.google.cloud.eventarc.v1.ListTriggersRequest result = + new com.google.cloud.eventarc.v1.ListTriggersRequest(this); result.parent_ = parent_; result.pageSize_ = pageSize_; result.pageToken_ = pageToken_; @@ -548,38 +573,39 @@ public com.google.cloud.eventarc.v1.ListTriggersRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListTriggersRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.ListTriggersRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListTriggersRequest) other); } else { super.mergeFrom(other); return this; @@ -587,7 +613,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListTriggersRequest other) { - if (other == com.google.cloud.eventarc.v1.ListTriggersRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListTriggersRequest.getDefaultInstance()) + return this; if (!other.getParent().isEmpty()) { parent_ = other.parent_; onChanged(); @@ -633,37 +660,43 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - parent_ = input.readStringRequireUtf8(); + case 10: + { + parent_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 16: { - pageSize_ = input.readInt32(); + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); - break; - } // case 16 - case 26: { - pageToken_ = input.readStringRequireUtf8(); + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); - break; - } // case 26 - case 34: { - orderBy_ = input.readStringRequireUtf8(); + break; + } // case 26 + case 34: + { + orderBy_ = input.readStringRequireUtf8(); - break; - } // case 34 - case 42: { - filter_ = input.readStringRequireUtf8(); + break; + } // case 34 + case 42: + { + filter_ = input.readStringRequireUtf8(); - break; - } // case 42 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -676,18 +709,22 @@ public Builder mergeFrom( private java.lang.Object parent_ = ""; /** + * + * *
      * Required. The parent collection to list triggers on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ public java.lang.String getParent() { java.lang.Object ref = parent_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parent_ = s; return s; @@ -696,20 +733,23 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection to list triggers on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - public com.google.protobuf.ByteString - getParentBytes() { + public com.google.protobuf.ByteString getParentBytes() { java.lang.Object ref = parent_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); parent_ = b; return b; } else { @@ -717,67 +757,83 @@ public java.lang.String getParent() { } } /** + * + * *
      * Required. The parent collection to list triggers on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The parent to set. * @return This builder for chaining. */ - public Builder setParent( - java.lang.String value) { + public Builder setParent(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + parent_ = value; onChanged(); return this; } /** + * + * *
      * Required. The parent collection to list triggers on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearParent() { - + parent_ = getDefaultInstance().getParent(); onChanged(); return this; } /** + * + * *
      * Required. The parent collection to list triggers on.
      * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for parent to set. * @return This builder for chaining. */ - public Builder setParentBytes( - com.google.protobuf.ByteString value) { + public Builder setParentBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + parent_ = value; onChanged(); return this; } - private int pageSize_ ; + private int pageSize_; /** + * + * *
      * The maximum number of triggers to return on each page.
      * Note: The service may send fewer.
      * 
* * int32 page_size = 2; + * * @return The pageSize. */ @java.lang.Override @@ -785,32 +841,38 @@ public int getPageSize() { return pageSize_; } /** + * + * *
      * The maximum number of triggers to return on each page.
      * Note: The service may send fewer.
      * 
* * int32 page_size = 2; + * * @param value The pageSize to set. * @return This builder for chaining. */ public Builder setPageSize(int value) { - + pageSize_ = value; onChanged(); return this; } /** + * + * *
      * The maximum number of triggers to return on each page.
      * Note: The service may send fewer.
      * 
* * int32 page_size = 2; + * * @return This builder for chaining. */ public Builder clearPageSize() { - + pageSize_ = 0; onChanged(); return this; @@ -818,6 +880,8 @@ public Builder clearPageSize() { private java.lang.Object pageToken_ = ""; /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListTriggers` call to retrieve the subsequent page.
@@ -826,13 +890,13 @@ public Builder clearPageSize() {
      * 
* * string page_token = 3; + * * @return The pageToken. */ public java.lang.String getPageToken() { java.lang.Object ref = pageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); pageToken_ = s; return s; @@ -841,6 +905,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListTriggers` call to retrieve the subsequent page.
@@ -849,15 +915,14 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - public com.google.protobuf.ByteString - getPageTokenBytes() { + public com.google.protobuf.ByteString getPageTokenBytes() { java.lang.Object ref = pageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); pageToken_ = b; return b; } else { @@ -865,6 +930,8 @@ public java.lang.String getPageToken() { } } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListTriggers` call to retrieve the subsequent page.
@@ -873,20 +940,22 @@ public java.lang.String getPageToken() {
      * 
* * string page_token = 3; + * * @param value The pageToken to set. * @return This builder for chaining. */ - public Builder setPageToken( - java.lang.String value) { + public Builder setPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + pageToken_ = value; onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListTriggers` call to retrieve the subsequent page.
@@ -895,15 +964,18 @@ public Builder setPageToken(
      * 
* * string page_token = 3; + * * @return This builder for chaining. */ public Builder clearPageToken() { - + pageToken_ = getDefaultInstance().getPageToken(); onChanged(); return this; } /** + * + * *
      * The page token; provide the value from the `next_page_token` field in a
      * previous `ListTriggers` call to retrieve the subsequent page.
@@ -912,16 +984,16 @@ public Builder clearPageToken() {
      * 
* * string page_token = 3; + * * @param value The bytes for pageToken to set. * @return This builder for chaining. */ - public Builder setPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + pageToken_ = value; onChanged(); return this; @@ -929,6 +1001,8 @@ public Builder setPageTokenBytes( private java.lang.Object orderBy_ = ""; /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -937,13 +1011,13 @@ public Builder setPageTokenBytes(
      * 
* * string order_by = 4; + * * @return The orderBy. */ public java.lang.String getOrderBy() { java.lang.Object ref = orderBy_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); orderBy_ = s; return s; @@ -952,6 +1026,8 @@ public java.lang.String getOrderBy() { } } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -960,15 +1036,14 @@ public java.lang.String getOrderBy() {
      * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ - public com.google.protobuf.ByteString - getOrderByBytes() { + public com.google.protobuf.ByteString getOrderByBytes() { java.lang.Object ref = orderBy_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); orderBy_ = b; return b; } else { @@ -976,6 +1051,8 @@ public java.lang.String getOrderBy() { } } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -984,20 +1061,22 @@ public java.lang.String getOrderBy() {
      * 
* * string order_by = 4; + * * @param value The orderBy to set. * @return This builder for chaining. */ - public Builder setOrderBy( - java.lang.String value) { + public Builder setOrderBy(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + orderBy_ = value; onChanged(); return this; } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -1006,15 +1085,18 @@ public Builder setOrderBy(
      * 
* * string order_by = 4; + * * @return This builder for chaining. */ public Builder clearOrderBy() { - + orderBy_ = getDefaultInstance().getOrderBy(); onChanged(); return this; } /** + * + * *
      * The sorting order of the resources returned. Value should be a
      * comma-separated list of fields. The default sorting order is ascending. To
@@ -1023,16 +1105,16 @@ public Builder clearOrderBy() {
      * 
* * string order_by = 4; + * * @param value The bytes for orderBy to set. * @return This builder for chaining. */ - public Builder setOrderByBytes( - com.google.protobuf.ByteString value) { + public Builder setOrderByBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + orderBy_ = value; onChanged(); return this; @@ -1040,6 +1122,8 @@ public Builder setOrderByBytes( private java.lang.Object filter_ = ""; /** + * + * *
      * Filter field. Used to filter the Triggers to be listed. Possible filters
      * are described in https://google.aip.dev/160. For example, using
@@ -1047,13 +1131,13 @@ public Builder setOrderByBytes(
      * 
* * string filter = 5; + * * @return The filter. */ public java.lang.String getFilter() { java.lang.Object ref = filter_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); filter_ = s; return s; @@ -1062,6 +1146,8 @@ public java.lang.String getFilter() { } } /** + * + * *
      * Filter field. Used to filter the Triggers to be listed. Possible filters
      * are described in https://google.aip.dev/160. For example, using
@@ -1069,15 +1155,14 @@ public java.lang.String getFilter() {
      * 
* * string filter = 5; + * * @return The bytes for filter. */ - public com.google.protobuf.ByteString - getFilterBytes() { + public com.google.protobuf.ByteString getFilterBytes() { java.lang.Object ref = filter_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); filter_ = b; return b; } else { @@ -1085,6 +1170,8 @@ public java.lang.String getFilter() { } } /** + * + * *
      * Filter field. Used to filter the Triggers to be listed. Possible filters
      * are described in https://google.aip.dev/160. For example, using
@@ -1092,20 +1179,22 @@ public java.lang.String getFilter() {
      * 
* * string filter = 5; + * * @param value The filter to set. * @return This builder for chaining. */ - public Builder setFilter( - java.lang.String value) { + public Builder setFilter(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + filter_ = value; onChanged(); return this; } /** + * + * *
      * Filter field. Used to filter the Triggers to be listed. Possible filters
      * are described in https://google.aip.dev/160. For example, using
@@ -1113,15 +1202,18 @@ public Builder setFilter(
      * 
* * string filter = 5; + * * @return This builder for chaining. */ public Builder clearFilter() { - + filter_ = getDefaultInstance().getFilter(); onChanged(); return this; } /** + * + * *
      * Filter field. Used to filter the Triggers to be listed. Possible filters
      * are described in https://google.aip.dev/160. For example, using
@@ -1129,23 +1221,23 @@ public Builder clearFilter() {
      * 
* * string filter = 5; + * * @param value The bytes for filter to set. * @return This builder for chaining. */ - public Builder setFilterBytes( - com.google.protobuf.ByteString value) { + public Builder setFilterBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + filter_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1155,12 +1247,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListTriggersRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListTriggersRequest) private static final com.google.cloud.eventarc.v1.ListTriggersRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListTriggersRequest(); } @@ -1169,27 +1261,27 @@ public static com.google.cloud.eventarc.v1.ListTriggersRequest getDefaultInstanc return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListTriggersRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListTriggersRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1204,6 +1296,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ListTriggersRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java similarity index 82% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java index f8d5c9972feb..900278360db1 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersRequestOrBuilder.java @@ -3,42 +3,57 @@ package com.google.cloud.eventarc.v1; -public interface ListTriggersRequestOrBuilder extends +public interface ListTriggersRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListTriggersRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The parent collection to list triggers on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The parent. */ java.lang.String getParent(); /** + * + * *
    * Required. The parent collection to list triggers on.
    * 
* - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for parent. */ - com.google.protobuf.ByteString - getParentBytes(); + com.google.protobuf.ByteString getParentBytes(); /** + * + * *
    * The maximum number of triggers to return on each page.
    * Note: The service may send fewer.
    * 
* * int32 page_size = 2; + * * @return The pageSize. */ int getPageSize(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListTriggers` call to retrieve the subsequent page.
@@ -47,10 +62,13 @@ public interface ListTriggersRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The pageToken. */ java.lang.String getPageToken(); /** + * + * *
    * The page token; provide the value from the `next_page_token` field in a
    * previous `ListTriggers` call to retrieve the subsequent page.
@@ -59,12 +77,14 @@ public interface ListTriggersRequestOrBuilder extends
    * 
* * string page_token = 3; + * * @return The bytes for pageToken. */ - com.google.protobuf.ByteString - getPageTokenBytes(); + com.google.protobuf.ByteString getPageTokenBytes(); /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -73,10 +93,13 @@ public interface ListTriggersRequestOrBuilder extends
    * 
* * string order_by = 4; + * * @return The orderBy. */ java.lang.String getOrderBy(); /** + * + * *
    * The sorting order of the resources returned. Value should be a
    * comma-separated list of fields. The default sorting order is ascending. To
@@ -85,12 +108,14 @@ public interface ListTriggersRequestOrBuilder extends
    * 
* * string order_by = 4; + * * @return The bytes for orderBy. */ - com.google.protobuf.ByteString - getOrderByBytes(); + com.google.protobuf.ByteString getOrderByBytes(); /** + * + * *
    * Filter field. Used to filter the Triggers to be listed. Possible filters
    * are described in https://google.aip.dev/160. For example, using
@@ -98,10 +123,13 @@ public interface ListTriggersRequestOrBuilder extends
    * 
* * string filter = 5; + * * @return The filter. */ java.lang.String getFilter(); /** + * + * *
    * Filter field. Used to filter the Triggers to be listed. Possible filters
    * are described in https://google.aip.dev/160. For example, using
@@ -109,8 +137,8 @@ public interface ListTriggersRequestOrBuilder extends
    * 
* * string filter = 5; + * * @return The bytes for filter. */ - com.google.protobuf.ByteString - getFilterBytes(); + com.google.protobuf.ByteString getFilterBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java similarity index 74% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java index f0b3ea43d338..adff743578e1 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponse.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The response message for the `ListTriggers` method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersResponse} */ -public final class ListTriggersResponse extends - com.google.protobuf.GeneratedMessageV3 implements +public final class ListTriggersResponse extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.ListTriggersResponse) ListTriggersResponseOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use ListTriggersResponse.newBuilder() to construct. private ListTriggersResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private ListTriggersResponse() { triggers_ = java.util.Collections.emptyList(); nextPageToken_ = ""; @@ -27,32 +30,35 @@ private ListTriggersResponse() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new ListTriggersResponse(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListTriggersResponse.class, com.google.cloud.eventarc.v1.ListTriggersResponse.Builder.class); + com.google.cloud.eventarc.v1.ListTriggersResponse.class, + com.google.cloud.eventarc.v1.ListTriggersResponse.Builder.class); } public static final int TRIGGERS_FIELD_NUMBER = 1; private java.util.List triggers_; /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -64,6 +70,8 @@ public java.util.List getTriggersList() { return triggers_; } /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -71,11 +79,13 @@ public java.util.List getTriggersList() { * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ @java.lang.Override - public java.util.List + public java.util.List getTriggersOrBuilderList() { return triggers_; } /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -87,6 +97,8 @@ public int getTriggersCount() { return triggers_.size(); } /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -98,6 +110,8 @@ public com.google.cloud.eventarc.v1.Trigger getTriggers(int index) { return triggers_.get(index); } /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -105,20 +119,22 @@ public com.google.cloud.eventarc.v1.Trigger getTriggers(int index) { * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ @java.lang.Override - public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder(int index) { return triggers_.get(index); } public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; private volatile java.lang.Object nextPageToken_; /** + * + * *
    * A page token that can be sent to `ListTriggers` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ @java.lang.Override @@ -127,30 +143,30 @@ public java.lang.String getNextPageToken() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; } } /** + * + * *
    * A page token that can be sent to `ListTriggers` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ @java.lang.Override - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -161,34 +177,42 @@ public java.lang.String getNextPageToken() { public static final int UNREACHABLE_FIELD_NUMBER = 3; private com.google.protobuf.LazyStringList unreachable_; /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_; } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -196,20 +220,23 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -221,8 +248,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < triggers_.size(); i++) { output.writeMessage(1, triggers_.get(i)); } @@ -242,8 +268,7 @@ public int getSerializedSize() { size = 0; for (int i = 0; i < triggers_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, triggers_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, triggers_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); @@ -264,19 +289,17 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.ListTriggersResponse)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.ListTriggersResponse other = (com.google.cloud.eventarc.v1.ListTriggersResponse) obj; + com.google.cloud.eventarc.v1.ListTriggersResponse other = + (com.google.cloud.eventarc.v1.ListTriggersResponse) obj; - if (!getTriggersList() - .equals(other.getTriggersList())) return false; - if (!getNextPageToken() - .equals(other.getNextPageToken())) return false; - if (!getUnreachableList() - .equals(other.getUnreachableList())) return false; + if (!getTriggersList().equals(other.getTriggersList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableList().equals(other.getUnreachableList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -304,129 +327,135 @@ public int hashCode() { } public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.ListTriggersResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.ListTriggersResponse parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.ListTriggersResponse prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The response message for the `ListTriggers` method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.ListTriggersResponse} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.ListTriggersResponse) com.google.cloud.eventarc.v1.ListTriggersResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.ListTriggersResponse.class, com.google.cloud.eventarc.v1.ListTriggersResponse.Builder.class); + com.google.cloud.eventarc.v1.ListTriggersResponse.class, + com.google.cloud.eventarc.v1.ListTriggersResponse.Builder.class); } // Construct using com.google.cloud.eventarc.v1.ListTriggersResponse.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -445,9 +474,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor; } @java.lang.Override @@ -466,7 +495,8 @@ public com.google.cloud.eventarc.v1.ListTriggersResponse build() { @java.lang.Override public com.google.cloud.eventarc.v1.ListTriggersResponse buildPartial() { - com.google.cloud.eventarc.v1.ListTriggersResponse result = new com.google.cloud.eventarc.v1.ListTriggersResponse(this); + com.google.cloud.eventarc.v1.ListTriggersResponse result = + new com.google.cloud.eventarc.v1.ListTriggersResponse(this); int from_bitField0_ = bitField0_; if (triggersBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { @@ -491,38 +521,39 @@ public com.google.cloud.eventarc.v1.ListTriggersResponse buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.ListTriggersResponse) { - return mergeFrom((com.google.cloud.eventarc.v1.ListTriggersResponse)other); + return mergeFrom((com.google.cloud.eventarc.v1.ListTriggersResponse) other); } else { super.mergeFrom(other); return this; @@ -530,7 +561,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.ListTriggersResponse other) { - if (other == com.google.cloud.eventarc.v1.ListTriggersResponse.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.ListTriggersResponse.getDefaultInstance()) + return this; if (triggersBuilder_ == null) { if (!other.triggers_.isEmpty()) { if (triggers_.isEmpty()) { @@ -549,9 +581,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.ListTriggersResponse other triggersBuilder_ = null; triggers_ = other.triggers_; bitField0_ = (bitField0_ & ~0x00000001); - triggersBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getTriggersFieldBuilder() : null; + triggersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getTriggersFieldBuilder() + : null; } else { triggersBuilder_.addAllMessages(other.triggers_); } @@ -597,36 +630,39 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - com.google.cloud.eventarc.v1.Trigger m = - input.readMessage( - com.google.cloud.eventarc.v1.Trigger.parser(), - extensionRegistry); - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - triggers_.add(m); - } else { - triggersBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: { - nextPageToken_ = input.readStringRequireUtf8(); + case 10: + { + com.google.cloud.eventarc.v1.Trigger m = + input.readMessage( + com.google.cloud.eventarc.v1.Trigger.parser(), extensionRegistry); + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.add(m); + } else { + triggersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - java.lang.String s = input.readStringRequireUtf8(); - ensureUnreachableIsMutable(); - unreachable_.add(s); - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableIsMutable(); + unreachable_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -636,21 +672,28 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.util.List triggers_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureTriggersIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { triggers_ = new java.util.ArrayList(triggers_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder> triggersBuilder_; + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + triggersBuilder_; /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -665,6 +708,8 @@ public java.util.List getTriggersList() { } } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -679,6 +724,8 @@ public int getTriggersCount() { } } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -693,14 +740,15 @@ public com.google.cloud.eventarc.v1.Trigger getTriggers(int index) { } } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public Builder setTriggers( - int index, com.google.cloud.eventarc.v1.Trigger value) { + public Builder setTriggers(int index, com.google.cloud.eventarc.v1.Trigger value) { if (triggersBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -714,6 +762,8 @@ public Builder setTriggers( return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -732,6 +782,8 @@ public Builder setTriggers( return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -752,14 +804,15 @@ public Builder addTriggers(com.google.cloud.eventarc.v1.Trigger value) { return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public Builder addTriggers( - int index, com.google.cloud.eventarc.v1.Trigger value) { + public Builder addTriggers(int index, com.google.cloud.eventarc.v1.Trigger value) { if (triggersBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -773,14 +826,15 @@ public Builder addTriggers( return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public Builder addTriggers( - com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + public Builder addTriggers(com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { if (triggersBuilder_ == null) { ensureTriggersIsMutable(); triggers_.add(builderForValue.build()); @@ -791,6 +845,8 @@ public Builder addTriggers( return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -809,6 +865,8 @@ public Builder addTriggers( return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -819,8 +877,7 @@ public Builder addAllTriggers( java.lang.Iterable values) { if (triggersBuilder_ == null) { ensureTriggersIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, triggers_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, triggers_); onChanged(); } else { triggersBuilder_.addAllMessages(values); @@ -828,6 +885,8 @@ public Builder addAllTriggers( return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -845,6 +904,8 @@ public Builder clearTriggers() { return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -862,39 +923,44 @@ public Builder removeTriggers(int index) { return this; } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public com.google.cloud.eventarc.v1.Trigger.Builder getTriggersBuilder( - int index) { + public com.google.cloud.eventarc.v1.Trigger.Builder getTriggersBuilder(int index) { return getTriggersFieldBuilder().getBuilder(index); } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder(int index) { if (triggersBuilder_ == null) { - return triggers_.get(index); } else { + return triggers_.get(index); + } else { return triggersBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public java.util.List - getTriggersOrBuilderList() { + public java.util.List + getTriggersOrBuilderList() { if (triggersBuilder_ != null) { return triggersBuilder_.getMessageOrBuilderList(); } else { @@ -902,6 +968,8 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder( } } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
@@ -909,42 +977,47 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder( * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ public com.google.cloud.eventarc.v1.Trigger.Builder addTriggersBuilder() { - return getTriggersFieldBuilder().addBuilder( - com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()); + return getTriggersFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()); } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public com.google.cloud.eventarc.v1.Trigger.Builder addTriggersBuilder( - int index) { - return getTriggersFieldBuilder().addBuilder( - index, com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()); + public com.google.cloud.eventarc.v1.Trigger.Builder addTriggersBuilder(int index) { + return getTriggersFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.Trigger.getDefaultInstance()); } /** + * + * *
      * The requested triggers, up to the number specified in `page_size`.
      * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - public java.util.List - getTriggersBuilderList() { + public java.util.List getTriggersBuilderList() { return getTriggersFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder> + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> getTriggersFieldBuilder() { if (triggersBuilder_ == null) { - triggersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder>( - triggers_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); + triggersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder>( + triggers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); triggers_ = null; } return triggersBuilder_; @@ -952,19 +1025,21 @@ public com.google.cloud.eventarc.v1.Trigger.Builder addTriggersBuilder( private java.lang.Object nextPageToken_ = ""; /** + * + * *
      * A page token that can be sent to `ListTriggers` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ public java.lang.String getNextPageToken() { java.lang.Object ref = nextPageToken_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); nextPageToken_ = s; return s; @@ -973,21 +1048,22 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListTriggers` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - public com.google.protobuf.ByteString - getNextPageTokenBytes() { + public com.google.protobuf.ByteString getNextPageTokenBytes() { java.lang.Object ref = nextPageToken_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); nextPageToken_ = b; return b; } else { @@ -995,98 +1071,115 @@ public java.lang.String getNextPageToken() { } } /** + * + * *
      * A page token that can be sent to `ListTriggers` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @param value The nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageToken( - java.lang.String value) { + public Builder setNextPageToken(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + nextPageToken_ = value; onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListTriggers` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @return This builder for chaining. */ public Builder clearNextPageToken() { - + nextPageToken_ = getDefaultInstance().getNextPageToken(); onChanged(); return this; } /** + * + * *
      * A page token that can be sent to `ListTriggers` to request the next page.
      * If this is empty, then there are no more pages.
      * 
* * string next_page_token = 2; + * * @param value The bytes for nextPageToken to set. * @return This builder for chaining. */ - public Builder setNextPageTokenBytes( - com.google.protobuf.ByteString value) { + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + nextPageToken_ = value; onChanged(); return this; } - private com.google.protobuf.LazyStringList unreachable_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList unreachable_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensureUnreachableIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { unreachable_ = new com.google.protobuf.LazyStringArrayList(unreachable_); bitField0_ |= 0x00000002; - } + } } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - public com.google.protobuf.ProtocolStringList - getUnreachableList() { + public com.google.protobuf.ProtocolStringList getUnreachableList() { return unreachable_.getUnmodifiableView(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ public int getUnreachableCount() { return unreachable_.size(); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ @@ -1094,80 +1187,90 @@ public java.lang.String getUnreachable(int index) { return unreachable_.get(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - public com.google.protobuf.ByteString - getUnreachableBytes(int index) { + public com.google.protobuf.ByteString getUnreachableBytes(int index) { return unreachable_.getByteString(index); } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param index The index to set the value at. * @param value The unreachable to set. * @return This builder for chaining. */ - public Builder setUnreachable( - int index, java.lang.String value) { + public Builder setUnreachable(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.set(index, value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachable( - java.lang.String value) { + public Builder addUnreachable(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureUnreachableIsMutable(); + throw new NullPointerException(); + } + ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param values The unreachable to add. * @return This builder for chaining. */ - public Builder addAllUnreachable( - java.lang.Iterable values) { + public Builder addAllUnreachable(java.lang.Iterable values) { ensureUnreachableIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, unreachable_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachable_); onChanged(); return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @return This builder for chaining. */ public Builder clearUnreachable() { @@ -1177,28 +1280,30 @@ public Builder clearUnreachable() { return this; } /** + * + * *
      * Unreachable resources, if any.
      * 
* * repeated string unreachable = 3; + * * @param value The bytes of the unreachable to add. * @return This builder for chaining. */ - public Builder addUnreachableBytes( - com.google.protobuf.ByteString value) { + public Builder addUnreachableBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensureUnreachableIsMutable(); unreachable_.add(value); onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1208,12 +1313,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.ListTriggersResponse) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.ListTriggersResponse) private static final com.google.cloud.eventarc.v1.ListTriggersResponse DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.ListTriggersResponse(); } @@ -1222,27 +1327,27 @@ public static com.google.cloud.eventarc.v1.ListTriggersResponse getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListTriggersResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListTriggersResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1257,6 +1362,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.ListTriggersResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java similarity index 85% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java index d39d21c7777f..f98160a1acb1 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ListTriggersResponseOrBuilder.java @@ -3,20 +3,24 @@ package com.google.cloud.eventarc.v1; -public interface ListTriggersResponseOrBuilder extends +public interface ListTriggersResponseOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.ListTriggersResponse) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - java.util.List - getTriggersList(); + java.util.List getTriggersList(); /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -25,6 +29,8 @@ public interface ListTriggersResponseOrBuilder extends */ com.google.cloud.eventarc.v1.Trigger getTriggers(int index); /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
@@ -33,84 +39,102 @@ public interface ListTriggersResponseOrBuilder extends */ int getTriggersCount(); /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - java.util.List + java.util.List getTriggersOrBuilderList(); /** + * + * *
    * The requested triggers, up to the number specified in `page_size`.
    * 
* * repeated .google.cloud.eventarc.v1.Trigger triggers = 1; */ - com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder( - int index); + com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggersOrBuilder(int index); /** + * + * *
    * A page token that can be sent to `ListTriggers` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The nextPageToken. */ java.lang.String getNextPageToken(); /** + * + * *
    * A page token that can be sent to `ListTriggers` to request the next page.
    * If this is empty, then there are no more pages.
    * 
* * string next_page_token = 2; + * * @return The bytes for nextPageToken. */ - com.google.protobuf.ByteString - getNextPageTokenBytes(); + com.google.protobuf.ByteString getNextPageTokenBytes(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return A list containing the unreachable. */ - java.util.List - getUnreachableList(); + java.util.List getUnreachableList(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @return The count of unreachable. */ int getUnreachableCount(); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the element to return. * @return The unreachable at the given index. */ java.lang.String getUnreachable(int index); /** + * + * *
    * Unreachable resources, if any.
    * 
* * repeated string unreachable = 3; + * * @param index The index of the value to return. * @return The bytes of the unreachable at the given index. */ - com.google.protobuf.ByteString - getUnreachableBytes(int index); + com.google.protobuf.ByteString getUnreachableBytes(int index); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java new file mode 100644 index 000000000000..a964c164178b --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/LocationName.java @@ -0,0 +1,192 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class LocationName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION = + PathTemplate.createWithoutUrlEncoding("projects/{project}/locations/{location}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + + @Deprecated + protected LocationName() { + project = null; + location = null; + } + + private LocationName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static LocationName of(String project, String location) { + return newBuilder().setProject(project).setLocation(location).build(); + } + + public static String format(String project, String location) { + return newBuilder().setProject(project).setLocation(location).build().toString(); + } + + public static LocationName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION.validatedMatch( + formattedString, "LocationName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List values) { + List list = new ArrayList<>(values.size()); + for (LocationName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION.instantiate("project", project, "location", location); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + LocationName that = ((LocationName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + return h; + } + + /** Builder for projects/{project}/locations/{location}. */ + public static class Builder { + private String project; + private String location; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + private Builder(LocationName locationName) { + this.project = locationName.project; + this.location = locationName.location; + } + + public LocationName build() { + return new LocationName(this); + } + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java similarity index 71% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java index 2a1b153c6f21..c643a6f4a14c 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadata.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * Represents the metadata of the long-running operation.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.OperationMetadata} */ -public final class OperationMetadata extends - com.google.protobuf.GeneratedMessageV3 implements +public final class OperationMetadata extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.OperationMetadata) OperationMetadataOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use OperationMetadata.newBuilder() to construct. private OperationMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private OperationMetadata() { target_ = ""; verb_ = ""; @@ -28,37 +31,42 @@ private OperationMetadata() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new OperationMetadata(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.OperationMetadata.class, com.google.cloud.eventarc.v1.OperationMetadata.Builder.class); + com.google.cloud.eventarc.v1.OperationMetadata.class, + com.google.cloud.eventarc.v1.OperationMetadata.Builder.class); } public static final int CREATE_TIME_FIELD_NUMBER = 1; private com.google.protobuf.Timestamp createTime_; /** + * + * *
    * Output only. The time the operation was created.
    * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ @java.lang.Override @@ -66,11 +74,15 @@ public boolean hasCreateTime() { return createTime_ != null; } /** + * + * *
    * Output only. The time the operation was created.
    * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ @java.lang.Override @@ -78,11 +90,14 @@ public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** + * + * *
    * Output only. The time the operation was created.
    * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { @@ -92,11 +107,15 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { public static final int END_TIME_FIELD_NUMBER = 2; private com.google.protobuf.Timestamp endTime_; /** + * + * *
    * Output only. The time the operation finished running.
    * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the endTime field is set. */ @java.lang.Override @@ -104,11 +123,15 @@ public boolean hasEndTime() { return endTime_ != null; } /** + * + * *
    * Output only. The time the operation finished running.
    * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The endTime. */ @java.lang.Override @@ -116,11 +139,14 @@ public com.google.protobuf.Timestamp getEndTime() { return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } /** + * + * *
    * Output only. The time the operation finished running.
    * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { @@ -130,11 +156,14 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { public static final int TARGET_FIELD_NUMBER = 3; private volatile java.lang.Object target_; /** + * + * *
    * Output only. Server-defined resource path for the target of the operation.
    * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The target. */ @java.lang.Override @@ -143,29 +172,29 @@ public java.lang.String getTarget() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); target_ = s; return s; } } /** + * + * *
    * Output only. Server-defined resource path for the target of the operation.
    * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for target. */ @java.lang.Override - public com.google.protobuf.ByteString - getTargetBytes() { + public com.google.protobuf.ByteString getTargetBytes() { java.lang.Object ref = target_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); target_ = b; return b; } else { @@ -176,11 +205,14 @@ public java.lang.String getTarget() { public static final int VERB_FIELD_NUMBER = 4; private volatile java.lang.Object verb_; /** + * + * *
    * Output only. Name of the verb executed by the operation.
    * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The verb. */ @java.lang.Override @@ -189,29 +221,29 @@ public java.lang.String getVerb() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); verb_ = s; return s; } } /** + * + * *
    * Output only. Name of the verb executed by the operation.
    * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for verb. */ @java.lang.Override - public com.google.protobuf.ByteString - getVerbBytes() { + public com.google.protobuf.ByteString getVerbBytes() { java.lang.Object ref = verb_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); verb_ = b; return b; } else { @@ -222,11 +254,14 @@ public java.lang.String getVerb() { public static final int STATUS_MESSAGE_FIELD_NUMBER = 5; private volatile java.lang.Object statusMessage_; /** + * + * *
    * Output only. Human-readable status of the operation, if any.
    * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The statusMessage. */ @java.lang.Override @@ -235,29 +270,29 @@ public java.lang.String getStatusMessage() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); statusMessage_ = s; return s; } } /** + * + * *
    * Output only. Human-readable status of the operation, if any.
    * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for statusMessage. */ @java.lang.Override - public com.google.protobuf.ByteString - getStatusMessageBytes() { + public com.google.protobuf.ByteString getStatusMessageBytes() { java.lang.Object ref = statusMessage_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); statusMessage_ = b; return b; } else { @@ -268,6 +303,8 @@ public java.lang.String getStatusMessage() { public static final int REQUESTED_CANCELLATION_FIELD_NUMBER = 6; private boolean requestedCancellation_; /** + * + * *
    * Output only. Identifies whether the user has requested cancellation
    * of the operation. Operations that have successfully been cancelled
@@ -276,6 +313,7 @@ public java.lang.String getStatusMessage() {
    * 
* * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The requestedCancellation. */ @java.lang.Override @@ -286,11 +324,14 @@ public boolean getRequestedCancellation() { public static final int API_VERSION_FIELD_NUMBER = 7; private volatile java.lang.Object apiVersion_; /** + * + * *
    * Output only. API version used to start the operation.
    * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The apiVersion. */ @java.lang.Override @@ -299,29 +340,29 @@ public java.lang.String getApiVersion() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); apiVersion_ = s; return s; } } /** + * + * *
    * Output only. API version used to start the operation.
    * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for apiVersion. */ @java.lang.Override - public com.google.protobuf.ByteString - getApiVersionBytes() { + public com.google.protobuf.ByteString getApiVersionBytes() { java.lang.Object ref = apiVersion_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); apiVersion_ = b; return b; } else { @@ -330,6 +371,7 @@ public java.lang.String getApiVersion() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -341,8 +383,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (createTime_ != null) { output.writeMessage(1, getCreateTime()); } @@ -374,12 +415,10 @@ public int getSerializedSize() { size = 0; if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getCreateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCreateTime()); } if (endTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getEndTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getEndTime()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(target_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, target_); @@ -391,8 +430,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, statusMessage_); } if (requestedCancellation_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(6, requestedCancellation_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, requestedCancellation_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(apiVersion_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, apiVersion_); @@ -405,33 +443,27 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.OperationMetadata)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.OperationMetadata other = (com.google.cloud.eventarc.v1.OperationMetadata) obj; + com.google.cloud.eventarc.v1.OperationMetadata other = + (com.google.cloud.eventarc.v1.OperationMetadata) obj; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { - if (!getCreateTime() - .equals(other.getCreateTime())) return false; + if (!getCreateTime().equals(other.getCreateTime())) return false; } if (hasEndTime() != other.hasEndTime()) return false; if (hasEndTime()) { - if (!getEndTime() - .equals(other.getEndTime())) return false; - } - if (!getTarget() - .equals(other.getTarget())) return false; - if (!getVerb() - .equals(other.getVerb())) return false; - if (!getStatusMessage() - .equals(other.getStatusMessage())) return false; - if (getRequestedCancellation() - != other.getRequestedCancellation()) return false; - if (!getApiVersion() - .equals(other.getApiVersion())) return false; + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (!getTarget().equals(other.getTarget())) return false; + if (!getVerb().equals(other.getVerb())) return false; + if (!getStatusMessage().equals(other.getStatusMessage())) return false; + if (getRequestedCancellation() != other.getRequestedCancellation()) return false; + if (!getApiVersion().equals(other.getApiVersion())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -458,8 +490,7 @@ public int hashCode() { hash = (37 * hash) + STATUS_MESSAGE_FIELD_NUMBER; hash = (53 * hash) + getStatusMessage().hashCode(); hash = (37 * hash) + REQUESTED_CANCELLATION_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getRequestedCancellation()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getRequestedCancellation()); hash = (37 * hash) + API_VERSION_FIELD_NUMBER; hash = (53 * hash) + getApiVersion().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); @@ -467,130 +498,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.OperationMetadata parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.OperationMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.OperationMetadata parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.OperationMetadata prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Represents the metadata of the long-running operation.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.OperationMetadata} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.OperationMetadata) com.google.cloud.eventarc.v1.OperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.OperationMetadata.class, com.google.cloud.eventarc.v1.OperationMetadata.Builder.class); + com.google.cloud.eventarc.v1.OperationMetadata.class, + com.google.cloud.eventarc.v1.OperationMetadata.Builder.class); } // Construct using com.google.cloud.eventarc.v1.OperationMetadata.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -620,9 +657,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor; } @java.lang.Override @@ -641,7 +678,8 @@ public com.google.cloud.eventarc.v1.OperationMetadata build() { @java.lang.Override public com.google.cloud.eventarc.v1.OperationMetadata buildPartial() { - com.google.cloud.eventarc.v1.OperationMetadata result = new com.google.cloud.eventarc.v1.OperationMetadata(this); + com.google.cloud.eventarc.v1.OperationMetadata result = + new com.google.cloud.eventarc.v1.OperationMetadata(this); if (createTimeBuilder_ == null) { result.createTime_ = createTime_; } else { @@ -665,38 +703,39 @@ public com.google.cloud.eventarc.v1.OperationMetadata buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.OperationMetadata) { - return mergeFrom((com.google.cloud.eventarc.v1.OperationMetadata)other); + return mergeFrom((com.google.cloud.eventarc.v1.OperationMetadata) other); } else { super.mergeFrom(other); return this; @@ -756,51 +795,55 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - input.readMessage( - getCreateTimeFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 10 - case 18: { - input.readMessage( - getEndTimeFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 18 - case 26: { - target_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 34: { - verb_ = input.readStringRequireUtf8(); - - break; - } // case 34 - case 42: { - statusMessage_ = input.readStringRequireUtf8(); - - break; - } // case 42 - case 48: { - requestedCancellation_ = input.readBool(); - - break; - } // case 48 - case 58: { - apiVersion_ = input.readStringRequireUtf8(); - - break; - } // case 58 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + target_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + verb_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + statusMessage_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 48: + { + requestedCancellation_ = input.readBool(); + + break; + } // case 48 + case 58: + { + apiVersion_ = input.readStringRequireUtf8(); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -813,39 +856,58 @@ public Builder mergeFrom( private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return createTimeBuilder_ != null || createTime_ != null; } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { @@ -861,14 +923,17 @@ public Builder setCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setCreateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); onChanged(); @@ -879,17 +944,21 @@ public Builder setCreateTime( return this; } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (createTime_ != null) { createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); } else { createTime_ = value; } @@ -901,11 +970,15 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearCreateTime() { if (createTimeBuilder_ == null) { @@ -919,48 +992,64 @@ public Builder clearCreateTime() { return this; } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - + onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { - return createTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } } /** + * + * *
      * Output only. The time the operation was created.
      * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { - createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), - getParentForChildren(), - isClean()); + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; @@ -968,24 +1057,35 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { private com.google.protobuf.Timestamp endTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> endTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the endTime field is set. */ public boolean hasEndTime() { return endTimeBuilder_ != null || endTime_ != null; } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The endTime. */ public com.google.protobuf.Timestamp getEndTime() { @@ -996,11 +1096,14 @@ public com.google.protobuf.Timestamp getEndTime() { } } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setEndTime(com.google.protobuf.Timestamp value) { if (endTimeBuilder_ == null) { @@ -1016,14 +1119,16 @@ public Builder setEndTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setEndTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (endTimeBuilder_ == null) { endTime_ = builderForValue.build(); onChanged(); @@ -1034,17 +1139,20 @@ public Builder setEndTime( return this; } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeEndTime(com.google.protobuf.Timestamp value) { if (endTimeBuilder_ == null) { if (endTime_ != null) { endTime_ = - com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); } else { endTime_ = value; } @@ -1056,11 +1164,14 @@ public Builder mergeEndTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearEndTime() { if (endTimeBuilder_ == null) { @@ -1074,48 +1185,59 @@ public Builder clearEndTime() { return this; } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { - + onChanged(); return getEndTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { if (endTimeBuilder_ != null) { return endTimeBuilder_.getMessageOrBuilder(); } else { - return endTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; } } /** + * + * *
      * Output only. The time the operation finished running.
      * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getEndTimeFieldBuilder() { if (endTimeBuilder_ == null) { - endTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getEndTime(), - getParentForChildren(), - isClean()); + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); endTime_ = null; } return endTimeBuilder_; @@ -1123,18 +1245,20 @@ public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { private java.lang.Object target_ = ""; /** + * + * *
      * Output only. Server-defined resource path for the target of the operation.
      * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The target. */ public java.lang.String getTarget() { java.lang.Object ref = target_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); target_ = s; return s; @@ -1143,20 +1267,21 @@ public java.lang.String getTarget() { } } /** + * + * *
      * Output only. Server-defined resource path for the target of the operation.
      * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for target. */ - public com.google.protobuf.ByteString - getTargetBytes() { + public com.google.protobuf.ByteString getTargetBytes() { java.lang.Object ref = target_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); target_ = b; return b; } else { @@ -1164,54 +1289,61 @@ public java.lang.String getTarget() { } } /** + * + * *
      * Output only. Server-defined resource path for the target of the operation.
      * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The target to set. * @return This builder for chaining. */ - public Builder setTarget( - java.lang.String value) { + public Builder setTarget(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + target_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Server-defined resource path for the target of the operation.
      * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearTarget() { - + target_ = getDefaultInstance().getTarget(); onChanged(); return this; } /** + * + * *
      * Output only. Server-defined resource path for the target of the operation.
      * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for target to set. * @return This builder for chaining. */ - public Builder setTargetBytes( - com.google.protobuf.ByteString value) { + public Builder setTargetBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + target_ = value; onChanged(); return this; @@ -1219,18 +1351,20 @@ public Builder setTargetBytes( private java.lang.Object verb_ = ""; /** + * + * *
      * Output only. Name of the verb executed by the operation.
      * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The verb. */ public java.lang.String getVerb() { java.lang.Object ref = verb_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); verb_ = s; return s; @@ -1239,20 +1373,21 @@ public java.lang.String getVerb() { } } /** + * + * *
      * Output only. Name of the verb executed by the operation.
      * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for verb. */ - public com.google.protobuf.ByteString - getVerbBytes() { + public com.google.protobuf.ByteString getVerbBytes() { java.lang.Object ref = verb_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); verb_ = b; return b; } else { @@ -1260,54 +1395,61 @@ public java.lang.String getVerb() { } } /** + * + * *
      * Output only. Name of the verb executed by the operation.
      * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The verb to set. * @return This builder for chaining. */ - public Builder setVerb( - java.lang.String value) { + public Builder setVerb(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + verb_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Name of the verb executed by the operation.
      * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearVerb() { - + verb_ = getDefaultInstance().getVerb(); onChanged(); return this; } /** + * + * *
      * Output only. Name of the verb executed by the operation.
      * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for verb to set. * @return This builder for chaining. */ - public Builder setVerbBytes( - com.google.protobuf.ByteString value) { + public Builder setVerbBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + verb_ = value; onChanged(); return this; @@ -1315,18 +1457,20 @@ public Builder setVerbBytes( private java.lang.Object statusMessage_ = ""; /** + * + * *
      * Output only. Human-readable status of the operation, if any.
      * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The statusMessage. */ public java.lang.String getStatusMessage() { java.lang.Object ref = statusMessage_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); statusMessage_ = s; return s; @@ -1335,20 +1479,21 @@ public java.lang.String getStatusMessage() { } } /** + * + * *
      * Output only. Human-readable status of the operation, if any.
      * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for statusMessage. */ - public com.google.protobuf.ByteString - getStatusMessageBytes() { + public com.google.protobuf.ByteString getStatusMessageBytes() { java.lang.Object ref = statusMessage_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); statusMessage_ = b; return b; } else { @@ -1356,61 +1501,70 @@ public java.lang.String getStatusMessage() { } } /** + * + * *
      * Output only. Human-readable status of the operation, if any.
      * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The statusMessage to set. * @return This builder for chaining. */ - public Builder setStatusMessage( - java.lang.String value) { + public Builder setStatusMessage(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + statusMessage_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Human-readable status of the operation, if any.
      * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearStatusMessage() { - + statusMessage_ = getDefaultInstance().getStatusMessage(); onChanged(); return this; } /** + * + * *
      * Output only. Human-readable status of the operation, if any.
      * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for statusMessage to set. * @return This builder for chaining. */ - public Builder setStatusMessageBytes( - com.google.protobuf.ByteString value) { + public Builder setStatusMessageBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + statusMessage_ = value; onChanged(); return this; } - private boolean requestedCancellation_ ; + private boolean requestedCancellation_; /** + * + * *
      * Output only. Identifies whether the user has requested cancellation
      * of the operation. Operations that have successfully been cancelled
@@ -1419,6 +1573,7 @@ public Builder setStatusMessageBytes(
      * 
* * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The requestedCancellation. */ @java.lang.Override @@ -1426,6 +1581,8 @@ public boolean getRequestedCancellation() { return requestedCancellation_; } /** + * + * *
      * Output only. Identifies whether the user has requested cancellation
      * of the operation. Operations that have successfully been cancelled
@@ -1434,16 +1591,19 @@ public boolean getRequestedCancellation() {
      * 
* * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The requestedCancellation to set. * @return This builder for chaining. */ public Builder setRequestedCancellation(boolean value) { - + requestedCancellation_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Identifies whether the user has requested cancellation
      * of the operation. Operations that have successfully been cancelled
@@ -1452,10 +1612,11 @@ public Builder setRequestedCancellation(boolean value) {
      * 
* * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearRequestedCancellation() { - + requestedCancellation_ = false; onChanged(); return this; @@ -1463,18 +1624,20 @@ public Builder clearRequestedCancellation() { private java.lang.Object apiVersion_ = ""; /** + * + * *
      * Output only. API version used to start the operation.
      * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The apiVersion. */ public java.lang.String getApiVersion() { java.lang.Object ref = apiVersion_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); apiVersion_ = s; return s; @@ -1483,20 +1646,21 @@ public java.lang.String getApiVersion() { } } /** + * + * *
      * Output only. API version used to start the operation.
      * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for apiVersion. */ - public com.google.protobuf.ByteString - getApiVersionBytes() { + public com.google.protobuf.ByteString getApiVersionBytes() { java.lang.Object ref = apiVersion_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); apiVersion_ = b; return b; } else { @@ -1504,61 +1668,68 @@ public java.lang.String getApiVersion() { } } /** + * + * *
      * Output only. API version used to start the operation.
      * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The apiVersion to set. * @return This builder for chaining. */ - public Builder setApiVersion( - java.lang.String value) { + public Builder setApiVersion(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + apiVersion_ = value; onChanged(); return this; } /** + * + * *
      * Output only. API version used to start the operation.
      * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearApiVersion() { - + apiVersion_ = getDefaultInstance().getApiVersion(); onChanged(); return this; } /** + * + * *
      * Output only. API version used to start the operation.
      * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for apiVersion to set. * @return This builder for chaining. */ - public Builder setApiVersionBytes( - com.google.protobuf.ByteString value) { + public Builder setApiVersionBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + apiVersion_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1568,12 +1739,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.OperationMetadata) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.OperationMetadata) private static final com.google.cloud.eventarc.v1.OperationMetadata DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.OperationMetadata(); } @@ -1582,27 +1753,27 @@ public static com.google.cloud.eventarc.v1.OperationMetadata getDefaultInstance( return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public OperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public OperationMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1617,6 +1788,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.OperationMetadata getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java similarity index 84% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java index a97cdccf7867..fef08f0a69f5 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/OperationMetadataOrBuilder.java @@ -3,125 +3,165 @@ package com.google.cloud.eventarc.v1; -public interface OperationMetadataOrBuilder extends +public interface OperationMetadataOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.OperationMetadata) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Output only. The time the operation was created.
    * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ boolean hasCreateTime(); /** + * + * *
    * Output only. The time the operation was created.
    * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ com.google.protobuf.Timestamp getCreateTime(); /** + * + * *
    * Output only. The time the operation was created.
    * 
* - * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); /** + * + * *
    * Output only. The time the operation finished running.
    * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the endTime field is set. */ boolean hasEndTime(); /** + * + * *
    * Output only. The time the operation finished running.
    * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The endTime. */ com.google.protobuf.Timestamp getEndTime(); /** + * + * *
    * Output only. The time the operation finished running.
    * 
* - * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp end_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); /** + * + * *
    * Output only. Server-defined resource path for the target of the operation.
    * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The target. */ java.lang.String getTarget(); /** + * + * *
    * Output only. Server-defined resource path for the target of the operation.
    * 
* * string target = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for target. */ - com.google.protobuf.ByteString - getTargetBytes(); + com.google.protobuf.ByteString getTargetBytes(); /** + * + * *
    * Output only. Name of the verb executed by the operation.
    * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The verb. */ java.lang.String getVerb(); /** + * + * *
    * Output only. Name of the verb executed by the operation.
    * 
* * string verb = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for verb. */ - com.google.protobuf.ByteString - getVerbBytes(); + com.google.protobuf.ByteString getVerbBytes(); /** + * + * *
    * Output only. Human-readable status of the operation, if any.
    * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The statusMessage. */ java.lang.String getStatusMessage(); /** + * + * *
    * Output only. Human-readable status of the operation, if any.
    * 
* * string status_message = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for statusMessage. */ - com.google.protobuf.ByteString - getStatusMessageBytes(); + com.google.protobuf.ByteString getStatusMessageBytes(); /** + * + * *
    * Output only. Identifies whether the user has requested cancellation
    * of the operation. Operations that have successfully been cancelled
@@ -130,27 +170,33 @@ public interface OperationMetadataOrBuilder extends
    * 
* * bool requested_cancellation = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The requestedCancellation. */ boolean getRequestedCancellation(); /** + * + * *
    * Output only. API version used to start the operation.
    * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The apiVersion. */ java.lang.String getApiVersion(); /** + * + * *
    * Output only. API version used to start the operation.
    * 
* * string api_version = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for apiVersion. */ - com.google.protobuf.ByteString - getApiVersionBytes(); + com.google.protobuf.ByteString getApiVersionBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java similarity index 66% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java index 5e734d6fb392..c1ce4ac46dba 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Provider.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A representation of the Provider resource.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.Provider} */ -public final class Provider extends - com.google.protobuf.GeneratedMessageV3 implements +public final class Provider extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Provider) ProviderOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use Provider.newBuilder() to construct. private Provider(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private Provider() { name_ = ""; displayName_ = ""; @@ -27,38 +30,42 @@ private Provider() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Provider(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_Provider_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Provider.class, com.google.cloud.eventarc.v1.Provider.Builder.class); + com.google.cloud.eventarc.v1.Provider.class, + com.google.cloud.eventarc.v1.Provider.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
    * format.
    * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The name. */ @java.lang.Override @@ -67,30 +74,30 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
    * format.
    * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -101,11 +108,14 @@ public java.lang.String getName() { public static final int DISPLAY_NAME_FIELD_NUMBER = 2; private volatile java.lang.Object displayName_; /** + * + * *
    * Output only. Human friendly name for the Provider. For example "Cloud Storage".
    * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The displayName. */ @java.lang.Override @@ -114,29 +124,29 @@ public java.lang.String getDisplayName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; } } /** + * + * *
    * Output only. Human friendly name for the Provider. For example "Cloud Storage".
    * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for displayName. */ @java.lang.Override - public com.google.protobuf.ByteString - getDisplayNameBytes() { + public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); displayName_ = b; return b; } else { @@ -147,64 +157,84 @@ public java.lang.String getDisplayName() { public static final int EVENT_TYPES_FIELD_NUMBER = 3; private java.util.List eventTypes_; /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public java.util.List getEventTypesList() { return eventTypes_; } /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - public java.util.List + public java.util.List getEventTypesOrBuilderList() { return eventTypes_; } /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public int getEventTypesCount() { return eventTypes_.size(); } /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.EventType getEventTypes(int index) { return eventTypes_.get(index); } /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder(int index) { return eventTypes_.get(index); } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -216,8 +246,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -243,8 +272,7 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); } for (int i = 0; i < eventTypes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(3, eventTypes_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, eventTypes_.get(i)); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -254,19 +282,16 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.Provider)) { return super.equals(obj); } com.google.cloud.eventarc.v1.Provider other = (com.google.cloud.eventarc.v1.Provider) obj; - if (!getName() - .equals(other.getName())) return false; - if (!getDisplayName() - .equals(other.getDisplayName())) return false; - if (!getEventTypesList() - .equals(other.getEventTypesList())) return false; + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getEventTypesList().equals(other.getEventTypesList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -291,130 +316,135 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.Provider parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.Provider parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Provider parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.Provider parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.cloud.eventarc.v1.Provider parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Provider parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Provider parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Provider parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Provider parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Provider parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Provider parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Provider parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Provider parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Provider parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.Provider prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A representation of the Provider resource.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.Provider} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Provider) com.google.cloud.eventarc.v1.ProviderOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_Provider_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Provider.class, com.google.cloud.eventarc.v1.Provider.Builder.class); + com.google.cloud.eventarc.v1.Provider.class, + com.google.cloud.eventarc.v1.Provider.Builder.class); } // Construct using com.google.cloud.eventarc.v1.Provider.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -433,9 +463,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.DiscoveryProto.internal_static_google_cloud_eventarc_v1_Provider_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.DiscoveryProto + .internal_static_google_cloud_eventarc_v1_Provider_descriptor; } @java.lang.Override @@ -454,7 +484,8 @@ public com.google.cloud.eventarc.v1.Provider build() { @java.lang.Override public com.google.cloud.eventarc.v1.Provider buildPartial() { - com.google.cloud.eventarc.v1.Provider result = new com.google.cloud.eventarc.v1.Provider(this); + com.google.cloud.eventarc.v1.Provider result = + new com.google.cloud.eventarc.v1.Provider(this); int from_bitField0_ = bitField0_; result.name_ = name_; result.displayName_ = displayName_; @@ -475,38 +506,39 @@ public com.google.cloud.eventarc.v1.Provider buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.Provider) { - return mergeFrom((com.google.cloud.eventarc.v1.Provider)other); + return mergeFrom((com.google.cloud.eventarc.v1.Provider) other); } else { super.mergeFrom(other); return this; @@ -541,9 +573,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.Provider other) { eventTypesBuilder_ = null; eventTypes_ = other.eventTypes_; bitField0_ = (bitField0_ & ~0x00000001); - eventTypesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getEventTypesFieldBuilder() : null; + eventTypesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getEventTypesFieldBuilder() + : null; } else { eventTypesBuilder_.addAllMessages(other.eventTypes_); } @@ -575,35 +608,38 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); + case 10: + { + name_ = input.readStringRequireUtf8(); - break; - } // case 10 - case 18: { - displayName_ = input.readStringRequireUtf8(); + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); - break; - } // case 18 - case 26: { - com.google.cloud.eventarc.v1.EventType m = - input.readMessage( - com.google.cloud.eventarc.v1.EventType.parser(), - extensionRegistry); - if (eventTypesBuilder_ == null) { - ensureEventTypesIsMutable(); - eventTypes_.add(m); - } else { - eventTypesBuilder_.addMessage(m); - } - break; - } // case 26 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 18 + case 26: + { + com.google.cloud.eventarc.v1.EventType m = + input.readMessage( + com.google.cloud.eventarc.v1.EventType.parser(), extensionRegistry); + if (eventTypesBuilder_ == null) { + ensureEventTypesIsMutable(); + eventTypes_.add(m); + } else { + eventTypesBuilder_.addMessage(m); + } + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -613,23 +649,26 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.lang.Object name_ = ""; /** + * + * *
      * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
      * format.
      * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -638,21 +677,22 @@ public java.lang.String getName() { } } /** + * + * *
      * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
      * format.
      * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -660,57 +700,64 @@ public java.lang.String getName() { } } /** + * + * *
      * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
      * format.
      * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
      * format.
      * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
      * format.
      * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; @@ -718,18 +765,20 @@ public Builder setNameBytes( private java.lang.Object displayName_ = ""; /** + * + * *
      * Output only. Human friendly name for the Provider. For example "Cloud Storage".
      * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The displayName. */ public java.lang.String getDisplayName() { java.lang.Object ref = displayName_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); displayName_ = s; return s; @@ -738,20 +787,21 @@ public java.lang.String getDisplayName() { } } /** + * + * *
      * Output only. Human friendly name for the Provider. For example "Cloud Storage".
      * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for displayName. */ - public com.google.protobuf.ByteString - getDisplayNameBytes() { + public com.google.protobuf.ByteString getDisplayNameBytes() { java.lang.Object ref = displayName_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); displayName_ = b; return b; } else { @@ -759,77 +809,92 @@ public java.lang.String getDisplayName() { } } /** + * + * *
      * Output only. Human friendly name for the Provider. For example "Cloud Storage".
      * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The displayName to set. * @return This builder for chaining. */ - public Builder setDisplayName( - java.lang.String value) { + public Builder setDisplayName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + displayName_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Human friendly name for the Provider. For example "Cloud Storage".
      * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearDisplayName() { - + displayName_ = getDefaultInstance().getDisplayName(); onChanged(); return this; } /** + * + * *
      * Output only. Human friendly name for the Provider. For example "Cloud Storage".
      * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for displayName to set. * @return This builder for chaining. */ - public Builder setDisplayNameBytes( - com.google.protobuf.ByteString value) { + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + displayName_ = value; onChanged(); return this; } private java.util.List eventTypes_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureEventTypesIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { eventTypes_ = new java.util.ArrayList(eventTypes_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.EventType, com.google.cloud.eventarc.v1.EventType.Builder, com.google.cloud.eventarc.v1.EventTypeOrBuilder> eventTypesBuilder_; + com.google.cloud.eventarc.v1.EventType, + com.google.cloud.eventarc.v1.EventType.Builder, + com.google.cloud.eventarc.v1.EventTypeOrBuilder> + eventTypesBuilder_; /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List getEventTypesList() { if (eventTypesBuilder_ == null) { @@ -839,11 +904,15 @@ public java.util.List getEventTypesList( } } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public int getEventTypesCount() { if (eventTypesBuilder_ == null) { @@ -853,11 +922,15 @@ public int getEventTypesCount() { } } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.EventType getEventTypes(int index) { if (eventTypesBuilder_ == null) { @@ -867,14 +940,17 @@ public com.google.cloud.eventarc.v1.EventType getEventTypes(int index) { } } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setEventTypes( - int index, com.google.cloud.eventarc.v1.EventType value) { + public Builder setEventTypes(int index, com.google.cloud.eventarc.v1.EventType value) { if (eventTypesBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -888,11 +964,15 @@ public Builder setEventTypes( return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setEventTypes( int index, com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { @@ -906,11 +986,15 @@ public Builder setEventTypes( return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addEventTypes(com.google.cloud.eventarc.v1.EventType value) { if (eventTypesBuilder_ == null) { @@ -926,14 +1010,17 @@ public Builder addEventTypes(com.google.cloud.eventarc.v1.EventType value) { return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder addEventTypes( - int index, com.google.cloud.eventarc.v1.EventType value) { + public Builder addEventTypes(int index, com.google.cloud.eventarc.v1.EventType value) { if (eventTypesBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -947,14 +1034,17 @@ public Builder addEventTypes( return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder addEventTypes( - com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { + public Builder addEventTypes(com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { if (eventTypesBuilder_ == null) { ensureEventTypesIsMutable(); eventTypes_.add(builderForValue.build()); @@ -965,11 +1055,15 @@ public Builder addEventTypes( return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addEventTypes( int index, com.google.cloud.eventarc.v1.EventType.Builder builderForValue) { @@ -983,18 +1077,21 @@ public Builder addEventTypes( return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addAllEventTypes( java.lang.Iterable values) { if (eventTypesBuilder_ == null) { ensureEventTypesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, eventTypes_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, eventTypes_); onChanged(); } else { eventTypesBuilder_.addAllMessages(values); @@ -1002,11 +1099,15 @@ public Builder addAllEventTypes( return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearEventTypes() { if (eventTypesBuilder_ == null) { @@ -1019,11 +1120,15 @@ public Builder clearEventTypes() { return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder removeEventTypes(int index) { if (eventTypesBuilder_ == null) { @@ -1036,39 +1141,50 @@ public Builder removeEventTypes(int index) { return this; } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public com.google.cloud.eventarc.v1.EventType.Builder getEventTypesBuilder( - int index) { + public com.google.cloud.eventarc.v1.EventType.Builder getEventTypesBuilder(int index) { return getEventTypesFieldBuilder().getBuilder(index); } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder(int index) { if (eventTypesBuilder_ == null) { - return eventTypes_.get(index); } else { + return eventTypes_.get(index); + } else { return eventTypesBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public java.util.List - getEventTypesOrBuilderList() { + public java.util.List + getEventTypesOrBuilderList() { if (eventTypesBuilder_ != null) { return eventTypesBuilder_.getMessageOrBuilderList(); } else { @@ -1076,56 +1192,70 @@ public com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder( } } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.eventarc.v1.EventType.Builder addEventTypesBuilder() { - return getEventTypesFieldBuilder().addBuilder( - com.google.cloud.eventarc.v1.EventType.getDefaultInstance()); + return getEventTypesFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.EventType.getDefaultInstance()); } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public com.google.cloud.eventarc.v1.EventType.Builder addEventTypesBuilder( - int index) { - return getEventTypesFieldBuilder().addBuilder( - index, com.google.cloud.eventarc.v1.EventType.getDefaultInstance()); + public com.google.cloud.eventarc.v1.EventType.Builder addEventTypesBuilder(int index) { + return getEventTypesFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.EventType.getDefaultInstance()); } /** + * + * *
      * Output only. Event types for this provider.
      * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public java.util.List - getEventTypesBuilderList() { + public java.util.List + getEventTypesBuilderList() { return getEventTypesFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.EventType, com.google.cloud.eventarc.v1.EventType.Builder, com.google.cloud.eventarc.v1.EventTypeOrBuilder> + com.google.cloud.eventarc.v1.EventType, + com.google.cloud.eventarc.v1.EventType.Builder, + com.google.cloud.eventarc.v1.EventTypeOrBuilder> getEventTypesFieldBuilder() { if (eventTypesBuilder_ == null) { - eventTypesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.EventType, com.google.cloud.eventarc.v1.EventType.Builder, com.google.cloud.eventarc.v1.EventTypeOrBuilder>( - eventTypes_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); + eventTypesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventType, + com.google.cloud.eventarc.v1.EventType.Builder, + com.google.cloud.eventarc.v1.EventTypeOrBuilder>( + eventTypes_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); eventTypes_ = null; } return eventTypesBuilder_; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1135,12 +1265,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Provider) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Provider) private static final com.google.cloud.eventarc.v1.Provider DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Provider(); } @@ -1149,27 +1279,27 @@ public static com.google.cloud.eventarc.v1.Provider getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Provider parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Provider parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1184,6 +1314,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.Provider getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java new file mode 100644 index 000000000000..fe9daf1a7941 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderName.java @@ -0,0 +1,223 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class ProviderName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_PROVIDER = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/providers/{provider}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String provider; + + @Deprecated + protected ProviderName() { + project = null; + location = null; + provider = null; + } + + private ProviderName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + provider = Preconditions.checkNotNull(builder.getProvider()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getProvider() { + return provider; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static ProviderName of(String project, String location, String provider) { + return newBuilder().setProject(project).setLocation(location).setProvider(provider).build(); + } + + public static String format(String project, String location, String provider) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setProvider(provider) + .build() + .toString(); + } + + public static ProviderName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_PROVIDER.validatedMatch( + formattedString, "ProviderName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("provider")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List values) { + List list = new ArrayList<>(values.size()); + for (ProviderName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_PROVIDER.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (provider != null) { + fieldMapBuilder.put("provider", provider); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_PROVIDER.instantiate( + "project", project, "location", location, "provider", provider); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + ProviderName that = ((ProviderName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.provider, that.provider); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(provider); + return h; + } + + /** Builder for projects/{project}/locations/{location}/providers/{provider}. */ + public static class Builder { + private String project; + private String location; + private String provider; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getProvider() { + return provider; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setProvider(String provider) { + this.provider = provider; + return this; + } + + private Builder(ProviderName providerName) { + this.project = providerName.project; + this.location = providerName.location; + this.provider = providerName.provider; + } + + public ProviderName build() { + return new ProviderName(this); + } + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java similarity index 65% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java index e2f12eac3269..3ef3f8a7054b 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ProviderOrBuilder.java @@ -3,93 +3,122 @@ package com.google.cloud.eventarc.v1; -public interface ProviderOrBuilder extends +public interface ProviderOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Provider) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
    * format.
    * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Output only. In `projects/{project}/locations/{location}/providers/{provider_id}`
    * format.
    * 
* * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * Output only. Human friendly name for the Provider. For example "Cloud Storage".
    * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The displayName. */ java.lang.String getDisplayName(); /** + * + * *
    * Output only. Human friendly name for the Provider. For example "Cloud Storage".
    * 
* * string display_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for displayName. */ - com.google.protobuf.ByteString - getDisplayNameBytes(); + com.google.protobuf.ByteString getDisplayNameBytes(); /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - java.util.List - getEventTypesList(); + java.util.List getEventTypesList(); /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.eventarc.v1.EventType getEventTypes(int index); /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ int getEventTypesCount(); /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - java.util.List + java.util.List getEventTypesOrBuilderList(); /** + * + * *
    * Output only. Event types for this provider.
    * 
* - * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.eventarc.v1.EventType event_types = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder( - int index); + com.google.cloud.eventarc.v1.EventTypeOrBuilder getEventTypesOrBuilder(int index); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java similarity index 73% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java index a749ea9e0cd7..4bd1e326ae9c 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Pubsub.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * Represents a Pub/Sub transport.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.Pubsub} */ -public final class Pubsub extends - com.google.protobuf.GeneratedMessageV3 implements +public final class Pubsub extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Pubsub) PubsubOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use Pubsub.newBuilder() to construct. private Pubsub(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private Pubsub() { topic_ = ""; subscription_ = ""; @@ -26,32 +29,35 @@ private Pubsub() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Pubsub(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Pubsub.class, com.google.cloud.eventarc.v1.Pubsub.Builder.class); + com.google.cloud.eventarc.v1.Pubsub.class, + com.google.cloud.eventarc.v1.Pubsub.Builder.class); } public static final int TOPIC_FIELD_NUMBER = 1; private volatile java.lang.Object topic_; /** + * + * *
    * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
    * a transport for the event delivery. Format:
@@ -62,6 +68,7 @@ protected java.lang.Object newInstance(
    * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The topic. */ @java.lang.Override @@ -70,14 +77,15 @@ public java.lang.String getTopic() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); topic_ = s; return s; } } /** + * + * *
    * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
    * a transport for the event delivery. Format:
@@ -88,16 +96,15 @@ public java.lang.String getTopic() {
    * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for topic. */ @java.lang.Override - public com.google.protobuf.ByteString - getTopicBytes() { + public com.google.protobuf.ByteString getTopicBytes() { java.lang.Object ref = topic_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); topic_ = b; return b; } else { @@ -108,6 +115,8 @@ public java.lang.String getTopic() { public static final int SUBSCRIPTION_FIELD_NUMBER = 2; private volatile java.lang.Object subscription_; /** + * + * *
    * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
    * as a transport for the event delivery. Format:
@@ -115,6 +124,7 @@ public java.lang.String getTopic() {
    * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The subscription. */ @java.lang.Override @@ -123,14 +133,15 @@ public java.lang.String getSubscription() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); subscription_ = s; return s; } } /** + * + * *
    * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
    * as a transport for the event delivery. Format:
@@ -138,16 +149,15 @@ public java.lang.String getSubscription() {
    * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for subscription. */ @java.lang.Override - public com.google.protobuf.ByteString - getSubscriptionBytes() { + public com.google.protobuf.ByteString getSubscriptionBytes() { java.lang.Object ref = subscription_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); subscription_ = b; return b; } else { @@ -156,6 +166,7 @@ public java.lang.String getSubscription() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -167,8 +178,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(topic_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, topic_); } @@ -198,17 +208,15 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.Pubsub)) { return super.equals(obj); } com.google.cloud.eventarc.v1.Pubsub other = (com.google.cloud.eventarc.v1.Pubsub) obj; - if (!getTopic() - .equals(other.getTopic())) return false; - if (!getSubscription() - .equals(other.getSubscription())) return false; + if (!getTopic().equals(other.getTopic())) return false; + if (!getSubscription().equals(other.getSubscription())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -229,130 +237,135 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.Pubsub parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.Pubsub parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Pubsub parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Pubsub parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Pubsub parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.Pubsub prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Represents a Pub/Sub transport.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.Pubsub} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Pubsub) com.google.cloud.eventarc.v1.PubsubOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Pubsub.class, com.google.cloud.eventarc.v1.Pubsub.Builder.class); + com.google.cloud.eventarc.v1.Pubsub.class, + com.google.cloud.eventarc.v1.Pubsub.Builder.class); } // Construct using com.google.cloud.eventarc.v1.Pubsub.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -364,9 +377,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; } @java.lang.Override @@ -396,38 +409,39 @@ public com.google.cloud.eventarc.v1.Pubsub buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.Pubsub) { - return mergeFrom((com.google.cloud.eventarc.v1.Pubsub)other); + return mergeFrom((com.google.cloud.eventarc.v1.Pubsub) other); } else { super.mergeFrom(other); return this; @@ -470,22 +484,25 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - topic_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: { - subscription_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + topic_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + subscription_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -498,6 +515,8 @@ public Builder mergeFrom( private java.lang.Object topic_ = ""; /** + * + * *
      * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
      * a transport for the event delivery. Format:
@@ -508,13 +527,13 @@ public Builder mergeFrom(
      * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The topic. */ public java.lang.String getTopic() { java.lang.Object ref = topic_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); topic_ = s; return s; @@ -523,6 +542,8 @@ public java.lang.String getTopic() { } } /** + * + * *
      * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
      * a transport for the event delivery. Format:
@@ -533,15 +554,14 @@ public java.lang.String getTopic() {
      * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for topic. */ - public com.google.protobuf.ByteString - getTopicBytes() { + public com.google.protobuf.ByteString getTopicBytes() { java.lang.Object ref = topic_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); topic_ = b; return b; } else { @@ -549,6 +569,8 @@ public java.lang.String getTopic() { } } /** + * + * *
      * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
      * a transport for the event delivery. Format:
@@ -559,20 +581,22 @@ public java.lang.String getTopic() {
      * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The topic to set. * @return This builder for chaining. */ - public Builder setTopic( - java.lang.String value) { + public Builder setTopic(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + topic_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
      * a transport for the event delivery. Format:
@@ -583,15 +607,18 @@ public Builder setTopic(
      * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return This builder for chaining. */ public Builder clearTopic() { - + topic_ = getDefaultInstance().getTopic(); onChanged(); return this; } /** + * + * *
      * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
      * a transport for the event delivery. Format:
@@ -602,16 +629,16 @@ public Builder clearTopic() {
      * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The bytes for topic to set. * @return This builder for chaining. */ - public Builder setTopicBytes( - com.google.protobuf.ByteString value) { + public Builder setTopicBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + topic_ = value; onChanged(); return this; @@ -619,6 +646,8 @@ public Builder setTopicBytes( private java.lang.Object subscription_ = ""; /** + * + * *
      * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
      * as a transport for the event delivery. Format:
@@ -626,13 +655,13 @@ public Builder setTopicBytes(
      * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The subscription. */ public java.lang.String getSubscription() { java.lang.Object ref = subscription_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); subscription_ = s; return s; @@ -641,6 +670,8 @@ public java.lang.String getSubscription() { } } /** + * + * *
      * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
      * as a transport for the event delivery. Format:
@@ -648,15 +679,14 @@ public java.lang.String getSubscription() {
      * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for subscription. */ - public com.google.protobuf.ByteString - getSubscriptionBytes() { + public com.google.protobuf.ByteString getSubscriptionBytes() { java.lang.Object ref = subscription_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); subscription_ = b; return b; } else { @@ -664,6 +694,8 @@ public java.lang.String getSubscription() { } } /** + * + * *
      * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
      * as a transport for the event delivery. Format:
@@ -671,20 +703,22 @@ public java.lang.String getSubscription() {
      * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The subscription to set. * @return This builder for chaining. */ - public Builder setSubscription( - java.lang.String value) { + public Builder setSubscription(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + subscription_ = value; onChanged(); return this; } /** + * + * *
      * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
      * as a transport for the event delivery. Format:
@@ -692,15 +726,18 @@ public Builder setSubscription(
      * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearSubscription() { - + subscription_ = getDefaultInstance().getSubscription(); onChanged(); return this; } /** + * + * *
      * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
      * as a transport for the event delivery. Format:
@@ -708,23 +745,23 @@ public Builder clearSubscription() {
      * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for subscription to set. * @return This builder for chaining. */ - public Builder setSubscriptionBytes( - com.google.protobuf.ByteString value) { + public Builder setSubscriptionBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + subscription_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -734,12 +771,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Pubsub) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Pubsub) private static final com.google.cloud.eventarc.v1.Pubsub DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Pubsub(); } @@ -748,27 +785,27 @@ public static com.google.cloud.eventarc.v1.Pubsub getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Pubsub parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Pubsub parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -783,6 +820,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.Pubsub getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java similarity index 90% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java index e7a3e5421836..e4996182d942 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/PubsubOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface PubsubOrBuilder extends +public interface PubsubOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Pubsub) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
    * a transport for the event delivery. Format:
@@ -18,10 +21,13 @@ public interface PubsubOrBuilder extends
    * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The topic. */ java.lang.String getTopic(); /** + * + * *
    * Optional. The name of the Pub/Sub topic created and managed by Eventarc as
    * a transport for the event delivery. Format:
@@ -32,12 +38,14 @@ public interface PubsubOrBuilder extends
    * 
* * string topic = 1 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for topic. */ - com.google.protobuf.ByteString - getTopicBytes(); + com.google.protobuf.ByteString getTopicBytes(); /** + * + * *
    * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
    * as a transport for the event delivery. Format:
@@ -45,10 +53,13 @@ public interface PubsubOrBuilder extends
    * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The subscription. */ java.lang.String getSubscription(); /** + * + * *
    * Output only. The name of the Pub/Sub subscription created and managed by Eventarc
    * as a transport for the event delivery. Format:
@@ -56,8 +67,8 @@ public interface PubsubOrBuilder extends
    * 
* * string subscription = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for subscription. */ - com.google.protobuf.ByteString - getSubscriptionBytes(); + com.google.protobuf.ByteString getSubscriptionBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java similarity index 69% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java index a3f98fd0f152..72a8c92bb60d 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateCondition.java @@ -4,21 +4,24 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * A condition that is part of the trigger state computation.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.StateCondition} */ -public final class StateCondition extends - com.google.protobuf.GeneratedMessageV3 implements +public final class StateCondition extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.StateCondition) StateConditionOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use StateCondition.newBuilder() to construct. private StateCondition(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private StateCondition() { code_ = 0; message_ = ""; @@ -26,51 +29,60 @@ private StateCondition() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new StateCondition(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.StateCondition.class, com.google.cloud.eventarc.v1.StateCondition.Builder.class); + com.google.cloud.eventarc.v1.StateCondition.class, + com.google.cloud.eventarc.v1.StateCondition.Builder.class); } public static final int CODE_FIELD_NUMBER = 1; private int code_; /** + * + * *
    * The canonical code of the condition.
    * 
* * .google.rpc.Code code = 1; + * * @return The enum numeric value on the wire for code. */ - @java.lang.Override public int getCodeValue() { + @java.lang.Override + public int getCodeValue() { return code_; } /** + * + * *
    * The canonical code of the condition.
    * 
* * .google.rpc.Code code = 1; + * * @return The code. */ - @java.lang.Override public com.google.rpc.Code getCode() { + @java.lang.Override + public com.google.rpc.Code getCode() { @SuppressWarnings("deprecation") com.google.rpc.Code result = com.google.rpc.Code.valueOf(code_); return result == null ? com.google.rpc.Code.UNRECOGNIZED : result; @@ -79,11 +91,14 @@ protected java.lang.Object newInstance( public static final int MESSAGE_FIELD_NUMBER = 2; private volatile java.lang.Object message_; /** + * + * *
    * Human-readable message.
    * 
* * string message = 2; + * * @return The message. */ @java.lang.Override @@ -92,29 +107,29 @@ public java.lang.String getMessage() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); message_ = s; return s; } } /** + * + * *
    * Human-readable message.
    * 
* * string message = 2; + * * @return The bytes for message. */ @java.lang.Override - public com.google.protobuf.ByteString - getMessageBytes() { + public com.google.protobuf.ByteString getMessageBytes() { java.lang.Object ref = message_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); message_ = b; return b; } else { @@ -123,6 +138,7 @@ public java.lang.String getMessage() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -134,8 +150,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (code_ != com.google.rpc.Code.OK.getNumber()) { output.writeEnum(1, code_); } @@ -152,8 +167,7 @@ public int getSerializedSize() { size = 0; if (code_ != com.google.rpc.Code.OK.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, code_); + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, code_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, message_); @@ -166,16 +180,16 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.StateCondition)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.StateCondition other = (com.google.cloud.eventarc.v1.StateCondition) obj; + com.google.cloud.eventarc.v1.StateCondition other = + (com.google.cloud.eventarc.v1.StateCondition) obj; if (code_ != other.code_) return false; - if (!getMessage() - .equals(other.getMessage())) return false; + if (!getMessage().equals(other.getMessage())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -196,130 +210,136 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.StateCondition parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.StateCondition parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.StateCondition parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.StateCondition parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.StateCondition parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.StateCondition parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.StateCondition prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A condition that is part of the trigger state computation.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.StateCondition} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.StateCondition) com.google.cloud.eventarc.v1.StateConditionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.StateCondition.class, com.google.cloud.eventarc.v1.StateCondition.Builder.class); + com.google.cloud.eventarc.v1.StateCondition.class, + com.google.cloud.eventarc.v1.StateCondition.Builder.class); } // Construct using com.google.cloud.eventarc.v1.StateCondition.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -331,9 +351,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; } @java.lang.Override @@ -352,7 +372,8 @@ public com.google.cloud.eventarc.v1.StateCondition build() { @java.lang.Override public com.google.cloud.eventarc.v1.StateCondition buildPartial() { - com.google.cloud.eventarc.v1.StateCondition result = new com.google.cloud.eventarc.v1.StateCondition(this); + com.google.cloud.eventarc.v1.StateCondition result = + new com.google.cloud.eventarc.v1.StateCondition(this); result.code_ = code_; result.message_ = message_; onBuilt(); @@ -363,38 +384,39 @@ public com.google.cloud.eventarc.v1.StateCondition buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.StateCondition) { - return mergeFrom((com.google.cloud.eventarc.v1.StateCondition)other); + return mergeFrom((com.google.cloud.eventarc.v1.StateCondition) other); } else { super.mergeFrom(other); return this; @@ -436,22 +458,25 @@ public Builder mergeFrom( case 0: done = true; break; - case 8: { - code_ = input.readEnum(); - - break; - } // case 8 - case 18: { - message_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 8: + { + code_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + message_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -464,37 +489,47 @@ public Builder mergeFrom( private int code_ = 0; /** + * + * *
      * The canonical code of the condition.
      * 
* * .google.rpc.Code code = 1; + * * @return The enum numeric value on the wire for code. */ - @java.lang.Override public int getCodeValue() { + @java.lang.Override + public int getCodeValue() { return code_; } /** + * + * *
      * The canonical code of the condition.
      * 
* * .google.rpc.Code code = 1; + * * @param value The enum numeric value on the wire for code to set. * @return This builder for chaining. */ public Builder setCodeValue(int value) { - + code_ = value; onChanged(); return this; } /** + * + * *
      * The canonical code of the condition.
      * 
* * .google.rpc.Code code = 1; + * * @return The code. */ @java.lang.Override @@ -504,11 +539,14 @@ public com.google.rpc.Code getCode() { return result == null ? com.google.rpc.Code.UNRECOGNIZED : result; } /** + * + * *
      * The canonical code of the condition.
      * 
* * .google.rpc.Code code = 1; + * * @param value The code to set. * @return This builder for chaining. */ @@ -516,21 +554,24 @@ public Builder setCode(com.google.rpc.Code value) { if (value == null) { throw new NullPointerException(); } - + code_ = value.getNumber(); onChanged(); return this; } /** + * + * *
      * The canonical code of the condition.
      * 
* * .google.rpc.Code code = 1; + * * @return This builder for chaining. */ public Builder clearCode() { - + code_ = 0; onChanged(); return this; @@ -538,18 +579,20 @@ public Builder clearCode() { private java.lang.Object message_ = ""; /** + * + * *
      * Human-readable message.
      * 
* * string message = 2; + * * @return The message. */ public java.lang.String getMessage() { java.lang.Object ref = message_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); message_ = s; return s; @@ -558,20 +601,21 @@ public java.lang.String getMessage() { } } /** + * + * *
      * Human-readable message.
      * 
* * string message = 2; + * * @return The bytes for message. */ - public com.google.protobuf.ByteString - getMessageBytes() { + public com.google.protobuf.ByteString getMessageBytes() { java.lang.Object ref = message_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); message_ = b; return b; } else { @@ -579,61 +623,68 @@ public java.lang.String getMessage() { } } /** + * + * *
      * Human-readable message.
      * 
* * string message = 2; + * * @param value The message to set. * @return This builder for chaining. */ - public Builder setMessage( - java.lang.String value) { + public Builder setMessage(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + message_ = value; onChanged(); return this; } /** + * + * *
      * Human-readable message.
      * 
* * string message = 2; + * * @return This builder for chaining. */ public Builder clearMessage() { - + message_ = getDefaultInstance().getMessage(); onChanged(); return this; } /** + * + * *
      * Human-readable message.
      * 
* * string message = 2; + * * @param value The bytes for message to set. * @return This builder for chaining. */ - public Builder setMessageBytes( - com.google.protobuf.ByteString value) { + public Builder setMessageBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + message_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -643,12 +694,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.StateCondition) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.StateCondition) private static final com.google.cloud.eventarc.v1.StateCondition DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.StateCondition(); } @@ -657,27 +708,27 @@ public static com.google.cloud.eventarc.v1.StateCondition getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public StateCondition parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StateCondition parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -692,6 +743,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.StateCondition getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java similarity index 85% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java index 7f4df57d376e..54c79656b573 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/StateConditionOrBuilder.java @@ -3,46 +3,58 @@ package com.google.cloud.eventarc.v1; -public interface StateConditionOrBuilder extends +public interface StateConditionOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.StateCondition) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The canonical code of the condition.
    * 
* * .google.rpc.Code code = 1; + * * @return The enum numeric value on the wire for code. */ int getCodeValue(); /** + * + * *
    * The canonical code of the condition.
    * 
* * .google.rpc.Code code = 1; + * * @return The code. */ com.google.rpc.Code getCode(); /** + * + * *
    * Human-readable message.
    * 
* * string message = 2; + * * @return The message. */ java.lang.String getMessage(); /** + * + * *
    * Human-readable message.
    * 
* * string message = 2; + * * @return The bytes for message. */ - com.google.protobuf.ByteString - getMessageBytes(); + com.google.protobuf.ByteString getMessageBytes(); } diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java similarity index 70% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java index a9333cd19f26..6e6a15ddc1b9 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Transport.java @@ -4,6 +4,8 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * Represents the transport intermediaries created for the trigger to
  * deliver events.
@@ -11,51 +13,55 @@
  *
  * Protobuf type {@code google.cloud.eventarc.v1.Transport}
  */
-public final class Transport extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class Transport extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Transport)
     TransportOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use Transport.newBuilder() to construct.
   private Transport(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
-  private Transport() {
-  }
+
+  private Transport() {}
 
   @java.lang.Override
   @SuppressWarnings({"unused"})
-  protected java.lang.Object newInstance(
-      UnusedPrivateParameter unused) {
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
     return new Transport();
   }
 
   @java.lang.Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
-  public static final com.google.protobuf.Descriptors.Descriptor
-      getDescriptor() {
-    return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Transport_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.cloud.eventarc.v1.TriggerProto
+        .internal_static_google_cloud_eventarc_v1_Transport_descriptor;
   }
 
   @java.lang.Override
   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable
+    return com.google.cloud.eventarc.v1.TriggerProto
+        .internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            com.google.cloud.eventarc.v1.Transport.class, com.google.cloud.eventarc.v1.Transport.Builder.class);
+            com.google.cloud.eventarc.v1.Transport.class,
+            com.google.cloud.eventarc.v1.Transport.Builder.class);
   }
 
   private int intermediaryCase_ = 0;
   private java.lang.Object intermediary_;
+
   public enum IntermediaryCase
-      implements com.google.protobuf.Internal.EnumLite,
+      implements
+          com.google.protobuf.Internal.EnumLite,
           com.google.protobuf.AbstractMessage.InternalOneOfEnum {
     PUBSUB(1),
     INTERMEDIARY_NOT_SET(0);
     private final int value;
+
     private IntermediaryCase(int value) {
       this.value = value;
     }
@@ -71,30 +77,35 @@ public static IntermediaryCase valueOf(int value) {
 
     public static IntermediaryCase forNumber(int value) {
       switch (value) {
-        case 1: return PUBSUB;
-        case 0: return INTERMEDIARY_NOT_SET;
-        default: return null;
+        case 1:
+          return PUBSUB;
+        case 0:
+          return INTERMEDIARY_NOT_SET;
+        default:
+          return null;
       }
     }
+
     public int getNumber() {
       return this.value;
     }
   };
 
-  public IntermediaryCase
-  getIntermediaryCase() {
-    return IntermediaryCase.forNumber(
-        intermediaryCase_);
+  public IntermediaryCase getIntermediaryCase() {
+    return IntermediaryCase.forNumber(intermediaryCase_);
   }
 
   public static final int PUBSUB_FIELD_NUMBER = 1;
   /**
+   *
+   *
    * 
    * The Pub/Sub topic and subscription used by Eventarc as a transport
    * intermediary.
    * 
* * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * * @return Whether the pubsub field is set. */ @java.lang.Override @@ -102,22 +113,27 @@ public boolean hasPubsub() { return intermediaryCase_ == 1; } /** + * + * *
    * The Pub/Sub topic and subscription used by Eventarc as a transport
    * intermediary.
    * 
* * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * * @return The pubsub. */ @java.lang.Override public com.google.cloud.eventarc.v1.Pubsub getPubsub() { if (intermediaryCase_ == 1) { - return (com.google.cloud.eventarc.v1.Pubsub) intermediary_; + return (com.google.cloud.eventarc.v1.Pubsub) intermediary_; } return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance(); } /** + * + * *
    * The Pub/Sub topic and subscription used by Eventarc as a transport
    * intermediary.
@@ -128,12 +144,13 @@ public com.google.cloud.eventarc.v1.Pubsub getPubsub() {
   @java.lang.Override
   public com.google.cloud.eventarc.v1.PubsubOrBuilder getPubsubOrBuilder() {
     if (intermediaryCase_ == 1) {
-       return (com.google.cloud.eventarc.v1.Pubsub) intermediary_;
+      return (com.google.cloud.eventarc.v1.Pubsub) intermediary_;
     }
     return com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance();
   }
 
   private byte memoizedIsInitialized = -1;
+
   @java.lang.Override
   public final boolean isInitialized() {
     byte isInitialized = memoizedIsInitialized;
@@ -145,8 +162,7 @@ public final boolean isInitialized() {
   }
 
   @java.lang.Override
-  public void writeTo(com.google.protobuf.CodedOutputStream output)
-                      throws java.io.IOException {
+  public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
     if (intermediaryCase_ == 1) {
       output.writeMessage(1, (com.google.cloud.eventarc.v1.Pubsub) intermediary_);
     }
@@ -160,8 +176,9 @@ public int getSerializedSize() {
 
     size = 0;
     if (intermediaryCase_ == 1) {
-      size += com.google.protobuf.CodedOutputStream
-        .computeMessageSize(1, (com.google.cloud.eventarc.v1.Pubsub) intermediary_);
+      size +=
+          com.google.protobuf.CodedOutputStream.computeMessageSize(
+              1, (com.google.cloud.eventarc.v1.Pubsub) intermediary_);
     }
     size += getUnknownFields().getSerializedSize();
     memoizedSize = size;
@@ -171,7 +188,7 @@ public int getSerializedSize() {
   @java.lang.Override
   public boolean equals(final java.lang.Object obj) {
     if (obj == this) {
-     return true;
+      return true;
     }
     if (!(obj instanceof com.google.cloud.eventarc.v1.Transport)) {
       return super.equals(obj);
@@ -181,8 +198,7 @@ public boolean equals(final java.lang.Object obj) {
     if (!getIntermediaryCase().equals(other.getIntermediaryCase())) return false;
     switch (intermediaryCase_) {
       case 1:
-        if (!getPubsub()
-            .equals(other.getPubsub())) return false;
+        if (!getPubsub().equals(other.getPubsub())) return false;
         break;
       case 0:
       default:
@@ -211,97 +227,104 @@ public int hashCode() {
     return hash;
   }
 
-  public static com.google.cloud.eventarc.v1.Transport parseFrom(
-      java.nio.ByteBuffer data)
+  public static com.google.cloud.eventarc.v1.Transport parseFrom(java.nio.ByteBuffer data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
-      java.nio.ByteBuffer data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
       com.google.protobuf.ByteString data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
       com.google.protobuf.ByteString data,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(byte[] data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
-      byte[] data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(java.io.InputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseDelimitedFrom(java.io.InputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseDelimitedFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+        PARSER, input, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
-      com.google.protobuf.CodedInputStream input)
-      throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+      com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
+
   public static com.google.cloud.eventarc.v1.Transport parseFrom(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
   }
 
   @java.lang.Override
-  public Builder newBuilderForType() { return newBuilder(); }
+  public Builder newBuilderForType() {
+    return newBuilder();
+  }
+
   public static Builder newBuilder() {
     return DEFAULT_INSTANCE.toBuilder();
   }
+
   public static Builder newBuilder(com.google.cloud.eventarc.v1.Transport prototype) {
     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
   }
+
   @java.lang.Override
   public Builder toBuilder() {
-    return this == DEFAULT_INSTANCE
-        ? new Builder() : new Builder().mergeFrom(this);
+    return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
   }
 
   @java.lang.Override
-  protected Builder newBuilderForType(
-      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+  protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
     Builder builder = new Builder(parent);
     return builder;
   }
   /**
+   *
+   *
    * 
    * Represents the transport intermediaries created for the trigger to
    * deliver events.
@@ -309,33 +332,32 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.cloud.eventarc.v1.Transport}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Transport)
       com.google.cloud.eventarc.v1.TransportOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Transport_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.cloud.eventarc.v1.TriggerProto
+          .internal_static_google_cloud_eventarc_v1_Transport_descriptor;
     }
 
     @java.lang.Override
     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable
+      return com.google.cloud.eventarc.v1.TriggerProto
+          .internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              com.google.cloud.eventarc.v1.Transport.class, com.google.cloud.eventarc.v1.Transport.Builder.class);
+              com.google.cloud.eventarc.v1.Transport.class,
+              com.google.cloud.eventarc.v1.Transport.Builder.class);
     }
 
     // Construct using com.google.cloud.eventarc.v1.Transport.newBuilder()
-    private Builder() {
+    private Builder() {}
 
-    }
-
-    private Builder(
-        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
-
     }
+
     @java.lang.Override
     public Builder clear() {
       super.clear();
@@ -348,9 +370,9 @@ public Builder clear() {
     }
 
     @java.lang.Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Transport_descriptor;
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.cloud.eventarc.v1.TriggerProto
+          .internal_static_google_cloud_eventarc_v1_Transport_descriptor;
     }
 
     @java.lang.Override
@@ -369,7 +391,8 @@ public com.google.cloud.eventarc.v1.Transport build() {
 
     @java.lang.Override
     public com.google.cloud.eventarc.v1.Transport buildPartial() {
-      com.google.cloud.eventarc.v1.Transport result = new com.google.cloud.eventarc.v1.Transport(this);
+      com.google.cloud.eventarc.v1.Transport result =
+          new com.google.cloud.eventarc.v1.Transport(this);
       if (intermediaryCase_ == 1) {
         if (pubsubBuilder_ == null) {
           result.intermediary_ = intermediary_;
@@ -386,38 +409,39 @@ public com.google.cloud.eventarc.v1.Transport buildPartial() {
     public Builder clone() {
       return super.clone();
     }
+
     @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
+
     @java.lang.Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
+
     @java.lang.Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
+
     @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
+
     @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        java.lang.Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
+
     @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
       if (other instanceof com.google.cloud.eventarc.v1.Transport) {
-        return mergeFrom((com.google.cloud.eventarc.v1.Transport)other);
+        return mergeFrom((com.google.cloud.eventarc.v1.Transport) other);
       } else {
         super.mergeFrom(other);
         return this;
@@ -427,13 +451,15 @@ public Builder mergeFrom(com.google.protobuf.Message other) {
     public Builder mergeFrom(com.google.cloud.eventarc.v1.Transport other) {
       if (other == com.google.cloud.eventarc.v1.Transport.getDefaultInstance()) return this;
       switch (other.getIntermediaryCase()) {
-        case PUBSUB: {
-          mergePubsub(other.getPubsub());
-          break;
-        }
-        case INTERMEDIARY_NOT_SET: {
-          break;
-        }
+        case PUBSUB:
+          {
+            mergePubsub(other.getPubsub());
+            break;
+          }
+        case INTERMEDIARY_NOT_SET:
+          {
+            break;
+          }
       }
       this.mergeUnknownFields(other.getUnknownFields());
       onChanged();
@@ -461,19 +487,19 @@ public Builder mergeFrom(
             case 0:
               done = true;
               break;
-            case 10: {
-              input.readMessage(
-                  getPubsubFieldBuilder().getBuilder(),
-                  extensionRegistry);
-              intermediaryCase_ = 1;
-              break;
-            } // case 10
-            default: {
-              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
-                done = true; // was an endgroup tag
-              }
-              break;
-            } // default:
+            case 10:
+              {
+                input.readMessage(getPubsubFieldBuilder().getBuilder(), extensionRegistry);
+                intermediaryCase_ = 1;
+                break;
+              } // case 10
+            default:
+              {
+                if (!super.parseUnknownField(input, extensionRegistry, tag)) {
+                  done = true; // was an endgroup tag
+                }
+                break;
+              } // default:
           } // switch (tag)
         } // while (!done)
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@@ -483,12 +509,12 @@ public Builder mergeFrom(
       } // finally
       return this;
     }
+
     private int intermediaryCase_ = 0;
     private java.lang.Object intermediary_;
-    public IntermediaryCase
-        getIntermediaryCase() {
-      return IntermediaryCase.forNumber(
-          intermediaryCase_);
+
+    public IntermediaryCase getIntermediaryCase() {
+      return IntermediaryCase.forNumber(intermediaryCase_);
     }
 
     public Builder clearIntermediary() {
@@ -498,16 +524,21 @@ public Builder clearIntermediary() {
       return this;
     }
 
-
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.cloud.eventarc.v1.Pubsub, com.google.cloud.eventarc.v1.Pubsub.Builder, com.google.cloud.eventarc.v1.PubsubOrBuilder> pubsubBuilder_;
+            com.google.cloud.eventarc.v1.Pubsub,
+            com.google.cloud.eventarc.v1.Pubsub.Builder,
+            com.google.cloud.eventarc.v1.PubsubOrBuilder>
+        pubsubBuilder_;
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
      * 
* * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * * @return Whether the pubsub field is set. */ @java.lang.Override @@ -515,12 +546,15 @@ public boolean hasPubsub() { return intermediaryCase_ == 1; } /** + * + * *
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
      * 
* * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * * @return The pubsub. */ @java.lang.Override @@ -538,6 +572,8 @@ public com.google.cloud.eventarc.v1.Pubsub getPubsub() { } } /** + * + * *
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -559,6 +595,8 @@ public Builder setPubsub(com.google.cloud.eventarc.v1.Pubsub value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -566,8 +604,7 @@ public Builder setPubsub(com.google.cloud.eventarc.v1.Pubsub value) {
      *
      * .google.cloud.eventarc.v1.Pubsub pubsub = 1;
      */
-    public Builder setPubsub(
-        com.google.cloud.eventarc.v1.Pubsub.Builder builderForValue) {
+    public Builder setPubsub(com.google.cloud.eventarc.v1.Pubsub.Builder builderForValue) {
       if (pubsubBuilder_ == null) {
         intermediary_ = builderForValue.build();
         onChanged();
@@ -578,6 +615,8 @@ public Builder setPubsub(
       return this;
     }
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -587,10 +626,13 @@ public Builder setPubsub(
      */
     public Builder mergePubsub(com.google.cloud.eventarc.v1.Pubsub value) {
       if (pubsubBuilder_ == null) {
-        if (intermediaryCase_ == 1 &&
-            intermediary_ != com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance()) {
-          intermediary_ = com.google.cloud.eventarc.v1.Pubsub.newBuilder((com.google.cloud.eventarc.v1.Pubsub) intermediary_)
-              .mergeFrom(value).buildPartial();
+        if (intermediaryCase_ == 1
+            && intermediary_ != com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance()) {
+          intermediary_ =
+              com.google.cloud.eventarc.v1.Pubsub.newBuilder(
+                      (com.google.cloud.eventarc.v1.Pubsub) intermediary_)
+                  .mergeFrom(value)
+                  .buildPartial();
         } else {
           intermediary_ = value;
         }
@@ -606,6 +648,8 @@ public Builder mergePubsub(com.google.cloud.eventarc.v1.Pubsub value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -630,6 +674,8 @@ public Builder clearPubsub() {
       return this;
     }
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -641,6 +687,8 @@ public com.google.cloud.eventarc.v1.Pubsub.Builder getPubsubBuilder() {
       return getPubsubFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -660,6 +708,8 @@ public com.google.cloud.eventarc.v1.PubsubOrBuilder getPubsubOrBuilder() {
       }
     }
     /**
+     *
+     *
      * 
      * The Pub/Sub topic and subscription used by Eventarc as a transport
      * intermediary.
@@ -668,26 +718,32 @@ public com.google.cloud.eventarc.v1.PubsubOrBuilder getPubsubOrBuilder() {
      * .google.cloud.eventarc.v1.Pubsub pubsub = 1;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.cloud.eventarc.v1.Pubsub, com.google.cloud.eventarc.v1.Pubsub.Builder, com.google.cloud.eventarc.v1.PubsubOrBuilder> 
+            com.google.cloud.eventarc.v1.Pubsub,
+            com.google.cloud.eventarc.v1.Pubsub.Builder,
+            com.google.cloud.eventarc.v1.PubsubOrBuilder>
         getPubsubFieldBuilder() {
       if (pubsubBuilder_ == null) {
         if (!(intermediaryCase_ == 1)) {
           intermediary_ = com.google.cloud.eventarc.v1.Pubsub.getDefaultInstance();
         }
-        pubsubBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.cloud.eventarc.v1.Pubsub, com.google.cloud.eventarc.v1.Pubsub.Builder, com.google.cloud.eventarc.v1.PubsubOrBuilder>(
+        pubsubBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.cloud.eventarc.v1.Pubsub,
+                com.google.cloud.eventarc.v1.Pubsub.Builder,
+                com.google.cloud.eventarc.v1.PubsubOrBuilder>(
                 (com.google.cloud.eventarc.v1.Pubsub) intermediary_,
                 getParentForChildren(),
                 isClean());
         intermediary_ = null;
       }
       intermediaryCase_ = 1;
-      onChanged();;
+      onChanged();
+      ;
       return pubsubBuilder_;
     }
+
     @java.lang.Override
-    public final Builder setUnknownFields(
-        final com.google.protobuf.UnknownFieldSet unknownFields) {
+    public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
       return super.setUnknownFields(unknownFields);
     }
 
@@ -697,12 +753,12 @@ public final Builder mergeUnknownFields(
       return super.mergeUnknownFields(unknownFields);
     }
 
-
     // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Transport)
   }
 
   // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Transport)
   private static final com.google.cloud.eventarc.v1.Transport DEFAULT_INSTANCE;
+
   static {
     DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Transport();
   }
@@ -711,27 +767,27 @@ public static com.google.cloud.eventarc.v1.Transport getDefaultInstance() {
     return DEFAULT_INSTANCE;
   }
 
-  private static final com.google.protobuf.Parser
-      PARSER = new com.google.protobuf.AbstractParser() {
-    @java.lang.Override
-    public Transport parsePartialFrom(
-        com.google.protobuf.CodedInputStream input,
-        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
-        throws com.google.protobuf.InvalidProtocolBufferException {
-      Builder builder = newBuilder();
-      try {
-        builder.mergeFrom(input, extensionRegistry);
-      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
-        throw e.setUnfinishedMessage(builder.buildPartial());
-      } catch (com.google.protobuf.UninitializedMessageException e) {
-        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
-      } catch (java.io.IOException e) {
-        throw new com.google.protobuf.InvalidProtocolBufferException(e)
-            .setUnfinishedMessage(builder.buildPartial());
-      }
-      return builder.buildPartial();
-    }
-  };
+  private static final com.google.protobuf.Parser PARSER =
+      new com.google.protobuf.AbstractParser() {
+        @java.lang.Override
+        public Transport parsePartialFrom(
+            com.google.protobuf.CodedInputStream input,
+            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+            throws com.google.protobuf.InvalidProtocolBufferException {
+          Builder builder = newBuilder();
+          try {
+            builder.mergeFrom(input, extensionRegistry);
+          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+            throw e.setUnfinishedMessage(builder.buildPartial());
+          } catch (com.google.protobuf.UninitializedMessageException e) {
+            throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
+          } catch (java.io.IOException e) {
+            throw new com.google.protobuf.InvalidProtocolBufferException(e)
+                .setUnfinishedMessage(builder.buildPartial());
+          }
+          return builder.buildPartial();
+        }
+      };
 
   public static com.google.protobuf.Parser parser() {
     return PARSER;
@@ -746,6 +802,4 @@ public com.google.protobuf.Parser getParserForType() {
   public com.google.cloud.eventarc.v1.Transport getDefaultInstanceForType() {
     return DEFAULT_INSTANCE;
   }
-
 }
-
diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java
similarity index 92%
rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java
rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java
index 0e13bff8bbbb..898bc29db8f7 100644
--- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java
+++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TransportOrBuilder.java
@@ -3,31 +3,40 @@
 
 package com.google.cloud.eventarc.v1;
 
-public interface TransportOrBuilder extends
+public interface TransportOrBuilder
+    extends
     // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Transport)
     com.google.protobuf.MessageOrBuilder {
 
   /**
+   *
+   *
    * 
    * The Pub/Sub topic and subscription used by Eventarc as a transport
    * intermediary.
    * 
* * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * * @return Whether the pubsub field is set. */ boolean hasPubsub(); /** + * + * *
    * The Pub/Sub topic and subscription used by Eventarc as a transport
    * intermediary.
    * 
* * .google.cloud.eventarc.v1.Pubsub pubsub = 1; + * * @return The pubsub. */ com.google.cloud.eventarc.v1.Pubsub getPubsub(); /** + * + * *
    * The Pub/Sub topic and subscription used by Eventarc as a transport
    * intermediary.
diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java
similarity index 65%
rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java
rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java
index b5d0f66c2eed..01f4d2f15ed9 100644
--- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java
+++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/Trigger.java
@@ -4,21 +4,24 @@
 package com.google.cloud.eventarc.v1;
 
 /**
+ *
+ *
  * 
  * A representation of the trigger resource.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.Trigger} */ -public final class Trigger extends - com.google.protobuf.GeneratedMessageV3 implements +public final class Trigger extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.Trigger) TriggerOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use Trigger.newBuilder() to construct. private Trigger(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private Trigger() { name_ = ""; uid_ = ""; @@ -30,46 +33,48 @@ private Trigger() { @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new Trigger(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_descriptor; } @SuppressWarnings({"rawtypes"}) @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField( - int number) { + protected com.google.protobuf.MapField internalGetMapField(int number) { switch (number) { case 12: return internalGetLabels(); case 15: return internalGetConditions(); default: - throw new RuntimeException( - "Invalid map field number: " + number); + throw new RuntimeException("Invalid map field number: " + number); } } + @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Trigger.class, com.google.cloud.eventarc.v1.Trigger.Builder.class); + com.google.cloud.eventarc.v1.Trigger.class, + com.google.cloud.eventarc.v1.Trigger.Builder.class); } public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** + * + * *
    * Required. The resource name of the trigger. Must be unique within the location of the
    * project and must be in
@@ -77,6 +82,7 @@ protected com.google.protobuf.MapField internalGetMapField(
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ @java.lang.Override @@ -85,14 +91,15 @@ public java.lang.String getName() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } } /** + * + * *
    * Required. The resource name of the trigger. Must be unique within the location of the
    * project and must be in
@@ -100,16 +107,15 @@ public java.lang.String getName() {
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ @java.lang.Override - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -120,12 +126,15 @@ public java.lang.String getName() { public static final int UID_FIELD_NUMBER = 2; private volatile java.lang.Object uid_; /** + * + * *
    * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
    * string and guaranteed to remain unchanged until the resource is deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ @java.lang.Override @@ -134,30 +143,30 @@ public java.lang.String getUid() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); uid_ = s; return s; } } /** + * + * *
    * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
    * string and guaranteed to remain unchanged until the resource is deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ @java.lang.Override - public com.google.protobuf.ByteString - getUidBytes() { + public com.google.protobuf.ByteString getUidBytes() { java.lang.Object ref = uid_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); uid_ = b; return b; } else { @@ -168,11 +177,15 @@ public java.lang.String getUid() { public static final int CREATE_TIME_FIELD_NUMBER = 5; private com.google.protobuf.Timestamp createTime_; /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ @java.lang.Override @@ -180,11 +193,15 @@ public boolean hasCreateTime() { return createTime_ != null; } /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ @java.lang.Override @@ -192,11 +209,14 @@ public com.google.protobuf.Timestamp getCreateTime() { return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; } /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { @@ -206,11 +226,15 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { public static final int UPDATE_TIME_FIELD_NUMBER = 6; private com.google.protobuf.Timestamp updateTime_; /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ @java.lang.Override @@ -218,11 +242,15 @@ public boolean hasUpdateTime() { return updateTime_ != null; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ @java.lang.Override @@ -230,11 +258,14 @@ public com.google.protobuf.Timestamp getUpdateTime() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { @@ -244,71 +275,92 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { public static final int EVENT_FILTERS_FIELD_NUMBER = 8; private java.util.List eventFilters_; /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public java.util.List getEventFiltersList() { return eventFilters_; } /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override - public java.util.List + public java.util.List getEventFiltersOrBuilderList() { return eventFilters_; } /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public int getEventFiltersCount() { return eventFilters_.size(); } /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index) { return eventFilters_.get(index); } /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override - public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(int index) { return eventFilters_.get(index); } public static final int SERVICE_ACCOUNT_FIELD_NUMBER = 9; private volatile java.lang.Object serviceAccount_; /** + * + * *
    * Optional. The IAM service account email associated with the trigger. The
    * service account represents the identity of the trigger.
@@ -324,7 +376,10 @@ public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilde
    * have the `roles/eventarc.eventReceiver` IAM role.
    * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The serviceAccount. */ @java.lang.Override @@ -333,14 +388,15 @@ public java.lang.String getServiceAccount() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); serviceAccount_ = s; return s; } } /** + * + * *
    * Optional. The IAM service account email associated with the trigger. The
    * service account represents the identity of the trigger.
@@ -356,17 +412,18 @@ public java.lang.String getServiceAccount() {
    * have the `roles/eventarc.eventReceiver` IAM role.
    * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for serviceAccount. */ @java.lang.Override - public com.google.protobuf.ByteString - getServiceAccountBytes() { + public com.google.protobuf.ByteString getServiceAccountBytes() { java.lang.Object ref = serviceAccount_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); serviceAccount_ = b; return b; } else { @@ -377,11 +434,16 @@ public java.lang.String getServiceAccount() { public static final int DESTINATION_FIELD_NUMBER = 10; private com.google.cloud.eventarc.v1.Destination destination_; /** + * + * *
    * Required. Destination specifies where the events should be sent to.
    * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the destination field is set. */ @java.lang.Override @@ -389,23 +451,34 @@ public boolean hasDestination() { return destination_ != null; } /** + * + * *
    * Required. Destination specifies where the events should be sent to.
    * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The destination. */ @java.lang.Override public com.google.cloud.eventarc.v1.Destination getDestination() { - return destination_ == null ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() : destination_; + return destination_ == null + ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() + : destination_; } /** + * + * *
    * Required. Destination specifies where the events should be sent to.
    * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder() { @@ -415,6 +488,8 @@ public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder public static final int TRANSPORT_FIELD_NUMBER = 11; private com.google.cloud.eventarc.v1.Transport transport_; /** + * + * *
    * Optional. To deliver messages, Eventarc might use other GCP
    * products as a transport intermediary. This field contains a reference to
@@ -422,7 +497,10 @@ public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder
    * purposes.
    * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * * @return Whether the transport field is set. */ @java.lang.Override @@ -430,6 +508,8 @@ public boolean hasTransport() { return transport_ != null; } /** + * + * *
    * Optional. To deliver messages, Eventarc might use other GCP
    * products as a transport intermediary. This field contains a reference to
@@ -437,14 +517,21 @@ public boolean hasTransport() {
    * purposes.
    * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * * @return The transport. */ @java.lang.Override public com.google.cloud.eventarc.v1.Transport getTransport() { - return transport_ == null ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() : transport_; + return transport_ == null + ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() + : transport_; } /** + * + * *
    * Optional. To deliver messages, Eventarc might use other GCP
    * products as a transport intermediary. This field contains a reference to
@@ -452,7 +539,9 @@ public com.google.cloud.eventarc.v1.Transport getTransport() {
    * purposes.
    * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ @java.lang.Override public com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder() { @@ -460,24 +549,23 @@ public com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder() { } public static final int LABELS_FIELD_NUMBER = 12; + private static final class LabelsDefaultEntryHolder { - static final com.google.protobuf.MapEntry< - java.lang.String, java.lang.String> defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); } - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> labels_; - private com.google.protobuf.MapField - internalGetLabels() { + + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField( - LabelsDefaultEntryHolder.defaultEntry); + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); } return labels_; } @@ -486,28 +574,30 @@ public int getLabelsCount() { return internalGetLabels().getMap().size(); } /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - @java.lang.Override - public boolean containsLabels( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } return internalGetLabels().getMap().containsKey(key); } - /** - * Use {@link #getLabelsMap()} instead. - */ + /** Use {@link #getLabelsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); } /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
@@ -515,11 +605,12 @@ public java.util.Map getLabels() { * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override - public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
@@ -527,16 +618,16 @@ public java.util.Map getLabelsMap() { * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override - - public java.lang.String getLabelsOrDefault( - java.lang.String key, - java.lang.String defaultValue) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetLabels().getMap(); + public java.lang.String getLabelsOrDefault(java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
@@ -544,12 +635,11 @@ public java.lang.String getLabelsOrDefault( * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override - - public java.lang.String getLabelsOrThrow( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetLabels().getMap(); + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } @@ -559,6 +649,8 @@ public java.lang.String getLabelsOrThrow( public static final int CHANNEL_FIELD_NUMBER = 13; private volatile java.lang.Object channel_; /** + * + * *
    * Optional. The name of the channel associated with the trigger in
    * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -566,6 +658,7 @@ public java.lang.String getLabelsOrThrow(
    * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The channel. */ @java.lang.Override @@ -574,14 +667,15 @@ public java.lang.String getChannel() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channel_ = s; return s; } } /** + * + * *
    * Optional. The name of the channel associated with the trigger in
    * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -589,16 +683,15 @@ public java.lang.String getChannel() {
    * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for channel. */ @java.lang.Override - public com.google.protobuf.ByteString - getChannelBytes() { + public com.google.protobuf.ByteString getChannelBytes() { java.lang.Object ref = channel_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channel_ = b; return b; } else { @@ -607,24 +700,30 @@ public java.lang.String getChannel() { } public static final int CONDITIONS_FIELD_NUMBER = 15; + private static final class ConditionsDefaultEntryHolder { static final com.google.protobuf.MapEntry< - java.lang.String, com.google.cloud.eventarc.v1.StateCondition> defaultEntry = + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + defaultEntry = com.google.protobuf.MapEntry - .newDefaultInstance( - com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.MESSAGE, - com.google.cloud.eventarc.v1.StateCondition.getDefaultInstance()); + .newDefaultInstance( + com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.MESSAGE, + com.google.cloud.eventarc.v1.StateCondition.getDefaultInstance()); } + private com.google.protobuf.MapField< - java.lang.String, com.google.cloud.eventarc.v1.StateCondition> conditions_; - private com.google.protobuf.MapField - internalGetConditions() { + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + conditions_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + internalGetConditions() { if (conditions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - ConditionsDefaultEntryHolder.defaultEntry); + return com.google.protobuf.MapField.emptyMapField(ConditionsDefaultEntryHolder.defaultEntry); } return conditions_; } @@ -633,68 +732,83 @@ public int getConditionsCount() { return internalGetConditions().getMap().size(); } /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - @java.lang.Override - public boolean containsConditions( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } + public boolean containsConditions(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } return internalGetConditions().getMap().containsKey(key); } - /** - * Use {@link #getConditionsMap()} instead. - */ + /** Use {@link #getConditionsMap()} instead. */ @java.lang.Override @java.lang.Deprecated - public java.util.Map getConditions() { + public java.util.Map + getConditions() { return getConditionsMap(); } /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - - public java.util.Map getConditionsMap() { + public java.util.Map + getConditionsMap() { return internalGetConditions().getMap(); } /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - public com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( - java.lang.String key, - com.google.cloud.eventarc.v1.StateCondition defaultValue) { - if (key == null) { throw new NullPointerException("map key"); } + java.lang.String key, com.google.cloud.eventarc.v1.StateCondition defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } java.util.Map map = internalGetConditions().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - - public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } + public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } java.util.Map map = internalGetConditions().getMap(); if (!map.containsKey(key)) { @@ -706,6 +820,8 @@ public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow( public static final int ETAG_FIELD_NUMBER = 99; private volatile java.lang.Object etag_; /** + * + * *
    * Output only. This checksum is computed by the server based on the value of other
    * fields, and might be sent only on create requests to ensure that the
@@ -713,6 +829,7 @@ public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(
    * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The etag. */ @java.lang.Override @@ -721,14 +838,15 @@ public java.lang.String getEtag() { if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); etag_ = s; return s; } } /** + * + * *
    * Output only. This checksum is computed by the server based on the value of other
    * fields, and might be sent only on create requests to ensure that the
@@ -736,16 +854,15 @@ public java.lang.String getEtag() {
    * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for etag. */ @java.lang.Override - public com.google.protobuf.ByteString - getEtagBytes() { + public com.google.protobuf.ByteString getEtagBytes() { java.lang.Object ref = etag_; if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); etag_ = b; return b; } else { @@ -754,6 +871,7 @@ public java.lang.String getEtag() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -765,8 +883,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } @@ -791,21 +908,13 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) if (transport_ != null) { output.writeMessage(11, getTransport()); } - com.google.protobuf.GeneratedMessageV3 - .serializeStringMapTo( - output, - internalGetLabels(), - LabelsDefaultEntryHolder.defaultEntry, - 12); + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 12); if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channel_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 13, channel_); } - com.google.protobuf.GeneratedMessageV3 - .serializeStringMapTo( - output, - internalGetConditions(), - ConditionsDefaultEntryHolder.defaultEntry, - 15); + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetConditions(), ConditionsDefaultEntryHolder.defaultEntry, 15); if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 99, etag_); } @@ -825,50 +934,46 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); } if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(5, getCreateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); } if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(6, getUpdateTime()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); } for (int i = 0; i < eventFilters_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(8, eventFilters_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, eventFilters_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, serviceAccount_); } if (destination_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(10, getDestination()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getDestination()); } if (transport_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(11, getTransport()); - } - for (java.util.Map.Entry entry - : internalGetLabels().getMap().entrySet()) { - com.google.protobuf.MapEntry - labels__ = LabelsDefaultEntryHolder.defaultEntry.newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(12, labels__); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getTransport()); + } + for (java.util.Map.Entry entry : + internalGetLabels().getMap().entrySet()) { + com.google.protobuf.MapEntry labels__ = + LabelsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, labels__); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(channel_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(13, channel_); } - for (java.util.Map.Entry entry - : internalGetConditions().getMap().entrySet()) { + for (java.util.Map.Entry entry : + internalGetConditions().getMap().entrySet()) { com.google.protobuf.MapEntry - conditions__ = ConditionsDefaultEntryHolder.defaultEntry.newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(15, conditions__); + conditions__ = + ConditionsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, conditions__); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(99, etag_); @@ -881,49 +986,37 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.Trigger)) { return super.equals(obj); } com.google.cloud.eventarc.v1.Trigger other = (com.google.cloud.eventarc.v1.Trigger) obj; - if (!getName() - .equals(other.getName())) return false; - if (!getUid() - .equals(other.getUid())) return false; + if (!getName().equals(other.getName())) return false; + if (!getUid().equals(other.getUid())) return false; if (hasCreateTime() != other.hasCreateTime()) return false; if (hasCreateTime()) { - if (!getCreateTime() - .equals(other.getCreateTime())) return false; + if (!getCreateTime().equals(other.getCreateTime())) return false; } if (hasUpdateTime() != other.hasUpdateTime()) return false; if (hasUpdateTime()) { - if (!getUpdateTime() - .equals(other.getUpdateTime())) return false; + if (!getUpdateTime().equals(other.getUpdateTime())) return false; } - if (!getEventFiltersList() - .equals(other.getEventFiltersList())) return false; - if (!getServiceAccount() - .equals(other.getServiceAccount())) return false; + if (!getEventFiltersList().equals(other.getEventFiltersList())) return false; + if (!getServiceAccount().equals(other.getServiceAccount())) return false; if (hasDestination() != other.hasDestination()) return false; if (hasDestination()) { - if (!getDestination() - .equals(other.getDestination())) return false; + if (!getDestination().equals(other.getDestination())) return false; } if (hasTransport() != other.hasTransport()) return false; if (hasTransport()) { - if (!getTransport() - .equals(other.getTransport())) return false; - } - if (!internalGetLabels().equals( - other.internalGetLabels())) return false; - if (!getChannel() - .equals(other.getChannel())) return false; - if (!internalGetConditions().equals( - other.internalGetConditions())) return false; - if (!getEtag() - .equals(other.getEtag())) return false; + if (!getTransport().equals(other.getTransport())) return false; + } + if (!internalGetLabels().equals(other.internalGetLabels())) return false; + if (!getChannel().equals(other.getChannel())) return false; + if (!internalGetConditions().equals(other.internalGetConditions())) return false; + if (!getEtag().equals(other.getEtag())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -978,156 +1071,159 @@ public int hashCode() { return hash; } - public static com.google.cloud.eventarc.v1.Trigger parseFrom( - java.nio.ByteBuffer data) + public static com.google.cloud.eventarc.v1.Trigger parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.Trigger parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.cloud.eventarc.v1.Trigger parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Trigger parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Trigger parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.Trigger parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.Trigger prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * A representation of the trigger resource.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.Trigger} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.Trigger) com.google.cloud.eventarc.v1.TriggerOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_descriptor; } @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField( - int number) { + protected com.google.protobuf.MapField internalGetMapField(int number) { switch (number) { case 12: return internalGetLabels(); case 15: return internalGetConditions(); default: - throw new RuntimeException( - "Invalid map field number: " + number); + throw new RuntimeException("Invalid map field number: " + number); } } + @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField( - int number) { + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { switch (number) { case 12: return internalGetMutableLabels(); case 15: return internalGetMutableConditions(); default: - throw new RuntimeException( - "Invalid map field number: " + number); + throw new RuntimeException("Invalid map field number: " + number); } } + @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.Trigger.class, com.google.cloud.eventarc.v1.Trigger.Builder.class); + com.google.cloud.eventarc.v1.Trigger.class, + com.google.cloud.eventarc.v1.Trigger.Builder.class); } // Construct using com.google.cloud.eventarc.v1.Trigger.newBuilder() - private Builder() { - - } + private Builder() {} - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -1178,9 +1274,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.TriggerProto.internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.TriggerProto + .internal_static_google_cloud_eventarc_v1_Trigger_descriptor; } @java.lang.Override @@ -1247,38 +1343,39 @@ public com.google.cloud.eventarc.v1.Trigger buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.Trigger) { - return mergeFrom((com.google.cloud.eventarc.v1.Trigger)other); + return mergeFrom((com.google.cloud.eventarc.v1.Trigger) other); } else { super.mergeFrom(other); return this; @@ -1319,9 +1416,10 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.Trigger other) { eventFiltersBuilder_ = null; eventFilters_ = other.eventFilters_; bitField0_ = (bitField0_ & ~0x00000001); - eventFiltersBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getEventFiltersFieldBuilder() : null; + eventFiltersBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getEventFiltersFieldBuilder() + : null; } else { eventFiltersBuilder_.addAllMessages(other.eventFilters_); } @@ -1337,14 +1435,12 @@ public Builder mergeFrom(com.google.cloud.eventarc.v1.Trigger other) { if (other.hasTransport()) { mergeTransport(other.getTransport()); } - internalGetMutableLabels().mergeFrom( - other.internalGetLabels()); + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); if (!other.getChannel().isEmpty()) { channel_ = other.channel_; onChanged(); } - internalGetMutableConditions().mergeFrom( - other.internalGetConditions()); + internalGetMutableConditions().mergeFrom(other.internalGetConditions()); if (!other.getEtag().isEmpty()) { etag_ = other.etag_; onChanged(); @@ -1375,94 +1471,104 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: { - uid_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 42: { - input.readMessage( - getCreateTimeFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 42 - case 50: { - input.readMessage( - getUpdateTimeFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 50 - case 66: { - com.google.cloud.eventarc.v1.EventFilter m = - input.readMessage( - com.google.cloud.eventarc.v1.EventFilter.parser(), - extensionRegistry); - if (eventFiltersBuilder_ == null) { - ensureEventFiltersIsMutable(); - eventFilters_.add(m); - } else { - eventFiltersBuilder_.addMessage(m); - } - break; - } // case 66 - case 74: { - serviceAccount_ = input.readStringRequireUtf8(); - - break; - } // case 74 - case 82: { - input.readMessage( - getDestinationFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 82 - case 90: { - input.readMessage( - getTransportFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 90 - case 98: { - com.google.protobuf.MapEntry - labels__ = input.readMessage( - LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - internalGetMutableLabels().getMutableMap().put( - labels__.getKey(), labels__.getValue()); - break; - } // case 98 - case 106: { - channel_ = input.readStringRequireUtf8(); - - break; - } // case 106 - case 122: { - com.google.protobuf.MapEntry - conditions__ = input.readMessage( - ConditionsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - internalGetMutableConditions().getMutableMap().put( - conditions__.getKey(), conditions__.getValue()); - break; - } // case 122 - case 794: { - etag_ = input.readStringRequireUtf8(); - - break; - } // case 794 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + uid_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 66: + { + com.google.cloud.eventarc.v1.EventFilter m = + input.readMessage( + com.google.cloud.eventarc.v1.EventFilter.parser(), extensionRegistry); + if (eventFiltersBuilder_ == null) { + ensureEventFiltersIsMutable(); + eventFilters_.add(m); + } else { + eventFiltersBuilder_.addMessage(m); + } + break; + } // case 66 + case 74: + { + serviceAccount_ = input.readStringRequireUtf8(); + + break; + } // case 74 + case 82: + { + input.readMessage(getDestinationFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 82 + case 90: + { + input.readMessage(getTransportFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 90 + case 98: + { + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableLabels() + .getMutableMap() + .put(labels__.getKey(), labels__.getValue()); + break; + } // case 98 + case 106: + { + channel_ = input.readStringRequireUtf8(); + + break; + } // case 106 + case 122: + { + com.google.protobuf.MapEntry< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + conditions__ = + input.readMessage( + ConditionsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableConditions() + .getMutableMap() + .put(conditions__.getKey(), conditions__.getValue()); + break; + } // case 122 + case 794: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 794 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -1472,10 +1578,13 @@ public Builder mergeFrom( } // finally return this; } + private int bitField0_; private java.lang.Object name_ = ""; /** + * + * *
      * Required. The resource name of the trigger. Must be unique within the location of the
      * project and must be in
@@ -1483,13 +1592,13 @@ public Builder mergeFrom(
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; @@ -1498,6 +1607,8 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The resource name of the trigger. Must be unique within the location of the
      * project and must be in
@@ -1505,15 +1616,14 @@ public java.lang.String getName() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - public com.google.protobuf.ByteString - getNameBytes() { + public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); name_ = b; return b; } else { @@ -1521,6 +1631,8 @@ public java.lang.String getName() { } } /** + * + * *
      * Required. The resource name of the trigger. Must be unique within the location of the
      * project and must be in
@@ -1528,20 +1640,22 @@ public java.lang.String getName() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The name to set. * @return This builder for chaining. */ - public Builder setName( - java.lang.String value) { + public Builder setName(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + name_ = value; onChanged(); return this; } /** + * + * *
      * Required. The resource name of the trigger. Must be unique within the location of the
      * project and must be in
@@ -1549,15 +1663,18 @@ public Builder setName(
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearName() { - + name_ = getDefaultInstance().getName(); onChanged(); return this; } /** + * + * *
      * Required. The resource name of the trigger. Must be unique within the location of the
      * project and must be in
@@ -1565,16 +1682,16 @@ public Builder clearName() {
      * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The bytes for name to set. * @return This builder for chaining. */ - public Builder setNameBytes( - com.google.protobuf.ByteString value) { + public Builder setNameBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + name_ = value; onChanged(); return this; @@ -1582,19 +1699,21 @@ public Builder setNameBytes( private java.lang.Object uid_ = ""; /** + * + * *
      * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
      * string and guaranteed to remain unchanged until the resource is deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ public java.lang.String getUid() { java.lang.Object ref = uid_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); uid_ = s; return s; @@ -1603,21 +1722,22 @@ public java.lang.String getUid() { } } /** + * + * *
      * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
      * string and guaranteed to remain unchanged until the resource is deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ - public com.google.protobuf.ByteString - getUidBytes() { + public com.google.protobuf.ByteString getUidBytes() { java.lang.Object ref = uid_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); uid_ = b; return b; } else { @@ -1625,57 +1745,64 @@ public java.lang.String getUid() { } } /** + * + * *
      * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
      * string and guaranteed to remain unchanged until the resource is deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The uid to set. * @return This builder for chaining. */ - public Builder setUid( - java.lang.String value) { + public Builder setUid(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + uid_ = value; onChanged(); return this; } /** + * + * *
      * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
      * string and guaranteed to remain unchanged until the resource is deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearUid() { - + uid_ = getDefaultInstance().getUid(); onChanged(); return this; } /** + * + * *
      * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
      * string and guaranteed to remain unchanged until the resource is deleted.
      * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for uid to set. * @return This builder for chaining. */ - public Builder setUidBytes( - com.google.protobuf.ByteString value) { + public Builder setUidBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + uid_ = value; onChanged(); return this; @@ -1683,39 +1810,58 @@ public Builder setUidBytes( private com.google.protobuf.Timestamp createTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ public boolean hasCreateTime() { return createTimeBuilder_ != null || createTime_ != null; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ public com.google.protobuf.Timestamp getCreateTime() { if (createTimeBuilder_ == null) { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } else { return createTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { @@ -1731,14 +1877,17 @@ public Builder setCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setCreateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (createTimeBuilder_ == null) { createTime_ = builderForValue.build(); onChanged(); @@ -1749,17 +1898,21 @@ public Builder setCreateTime( return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { if (createTimeBuilder_ == null) { if (createTime_ != null) { createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); } else { createTime_ = value; } @@ -1771,11 +1924,15 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearCreateTime() { if (createTimeBuilder_ == null) { @@ -1789,48 +1946,64 @@ public Builder clearCreateTime() { return this; } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - + onChanged(); return getCreateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { if (createTimeBuilder_ != null) { return createTimeBuilder_.getMessageOrBuilder(); } else { - return createTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; } } /** + * + * *
      * Output only. The creation time.
      * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getCreateTimeFieldBuilder() { if (createTimeBuilder_ == null) { - createTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), - getParentForChildren(), - isClean()); + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getCreateTime(), getParentForChildren(), isClean()); createTime_ = null; } return createTimeBuilder_; @@ -1838,39 +2011,58 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { private com.google.protobuf.Timestamp updateTime_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> updateTimeBuilder_; + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ public boolean hasUpdateTime() { return updateTimeBuilder_ != null || updateTime_ != null; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ public com.google.protobuf.Timestamp getUpdateTime() { if (updateTimeBuilder_ == null) { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } else { return updateTimeBuilder_.getMessage(); } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { @@ -1886,14 +2078,17 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder setUpdateTime( - com.google.protobuf.Timestamp.Builder builderForValue) { + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { if (updateTimeBuilder_ == null) { updateTime_ = builderForValue.build(); onChanged(); @@ -1904,17 +2099,21 @@ public Builder setUpdateTime( return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { if (updateTimeBuilder_ == null) { if (updateTime_ != null) { updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); } else { updateTime_ = value; } @@ -1926,11 +2125,15 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearUpdateTime() { if (updateTimeBuilder_ == null) { @@ -1944,72 +2147,97 @@ public Builder clearUpdateTime() { return this; } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - + onChanged(); return getUpdateTimeFieldBuilder().getBuilder(); } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { if (updateTimeBuilder_ != null) { return updateTimeBuilder_.getMessageOrBuilder(); } else { - return updateTime_ == null ? - com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; } } /** + * + * *
      * Output only. The last-modified time.
      * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> getUpdateTimeFieldBuilder() { if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), - getParentForChildren(), - isClean()); + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); updateTime_ = null; } return updateTimeBuilder_; } private java.util.List eventFilters_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureEventFiltersIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { - eventFilters_ = new java.util.ArrayList(eventFilters_); + eventFilters_ = + new java.util.ArrayList(eventFilters_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.EventFilter, com.google.cloud.eventarc.v1.EventFilter.Builder, com.google.cloud.eventarc.v1.EventFilterOrBuilder> eventFiltersBuilder_; + com.google.cloud.eventarc.v1.EventFilter, + com.google.cloud.eventarc.v1.EventFilter.Builder, + com.google.cloud.eventarc.v1.EventFilterOrBuilder> + eventFiltersBuilder_; /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public java.util.List getEventFiltersList() { if (eventFiltersBuilder_ == null) { @@ -2019,12 +2247,16 @@ public java.util.List getEventFiltersL } } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public int getEventFiltersCount() { if (eventFiltersBuilder_ == null) { @@ -2034,12 +2266,16 @@ public int getEventFiltersCount() { } } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index) { if (eventFiltersBuilder_ == null) { @@ -2049,15 +2285,18 @@ public com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index) { } } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public Builder setEventFilters( - int index, com.google.cloud.eventarc.v1.EventFilter value) { + public Builder setEventFilters(int index, com.google.cloud.eventarc.v1.EventFilter value) { if (eventFiltersBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -2071,12 +2310,16 @@ public Builder setEventFilters( return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder setEventFilters( int index, com.google.cloud.eventarc.v1.EventFilter.Builder builderForValue) { @@ -2090,12 +2333,16 @@ public Builder setEventFilters( return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder addEventFilters(com.google.cloud.eventarc.v1.EventFilter value) { if (eventFiltersBuilder_ == null) { @@ -2111,15 +2358,18 @@ public Builder addEventFilters(com.google.cloud.eventarc.v1.EventFilter value) { return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public Builder addEventFilters( - int index, com.google.cloud.eventarc.v1.EventFilter value) { + public Builder addEventFilters(int index, com.google.cloud.eventarc.v1.EventFilter value) { if (eventFiltersBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -2133,12 +2383,16 @@ public Builder addEventFilters( return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder addEventFilters( com.google.cloud.eventarc.v1.EventFilter.Builder builderForValue) { @@ -2152,12 +2406,16 @@ public Builder addEventFilters( return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder addEventFilters( int index, com.google.cloud.eventarc.v1.EventFilter.Builder builderForValue) { @@ -2171,19 +2429,22 @@ public Builder addEventFilters( return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder addAllEventFilters( java.lang.Iterable values) { if (eventFiltersBuilder_ == null) { ensureEventFiltersIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, eventFilters_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, eventFilters_); onChanged(); } else { eventFiltersBuilder_.addAllMessages(values); @@ -2191,12 +2452,16 @@ public Builder addAllEventFilters( return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder clearEventFilters() { if (eventFiltersBuilder_ == null) { @@ -2209,12 +2474,16 @@ public Builder clearEventFilters() { return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public Builder removeEventFilters(int index) { if (eventFiltersBuilder_ == null) { @@ -2227,42 +2496,53 @@ public Builder removeEventFilters(int index) { return this; } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public com.google.cloud.eventarc.v1.EventFilter.Builder getEventFiltersBuilder( - int index) { + public com.google.cloud.eventarc.v1.EventFilter.Builder getEventFiltersBuilder(int index) { return getEventFiltersFieldBuilder().getBuilder(index); } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder( - int index) { + public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(int index) { if (eventFiltersBuilder_ == null) { - return eventFilters_.get(index); } else { + return eventFilters_.get(index); + } else { return eventFiltersBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public java.util.List - getEventFiltersOrBuilderList() { + public java.util.List + getEventFiltersOrBuilderList() { if (eventFiltersBuilder_ != null) { return eventFiltersBuilder_.getMessageOrBuilderList(); } else { @@ -2270,52 +2550,66 @@ public com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilde } } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder() { - return getEventFiltersFieldBuilder().addBuilder( - com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()); + return getEventFiltersFieldBuilder() + .addBuilder(com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()); } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder( - int index) { - return getEventFiltersFieldBuilder().addBuilder( - index, com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()); + public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder(int index) { + return getEventFiltersFieldBuilder() + .addBuilder(index, com.google.cloud.eventarc.v1.EventFilter.getDefaultInstance()); } /** + * + * *
      * Required. Unordered list. The list of filters that applies to event attributes. Only events that
      * match all the provided filters are sent to the destination.
      * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - public java.util.List - getEventFiltersBuilderList() { + public java.util.List + getEventFiltersBuilderList() { return getEventFiltersFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.EventFilter, com.google.cloud.eventarc.v1.EventFilter.Builder, com.google.cloud.eventarc.v1.EventFilterOrBuilder> + com.google.cloud.eventarc.v1.EventFilter, + com.google.cloud.eventarc.v1.EventFilter.Builder, + com.google.cloud.eventarc.v1.EventFilterOrBuilder> getEventFiltersFieldBuilder() { if (eventFiltersBuilder_ == null) { - eventFiltersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.eventarc.v1.EventFilter, com.google.cloud.eventarc.v1.EventFilter.Builder, com.google.cloud.eventarc.v1.EventFilterOrBuilder>( - eventFilters_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); + eventFiltersBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.eventarc.v1.EventFilter, + com.google.cloud.eventarc.v1.EventFilter.Builder, + com.google.cloud.eventarc.v1.EventFilterOrBuilder>( + eventFilters_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); eventFilters_ = null; } return eventFiltersBuilder_; @@ -2323,6 +2617,8 @@ public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder( private java.lang.Object serviceAccount_ = ""; /** + * + * *
      * Optional. The IAM service account email associated with the trigger. The
      * service account represents the identity of the trigger.
@@ -2338,14 +2634,16 @@ public com.google.cloud.eventarc.v1.EventFilter.Builder addEventFiltersBuilder(
      * have the `roles/eventarc.eventReceiver` IAM role.
      * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The serviceAccount. */ public java.lang.String getServiceAccount() { java.lang.Object ref = serviceAccount_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); serviceAccount_ = s; return s; @@ -2354,6 +2652,8 @@ public java.lang.String getServiceAccount() { } } /** + * + * *
      * Optional. The IAM service account email associated with the trigger. The
      * service account represents the identity of the trigger.
@@ -2369,16 +2669,17 @@ public java.lang.String getServiceAccount() {
      * have the `roles/eventarc.eventReceiver` IAM role.
      * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for serviceAccount. */ - public com.google.protobuf.ByteString - getServiceAccountBytes() { + public com.google.protobuf.ByteString getServiceAccountBytes() { java.lang.Object ref = serviceAccount_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); serviceAccount_ = b; return b; } else { @@ -2386,6 +2687,8 @@ public java.lang.String getServiceAccount() { } } /** + * + * *
      * Optional. The IAM service account email associated with the trigger. The
      * service account represents the identity of the trigger.
@@ -2401,21 +2704,25 @@ public java.lang.String getServiceAccount() {
      * have the `roles/eventarc.eventReceiver` IAM role.
      * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @param value The serviceAccount to set. * @return This builder for chaining. */ - public Builder setServiceAccount( - java.lang.String value) { + public Builder setServiceAccount(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + serviceAccount_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The IAM service account email associated with the trigger. The
      * service account represents the identity of the trigger.
@@ -2431,16 +2738,21 @@ public Builder setServiceAccount(
      * have the `roles/eventarc.eventReceiver` IAM role.
      * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return This builder for chaining. */ public Builder clearServiceAccount() { - + serviceAccount_ = getDefaultInstance().getServiceAccount(); onChanged(); return this; } /** + * + * *
      * Optional. The IAM service account email associated with the trigger. The
      * service account represents the identity of the trigger.
@@ -2456,17 +2768,19 @@ public Builder clearServiceAccount() {
      * have the `roles/eventarc.eventReceiver` IAM role.
      * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @param value The bytes for serviceAccount to set. * @return This builder for chaining. */ - public Builder setServiceAccountBytes( - com.google.protobuf.ByteString value) { + public Builder setServiceAccountBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + serviceAccount_ = value; onChanged(); return this; @@ -2474,39 +2788,58 @@ public Builder setServiceAccountBytes( private com.google.cloud.eventarc.v1.Destination destination_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Destination, com.google.cloud.eventarc.v1.Destination.Builder, com.google.cloud.eventarc.v1.DestinationOrBuilder> destinationBuilder_; + com.google.cloud.eventarc.v1.Destination, + com.google.cloud.eventarc.v1.Destination.Builder, + com.google.cloud.eventarc.v1.DestinationOrBuilder> + destinationBuilder_; /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the destination field is set. */ public boolean hasDestination() { return destinationBuilder_ != null || destination_ != null; } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The destination. */ public com.google.cloud.eventarc.v1.Destination getDestination() { if (destinationBuilder_ == null) { - return destination_ == null ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() : destination_; + return destination_ == null + ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() + : destination_; } else { return destinationBuilder_.getMessage(); } } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setDestination(com.google.cloud.eventarc.v1.Destination value) { if (destinationBuilder_ == null) { @@ -2522,11 +2855,15 @@ public Builder setDestination(com.google.cloud.eventarc.v1.Destination value) { return this; } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setDestination( com.google.cloud.eventarc.v1.Destination.Builder builderForValue) { @@ -2540,17 +2877,23 @@ public Builder setDestination( return this; } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder mergeDestination(com.google.cloud.eventarc.v1.Destination value) { if (destinationBuilder_ == null) { if (destination_ != null) { destination_ = - com.google.cloud.eventarc.v1.Destination.newBuilder(destination_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.Destination.newBuilder(destination_) + .mergeFrom(value) + .buildPartial(); } else { destination_ = value; } @@ -2562,11 +2905,15 @@ public Builder mergeDestination(com.google.cloud.eventarc.v1.Destination value) return this; } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder clearDestination() { if (destinationBuilder_ == null) { @@ -2580,48 +2927,64 @@ public Builder clearDestination() { return this; } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.Destination.Builder getDestinationBuilder() { - + onChanged(); return getDestinationFieldBuilder().getBuilder(); } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder() { if (destinationBuilder_ != null) { return destinationBuilder_.getMessageOrBuilder(); } else { - return destination_ == null ? - com.google.cloud.eventarc.v1.Destination.getDefaultInstance() : destination_; + return destination_ == null + ? com.google.cloud.eventarc.v1.Destination.getDefaultInstance() + : destination_; } } /** + * + * *
      * Required. Destination specifies where the events should be sent to.
      * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Destination, com.google.cloud.eventarc.v1.Destination.Builder, com.google.cloud.eventarc.v1.DestinationOrBuilder> + com.google.cloud.eventarc.v1.Destination, + com.google.cloud.eventarc.v1.Destination.Builder, + com.google.cloud.eventarc.v1.DestinationOrBuilder> getDestinationFieldBuilder() { if (destinationBuilder_ == null) { - destinationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Destination, com.google.cloud.eventarc.v1.Destination.Builder, com.google.cloud.eventarc.v1.DestinationOrBuilder>( - getDestination(), - getParentForChildren(), - isClean()); + destinationBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Destination, + com.google.cloud.eventarc.v1.Destination.Builder, + com.google.cloud.eventarc.v1.DestinationOrBuilder>( + getDestination(), getParentForChildren(), isClean()); destination_ = null; } return destinationBuilder_; @@ -2629,8 +2992,13 @@ public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder private com.google.cloud.eventarc.v1.Transport transport_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Transport, com.google.cloud.eventarc.v1.Transport.Builder, com.google.cloud.eventarc.v1.TransportOrBuilder> transportBuilder_; + com.google.cloud.eventarc.v1.Transport, + com.google.cloud.eventarc.v1.Transport.Builder, + com.google.cloud.eventarc.v1.TransportOrBuilder> + transportBuilder_; /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2638,13 +3006,18 @@ public com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * * @return Whether the transport field is set. */ public boolean hasTransport() { return transportBuilder_ != null || transport_ != null; } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2652,17 +3025,24 @@ public boolean hasTransport() {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * * @return The transport. */ public com.google.cloud.eventarc.v1.Transport getTransport() { if (transportBuilder_ == null) { - return transport_ == null ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() : transport_; + return transport_ == null + ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() + : transport_; } else { return transportBuilder_.getMessage(); } } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2670,7 +3050,9 @@ public com.google.cloud.eventarc.v1.Transport getTransport() {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ public Builder setTransport(com.google.cloud.eventarc.v1.Transport value) { if (transportBuilder_ == null) { @@ -2686,6 +3068,8 @@ public Builder setTransport(com.google.cloud.eventarc.v1.Transport value) { return this; } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2693,10 +3077,11 @@ public Builder setTransport(com.google.cloud.eventarc.v1.Transport value) {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ - public Builder setTransport( - com.google.cloud.eventarc.v1.Transport.Builder builderForValue) { + public Builder setTransport(com.google.cloud.eventarc.v1.Transport.Builder builderForValue) { if (transportBuilder_ == null) { transport_ = builderForValue.build(); onChanged(); @@ -2707,6 +3092,8 @@ public Builder setTransport( return this; } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2714,13 +3101,17 @@ public Builder setTransport(
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ public Builder mergeTransport(com.google.cloud.eventarc.v1.Transport value) { if (transportBuilder_ == null) { if (transport_ != null) { transport_ = - com.google.cloud.eventarc.v1.Transport.newBuilder(transport_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.Transport.newBuilder(transport_) + .mergeFrom(value) + .buildPartial(); } else { transport_ = value; } @@ -2732,6 +3123,8 @@ public Builder mergeTransport(com.google.cloud.eventarc.v1.Transport value) { return this; } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2739,7 +3132,9 @@ public Builder mergeTransport(com.google.cloud.eventarc.v1.Transport value) {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ public Builder clearTransport() { if (transportBuilder_ == null) { @@ -2753,6 +3148,8 @@ public Builder clearTransport() { return this; } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2760,14 +3157,18 @@ public Builder clearTransport() {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ public com.google.cloud.eventarc.v1.Transport.Builder getTransportBuilder() { - + onChanged(); return getTransportFieldBuilder().getBuilder(); } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2775,17 +3176,22 @@ public com.google.cloud.eventarc.v1.Transport.Builder getTransportBuilder() {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ public com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder() { if (transportBuilder_ != null) { return transportBuilder_.getMessageOrBuilder(); } else { - return transport_ == null ? - com.google.cloud.eventarc.v1.Transport.getDefaultInstance() : transport_; + return transport_ == null + ? com.google.cloud.eventarc.v1.Transport.getDefaultInstance() + : transport_; } } /** + * + * *
      * Optional. To deliver messages, Eventarc might use other GCP
      * products as a transport intermediary. This field contains a reference to
@@ -2793,38 +3199,42 @@ public com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder() {
      * purposes.
      * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Transport, com.google.cloud.eventarc.v1.Transport.Builder, com.google.cloud.eventarc.v1.TransportOrBuilder> + com.google.cloud.eventarc.v1.Transport, + com.google.cloud.eventarc.v1.Transport.Builder, + com.google.cloud.eventarc.v1.TransportOrBuilder> getTransportFieldBuilder() { if (transportBuilder_ == null) { - transportBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Transport, com.google.cloud.eventarc.v1.Transport.Builder, com.google.cloud.eventarc.v1.TransportOrBuilder>( - getTransport(), - getParentForChildren(), - isClean()); + transportBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Transport, + com.google.cloud.eventarc.v1.Transport.Builder, + com.google.cloud.eventarc.v1.TransportOrBuilder>( + getTransport(), getParentForChildren(), isClean()); transport_ = null; } return transportBuilder_; } - private com.google.protobuf.MapField< - java.lang.String, java.lang.String> labels_; - private com.google.protobuf.MapField - internalGetLabels() { + private com.google.protobuf.MapField labels_; + + private com.google.protobuf.MapField internalGetLabels() { if (labels_ == null) { - return com.google.protobuf.MapField.emptyMapField( - LabelsDefaultEntryHolder.defaultEntry); + return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); } return labels_; } + private com.google.protobuf.MapField - internalGetMutableLabels() { - onChanged();; + internalGetMutableLabels() { + onChanged(); + ; if (labels_ == null) { - labels_ = com.google.protobuf.MapField.newMapField( - LabelsDefaultEntryHolder.defaultEntry); + labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); } if (!labels_.isMutable()) { labels_ = labels_.copy(); @@ -2836,28 +3246,30 @@ public int getLabelsCount() { return internalGetLabels().getMap().size(); } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - @java.lang.Override - public boolean containsLabels( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } + public boolean containsLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } return internalGetLabels().getMap().containsKey(key); } - /** - * Use {@link #getLabelsMap()} instead. - */ + /** Use {@link #getLabelsMap()} instead. */ @java.lang.Override @java.lang.Deprecated public java.util.Map getLabels() { return getLabelsMap(); } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
@@ -2865,11 +3277,12 @@ public java.util.Map getLabels() { * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override - public java.util.Map getLabelsMap() { return internalGetLabels().getMap(); } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
@@ -2877,16 +3290,17 @@ public java.util.Map getLabelsMap() { * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override - public java.lang.String getLabelsOrDefault( - java.lang.String key, - java.lang.String defaultValue) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetLabels().getMap(); + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
@@ -2894,12 +3308,11 @@ public java.lang.String getLabelsOrDefault( * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ @java.lang.Override - - public java.lang.String getLabelsOrThrow( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - java.util.Map map = - internalGetLabels().getMap(); + public java.lang.String getLabelsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetLabels().getMap(); if (!map.containsKey(key)) { throw new java.lang.IllegalArgumentException(); } @@ -2907,69 +3320,68 @@ public java.lang.String getLabelsOrThrow( } public Builder clearLabels() { - internalGetMutableLabels().getMutableMap() - .clear(); + internalGetMutableLabels().getMutableMap().clear(); return this; } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - - public Builder removeLabels( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - internalGetMutableLabels().getMutableMap() - .remove(key); + public Builder removeLabels(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableLabels().getMutableMap().remove(key); return this; } - /** - * Use alternate mutation accessors instead. - */ + /** Use alternate mutation accessors instead. */ @java.lang.Deprecated - public java.util.Map - getMutableLabels() { + public java.util.Map getMutableLabels() { return internalGetMutableLabels().getMutableMap(); } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - public Builder putLabels( - java.lang.String key, - java.lang.String value) { - if (key == null) { throw new NullPointerException("map key"); } + public Builder putLabels(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } if (value == null) { - throw new NullPointerException("map value"); -} + throw new NullPointerException("map value"); + } - internalGetMutableLabels().getMutableMap() - .put(key, value); + internalGetMutableLabels().getMutableMap().put(key, value); return this; } /** + * + * *
      * Optional. User labels attached to the triggers that can be used to group resources.
      * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - - public Builder putAllLabels( - java.util.Map values) { - internalGetMutableLabels().getMutableMap() - .putAll(values); + public Builder putAllLabels(java.util.Map values) { + internalGetMutableLabels().getMutableMap().putAll(values); return this; } private java.lang.Object channel_ = ""; /** + * + * *
      * Optional. The name of the channel associated with the trigger in
      * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -2977,13 +3389,13 @@ public Builder putAllLabels(
      * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The channel. */ public java.lang.String getChannel() { java.lang.Object ref = channel_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); channel_ = s; return s; @@ -2992,6 +3404,8 @@ public java.lang.String getChannel() { } } /** + * + * *
      * Optional. The name of the channel associated with the trigger in
      * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -2999,15 +3413,14 @@ public java.lang.String getChannel() {
      * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for channel. */ - public com.google.protobuf.ByteString - getChannelBytes() { + public com.google.protobuf.ByteString getChannelBytes() { java.lang.Object ref = channel_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); channel_ = b; return b; } else { @@ -3015,6 +3428,8 @@ public java.lang.String getChannel() { } } /** + * + * *
      * Optional. The name of the channel associated with the trigger in
      * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -3022,20 +3437,22 @@ public java.lang.String getChannel() {
      * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The channel to set. * @return This builder for chaining. */ - public Builder setChannel( - java.lang.String value) { + public Builder setChannel(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + channel_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The name of the channel associated with the trigger in
      * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -3043,15 +3460,18 @@ public Builder setChannel(
      * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return This builder for chaining. */ public Builder clearChannel() { - + channel_ = getDefaultInstance().getChannel(); onChanged(); return this; } /** + * + * *
      * Optional. The name of the channel associated with the trigger in
      * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -3059,37 +3479,43 @@ public Builder clearChannel() {
      * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @param value The bytes for channel to set. * @return This builder for chaining. */ - public Builder setChannelBytes( - com.google.protobuf.ByteString value) { + public Builder setChannelBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + channel_ = value; onChanged(); return this; } private com.google.protobuf.MapField< - java.lang.String, com.google.cloud.eventarc.v1.StateCondition> conditions_; - private com.google.protobuf.MapField - internalGetConditions() { + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + conditions_; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + internalGetConditions() { if (conditions_ == null) { return com.google.protobuf.MapField.emptyMapField( ConditionsDefaultEntryHolder.defaultEntry); } return conditions_; } - private com.google.protobuf.MapField - internalGetMutableConditions() { - onChanged();; + + private com.google.protobuf.MapField< + java.lang.String, com.google.cloud.eventarc.v1.StateCondition> + internalGetMutableConditions() { + onChanged(); + ; if (conditions_ == null) { - conditions_ = com.google.protobuf.MapField.newMapField( - ConditionsDefaultEntryHolder.defaultEntry); + conditions_ = + com.google.protobuf.MapField.newMapField(ConditionsDefaultEntryHolder.defaultEntry); } if (!conditions_.isMutable()) { conditions_ = conditions_.copy(); @@ -3101,68 +3527,83 @@ public int getConditionsCount() { return internalGetConditions().getMap().size(); } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - @java.lang.Override - public boolean containsConditions( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } + public boolean containsConditions(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } return internalGetConditions().getMap().containsKey(key); } - /** - * Use {@link #getConditionsMap()} instead. - */ + /** Use {@link #getConditionsMap()} instead. */ @java.lang.Override @java.lang.Deprecated - public java.util.Map getConditions() { + public java.util.Map + getConditions() { return getConditionsMap(); } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - - public java.util.Map getConditionsMap() { + public java.util.Map + getConditionsMap() { return internalGetConditions().getMap(); } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - public com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( - java.lang.String key, - com.google.cloud.eventarc.v1.StateCondition defaultValue) { - if (key == null) { throw new NullPointerException("map key"); } + java.lang.String key, com.google.cloud.eventarc.v1.StateCondition defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } java.util.Map map = internalGetConditions().getMap(); return map.containsKey(key) ? map.get(key) : defaultValue; } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override - - public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } + public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } java.util.Map map = internalGetConditions().getMap(); if (!map.containsKey(key)) { @@ -3172,69 +3613,77 @@ public com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow( } public Builder clearConditions() { - internalGetMutableConditions().getMutableMap() - .clear(); + internalGetMutableConditions().getMutableMap().clear(); return this; } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - - public Builder removeConditions( - java.lang.String key) { - if (key == null) { throw new NullPointerException("map key"); } - internalGetMutableConditions().getMutableMap() - .remove(key); + public Builder removeConditions(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableConditions().getMutableMap().remove(key); return this; } - /** - * Use alternate mutation accessors instead. - */ + /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map - getMutableConditions() { + getMutableConditions() { return internalGetMutableConditions().getMutableMap(); } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder putConditions( - java.lang.String key, - com.google.cloud.eventarc.v1.StateCondition value) { - if (key == null) { throw new NullPointerException("map key"); } + java.lang.String key, com.google.cloud.eventarc.v1.StateCondition value) { + if (key == null) { + throw new NullPointerException("map key"); + } if (value == null) { - throw new NullPointerException("map value"); -} + throw new NullPointerException("map value"); + } - internalGetMutableConditions().getMutableMap() - .put(key, value); + internalGetMutableConditions().getMutableMap().put(key, value); return this; } /** + * + * *
      * Output only. The reason(s) why a trigger is in FAILED state.
      * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - public Builder putAllConditions( java.util.Map values) { - internalGetMutableConditions().getMutableMap() - .putAll(values); + internalGetMutableConditions().getMutableMap().putAll(values); return this; } private java.lang.Object etag_ = ""; /** + * + * *
      * Output only. This checksum is computed by the server based on the value of other
      * fields, and might be sent only on create requests to ensure that the
@@ -3242,13 +3691,13 @@ public Builder putAllConditions(
      * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The etag. */ public java.lang.String getEtag() { java.lang.Object ref = etag_; if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); etag_ = s; return s; @@ -3257,6 +3706,8 @@ public java.lang.String getEtag() { } } /** + * + * *
      * Output only. This checksum is computed by the server based on the value of other
      * fields, and might be sent only on create requests to ensure that the
@@ -3264,15 +3715,14 @@ public java.lang.String getEtag() {
      * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for etag. */ - public com.google.protobuf.ByteString - getEtagBytes() { + public com.google.protobuf.ByteString getEtagBytes() { java.lang.Object ref = etag_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); etag_ = b; return b; } else { @@ -3280,6 +3730,8 @@ public java.lang.String getEtag() { } } /** + * + * *
      * Output only. This checksum is computed by the server based on the value of other
      * fields, and might be sent only on create requests to ensure that the
@@ -3287,20 +3739,22 @@ public java.lang.String getEtag() {
      * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The etag to set. * @return This builder for chaining. */ - public Builder setEtag( - java.lang.String value) { + public Builder setEtag(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + etag_ = value; onChanged(); return this; } /** + * + * *
      * Output only. This checksum is computed by the server based on the value of other
      * fields, and might be sent only on create requests to ensure that the
@@ -3308,15 +3762,18 @@ public Builder setEtag(
      * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return This builder for chaining. */ public Builder clearEtag() { - + etag_ = getDefaultInstance().getEtag(); onChanged(); return this; } /** + * + * *
      * Output only. This checksum is computed by the server based on the value of other
      * fields, and might be sent only on create requests to ensure that the
@@ -3324,23 +3781,23 @@ public Builder clearEtag() {
      * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @param value The bytes for etag to set. * @return This builder for chaining. */ - public Builder setEtagBytes( - com.google.protobuf.ByteString value) { + public Builder setEtagBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + etag_ = value; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -3350,12 +3807,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.Trigger) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.Trigger) private static final com.google.cloud.eventarc.v1.Trigger DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.Trigger(); } @@ -3364,27 +3821,27 @@ public static com.google.cloud.eventarc.v1.Trigger getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Trigger parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Trigger parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -3399,6 +3856,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.Trigger getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java new file mode 100644 index 000000000000..6b8fd06b3b4b --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerName.java @@ -0,0 +1,223 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1; + +import com.google.api.pathtemplate.PathTemplate; +import com.google.api.resourcenames.ResourceName; +import com.google.common.base.Preconditions; +import com.google.common.collect.ImmutableMap; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class TriggerName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_TRIGGER = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/triggers/{trigger}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String trigger; + + @Deprecated + protected TriggerName() { + project = null; + location = null; + trigger = null; + } + + private TriggerName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + trigger = Preconditions.checkNotNull(builder.getTrigger()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getTrigger() { + return trigger; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static TriggerName of(String project, String location, String trigger) { + return newBuilder().setProject(project).setLocation(location).setTrigger(trigger).build(); + } + + public static String format(String project, String location, String trigger) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setTrigger(trigger) + .build() + .toString(); + } + + public static TriggerName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_TRIGGER.validatedMatch( + formattedString, "TriggerName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("trigger")); + } + + public static List parseList(List formattedStrings) { + List list = new ArrayList<>(formattedStrings.size()); + for (String formattedString : formattedStrings) { + list.add(parse(formattedString)); + } + return list; + } + + public static List toStringList(List values) { + List list = new ArrayList<>(values.size()); + for (TriggerName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_TRIGGER.matches(formattedString); + } + + @Override + public Map getFieldValuesMap() { + if (fieldValuesMap == null) { + synchronized (this) { + if (fieldValuesMap == null) { + ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); + if (project != null) { + fieldMapBuilder.put("project", project); + } + if (location != null) { + fieldMapBuilder.put("location", location); + } + if (trigger != null) { + fieldMapBuilder.put("trigger", trigger); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_TRIGGER.instantiate( + "project", project, "location", location, "trigger", trigger); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + TriggerName that = ((TriggerName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.trigger, that.trigger); + } + return false; + } + + @Override + public int hashCode() { + int h = 1; + h *= 1000003; + h ^= Objects.hashCode(project); + h *= 1000003; + h ^= Objects.hashCode(location); + h *= 1000003; + h ^= Objects.hashCode(trigger); + return h; + } + + /** Builder for projects/{project}/locations/{location}/triggers/{trigger}. */ + public static class Builder { + private String project; + private String location; + private String trigger; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getTrigger() { + return trigger; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setTrigger(String trigger) { + this.trigger = trigger; + return this; + } + + private Builder(TriggerName triggerName) { + this.project = triggerName.project; + this.location = triggerName.location; + this.trigger = triggerName.trigger; + } + + public TriggerName build() { + return new TriggerName(this); + } + } +} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java similarity index 71% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java index 3b91484d4bed..189a6ee15fe2 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerOrBuilder.java @@ -3,11 +3,14 @@ package com.google.cloud.eventarc.v1; -public interface TriggerOrBuilder extends +public interface TriggerOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.Trigger) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Required. The resource name of the trigger. Must be unique within the location of the
    * project and must be in
@@ -15,10 +18,13 @@ public interface TriggerOrBuilder extends
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The name. */ java.lang.String getName(); /** + * + * *
    * Required. The resource name of the trigger. Must be unique within the location of the
    * project and must be in
@@ -26,137 +32,184 @@ public interface TriggerOrBuilder extends
    * 
* * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * * @return The bytes for name. */ - com.google.protobuf.ByteString - getNameBytes(); + com.google.protobuf.ByteString getNameBytes(); /** + * + * *
    * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
    * string and guaranteed to remain unchanged until the resource is deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The uid. */ java.lang.String getUid(); /** + * + * *
    * Output only. Server-assigned unique identifier for the trigger. The value is a UUID4
    * string and guaranteed to remain unchanged until the resource is deleted.
    * 
* * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for uid. */ - com.google.protobuf.ByteString - getUidBytes(); + com.google.protobuf.ByteString getUidBytes(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the createTime field is set. */ boolean hasCreateTime(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The createTime. */ com.google.protobuf.Timestamp getCreateTime(); /** + * + * *
    * Output only. The creation time.
    * 
* - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return Whether the updateTime field is set. */ boolean hasUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * * @return The updateTime. */ com.google.protobuf.Timestamp getUpdateTime(); /** + * + * *
    * Output only. The last-modified time.
    * 
* - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - java.util.List - getEventFiltersList(); + java.util.List getEventFiltersList(); /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ com.google.cloud.eventarc.v1.EventFilter getEventFilters(int index); /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ int getEventFiltersCount(); /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - java.util.List + java.util.List getEventFiltersOrBuilderList(); /** + * + * *
    * Required. Unordered list. The list of filters that applies to event attributes. Only events that
    * match all the provided filters are sent to the destination.
    * 
* - * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.eventarc.v1.EventFilter event_filters = 8 [(.google.api.field_behavior) = UNORDERED_LIST, (.google.api.field_behavior) = REQUIRED]; + * */ - com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder( - int index); + com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(int index); /** + * + * *
    * Optional. The IAM service account email associated with the trigger. The
    * service account represents the identity of the trigger.
@@ -172,11 +225,16 @@ com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(
    * have the `roles/eventarc.eventReceiver` IAM role.
    * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The serviceAccount. */ java.lang.String getServiceAccount(); /** + * + * *
    * Optional. The IAM service account email associated with the trigger. The
    * service account represents the identity of the trigger.
@@ -192,40 +250,58 @@ com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(
    * have the `roles/eventarc.eventReceiver` IAM role.
    * 
* - * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * string service_account = 9 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * * @return The bytes for serviceAccount. */ - com.google.protobuf.ByteString - getServiceAccountBytes(); + com.google.protobuf.ByteString getServiceAccountBytes(); /** + * + * *
    * Required. Destination specifies where the events should be sent to.
    * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the destination field is set. */ boolean hasDestination(); /** + * + * *
    * Required. Destination specifies where the events should be sent to.
    * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The destination. */ com.google.cloud.eventarc.v1.Destination getDestination(); /** + * + * *
    * Required. Destination specifies where the events should be sent to.
    * 
* - * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.Destination destination = 10 [(.google.api.field_behavior) = REQUIRED]; + * */ com.google.cloud.eventarc.v1.DestinationOrBuilder getDestinationOrBuilder(); /** + * + * *
    * Optional. To deliver messages, Eventarc might use other GCP
    * products as a transport intermediary. This field contains a reference to
@@ -233,11 +309,16 @@ com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(
    * purposes.
    * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * * @return Whether the transport field is set. */ boolean hasTransport(); /** + * + * *
    * Optional. To deliver messages, Eventarc might use other GCP
    * products as a transport intermediary. This field contains a reference to
@@ -245,11 +326,16 @@ com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(
    * purposes.
    * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * * @return The transport. */ com.google.cloud.eventarc.v1.Transport getTransport(); /** + * + * *
    * Optional. To deliver messages, Eventarc might use other GCP
    * products as a transport intermediary. This field contains a reference to
@@ -257,11 +343,15 @@ com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder(
    * purposes.
    * 
* - * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * + * .google.cloud.eventarc.v1.Transport transport = 11 [(.google.api.field_behavior) = OPTIONAL]; + * */ com.google.cloud.eventarc.v1.TransportOrBuilder getTransportOrBuilder(); /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
@@ -270,30 +360,31 @@ com.google.cloud.eventarc.v1.EventFilterOrBuilder getEventFiltersOrBuilder( */ int getLabelsCount(); /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - boolean containsLabels( - java.lang.String key); - /** - * Use {@link #getLabelsMap()} instead. - */ + boolean containsLabels(java.lang.String key); + /** Use {@link #getLabelsMap()} instead. */ @java.lang.Deprecated - java.util.Map - getLabels(); + java.util.Map getLabels(); /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - java.util.Map - getLabelsMap(); + java.util.Map getLabelsMap(); /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
@@ -302,22 +393,24 @@ boolean containsLabels( */ /* nullable */ -java.lang.String getLabelsOrDefault( + java.lang.String getLabelsOrDefault( java.lang.String key, /* nullable */ -java.lang.String defaultValue); + java.lang.String defaultValue); /** + * + * *
    * Optional. User labels attached to the triggers that can be used to group resources.
    * 
* * map<string, string> labels = 12 [(.google.api.field_behavior) = OPTIONAL]; */ - - java.lang.String getLabelsOrThrow( - java.lang.String key); + java.lang.String getLabelsOrThrow(java.lang.String key); /** + * + * *
    * Optional. The name of the channel associated with the trigger in
    * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -325,10 +418,13 @@ java.lang.String getLabelsOrThrow(
    * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The channel. */ java.lang.String getChannel(); /** + * + * *
    * Optional. The name of the channel associated with the trigger in
    * `projects/{project}/locations/{location}/channels/{channel}` format.
@@ -336,68 +432,83 @@ java.lang.String getLabelsOrThrow(
    * 
* * string channel = 13 [(.google.api.field_behavior) = OPTIONAL]; + * * @return The bytes for channel. */ - com.google.protobuf.ByteString - getChannelBytes(); + com.google.protobuf.ByteString getChannelBytes(); /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ int getConditionsCount(); /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - boolean containsConditions( - java.lang.String key); - /** - * Use {@link #getConditionsMap()} instead. + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ + boolean containsConditions(java.lang.String key); + /** Use {@link #getConditionsMap()} instead. */ @java.lang.Deprecated - java.util.Map - getConditions(); + java.util.Map getConditions(); /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - java.util.Map - getConditionsMap(); + java.util.Map getConditionsMap(); /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ /* nullable */ -com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( + com.google.cloud.eventarc.v1.StateCondition getConditionsOrDefault( java.lang.String key, /* nullable */ -com.google.cloud.eventarc.v1.StateCondition defaultValue); + com.google.cloud.eventarc.v1.StateCondition defaultValue); /** + * + * *
    * Output only. The reason(s) why a trigger is in FAILED state.
    * 
* - * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * map<string, .google.cloud.eventarc.v1.StateCondition> conditions = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ - - com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow( - java.lang.String key); + com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(java.lang.String key); /** + * + * *
    * Output only. This checksum is computed by the server based on the value of other
    * fields, and might be sent only on create requests to ensure that the
@@ -405,10 +516,13 @@ com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(
    * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The etag. */ java.lang.String getEtag(); /** + * + * *
    * Output only. This checksum is computed by the server based on the value of other
    * fields, and might be sent only on create requests to ensure that the
@@ -416,8 +530,8 @@ com.google.cloud.eventarc.v1.StateCondition getConditionsOrThrow(
    * 
* * string etag = 99 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * @return The bytes for etag. */ - com.google.protobuf.ByteString - getEtagBytes(); + com.google.protobuf.ByteString getEtagBytes(); } diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java new file mode 100644 index 000000000000..dd10b659f7c9 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java @@ -0,0 +1,238 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/eventarc/v1/trigger.proto + +package com.google.cloud.eventarc.v1; + +public final class TriggerProto { + private TriggerProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Trigger_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Destination_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Transport_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_GKE_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n&google/cloud/eventarc/v1/trigger.proto" + + "\022\030google.cloud.eventarc.v1\032\037google/api/f" + + "ield_behavior.proto\032\031google/api/resource" + + ".proto\032\037google/protobuf/timestamp.proto\032" + + "\025google/rpc/code.proto\"\334\006\n\007Trigger\022\021\n\004na" + + "me\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 \001(\tB\003\340A\003\0224\n\013creat" + + "e_time\030\005 \001(\0132\032.google.protobuf.Timestamp" + + "B\003\340A\003\0224\n\013update_time\030\006 \001(\0132\032.google.prot" + + "obuf.TimestampB\003\340A\003\022D\n\revent_filters\030\010 \003" + + "(\0132%.google.cloud.eventarc.v1.EventFilte" + + "rB\006\340A\006\340A\002\022B\n\017service_account\030\t \001(\tB)\340A\001\372" + + "A#\n!iam.googleapis.com/ServiceAccount\022?\n" + + "\013destination\030\n \001(\0132%.google.cloud.eventa" + + "rc.v1.DestinationB\003\340A\002\022;\n\ttransport\030\013 \001(" + + "\0132#.google.cloud.eventarc.v1.TransportB\003" + + "\340A\001\022B\n\006labels\030\014 \003(\0132-.google.cloud.event" + + "arc.v1.Trigger.LabelsEntryB\003\340A\001\022\024\n\007chann" + + "el\030\r \001(\tB\003\340A\001\022J\n\nconditions\030\017 \003(\01321.goog" + + "le.cloud.eventarc.v1.Trigger.ConditionsE" + + "ntryB\003\340A\003\022\021\n\004etag\030c \001(\tB\003\340A\003\032-\n\013LabelsEn" + + "try\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\032[\n\017C" + + "onditionsEntry\022\013\n\003key\030\001 \001(\t\0227\n\005value\030\002 \001" + + "(\0132(.google.cloud.eventarc.v1.StateCondi" + + "tion:\0028\001:s\352Ap\n\037eventarc.googleapis.com/T" + + "rigger\022:projects/{project}/locations/{lo" + + "cation}/triggers/{trigger}*\010triggers2\007tr" + + "igger\"P\n\013EventFilter\022\026\n\tattribute\030\001 \001(\tB" + + "\003\340A\002\022\022\n\005value\030\002 \001(\tB\003\340A\002\022\025\n\010operator\030\003 \001" + + "(\tB\003\340A\001\"A\n\016StateCondition\022\036\n\004code\030\001 \001(\0162" + + "\020.google.rpc.Code\022\017\n\007message\030\002 \001(\t\"\212\002\n\013D" + + "estination\0227\n\tcloud_run\030\001 \001(\0132\".google.c" + + "loud.eventarc.v1.CloudRunH\000\022J\n\016cloud_fun" + + "ction\030\002 \001(\tB0\372A-\n+cloudfunctions.googlea" + + "pis.com/CloudFunctionH\000\022,\n\003gke\030\003 \001(\0132\035.g" + + "oogle.cloud.eventarc.v1.GKEH\000\022:\n\010workflo" + + "w\030\004 \001(\tB&\372A#\n!workflows.googleapis.com/W" + + "orkflowH\000B\014\n\ndescriptor\"O\n\tTransport\0222\n\006" + + "pubsub\030\001 \001(\0132 .google.cloud.eventarc.v1." + + "PubsubH\000B\016\n\014intermediary\"g\n\010CloudRun\0223\n\007" + + "service\030\001 \001(\tB\"\340A\002\372A\034\n\032run.googleapis.co" + + "m/Service\022\021\n\004path\030\002 \001(\tB\003\340A\001\022\023\n\006region\030\003" + + " \001(\tB\003\340A\002\"s\n\003GKE\022\024\n\007cluster\030\001 \001(\tB\003\340A\002\022\025" + + "\n\010location\030\002 \001(\tB\003\340A\002\022\026\n\tnamespace\030\003 \001(\t" + + "B\003\340A\002\022\024\n\007service\030\004 \001(\tB\003\340A\002\022\021\n\004path\030\005 \001(" + + "\tB\003\340A\001\"7\n\006Pubsub\022\022\n\005topic\030\001 \001(\tB\003\340A\001\022\031\n\014" + + "subscription\030\002 \001(\tB\003\340A\003B\300\003\n\034com.google.c" + + "loud.eventarc.v1B\014TriggerProtoP\001Z@google" + + ".golang.org/genproto/googleapis/cloud/ev" + + "entarc/v1;eventarc\352Ak\n+cloudfunctions.go" + + "ogleapis.com/CloudFunction\022 * The request message for the UpdateChannel method. *
* * Protobuf type {@code google.cloud.eventarc.v1.UpdateChannelRequest} */ -public final class UpdateChannelRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class UpdateChannelRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.UpdateChannelRequest) UpdateChannelRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use UpdateChannelRequest.newBuilder() to construct. private UpdateChannelRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private UpdateChannelRequest() { - } + + private UpdateChannelRequest() {} @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new UpdateChannelRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.UpdateChannelRequest.class, com.google.cloud.eventarc.v1.UpdateChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.UpdateChannelRequest.class, + com.google.cloud.eventarc.v1.UpdateChannelRequest.Builder.class); } public static final int CHANNEL_FIELD_NUMBER = 1; private com.google.cloud.eventarc.v1.Channel channel_; /** + * + * *
    * The channel to be updated.
    * 
* * .google.cloud.eventarc.v1.Channel channel = 1; + * * @return Whether the channel field is set. */ @java.lang.Override @@ -62,11 +68,14 @@ public boolean hasChannel() { return channel_ != null; } /** + * + * *
    * The channel to be updated.
    * 
* * .google.cloud.eventarc.v1.Channel channel = 1; + * * @return The channel. */ @java.lang.Override @@ -74,6 +83,8 @@ public com.google.cloud.eventarc.v1.Channel getChannel() { return channel_ == null ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; } /** + * + * *
    * The channel to be updated.
    * 
@@ -88,6 +99,8 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { public static final int UPDATE_MASK_FIELD_NUMBER = 2; private com.google.protobuf.FieldMask updateMask_; /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -95,6 +108,7 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() {
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ @java.lang.Override @@ -102,6 +116,8 @@ public boolean hasUpdateMask() { return updateMask_ != null; } /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -109,6 +125,7 @@ public boolean hasUpdateMask() {
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ @java.lang.Override @@ -116,6 +133,8 @@ public com.google.protobuf.FieldMask getUpdateMask() { return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; } /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -132,12 +151,15 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
   public static final int VALIDATE_ONLY_FIELD_NUMBER = 3;
   private boolean validateOnly_;
   /**
+   *
+   *
    * 
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -146,6 +168,7 @@ public boolean getValidateOnly() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -157,8 +180,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (channel_ != null) { output.writeMessage(1, getChannel()); } @@ -178,16 +200,13 @@ public int getSerializedSize() { size = 0; if (channel_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getChannel()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getChannel()); } if (updateMask_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getUpdateMask()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); } if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(3, validateOnly_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, validateOnly_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -197,25 +216,23 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.UpdateChannelRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.UpdateChannelRequest other = (com.google.cloud.eventarc.v1.UpdateChannelRequest) obj; + com.google.cloud.eventarc.v1.UpdateChannelRequest other = + (com.google.cloud.eventarc.v1.UpdateChannelRequest) obj; if (hasChannel() != other.hasChannel()) return false; if (hasChannel()) { - if (!getChannel() - .equals(other.getChannel())) return false; + if (!getChannel().equals(other.getChannel())) return false; } if (hasUpdateMask() != other.hasUpdateMask()) return false; if (hasUpdateMask()) { - if (!getUpdateMask() - .equals(other.getUpdateMask())) return false; + if (!getUpdateMask().equals(other.getUpdateMask())) return false; } - if (getValidateOnly() - != other.getValidateOnly()) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -236,137 +253,142 @@ public int hashCode() { hash = (53 * hash) + getUpdateMask().hashCode(); } hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getValidateOnly()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.UpdateChannelRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.UpdateChannelRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the UpdateChannel method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.UpdateChannelRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.UpdateChannelRequest) com.google.cloud.eventarc.v1.UpdateChannelRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.UpdateChannelRequest.class, com.google.cloud.eventarc.v1.UpdateChannelRequest.Builder.class); + com.google.cloud.eventarc.v1.UpdateChannelRequest.class, + com.google.cloud.eventarc.v1.UpdateChannelRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.UpdateChannelRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -388,9 +410,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor; } @java.lang.Override @@ -409,7 +431,8 @@ public com.google.cloud.eventarc.v1.UpdateChannelRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.UpdateChannelRequest buildPartial() { - com.google.cloud.eventarc.v1.UpdateChannelRequest result = new com.google.cloud.eventarc.v1.UpdateChannelRequest(this); + com.google.cloud.eventarc.v1.UpdateChannelRequest result = + new com.google.cloud.eventarc.v1.UpdateChannelRequest(this); if (channelBuilder_ == null) { result.channel_ = channel_; } else { @@ -429,38 +452,39 @@ public com.google.cloud.eventarc.v1.UpdateChannelRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.UpdateChannelRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.UpdateChannelRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.UpdateChannelRequest) other); } else { super.mergeFrom(other); return this; @@ -468,7 +492,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.UpdateChannelRequest other) { - if (other == com.google.cloud.eventarc.v1.UpdateChannelRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.UpdateChannelRequest.getDefaultInstance()) + return this; if (other.hasChannel()) { mergeChannel(other.getChannel()); } @@ -504,31 +529,31 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - input.readMessage( - getChannelFieldBuilder().getBuilder(), - extensionRegistry); + case 10: + { + input.readMessage(getChannelFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 10 - case 18: { - input.readMessage( - getUpdateMaskFieldBuilder().getBuilder(), - extensionRegistry); + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 18 - case 24: { - validateOnly_ = input.readBool(); + break; + } // case 18 + case 24: + { + validateOnly_ = input.readBool(); - break; - } // case 24 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -541,34 +566,47 @@ public Builder mergeFrom( private com.google.cloud.eventarc.v1.Channel channel_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder> channelBuilder_; + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> + channelBuilder_; /** + * + * *
      * The channel to be updated.
      * 
* * .google.cloud.eventarc.v1.Channel channel = 1; + * * @return Whether the channel field is set. */ public boolean hasChannel() { return channelBuilder_ != null || channel_ != null; } /** + * + * *
      * The channel to be updated.
      * 
* * .google.cloud.eventarc.v1.Channel channel = 1; + * * @return The channel. */ public com.google.cloud.eventarc.v1.Channel getChannel() { if (channelBuilder_ == null) { - return channel_ == null ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; } else { return channelBuilder_.getMessage(); } } /** + * + * *
      * The channel to be updated.
      * 
@@ -589,14 +627,15 @@ public Builder setChannel(com.google.cloud.eventarc.v1.Channel value) { return this; } /** + * + * *
      * The channel to be updated.
      * 
* * .google.cloud.eventarc.v1.Channel channel = 1; */ - public Builder setChannel( - com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { + public Builder setChannel(com.google.cloud.eventarc.v1.Channel.Builder builderForValue) { if (channelBuilder_ == null) { channel_ = builderForValue.build(); onChanged(); @@ -607,6 +646,8 @@ public Builder setChannel( return this; } /** + * + * *
      * The channel to be updated.
      * 
@@ -617,7 +658,9 @@ public Builder mergeChannel(com.google.cloud.eventarc.v1.Channel value) { if (channelBuilder_ == null) { if (channel_ != null) { channel_ = - com.google.cloud.eventarc.v1.Channel.newBuilder(channel_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.Channel.newBuilder(channel_) + .mergeFrom(value) + .buildPartial(); } else { channel_ = value; } @@ -629,6 +672,8 @@ public Builder mergeChannel(com.google.cloud.eventarc.v1.Channel value) { return this; } /** + * + * *
      * The channel to be updated.
      * 
@@ -647,6 +692,8 @@ public Builder clearChannel() { return this; } /** + * + * *
      * The channel to be updated.
      * 
@@ -654,11 +701,13 @@ public Builder clearChannel() { * .google.cloud.eventarc.v1.Channel channel = 1; */ public com.google.cloud.eventarc.v1.Channel.Builder getChannelBuilder() { - + onChanged(); return getChannelFieldBuilder().getBuilder(); } /** + * + * *
      * The channel to be updated.
      * 
@@ -669,11 +718,14 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { if (channelBuilder_ != null) { return channelBuilder_.getMessageOrBuilder(); } else { - return channel_ == null ? - com.google.cloud.eventarc.v1.Channel.getDefaultInstance() : channel_; + return channel_ == null + ? com.google.cloud.eventarc.v1.Channel.getDefaultInstance() + : channel_; } } /** + * + * *
      * The channel to be updated.
      * 
@@ -681,14 +733,17 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { * .google.cloud.eventarc.v1.Channel channel = 1; */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder> + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder> getChannelFieldBuilder() { if (channelBuilder_ == null) { - channelBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Channel, com.google.cloud.eventarc.v1.Channel.Builder, com.google.cloud.eventarc.v1.ChannelOrBuilder>( - getChannel(), - getParentForChildren(), - isClean()); + channelBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Channel, + com.google.cloud.eventarc.v1.Channel.Builder, + com.google.cloud.eventarc.v1.ChannelOrBuilder>( + getChannel(), getParentForChildren(), isClean()); channel_ = null; } return channelBuilder_; @@ -696,8 +751,13 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() { private com.google.protobuf.FieldMask updateMask_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder> updateMaskBuilder_; + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -705,12 +765,15 @@ public com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder() {
      * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ public boolean hasUpdateMask() { return updateMaskBuilder_ != null || updateMask_ != null; } /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -718,16 +781,21 @@ public boolean hasUpdateMask() {
      * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ public com.google.protobuf.FieldMask getUpdateMask() { if (updateMaskBuilder_ == null) { - return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; } else { return updateMaskBuilder_.getMessage(); } } /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -750,6 +818,8 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -758,8 +828,7 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
      *
      * .google.protobuf.FieldMask update_mask = 2;
      */
-    public Builder setUpdateMask(
-        com.google.protobuf.FieldMask.Builder builderForValue) {
+    public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) {
       if (updateMaskBuilder_ == null) {
         updateMask_ = builderForValue.build();
         onChanged();
@@ -770,6 +839,8 @@ public Builder setUpdateMask(
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -782,7 +853,7 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
       if (updateMaskBuilder_ == null) {
         if (updateMask_ != null) {
           updateMask_ =
-            com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
+              com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
         } else {
           updateMask_ = value;
         }
@@ -794,6 +865,8 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -814,6 +887,8 @@ public Builder clearUpdateMask() {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -823,11 +898,13 @@ public Builder clearUpdateMask() {
      * .google.protobuf.FieldMask update_mask = 2;
      */
     public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() {
-      
+
       onChanged();
       return getUpdateMaskFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -840,11 +917,14 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
       if (updateMaskBuilder_ != null) {
         return updateMaskBuilder_.getMessageOrBuilder();
       } else {
-        return updateMask_ == null ?
-            com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_;
+        return updateMask_ == null
+            ? com.google.protobuf.FieldMask.getDefaultInstance()
+            : updateMask_;
       }
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -854,27 +934,33 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
      * .google.protobuf.FieldMask update_mask = 2;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder> 
+            com.google.protobuf.FieldMask,
+            com.google.protobuf.FieldMask.Builder,
+            com.google.protobuf.FieldMaskOrBuilder>
         getUpdateMaskFieldBuilder() {
       if (updateMaskBuilder_ == null) {
-        updateMaskBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder>(
-                getUpdateMask(),
-                getParentForChildren(),
-                isClean());
+        updateMaskBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.protobuf.FieldMask,
+                com.google.protobuf.FieldMask.Builder,
+                com.google.protobuf.FieldMaskOrBuilder>(
+                getUpdateMask(), getParentForChildren(), isClean());
         updateMask_ = null;
       }
       return updateMaskBuilder_;
     }
 
-    private boolean validateOnly_ ;
+    private boolean validateOnly_;
     /**
+     *
+     *
      * 
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -882,39 +968,45 @@ public boolean getValidateOnly() { return validateOnly_; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The validateOnly to set. * @return This builder for chaining. */ public Builder setValidateOnly(boolean value) { - + validateOnly_ = value; onChanged(); return this; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValidateOnly() { - + validateOnly_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -924,12 +1016,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.UpdateChannelRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.UpdateChannelRequest) private static final com.google.cloud.eventarc.v1.UpdateChannelRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.UpdateChannelRequest(); } @@ -938,27 +1030,27 @@ public static com.google.cloud.eventarc.v1.UpdateChannelRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateChannelRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateChannelRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -973,6 +1065,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.UpdateChannelRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java similarity index 93% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java index 22129a8ff53a..ba9c0dcefbf9 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateChannelRequestOrBuilder.java @@ -3,29 +3,38 @@ package com.google.cloud.eventarc.v1; -public interface UpdateChannelRequestOrBuilder extends +public interface UpdateChannelRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.UpdateChannelRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The channel to be updated.
    * 
* * .google.cloud.eventarc.v1.Channel channel = 1; + * * @return Whether the channel field is set. */ boolean hasChannel(); /** + * + * *
    * The channel to be updated.
    * 
* * .google.cloud.eventarc.v1.Channel channel = 1; + * * @return The channel. */ com.google.cloud.eventarc.v1.Channel getChannel(); /** + * + * *
    * The channel to be updated.
    * 
@@ -35,6 +44,8 @@ public interface UpdateChannelRequestOrBuilder extends com.google.cloud.eventarc.v1.ChannelOrBuilder getChannelOrBuilder(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -42,10 +53,13 @@ public interface UpdateChannelRequestOrBuilder extends
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ boolean hasUpdateMask(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -53,10 +67,13 @@ public interface UpdateChannelRequestOrBuilder extends
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ com.google.protobuf.FieldMask getUpdateMask(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -68,12 +85,15 @@ public interface UpdateChannelRequestOrBuilder extends
   com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder();
 
   /**
+   *
+   *
    * 
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 3 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ boolean getValidateOnly(); diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java similarity index 65% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java index dba875831dc8..bc8494bcc7ff 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequest.java @@ -4,57 +4,66 @@ package com.google.cloud.eventarc.v1; /** + * + * *
  * The request message for the UpdateGoogleChannelConfig method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest} */ -public final class UpdateGoogleChannelConfigRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class UpdateGoogleChannelConfigRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) UpdateGoogleChannelConfigRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use UpdateGoogleChannelConfigRequest.newBuilder() to construct. - private UpdateGoogleChannelConfigRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + private UpdateGoogleChannelConfigRequest( + com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private UpdateGoogleChannelConfigRequest() { - } + + private UpdateGoogleChannelConfigRequest() {} @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new UpdateGoogleChannelConfigRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.Builder.class); + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.Builder.class); } public static final int GOOGLE_CHANNEL_CONFIG_FIELD_NUMBER = 1; private com.google.cloud.eventarc.v1.GoogleChannelConfig googleChannelConfig_; /** + * + * *
    * Required. The config to be updated.
    * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the googleChannelConfig field is set. */ @java.lang.Override @@ -62,32 +71,46 @@ public boolean hasGoogleChannelConfig() { return googleChannelConfig_ != null; } /** + * + * *
    * Required. The config to be updated.
    * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The googleChannelConfig. */ @java.lang.Override public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig() { - return googleChannelConfig_ == null ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() : googleChannelConfig_; + return googleChannelConfig_ == null + ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() + : googleChannelConfig_; } /** + * + * *
    * Required. The config to be updated.
    * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ @java.lang.Override - public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChannelConfigOrBuilder() { + public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder + getGoogleChannelConfigOrBuilder() { return getGoogleChannelConfig(); } public static final int UPDATE_MASK_FIELD_NUMBER = 2; private com.google.protobuf.FieldMask updateMask_; /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -95,6 +118,7 @@ public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChanne
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ @java.lang.Override @@ -102,6 +126,8 @@ public boolean hasUpdateMask() { return updateMask_ != null; } /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -109,6 +135,7 @@ public boolean hasUpdateMask() {
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ @java.lang.Override @@ -116,6 +143,8 @@ public com.google.protobuf.FieldMask getUpdateMask() { return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; } /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -130,6 +159,7 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
   }
 
   private byte memoizedIsInitialized = -1;
+
   @java.lang.Override
   public final boolean isInitialized() {
     byte isInitialized = memoizedIsInitialized;
@@ -141,8 +171,7 @@ public final boolean isInitialized() {
   }
 
   @java.lang.Override
-  public void writeTo(com.google.protobuf.CodedOutputStream output)
-                      throws java.io.IOException {
+  public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
     if (googleChannelConfig_ != null) {
       output.writeMessage(1, getGoogleChannelConfig());
     }
@@ -159,12 +188,10 @@ public int getSerializedSize() {
 
     size = 0;
     if (googleChannelConfig_ != null) {
-      size += com.google.protobuf.CodedOutputStream
-        .computeMessageSize(1, getGoogleChannelConfig());
+      size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGoogleChannelConfig());
     }
     if (updateMask_ != null) {
-      size += com.google.protobuf.CodedOutputStream
-        .computeMessageSize(2, getUpdateMask());
+      size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask());
     }
     size += getUnknownFields().getSerializedSize();
     memoizedSize = size;
@@ -174,22 +201,21 @@ public int getSerializedSize() {
   @java.lang.Override
   public boolean equals(final java.lang.Object obj) {
     if (obj == this) {
-     return true;
+      return true;
     }
     if (!(obj instanceof com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest)) {
       return super.equals(obj);
     }
-    com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest other = (com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) obj;
+    com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest other =
+        (com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) obj;
 
     if (hasGoogleChannelConfig() != other.hasGoogleChannelConfig()) return false;
     if (hasGoogleChannelConfig()) {
-      if (!getGoogleChannelConfig()
-          .equals(other.getGoogleChannelConfig())) return false;
+      if (!getGoogleChannelConfig().equals(other.getGoogleChannelConfig())) return false;
     }
     if (hasUpdateMask() != other.hasUpdateMask()) return false;
     if (hasUpdateMask()) {
-      if (!getUpdateMask()
-          .equals(other.getUpdateMask())) return false;
+      if (!getUpdateMask().equals(other.getUpdateMask())) return false;
     }
     if (!getUnknownFields().equals(other.getUnknownFields())) return false;
     return true;
@@ -216,129 +242,136 @@ public int hashCode() {
   }
 
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
-      java.nio.ByteBuffer data)
-      throws com.google.protobuf.InvalidProtocolBufferException {
+      java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
-      java.nio.ByteBuffer data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
       com.google.protobuf.ByteString data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
       com.google.protobuf.ByteString data,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(byte[] data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
-      byte[] data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(java.io.InputStream input)
-      throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+
+  public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
+      java.io.InputStream input) throws java.io.IOException {
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
   }
-  public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseDelimitedFrom(java.io.InputStream input)
-      throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input);
+
+  public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseDelimitedFrom(
+      java.io.InputStream input) throws java.io.IOException {
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseDelimitedFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+        PARSER, input, extensionRegistry);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
-      com.google.protobuf.CodedInputStream input)
-      throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+      com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
+
   public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest parseFrom(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
   }
 
   @java.lang.Override
-  public Builder newBuilderForType() { return newBuilder(); }
+  public Builder newBuilderForType() {
+    return newBuilder();
+  }
+
   public static Builder newBuilder() {
     return DEFAULT_INSTANCE.toBuilder();
   }
-  public static Builder newBuilder(com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest prototype) {
+
+  public static Builder newBuilder(
+      com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest prototype) {
     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
   }
+
   @java.lang.Override
   public Builder toBuilder() {
-    return this == DEFAULT_INSTANCE
-        ? new Builder() : new Builder().mergeFrom(this);
+    return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
   }
 
   @java.lang.Override
-  protected Builder newBuilderForType(
-      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+  protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
     Builder builder = new Builder(parent);
     return builder;
   }
   /**
+   *
+   *
    * 
    * The request message for the UpdateGoogleChannelConfig method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.Builder.class); + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -358,13 +391,14 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor; } @java.lang.Override - public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest getDefaultInstanceForType() { + public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest + getDefaultInstanceForType() { return com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.getDefaultInstance(); } @@ -379,7 +413,8 @@ public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest buildPartial() { - com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest result = new com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest(this); + com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest result = + new com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest(this); if (googleChannelConfigBuilder_ == null) { result.googleChannelConfig_ = googleChannelConfig_; } else { @@ -398,38 +433,39 @@ public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest buildPartia public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) other); } else { super.mergeFrom(other); return this; @@ -437,7 +473,9 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest other) { - if (other == com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.getDefaultInstance()) return this; + if (other + == com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.getDefaultInstance()) + return this; if (other.hasGoogleChannelConfig()) { mergeGoogleChannelConfig(other.getGoogleChannelConfig()); } @@ -470,26 +508,26 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - input.readMessage( - getGoogleChannelConfigFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 10 - case 18: { - input.readMessage( - getUpdateMaskFieldBuilder().getBuilder(), - extensionRegistry); - - break; - } // case 18 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + case 10: + { + input.readMessage( + getGoogleChannelConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -502,39 +540,58 @@ public Builder mergeFrom( private com.google.cloud.eventarc.v1.GoogleChannelConfig googleChannelConfig_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.GoogleChannelConfig, com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder> googleChannelConfigBuilder_; + com.google.cloud.eventarc.v1.GoogleChannelConfig, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder> + googleChannelConfigBuilder_; /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the googleChannelConfig field is set. */ public boolean hasGoogleChannelConfig() { return googleChannelConfigBuilder_ != null || googleChannelConfig_ != null; } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The googleChannelConfig. */ public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig() { if (googleChannelConfigBuilder_ == null) { - return googleChannelConfig_ == null ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() : googleChannelConfig_; + return googleChannelConfig_ == null + ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() + : googleChannelConfig_; } else { return googleChannelConfigBuilder_.getMessage(); } } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setGoogleChannelConfig(com.google.cloud.eventarc.v1.GoogleChannelConfig value) { if (googleChannelConfigBuilder_ == null) { @@ -550,11 +607,15 @@ public Builder setGoogleChannelConfig(com.google.cloud.eventarc.v1.GoogleChannel return this; } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder setGoogleChannelConfig( com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder builderForValue) { @@ -568,17 +629,24 @@ public Builder setGoogleChannelConfig( return this; } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ - public Builder mergeGoogleChannelConfig(com.google.cloud.eventarc.v1.GoogleChannelConfig value) { + public Builder mergeGoogleChannelConfig( + com.google.cloud.eventarc.v1.GoogleChannelConfig value) { if (googleChannelConfigBuilder_ == null) { if (googleChannelConfig_ != null) { googleChannelConfig_ = - com.google.cloud.eventarc.v1.GoogleChannelConfig.newBuilder(googleChannelConfig_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.GoogleChannelConfig.newBuilder(googleChannelConfig_) + .mergeFrom(value) + .buildPartial(); } else { googleChannelConfig_ = value; } @@ -590,11 +658,15 @@ public Builder mergeGoogleChannelConfig(com.google.cloud.eventarc.v1.GoogleChann return this; } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ public Builder clearGoogleChannelConfig() { if (googleChannelConfigBuilder_ == null) { @@ -608,48 +680,66 @@ public Builder clearGoogleChannelConfig() { return this; } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ - public com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder getGoogleChannelConfigBuilder() { - + public com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder + getGoogleChannelConfigBuilder() { + onChanged(); return getGoogleChannelConfigFieldBuilder().getBuilder(); } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ - public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChannelConfigOrBuilder() { + public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder + getGoogleChannelConfigOrBuilder() { if (googleChannelConfigBuilder_ != null) { return googleChannelConfigBuilder_.getMessageOrBuilder(); } else { - return googleChannelConfig_ == null ? - com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() : googleChannelConfig_; + return googleChannelConfig_ == null + ? com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance() + : googleChannelConfig_; } } /** + * + * *
      * Required. The config to be updated.
      * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.GoogleChannelConfig, com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder> + com.google.cloud.eventarc.v1.GoogleChannelConfig, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder> getGoogleChannelConfigFieldBuilder() { if (googleChannelConfigBuilder_ == null) { - googleChannelConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.GoogleChannelConfig, com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder>( - getGoogleChannelConfig(), - getParentForChildren(), - isClean()); + googleChannelConfigBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.GoogleChannelConfig, + com.google.cloud.eventarc.v1.GoogleChannelConfig.Builder, + com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder>( + getGoogleChannelConfig(), getParentForChildren(), isClean()); googleChannelConfig_ = null; } return googleChannelConfigBuilder_; @@ -657,8 +747,13 @@ public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChanne private com.google.protobuf.FieldMask updateMask_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder> updateMaskBuilder_; + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -666,12 +761,15 @@ public com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChanne
      * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ public boolean hasUpdateMask() { return updateMaskBuilder_ != null || updateMask_ != null; } /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -679,16 +777,21 @@ public boolean hasUpdateMask() {
      * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ public com.google.protobuf.FieldMask getUpdateMask() { if (updateMaskBuilder_ == null) { - return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; } else { return updateMaskBuilder_.getMessage(); } } /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -711,6 +814,8 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -719,8 +824,7 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
      *
      * .google.protobuf.FieldMask update_mask = 2;
      */
-    public Builder setUpdateMask(
-        com.google.protobuf.FieldMask.Builder builderForValue) {
+    public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) {
       if (updateMaskBuilder_ == null) {
         updateMask_ = builderForValue.build();
         onChanged();
@@ -731,6 +835,8 @@ public Builder setUpdateMask(
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -743,7 +849,7 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
       if (updateMaskBuilder_ == null) {
         if (updateMask_ != null) {
           updateMask_ =
-            com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
+              com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
         } else {
           updateMask_ = value;
         }
@@ -755,6 +861,8 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -775,6 +883,8 @@ public Builder clearUpdateMask() {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -784,11 +894,13 @@ public Builder clearUpdateMask() {
      * .google.protobuf.FieldMask update_mask = 2;
      */
     public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() {
-      
+
       onChanged();
       return getUpdateMaskFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -801,11 +913,14 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
       if (updateMaskBuilder_ != null) {
         return updateMaskBuilder_.getMessageOrBuilder();
       } else {
-        return updateMask_ == null ?
-            com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_;
+        return updateMask_ == null
+            ? com.google.protobuf.FieldMask.getDefaultInstance()
+            : updateMask_;
       }
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -815,21 +930,24 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
      * .google.protobuf.FieldMask update_mask = 2;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder> 
+            com.google.protobuf.FieldMask,
+            com.google.protobuf.FieldMask.Builder,
+            com.google.protobuf.FieldMaskOrBuilder>
         getUpdateMaskFieldBuilder() {
       if (updateMaskBuilder_ == null) {
-        updateMaskBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder>(
-                getUpdateMask(),
-                getParentForChildren(),
-                isClean());
+        updateMaskBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.protobuf.FieldMask,
+                com.google.protobuf.FieldMask.Builder,
+                com.google.protobuf.FieldMaskOrBuilder>(
+                getUpdateMask(), getParentForChildren(), isClean());
         updateMask_ = null;
       }
       return updateMaskBuilder_;
     }
+
     @java.lang.Override
-    public final Builder setUnknownFields(
-        final com.google.protobuf.UnknownFieldSet unknownFields) {
+    public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
       return super.setUnknownFields(unknownFields);
     }
 
@@ -839,12 +957,13 @@ public final Builder mergeUnknownFields(
       return super.mergeUnknownFields(unknownFields);
     }
 
-
     // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest)
   }
 
   // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest)
-  private static final com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest DEFAULT_INSTANCE;
+  private static final com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest
+      DEFAULT_INSTANCE;
+
   static {
     DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest();
   }
@@ -853,27 +972,27 @@ public static com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest getD
     return DEFAULT_INSTANCE;
   }
 
-  private static final com.google.protobuf.Parser
-      PARSER = new com.google.protobuf.AbstractParser() {
-    @java.lang.Override
-    public UpdateGoogleChannelConfigRequest parsePartialFrom(
-        com.google.protobuf.CodedInputStream input,
-        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
-        throws com.google.protobuf.InvalidProtocolBufferException {
-      Builder builder = newBuilder();
-      try {
-        builder.mergeFrom(input, extensionRegistry);
-      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
-        throw e.setUnfinishedMessage(builder.buildPartial());
-      } catch (com.google.protobuf.UninitializedMessageException e) {
-        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
-      } catch (java.io.IOException e) {
-        throw new com.google.protobuf.InvalidProtocolBufferException(e)
-            .setUnfinishedMessage(builder.buildPartial());
-      }
-      return builder.buildPartial();
-    }
-  };
+  private static final com.google.protobuf.Parser PARSER =
+      new com.google.protobuf.AbstractParser() {
+        @java.lang.Override
+        public UpdateGoogleChannelConfigRequest parsePartialFrom(
+            com.google.protobuf.CodedInputStream input,
+            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+            throws com.google.protobuf.InvalidProtocolBufferException {
+          Builder builder = newBuilder();
+          try {
+            builder.mergeFrom(input, extensionRegistry);
+          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+            throw e.setUnfinishedMessage(builder.buildPartial());
+          } catch (com.google.protobuf.UninitializedMessageException e) {
+            throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
+          } catch (java.io.IOException e) {
+            throw new com.google.protobuf.InvalidProtocolBufferException(e)
+                .setUnfinishedMessage(builder.buildPartial());
+          }
+          return builder.buildPartial();
+        }
+      };
 
   public static com.google.protobuf.Parser parser() {
     return PARSER;
@@ -888,6 +1007,4 @@ public com.google.protobuf.Parser getParserFor
   public com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest getDefaultInstanceForType() {
     return DEFAULT_INSTANCE;
   }
-
 }
-
diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java
similarity index 77%
rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java
rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java
index cb7a6d1552e4..da68112a5a3c 100644
--- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java
+++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateGoogleChannelConfigRequestOrBuilder.java
@@ -3,38 +3,55 @@
 
 package com.google.cloud.eventarc.v1;
 
-public interface UpdateGoogleChannelConfigRequestOrBuilder extends
+public interface UpdateGoogleChannelConfigRequestOrBuilder
+    extends
     // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest)
     com.google.protobuf.MessageOrBuilder {
 
   /**
+   *
+   *
    * 
    * Required. The config to be updated.
    * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return Whether the googleChannelConfig field is set. */ boolean hasGoogleChannelConfig(); /** + * + * *
    * Required. The config to be updated.
    * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * * @return The googleChannelConfig. */ com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig(); /** + * + * *
    * Required. The config to be updated.
    * 
* - * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * .google.cloud.eventarc.v1.GoogleChannelConfig google_channel_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * */ com.google.cloud.eventarc.v1.GoogleChannelConfigOrBuilder getGoogleChannelConfigOrBuilder(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -42,10 +59,13 @@ public interface UpdateGoogleChannelConfigRequestOrBuilder extends
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ boolean hasUpdateMask(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -53,10 +73,13 @@ public interface UpdateGoogleChannelConfigRequestOrBuilder extends
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ com.google.protobuf.FieldMask getUpdateMask(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java
similarity index 73%
rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java
rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java
index d0d5f5ff8a65..7a411d609e3c 100644
--- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java
+++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequest.java
@@ -4,57 +4,63 @@
 package com.google.cloud.eventarc.v1;
 
 /**
+ *
+ *
  * 
  * The request message for the UpdateTrigger method.
  * 
* * Protobuf type {@code google.cloud.eventarc.v1.UpdateTriggerRequest} */ -public final class UpdateTriggerRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class UpdateTriggerRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.cloud.eventarc.v1.UpdateTriggerRequest) UpdateTriggerRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use UpdateTriggerRequest.newBuilder() to construct. private UpdateTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private UpdateTriggerRequest() { - } + + private UpdateTriggerRequest() {} @java.lang.Override @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance( - UnusedPrivateParameter unused) { + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new UpdateTriggerRequest(); } @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, com.google.cloud.eventarc.v1.UpdateTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, + com.google.cloud.eventarc.v1.UpdateTriggerRequest.Builder.class); } public static final int TRIGGER_FIELD_NUMBER = 1; private com.google.cloud.eventarc.v1.Trigger trigger_; /** + * + * *
    * The trigger to be updated.
    * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; + * * @return Whether the trigger field is set. */ @java.lang.Override @@ -62,11 +68,14 @@ public boolean hasTrigger() { return trigger_ != null; } /** + * + * *
    * The trigger to be updated.
    * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; + * * @return The trigger. */ @java.lang.Override @@ -74,6 +83,8 @@ public com.google.cloud.eventarc.v1.Trigger getTrigger() { return trigger_ == null ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; } /** + * + * *
    * The trigger to be updated.
    * 
@@ -88,6 +99,8 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { public static final int UPDATE_MASK_FIELD_NUMBER = 2; private com.google.protobuf.FieldMask updateMask_; /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -95,6 +108,7 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() {
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ @java.lang.Override @@ -102,6 +116,8 @@ public boolean hasUpdateMask() { return updateMask_ != null; } /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -109,6 +125,7 @@ public boolean hasUpdateMask() {
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ @java.lang.Override @@ -116,6 +133,8 @@ public com.google.protobuf.FieldMask getUpdateMask() { return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; } /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -132,12 +151,15 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
   public static final int ALLOW_MISSING_FIELD_NUMBER = 3;
   private boolean allowMissing_;
   /**
+   *
+   *
    * 
    * If set to true, and the trigger is not found, a new trigger will be
    * created. In this situation, `update_mask` is ignored.
    * 
* * bool allow_missing = 3; + * * @return The allowMissing. */ @java.lang.Override @@ -148,12 +170,15 @@ public boolean getAllowMissing() { public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; private boolean validateOnly_; /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -162,6 +187,7 @@ public boolean getValidateOnly() { } private byte memoizedIsInitialized = -1; + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -173,8 +199,7 @@ public final boolean isInitialized() { } @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (trigger_ != null) { output.writeMessage(1, getTrigger()); } @@ -197,20 +222,16 @@ public int getSerializedSize() { size = 0; if (trigger_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, getTrigger()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTrigger()); } if (updateMask_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getUpdateMask()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); } if (allowMissing_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(3, allowMissing_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowMissing_); } if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(4, validateOnly_); + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; @@ -220,27 +241,24 @@ public int getSerializedSize() { @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } if (!(obj instanceof com.google.cloud.eventarc.v1.UpdateTriggerRequest)) { return super.equals(obj); } - com.google.cloud.eventarc.v1.UpdateTriggerRequest other = (com.google.cloud.eventarc.v1.UpdateTriggerRequest) obj; + com.google.cloud.eventarc.v1.UpdateTriggerRequest other = + (com.google.cloud.eventarc.v1.UpdateTriggerRequest) obj; if (hasTrigger() != other.hasTrigger()) return false; if (hasTrigger()) { - if (!getTrigger() - .equals(other.getTrigger())) return false; + if (!getTrigger().equals(other.getTrigger())) return false; } if (hasUpdateMask() != other.hasUpdateMask()) return false; if (hasUpdateMask()) { - if (!getUpdateMask() - .equals(other.getUpdateMask())) return false; + if (!getUpdateMask().equals(other.getUpdateMask())) return false; } - if (getAllowMissing() - != other.getAllowMissing()) return false; - if (getValidateOnly() - != other.getValidateOnly()) return false; + if (getAllowMissing() != other.getAllowMissing()) return false; + if (getValidateOnly() != other.getValidateOnly()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -261,140 +279,144 @@ public int hashCode() { hash = (53 * hash) + getUpdateMask().hashCode(); } hash = (37 * hash) + ALLOW_MISSING_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getAllowMissing()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowMissing()); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( - getValidateOnly()); + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( - java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } + public static com.google.cloud.eventarc.v1.UpdateTriggerRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } @java.lang.Override - public Builder newBuilderForType() { return newBuilder(); } + public Builder newBuilderForType() { + return newBuilder(); + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } + public static Builder newBuilder(com.google.cloud.eventarc.v1.UpdateTriggerRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The request message for the UpdateTrigger method.
    * 
* * Protobuf type {@code google.cloud.eventarc.v1.UpdateTriggerRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.cloud.eventarc.v1.UpdateTriggerRequest) com.google.cloud.eventarc.v1.UpdateTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, com.google.cloud.eventarc.v1.UpdateTriggerRequest.Builder.class); + com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, + com.google.cloud.eventarc.v1.UpdateTriggerRequest.Builder.class); } // Construct using com.google.cloud.eventarc.v1.UpdateTriggerRequest.newBuilder() - private Builder() { + private Builder() {} - } - - private Builder( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - } + @java.lang.Override public Builder clear() { super.clear(); @@ -418,9 +440,9 @@ public Builder clear() { } @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return com.google.cloud.eventarc.v1.EventarcProto.internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.eventarc.v1.EventarcProto + .internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor; } @java.lang.Override @@ -439,7 +461,8 @@ public com.google.cloud.eventarc.v1.UpdateTriggerRequest build() { @java.lang.Override public com.google.cloud.eventarc.v1.UpdateTriggerRequest buildPartial() { - com.google.cloud.eventarc.v1.UpdateTriggerRequest result = new com.google.cloud.eventarc.v1.UpdateTriggerRequest(this); + com.google.cloud.eventarc.v1.UpdateTriggerRequest result = + new com.google.cloud.eventarc.v1.UpdateTriggerRequest(this); if (triggerBuilder_ == null) { result.trigger_ = trigger_; } else { @@ -460,38 +483,39 @@ public com.google.cloud.eventarc.v1.UpdateTriggerRequest buildPartial() { public Builder clone() { return super.clone(); } + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } + @java.lang.Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } + @java.lang.Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - java.lang.Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.eventarc.v1.UpdateTriggerRequest) { - return mergeFrom((com.google.cloud.eventarc.v1.UpdateTriggerRequest)other); + return mergeFrom((com.google.cloud.eventarc.v1.UpdateTriggerRequest) other); } else { super.mergeFrom(other); return this; @@ -499,7 +523,8 @@ public Builder mergeFrom(com.google.protobuf.Message other) { } public Builder mergeFrom(com.google.cloud.eventarc.v1.UpdateTriggerRequest other) { - if (other == com.google.cloud.eventarc.v1.UpdateTriggerRequest.getDefaultInstance()) return this; + if (other == com.google.cloud.eventarc.v1.UpdateTriggerRequest.getDefaultInstance()) + return this; if (other.hasTrigger()) { mergeTrigger(other.getTrigger()); } @@ -538,36 +563,37 @@ public Builder mergeFrom( case 0: done = true; break; - case 10: { - input.readMessage( - getTriggerFieldBuilder().getBuilder(), - extensionRegistry); + case 10: + { + input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 10 - case 18: { - input.readMessage( - getUpdateMaskFieldBuilder().getBuilder(), - extensionRegistry); + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); - break; - } // case 18 - case 24: { - allowMissing_ = input.readBool(); + break; + } // case 18 + case 24: + { + allowMissing_ = input.readBool(); - break; - } // case 24 - case 32: { - validateOnly_ = input.readBool(); + break; + } // case 24 + case 32: + { + validateOnly_ = input.readBool(); - break; - } // case 32 - default: { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { @@ -580,34 +606,47 @@ public Builder mergeFrom( private com.google.cloud.eventarc.v1.Trigger trigger_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder> triggerBuilder_; + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> + triggerBuilder_; /** + * + * *
      * The trigger to be updated.
      * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; + * * @return Whether the trigger field is set. */ public boolean hasTrigger() { return triggerBuilder_ != null || trigger_ != null; } /** + * + * *
      * The trigger to be updated.
      * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; + * * @return The trigger. */ public com.google.cloud.eventarc.v1.Trigger getTrigger() { if (triggerBuilder_ == null) { - return trigger_ == null ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; } else { return triggerBuilder_.getMessage(); } } /** + * + * *
      * The trigger to be updated.
      * 
@@ -628,14 +667,15 @@ public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger value) { return this; } /** + * + * *
      * The trigger to be updated.
      * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; */ - public Builder setTrigger( - com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { + public Builder setTrigger(com.google.cloud.eventarc.v1.Trigger.Builder builderForValue) { if (triggerBuilder_ == null) { trigger_ = builderForValue.build(); onChanged(); @@ -646,6 +686,8 @@ public Builder setTrigger( return this; } /** + * + * *
      * The trigger to be updated.
      * 
@@ -656,7 +698,9 @@ public Builder mergeTrigger(com.google.cloud.eventarc.v1.Trigger value) { if (triggerBuilder_ == null) { if (trigger_ != null) { trigger_ = - com.google.cloud.eventarc.v1.Trigger.newBuilder(trigger_).mergeFrom(value).buildPartial(); + com.google.cloud.eventarc.v1.Trigger.newBuilder(trigger_) + .mergeFrom(value) + .buildPartial(); } else { trigger_ = value; } @@ -668,6 +712,8 @@ public Builder mergeTrigger(com.google.cloud.eventarc.v1.Trigger value) { return this; } /** + * + * *
      * The trigger to be updated.
      * 
@@ -686,6 +732,8 @@ public Builder clearTrigger() { return this; } /** + * + * *
      * The trigger to be updated.
      * 
@@ -693,11 +741,13 @@ public Builder clearTrigger() { * .google.cloud.eventarc.v1.Trigger trigger = 1; */ public com.google.cloud.eventarc.v1.Trigger.Builder getTriggerBuilder() { - + onChanged(); return getTriggerFieldBuilder().getBuilder(); } /** + * + * *
      * The trigger to be updated.
      * 
@@ -708,11 +758,14 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { if (triggerBuilder_ != null) { return triggerBuilder_.getMessageOrBuilder(); } else { - return trigger_ == null ? - com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() : trigger_; + return trigger_ == null + ? com.google.cloud.eventarc.v1.Trigger.getDefaultInstance() + : trigger_; } } /** + * + * *
      * The trigger to be updated.
      * 
@@ -720,14 +773,17 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { * .google.cloud.eventarc.v1.Trigger trigger = 1; */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder> + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder> getTriggerFieldBuilder() { if (triggerBuilder_ == null) { - triggerBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloud.eventarc.v1.Trigger, com.google.cloud.eventarc.v1.Trigger.Builder, com.google.cloud.eventarc.v1.TriggerOrBuilder>( - getTrigger(), - getParentForChildren(), - isClean()); + triggerBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.eventarc.v1.Trigger, + com.google.cloud.eventarc.v1.Trigger.Builder, + com.google.cloud.eventarc.v1.TriggerOrBuilder>( + getTrigger(), getParentForChildren(), isClean()); trigger_ = null; } return triggerBuilder_; @@ -735,8 +791,13 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() { private com.google.protobuf.FieldMask updateMask_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder> updateMaskBuilder_; + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -744,12 +805,15 @@ public com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder() {
      * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ public boolean hasUpdateMask() { return updateMaskBuilder_ != null || updateMask_ != null; } /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -757,16 +821,21 @@ public boolean hasUpdateMask() {
      * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ public com.google.protobuf.FieldMask getUpdateMask() { if (updateMaskBuilder_ == null) { - return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; } else { return updateMaskBuilder_.getMessage(); } } /** + * + * *
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -789,6 +858,8 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -797,8 +868,7 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
      *
      * .google.protobuf.FieldMask update_mask = 2;
      */
-    public Builder setUpdateMask(
-        com.google.protobuf.FieldMask.Builder builderForValue) {
+    public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) {
       if (updateMaskBuilder_ == null) {
         updateMask_ = builderForValue.build();
         onChanged();
@@ -809,6 +879,8 @@ public Builder setUpdateMask(
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -821,7 +893,7 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
       if (updateMaskBuilder_ == null) {
         if (updateMask_ != null) {
           updateMask_ =
-            com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
+              com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
         } else {
           updateMask_ = value;
         }
@@ -833,6 +905,8 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -853,6 +927,8 @@ public Builder clearUpdateMask() {
       return this;
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -862,11 +938,13 @@ public Builder clearUpdateMask() {
      * .google.protobuf.FieldMask update_mask = 2;
      */
     public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() {
-      
+
       onChanged();
       return getUpdateMaskFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -879,11 +957,14 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
       if (updateMaskBuilder_ != null) {
         return updateMaskBuilder_.getMessageOrBuilder();
       } else {
-        return updateMask_ == null ?
-            com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_;
+        return updateMask_ == null
+            ? com.google.protobuf.FieldMask.getDefaultInstance()
+            : updateMask_;
       }
     }
     /**
+     *
+     *
      * 
      * The fields to be updated; only fields explicitly provided are updated.
      * If no field mask is provided, all provided fields in the request are
@@ -893,27 +974,33 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
      * .google.protobuf.FieldMask update_mask = 2;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder> 
+            com.google.protobuf.FieldMask,
+            com.google.protobuf.FieldMask.Builder,
+            com.google.protobuf.FieldMaskOrBuilder>
         getUpdateMaskFieldBuilder() {
       if (updateMaskBuilder_ == null) {
-        updateMaskBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.protobuf.FieldMask, com.google.protobuf.FieldMask.Builder, com.google.protobuf.FieldMaskOrBuilder>(
-                getUpdateMask(),
-                getParentForChildren(),
-                isClean());
+        updateMaskBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.protobuf.FieldMask,
+                com.google.protobuf.FieldMask.Builder,
+                com.google.protobuf.FieldMaskOrBuilder>(
+                getUpdateMask(), getParentForChildren(), isClean());
         updateMask_ = null;
       }
       return updateMaskBuilder_;
     }
 
-    private boolean allowMissing_ ;
+    private boolean allowMissing_;
     /**
+     *
+     *
      * 
      * If set to true, and the trigger is not found, a new trigger will be
      * created. In this situation, `update_mask` is ignored.
      * 
* * bool allow_missing = 3; + * * @return The allowMissing. */ @java.lang.Override @@ -921,45 +1008,54 @@ public boolean getAllowMissing() { return allowMissing_; } /** + * + * *
      * If set to true, and the trigger is not found, a new trigger will be
      * created. In this situation, `update_mask` is ignored.
      * 
* * bool allow_missing = 3; + * * @param value The allowMissing to set. * @return This builder for chaining. */ public Builder setAllowMissing(boolean value) { - + allowMissing_ = value; onChanged(); return this; } /** + * + * *
      * If set to true, and the trigger is not found, a new trigger will be
      * created. In this situation, `update_mask` is ignored.
      * 
* * bool allow_missing = 3; + * * @return This builder for chaining. */ public Builder clearAllowMissing() { - + allowMissing_ = false; onChanged(); return this; } - private boolean validateOnly_ ; + private boolean validateOnly_; /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ @java.lang.Override @@ -967,39 +1063,45 @@ public boolean getValidateOnly() { return validateOnly_; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @param value The validateOnly to set. * @return This builder for chaining. */ public Builder setValidateOnly(boolean value) { - + validateOnly_ = value; onChanged(); return this; } /** + * + * *
      * Required. If set, validate the request and preview the review, but do not
      * post it.
      * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return This builder for chaining. */ public Builder clearValidateOnly() { - + validateOnly_ = false; onChanged(); return this; } + @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @@ -1009,12 +1111,12 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.eventarc.v1.UpdateTriggerRequest) } // @@protoc_insertion_point(class_scope:google.cloud.eventarc.v1.UpdateTriggerRequest) private static final com.google.cloud.eventarc.v1.UpdateTriggerRequest DEFAULT_INSTANCE; + static { DEFAULT_INSTANCE = new com.google.cloud.eventarc.v1.UpdateTriggerRequest(); } @@ -1023,27 +1125,27 @@ public static com.google.cloud.eventarc.v1.UpdateTriggerRequest getDefaultInstan return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateTriggerRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; @@ -1058,6 +1160,4 @@ public com.google.protobuf.Parser getParserForType() { public com.google.cloud.eventarc.v1.UpdateTriggerRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java similarity index 94% rename from owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java rename to java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java index 0a3e794a94d9..ad225519d72b 100644 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/UpdateTriggerRequestOrBuilder.java @@ -3,29 +3,38 @@ package com.google.cloud.eventarc.v1; -public interface UpdateTriggerRequestOrBuilder extends +public interface UpdateTriggerRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.cloud.eventarc.v1.UpdateTriggerRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The trigger to be updated.
    * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; + * * @return Whether the trigger field is set. */ boolean hasTrigger(); /** + * + * *
    * The trigger to be updated.
    * 
* * .google.cloud.eventarc.v1.Trigger trigger = 1; + * * @return The trigger. */ com.google.cloud.eventarc.v1.Trigger getTrigger(); /** + * + * *
    * The trigger to be updated.
    * 
@@ -35,6 +44,8 @@ public interface UpdateTriggerRequestOrBuilder extends com.google.cloud.eventarc.v1.TriggerOrBuilder getTriggerOrBuilder(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -42,10 +53,13 @@ public interface UpdateTriggerRequestOrBuilder extends
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return Whether the updateMask field is set. */ boolean hasUpdateMask(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -53,10 +67,13 @@ public interface UpdateTriggerRequestOrBuilder extends
    * 
* * .google.protobuf.FieldMask update_mask = 2; + * * @return The updateMask. */ com.google.protobuf.FieldMask getUpdateMask(); /** + * + * *
    * The fields to be updated; only fields explicitly provided are updated.
    * If no field mask is provided, all provided fields in the request are
@@ -68,23 +85,29 @@ public interface UpdateTriggerRequestOrBuilder extends
   com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder();
 
   /**
+   *
+   *
    * 
    * If set to true, and the trigger is not found, a new trigger will be
    * created. In this situation, `update_mask` is ignored.
    * 
* * bool allow_missing = 3; + * * @return The allowMissing. */ boolean getAllowMissing(); /** + * + * *
    * Required. If set, validate the request and preview the review, but do not
    * post it.
    * 
* * bool validate_only = 4 [(.google.api.field_behavior) = REQUIRED]; + * * @return The validateOnly. */ boolean getValidateOnly(); diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto new file mode 100644 index 000000000000..9c5395580b1d --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel.proto @@ -0,0 +1,120 @@ +// Copyright 2022 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.eventarc.v1; + +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.Eventarc.V1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/eventarc/v1;eventarc"; +option java_multiple_files = true; +option java_outer_classname = "ChannelProto"; +option java_package = "com.google.cloud.eventarc.v1"; +option php_namespace = "Google\\Cloud\\Eventarc\\V1"; +option ruby_package = "Google::Cloud::Eventarc::V1"; + +// A representation of the Channel resource. +// A Channel is a resource on which event providers publish their events. +// The published events are delivered through the transport associated with the +// channel. Note that a channel is associated with exactly one event provider. +message Channel { + option (google.api.resource) = { + type: "eventarc.googleapis.com/Channel" + pattern: "projects/{project}/locations/{location}/channels/{channel}" + plural: "channels" + singular: "channel" + }; + + // State lists all the possible states of a Channel + enum State { + // Default value. This value is unused. + STATE_UNSPECIFIED = 0; + + // The PENDING state indicates that a Channel has been created successfully + // and there is a new activation token available for the subscriber to use + // to convey the Channel to the provider in order to create a Connection. + PENDING = 1; + + // The ACTIVE state indicates that a Channel has been successfully + // connected with the event provider. + // An ACTIVE Channel is ready to receive and route events from the + // event provider. + ACTIVE = 2; + + // The INACTIVE state indicates that the Channel cannot receive events + // permanently. There are two possible cases this state can happen: + // + // 1. The SaaS provider disconnected from this Channel. + // 2. The Channel activation token has expired but the SaaS provider + // wasn't connected. + // + // To re-establish a Connection with a provider, the subscriber + // should create a new Channel and give it to the provider. + INACTIVE = 3; + } + + // Required. The resource name of the channel. Must be unique within the + // location on the project and must be in + // `projects/{project}/locations/{location}/channels/{channel_id}` format. + string name = 1 [(google.api.field_behavior) = REQUIRED]; + + // Output only. Server assigned unique identifier for the channel. The value + // is a UUID4 string and guaranteed to remain unchanged until the resource is + // deleted. + string uid = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The creation time. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The last-modified time. + google.protobuf.Timestamp update_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // The name of the event provider (e.g. Eventarc SaaS partner) associated + // with the channel. This provider will be granted permissions to publish + // events to the channel. Format: + // `projects/{project}/locations/{location}/providers/{provider_id}`. + string provider = 7; + + oneof transport { + // Output only. The name of the Pub/Sub topic created and managed by + // Eventarc system as a transport for the event delivery. Format: + // `projects/{project}/topics/{topic_id}`. + string pubsub_topic = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + } + + // Output only. The state of a Channel. + State state = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The activation token for the channel. The token must be used + // by the provider to register the channel for publishing. + string activation_token = 10 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Resource name of a KMS crypto key (managed by the user) used to + // encrypt/decrypt their event data. + // + // It must match the pattern + // `projects/*/locations/*/keyRings/*/cryptoKeys/*`. + string crypto_key_name = 11 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "cloudkms.googleapis.com/CryptoKey" + } + ]; +} diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto new file mode 100644 index 000000000000..576b5cc59f03 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/channel_connection.proto @@ -0,0 +1,71 @@ +// Copyright 2022 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.eventarc.v1; + +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.Eventarc.V1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/eventarc/v1;eventarc"; +option java_multiple_files = true; +option java_outer_classname = "ChannelConnectionProto"; +option java_package = "com.google.cloud.eventarc.v1"; +option php_namespace = "Google\\Cloud\\Eventarc\\V1"; +option ruby_package = "Google::Cloud::Eventarc::V1"; + +// A representation of the ChannelConnection resource. +// A ChannelConnection is a resource which event providers create during the +// activation process to establish a connection between the provider and the +// subscriber channel. +message ChannelConnection { + option (google.api.resource) = { + type: "eventarc.googleapis.com/ChannelConnection" + pattern: "projects/{project}/locations/{location}/channelConnections/{channel_connection}" + plural: "channelConnections" + singular: "channelConnection" + }; + + // Required. The name of the connection. + string name = 1 [(google.api.field_behavior) = REQUIRED]; + + // Output only. Server assigned ID of the resource. + // The server guarantees uniqueness and immutability until deleted. + string uid = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Required. The name of the connected subscriber Channel. + // This is a weak reference to avoid cross project and cross accounts + // references. This must be in + // `projects/{project}/location/{location}/channels/{channel_id}` format. + string channel = 5 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/Channel" + } + ]; + + // Output only. The creation time. + google.protobuf.Timestamp create_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The last-modified time. + google.protobuf.Timestamp update_time = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Input only. Activation token for the channel. The token will be used + // during the creation of ChannelConnection to bind the channel with the + // provider project. This field will not be stored in the provider resource. + string activation_token = 8 [(google.api.field_behavior) = INPUT_ONLY]; +} diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto new file mode 100644 index 000000000000..44633de81a3f --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/discovery.proto @@ -0,0 +1,86 @@ +// Copyright 2022 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.eventarc.v1; + +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; + +option go_package = "google.golang.org/genproto/googleapis/cloud/eventarc/v1;eventarc"; +option java_multiple_files = true; +option java_outer_classname = "DiscoveryProto"; +option java_package = "com.google.cloud.eventarc.v1"; + +// A representation of the Provider resource. +message Provider { + option (google.api.resource) = { + type: "eventarc.googleapis.com/Provider" + pattern: "projects/{project}/locations/{location}/providers/{provider}" + plural: "providers" + singular: "provider" + }; + + // Output only. In `projects/{project}/locations/{location}/providers/{provider_id}` + // format. + string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Human friendly name for the Provider. For example "Cloud Storage". + string display_name = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Event types for this provider. + repeated EventType event_types = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// A representation of the event type resource. +message EventType { + // Output only. The full name of the event type (for example, + // "google.cloud.storage.object.v1.finalized"). In the form of + // {provider-specific-prefix}.{resource}.{version}.{verb}. Types MUST be + // versioned and event schemas are guaranteed to remain backward compatible + // within one version. Note that event type versions and API versions do not + // need to match. + string type = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Human friendly description of what the event type is about. + // For example "Bucket created in Cloud Storage". + string description = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Filtering attributes for the event type. + repeated FilteringAttribute filtering_attributes = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. URI for the event schema. + // For example + // "https://github.com/googleapis/google-cloudevents/blob/master/proto/google/events/cloud/storage/v1/events.proto" + string event_schema_uri = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// A representation of the FilteringAttribute resource. +// Filtering attributes are per event type. +message FilteringAttribute { + // Output only. Attribute used for filtering the event type. + string attribute = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Description of the purpose of the attribute. + string description = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. If true, the triggers for this provider should always specify a filter + // on these attributes. Trigger creation will fail otherwise. + bool required = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. If true, the attribute accepts matching expressions in the Eventarc + // PathPattern format. + bool path_pattern_supported = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; +} diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto new file mode 100644 index 000000000000..44d46fce3b86 --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/eventarc.proto @@ -0,0 +1,632 @@ +// Copyright 2022 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.eventarc.v1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/cloud/eventarc/v1/channel.proto"; +import "google/cloud/eventarc/v1/channel_connection.proto"; +import "google/cloud/eventarc/v1/discovery.proto"; +import "google/cloud/eventarc/v1/google_channel_config.proto"; +import "google/cloud/eventarc/v1/trigger.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/field_mask.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.Eventarc.V1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/eventarc/v1;eventarc"; +option java_multiple_files = true; +option java_outer_classname = "EventarcProto"; +option java_package = "com.google.cloud.eventarc.v1"; +option php_namespace = "Google\\Cloud\\Eventarc\\V1"; +option ruby_package = "Google::Cloud::Eventarc::V1"; + +// Eventarc allows users to subscribe to various events that are provided by +// Google Cloud services and forward them to supported destinations. +service Eventarc { + option (google.api.default_host) = "eventarc.googleapis.com"; + option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform"; + + // Get a single trigger. + rpc GetTrigger(GetTriggerRequest) returns (Trigger) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/triggers/*}" + }; + option (google.api.method_signature) = "name"; + } + + // List triggers. + rpc ListTriggers(ListTriggersRequest) returns (ListTriggersResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/triggers" + }; + option (google.api.method_signature) = "parent"; + } + + // Create a new trigger in a particular project and location. + rpc CreateTrigger(CreateTriggerRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/triggers" + body: "trigger" + }; + option (google.api.method_signature) = "parent,trigger,trigger_id"; + option (google.longrunning.operation_info) = { + response_type: "Trigger" + metadata_type: "OperationMetadata" + }; + } + + // Update a single trigger. + rpc UpdateTrigger(UpdateTriggerRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{trigger.name=projects/*/locations/*/triggers/*}" + body: "trigger" + }; + option (google.api.method_signature) = "trigger,update_mask,allow_missing"; + option (google.longrunning.operation_info) = { + response_type: "Trigger" + metadata_type: "OperationMetadata" + }; + } + + // Delete a single trigger. + rpc DeleteTrigger(DeleteTriggerRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/triggers/*}" + }; + option (google.api.method_signature) = "name,allow_missing"; + option (google.longrunning.operation_info) = { + response_type: "Trigger" + metadata_type: "OperationMetadata" + }; + } + + // Get a single Channel. + rpc GetChannel(GetChannelRequest) returns (Channel) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/channels/*}" + }; + option (google.api.method_signature) = "name"; + } + + // List channels. + rpc ListChannels(ListChannelsRequest) returns (ListChannelsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/channels" + }; + option (google.api.method_signature) = "parent"; + } + + // Create a new channel in a particular project and location. + rpc CreateChannel(CreateChannelRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/channels" + body: "channel" + }; + option (google.api.method_signature) = "parent,channel,channel_id"; + option (google.longrunning.operation_info) = { + response_type: "Channel" + metadata_type: "OperationMetadata" + }; + } + + // Update a single channel. + rpc UpdateChannel(UpdateChannelRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{channel.name=projects/*/locations/*/channels/*}" + body: "channel" + }; + option (google.api.method_signature) = "channel,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "Channel" + metadata_type: "OperationMetadata" + }; + } + + // Delete a single channel. + rpc DeleteChannel(DeleteChannelRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/channels/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "Channel" + metadata_type: "OperationMetadata" + }; + } + + // Get a single Provider. + rpc GetProvider(GetProviderRequest) returns (Provider) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/providers/*}" + }; + option (google.api.method_signature) = "name"; + } + + // List providers. + rpc ListProviders(ListProvidersRequest) returns (ListProvidersResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/providers" + }; + option (google.api.method_signature) = "parent"; + } + + // Get a single ChannelConnection. + rpc GetChannelConnection(GetChannelConnectionRequest) returns (ChannelConnection) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/channelConnections/*}" + }; + option (google.api.method_signature) = "name"; + } + + // List channel connections. + rpc ListChannelConnections(ListChannelConnectionsRequest) returns (ListChannelConnectionsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/channelConnections" + }; + option (google.api.method_signature) = "parent"; + } + + // Create a new ChannelConnection in a particular project and location. + rpc CreateChannelConnection(CreateChannelConnectionRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/channelConnections" + body: "channel_connection" + }; + option (google.api.method_signature) = "parent,channel_connection,channel_connection_id"; + option (google.longrunning.operation_info) = { + response_type: "ChannelConnection" + metadata_type: "OperationMetadata" + }; + } + + // Delete a single ChannelConnection. + rpc DeleteChannelConnection(DeleteChannelConnectionRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/channelConnections/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "ChannelConnection" + metadata_type: "OperationMetadata" + }; + } + + // Get a GoogleChannelConfig + rpc GetGoogleChannelConfig(GetGoogleChannelConfigRequest) returns (GoogleChannelConfig) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/googleChannelConfig}" + }; + option (google.api.method_signature) = "name"; + } + + // Update a single GoogleChannelConfig + rpc UpdateGoogleChannelConfig(UpdateGoogleChannelConfigRequest) returns (GoogleChannelConfig) { + option (google.api.http) = { + patch: "/v1/{google_channel_config.name=projects/*/locations/*/googleChannelConfig}" + body: "google_channel_config" + }; + option (google.api.method_signature) = "google_channel_config,update_mask"; + } +} + +// The request message for the GetTrigger method. +message GetTriggerRequest { + // Required. The name of the trigger to get. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/Trigger" + } + ]; +} + +// The request message for the ListTriggers method. +message ListTriggersRequest { + // Required. The parent collection to list triggers on. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/Trigger" + } + ]; + + // The maximum number of triggers to return on each page. + // + // Note: The service may send fewer. + int32 page_size = 2; + + // The page token; provide the value from the `next_page_token` field in a + // previous `ListTriggers` call to retrieve the subsequent page. + // + // When paginating, all other parameters provided to `ListTriggers` must match + // the call that provided the page token. + string page_token = 3; + + // The sorting order of the resources returned. Value should be a + // comma-separated list of fields. The default sorting order is ascending. To + // specify descending order for a field, append a `desc` suffix; for example: + // `name desc, trigger_id`. + string order_by = 4; + + // Filter field. Used to filter the Triggers to be listed. Possible filters + // are described in https://google.aip.dev/160. For example, using + // "?filter=destination:gke" would list only Triggers with a gke destination. + string filter = 5; +} + +// The response message for the `ListTriggers` method. +message ListTriggersResponse { + // The requested triggers, up to the number specified in `page_size`. + repeated Trigger triggers = 1; + + // A page token that can be sent to `ListTriggers` to request the next page. + // If this is empty, then there are no more pages. + string next_page_token = 2; + + // Unreachable resources, if any. + repeated string unreachable = 3; +} + +// The request message for the CreateTrigger method. +message CreateTriggerRequest { + // Required. The parent collection in which to add this trigger. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/Trigger" + } + ]; + + // Required. The trigger to create. + Trigger trigger = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The user-provided ID to be assigned to the trigger. + string trigger_id = 3 [(google.api.field_behavior) = REQUIRED]; + + // Required. If set, validate the request and preview the review, but do not + // post it. + bool validate_only = 4 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the UpdateTrigger method. +message UpdateTriggerRequest { + // The trigger to be updated. + Trigger trigger = 1; + + // The fields to be updated; only fields explicitly provided are updated. + // If no field mask is provided, all provided fields in the request are + // updated. To update all fields, provide a field mask of "*". + google.protobuf.FieldMask update_mask = 2; + + // If set to true, and the trigger is not found, a new trigger will be + // created. In this situation, `update_mask` is ignored. + bool allow_missing = 3; + + // Required. If set, validate the request and preview the review, but do not + // post it. + bool validate_only = 4 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the DeleteTrigger method. +message DeleteTriggerRequest { + // Required. The name of the trigger to be deleted. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/Trigger" + } + ]; + + // If provided, the trigger will only be deleted if the etag matches the + // current etag on the resource. + string etag = 2; + + // If set to true, and the trigger is not found, the request will succeed + // but no action will be taken on the server. + bool allow_missing = 3; + + // Required. If set, validate the request and preview the review, but do not + // post it. + bool validate_only = 4 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the GetChannel method. +message GetChannelRequest { + // Required. The name of the channel to get. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/Channel" + } + ]; +} + +// The request message for the ListChannels method. +message ListChannelsRequest { + // Required. The parent collection to list channels on. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/Channel" + } + ]; + + // The maximum number of channels to return on each page. + // + // Note: The service may send fewer. + int32 page_size = 2; + + // The page token; provide the value from the `next_page_token` field in a + // previous `ListChannels` call to retrieve the subsequent page. + // + // When paginating, all other parameters provided to `ListChannels` must + // match the call that provided the page token. + string page_token = 3; + + // The sorting order of the resources returned. Value should be a + // comma-separated list of fields. The default sorting order is ascending. To + // specify descending order for a field, append a `desc` suffix; for example: + // `name desc, channel_id`. + string order_by = 4; +} + +// The response message for the `ListChannels` method. +message ListChannelsResponse { + // The requested channels, up to the number specified in `page_size`. + repeated Channel channels = 1; + + // A page token that can be sent to `ListChannels` to request the next page. + // If this is empty, then there are no more pages. + string next_page_token = 2; + + // Unreachable resources, if any. + repeated string unreachable = 3; +} + +// The request message for the CreateChannel method. +message CreateChannelRequest { + // Required. The parent collection in which to add this channel. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/Channel" + } + ]; + + // Required. The channel to create. + Channel channel = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The user-provided ID to be assigned to the channel. + string channel_id = 3 [(google.api.field_behavior) = REQUIRED]; + + // Required. If set, validate the request and preview the review, but do not + // post it. + bool validate_only = 4 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the UpdateChannel method. +message UpdateChannelRequest { + // The channel to be updated. + Channel channel = 1; + + // The fields to be updated; only fields explicitly provided are updated. + // If no field mask is provided, all provided fields in the request are + // updated. To update all fields, provide a field mask of "*". + google.protobuf.FieldMask update_mask = 2; + + // Required. If set, validate the request and preview the review, but do not + // post it. + bool validate_only = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the DeleteChannel method. +message DeleteChannelRequest { + // Required. The name of the channel to be deleted. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/Channel" + } + ]; + + // Required. If set, validate the request and preview the review, but do not + // post it. + bool validate_only = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the GetProvider method. +message GetProviderRequest { + // Required. The name of the provider to get. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/Provider" + } + ]; +} + +// The request message for the ListProviders method. +message ListProvidersRequest { + // Required. The parent of the provider to get. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/Provider" + } + ]; + + // The maximum number of providers to return on each page. + int32 page_size = 2; + + // The page token; provide the value from the `next_page_token` field in a + // previous `ListProviders` call to retrieve the subsequent page. + // + // When paginating, all other parameters provided to `ListProviders` must + // match the call that provided the page token. + string page_token = 3; + + // The sorting order of the resources returned. Value should be a + // comma-separated list of fields. The default sorting oder is ascending. To + // specify descending order for a field, append a `desc` suffix; for example: + // `name desc, _id`. + string order_by = 4; + + // The filter field that the list request will filter on. + string filter = 5; +} + +// The response message for the `ListProviders` method. +message ListProvidersResponse { + // The requested providers, up to the number specified in `page_size`. + repeated Provider providers = 1; + + // A page token that can be sent to `ListProviders` to request the next page. + // If this is empty, then there are no more pages. + string next_page_token = 2; + + // Unreachable resources, if any. + repeated string unreachable = 3; +} + +// The request message for the GetChannelConnection method. +message GetChannelConnectionRequest { + // Required. The name of the channel connection to get. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/ChannelConnection" + } + ]; +} + +// The request message for the ListChannelConnections method. +message ListChannelConnectionsRequest { + // Required. The parent collection from which to list channel connections. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/ChannelConnection" + } + ]; + + // The maximum number of channel connections to return on each page. + // + // Note: The service may send fewer responses. + int32 page_size = 2; + + // The page token; provide the value from the `next_page_token` field in a + // previous `ListChannelConnections` call to retrieve the subsequent page. + // + // When paginating, all other parameters provided to `ListChannelConnetions` + // match the call that provided the page token. + string page_token = 3; +} + +// The response message for the `ListChannelConnections` method. +message ListChannelConnectionsResponse { + // The requested channel connections, up to the number specified in + // `page_size`. + repeated ChannelConnection channel_connections = 1; + + // A page token that can be sent to `ListChannelConnections` to request the + // next page. + // If this is empty, then there are no more pages. + string next_page_token = 2; + + // Unreachable resources, if any. + repeated string unreachable = 3; +} + +// The request message for the CreateChannelConnection method. +message CreateChannelConnectionRequest { + // Required. The parent collection in which to add this channel connection. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "eventarc.googleapis.com/ChannelConnection" + } + ]; + + // Required. Channel connection to create. + ChannelConnection channel_connection = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The user-provided ID to be assigned to the channel connection. + string channel_connection_id = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for the DeleteChannelConnection method. +message DeleteChannelConnectionRequest { + // Required. The name of the channel connection to delete. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/ChannelConnection" + } + ]; +} + +// The request message for the UpdateGoogleChannelConfig method. +message UpdateGoogleChannelConfigRequest { + // Required. The config to be updated. + GoogleChannelConfig google_channel_config = 1 [(google.api.field_behavior) = REQUIRED]; + + // The fields to be updated; only fields explicitly provided are updated. + // If no field mask is provided, all provided fields in the request are + // updated. To update all fields, provide a field mask of "*". + google.protobuf.FieldMask update_mask = 2; +} + +// The request message for the GetGoogleChannelConfig method. +message GetGoogleChannelConfigRequest { + // Required. The name of the config to get. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "eventarc.googleapis.com/GoogleChannelConfig" + } + ]; +} + +// Represents the metadata of the long-running operation. +message OperationMetadata { + // Output only. The time the operation was created. + google.protobuf.Timestamp create_time = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time the operation finished running. + google.protobuf.Timestamp end_time = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Server-defined resource path for the target of the operation. + string target = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Name of the verb executed by the operation. + string verb = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Human-readable status of the operation, if any. + string status_message = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Identifies whether the user has requested cancellation + // of the operation. Operations that have successfully been cancelled + // have [Operation.error][] value with a [google.rpc.Status.code][google.rpc.Status.code] of 1, + // corresponding to `Code.CANCELLED`. + bool requested_cancellation = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. API version used to start the operation. + string api_version = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; +} diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto new file mode 100644 index 000000000000..2b440b57dc4a --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/google_channel_config.proto @@ -0,0 +1,65 @@ +// Copyright 2022 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.eventarc.v1; + +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; + +option csharp_namespace = "Google.Cloud.Eventarc.V1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/eventarc/v1;eventarc"; +option java_multiple_files = true; +option java_outer_classname = "GoogleChannelConfigProto"; +option java_package = "com.google.cloud.eventarc.v1"; +option php_namespace = "Google\\Cloud\\Eventarc\\V1"; +option ruby_package = "Google::Cloud::Eventarc::V1"; +option (google.api.resource_definition) = { + type: "cloudkms.googleapis.com/CryptoKey" + pattern: "projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}" +}; + +// A GoogleChannelConfig is a resource that stores the custom settings +// respected by Eventarc first-party triggers in the matching region. +// Once configured, first-party event data will be protected +// using the specified custom managed encryption key instead of Google-managed +// encryption keys. +message GoogleChannelConfig { + option (google.api.resource) = { + type: "eventarc.googleapis.com/GoogleChannelConfig" + pattern: "projects/{project}/locations/{location}/googleChannelConfig" + singular: "googleChannelConfig" + }; + + // Required. The resource name of the config. Must be in the format of, + // `projects/{project}/locations/{location}/googleChannelConfig`. + string name = 1 [(google.api.field_behavior) = REQUIRED]; + + // Output only. The last-modified time. + google.protobuf.Timestamp update_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Resource name of a KMS crypto key (managed by the user) used to + // encrypt/decrypt their event data. + // + // It must match the pattern + // `projects/*/locations/*/keyRings/*/cryptoKeys/*`. + string crypto_key_name = 7 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "cloudkms.googleapis.com/CryptoKey" + } + ]; +} diff --git a/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto new file mode 100644 index 000000000000..c4ede775f0af --- /dev/null +++ b/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/proto/google/cloud/eventarc/v1/trigger.proto @@ -0,0 +1,251 @@ +// Copyright 2022 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +syntax = "proto3"; + +package google.cloud.eventarc.v1; + +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/timestamp.proto"; +import "google/rpc/code.proto"; + +option go_package = "google.golang.org/genproto/googleapis/cloud/eventarc/v1;eventarc"; +option java_multiple_files = true; +option java_outer_classname = "TriggerProto"; +option java_package = "com.google.cloud.eventarc.v1"; +option (google.api.resource_definition) = { + type: "cloudfunctions.googleapis.com/CloudFunction" + pattern: "projects/{project}/locations/{location}/functions/{function}" +}; +option (google.api.resource_definition) = { + type: "iam.googleapis.com/ServiceAccount" + pattern: "projects/{project}/serviceAccounts/{service_account}" +}; +option (google.api.resource_definition) = { + type: "run.googleapis.com/Service" + pattern: "*" +}; +option (google.api.resource_definition) = { + type: "workflows.googleapis.com/Workflow" + pattern: "projects/{project}/locations/{location}/workflows/{workflow}" +}; + + +// A representation of the trigger resource. +message Trigger { + option (google.api.resource) = { + type: "eventarc.googleapis.com/Trigger" + pattern: "projects/{project}/locations/{location}/triggers/{trigger}" + plural: "triggers" + singular: "trigger" + }; + + // Required. The resource name of the trigger. Must be unique within the location of the + // project and must be in + // `projects/{project}/locations/{location}/triggers/{trigger}` format. + string name = 1 [(google.api.field_behavior) = REQUIRED]; + + // Output only. Server-assigned unique identifier for the trigger. The value is a UUID4 + // string and guaranteed to remain unchanged until the resource is deleted. + string uid = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The creation time. + google.protobuf.Timestamp create_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The last-modified time. + google.protobuf.Timestamp update_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Required. Unordered list. The list of filters that applies to event attributes. Only events that + // match all the provided filters are sent to the destination. + repeated EventFilter event_filters = 8 [ + (google.api.field_behavior) = UNORDERED_LIST, + (google.api.field_behavior) = REQUIRED + ]; + + // Optional. The IAM service account email associated with the trigger. The + // service account represents the identity of the trigger. + // + // The principal who calls this API must have the `iam.serviceAccounts.actAs` + // permission in the service account. See + // https://cloud.google.com/iam/docs/understanding-service-accounts?hl=en#sa_common + // for more information. + // + // For Cloud Run destinations, this service account is used to generate + // identity tokens when invoking the service. See + // https://cloud.google.com/run/docs/triggering/pubsub-push#create-service-account + // for information on how to invoke authenticated Cloud Run services. + // To create Audit Log triggers, the service account should also + // have the `roles/eventarc.eventReceiver` IAM role. + string service_account = 9 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "iam.googleapis.com/ServiceAccount" + } + ]; + + // Required. Destination specifies where the events should be sent to. + Destination destination = 10 [(google.api.field_behavior) = REQUIRED]; + + // Optional. To deliver messages, Eventarc might use other GCP + // products as a transport intermediary. This field contains a reference to + // that transport intermediary. This information can be used for debugging + // purposes. + Transport transport = 11 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. User labels attached to the triggers that can be used to group resources. + map labels = 12 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The name of the channel associated with the trigger in + // `projects/{project}/locations/{location}/channels/{channel}` format. + // You must provide a channel to receive events from Eventarc SaaS partners. + string channel = 13 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The reason(s) why a trigger is in FAILED state. + map conditions = 15 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. This checksum is computed by the server based on the value of other + // fields, and might be sent only on create requests to ensure that the + // client has an up-to-date value before proceeding. + string etag = 99 [(google.api.field_behavior) = OUTPUT_ONLY]; +} + +// Filters events based on exact matches on the CloudEvents attributes. +message EventFilter { + // Required. The name of a CloudEvents attribute. Currently, only a subset of attributes + // are supported for filtering. + // + // All triggers MUST provide a filter for the 'type' attribute. + string attribute = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The value for the attribute. + string value = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The operator used for matching the events with the value of the + // filter. If not specified, only events that have an exact key-value pair + // specified in the filter are matched. The only allowed value is + // `match-path-pattern`. + string operator = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// A condition that is part of the trigger state computation. +message StateCondition { + // The canonical code of the condition. + google.rpc.Code code = 1; + + // Human-readable message. + string message = 2; +} + +// Represents a target of an invocation over HTTP. +message Destination { + oneof descriptor { + // Cloud Run fully-managed resource that receives the events. The resource + // should be in the same project as the trigger. + CloudRun cloud_run = 1; + + // The Cloud Function resource name. Only Cloud Functions V2 is supported. + // Format: `projects/{project}/locations/{location}/functions/{function}` + string cloud_function = 2 [(google.api.resource_reference) = { + type: "cloudfunctions.googleapis.com/CloudFunction" + }]; + + // A GKE service capable of receiving events. The service should be running + // in the same project as the trigger. + GKE gke = 3; + + // The resource name of the Workflow whose Executions are triggered by + // the events. The Workflow resource should be deployed in the same project + // as the trigger. + // Format: `projects/{project}/locations/{location}/workflows/{workflow}` + string workflow = 4 [(google.api.resource_reference) = { + type: "workflows.googleapis.com/Workflow" + }]; + } +} + +// Represents the transport intermediaries created for the trigger to +// deliver events. +message Transport { + oneof intermediary { + // The Pub/Sub topic and subscription used by Eventarc as a transport + // intermediary. + Pubsub pubsub = 1; + } +} + +// Represents a Cloud Run destination. +message CloudRun { + // Required. The name of the Cloud Run service being addressed. See + // https://cloud.google.com/run/docs/reference/rest/v1/namespaces.services. + // + // Only services located in the same project as the trigger object + // can be addressed. + string service = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "run.googleapis.com/Service" + } + ]; + + // Optional. The relative path on the Cloud Run service the events should be sent to. + // + // The value must conform to the definition of a URI path segment (section 3.3 + // of RFC2396). Examples: "/route", "route", "route/subroute". + string path = 2 [(google.api.field_behavior) = OPTIONAL]; + + // Required. The region the Cloud Run service is deployed in. + string region = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// Represents a GKE destination. +message GKE { + // Required. The name of the cluster the GKE service is running in. The cluster must be + // running in the same project as the trigger being created. + string cluster = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The name of the Google Compute Engine in which the cluster resides, which + // can either be compute zone (for example, us-central1-a) for the zonal + // clusters or region (for example, us-central1) for regional clusters. + string location = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The namespace the GKE service is running in. + string namespace = 3 [(google.api.field_behavior) = REQUIRED]; + + // Required. Name of the GKE service. + string service = 4 [(google.api.field_behavior) = REQUIRED]; + + // Optional. The relative path on the GKE service the events should be sent to. + // + // The value must conform to the definition of a URI path segment (section 3.3 + // of RFC2396). Examples: "/route", "route", "route/subroute". + string path = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// Represents a Pub/Sub transport. +message Pubsub { + // Optional. The name of the Pub/Sub topic created and managed by Eventarc as + // a transport for the event delivery. Format: + // `projects/{PROJECT_ID}/topics/{TOPIC_NAME}`. + // + // You can set an existing topic for triggers of the type + // `google.cloud.pubsub.topic.v1.messagePublished`. The topic you provide + // here is not deleted by Eventarc at trigger deletion. + string topic = 1 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The name of the Pub/Sub subscription created and managed by Eventarc + // as a transport for the event delivery. Format: + // `projects/{PROJECT_ID}/subscriptions/{SUBSCRIPTION_NAME}`. + string subscription = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; +} diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java new file mode 100644 index 000000000000..94b19419c5e0 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_Create_SetCredentialsProvider_sync] +import com.google.api.gax.core.FixedCredentialsProvider; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.EventarcSettings; +import com.google.cloud.eventarc.v1.myCredentials; + +public class SyncCreateSetCredentialsProvider { + + public static void main(String[] args) throws Exception { + syncCreateSetCredentialsProvider(); + } + + public static void syncCreateSetCredentialsProvider() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + EventarcSettings eventarcSettings = + EventarcSettings.newBuilder() + .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)) + .build(); + EventarcClient eventarcClient = EventarcClient.create(eventarcSettings); + } +} +// [END eventarc_v1_generated_Eventarc_Create_SetCredentialsProvider_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java new file mode 100644 index 000000000000..dc2974680f5b --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetCredentialsProvider1.java @@ -0,0 +1,39 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_Create_SetCredentialsProvider1_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.EventarcSettings; + +public class SyncCreateSetCredentialsProvider1 { + + public static void main(String[] args) throws Exception { + syncCreateSetCredentialsProvider1(); + } + + public static void syncCreateSetCredentialsProvider1() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + EventarcSettings eventarcSettings = EventarcSettings.newHttpJsonBuilder().build(); + EventarcClient eventarcClient = EventarcClient.create(eventarcSettings); + } +} +// [END eventarc_v1_generated_Eventarc_Create_SetCredentialsProvider1_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java new file mode 100644 index 000000000000..343b2bb96a6d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/create/SyncCreateSetEndpoint.java @@ -0,0 +1,41 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_Create_SetEndpoint_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.EventarcSettings; +import com.google.cloud.eventarc.v1.myEndpoint; + +public class SyncCreateSetEndpoint { + + public static void main(String[] args) throws Exception { + syncCreateSetEndpoint(); + } + + public static void syncCreateSetEndpoint() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + EventarcSettings eventarcSettings = + EventarcSettings.newBuilder().setEndpoint(myEndpoint).build(); + EventarcClient eventarcClient = EventarcClient.create(eventarcSettings); + } +} +// [END eventarc_v1_generated_Eventarc_Create_SetEndpoint_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java new file mode 100644 index 000000000000..6e53e3b7d9a5 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannel.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannel_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.longrunning.Operation; + +public class AsyncCreateChannel { + + public static void main(String[] args) throws Exception { + asyncCreateChannel(); + } + + public static void asyncCreateChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateChannelRequest request = + CreateChannelRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setChannel(Channel.newBuilder().build()) + .setChannelId("channelId1461735806") + .setValidateOnly(true) + .build(); + ApiFuture future = eventarcClient.createChannelCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannel_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java new file mode 100644 index 000000000000..8764d977b68c --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/AsyncCreateChannelLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannel_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.OperationMetadata; + +public class AsyncCreateChannelLRO { + + public static void main(String[] args) throws Exception { + asyncCreateChannelLRO(); + } + + public static void asyncCreateChannelLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateChannelRequest request = + CreateChannelRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setChannel(Channel.newBuilder().build()) + .setChannelId("channelId1461735806") + .setValidateOnly(true) + .build(); + OperationFuture future = + eventarcClient.createChannelOperationCallable().futureCall(request); + // Do something. + Channel response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannel_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java new file mode 100644 index 000000000000..096e698fd6a2 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannel.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannel_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.CreateChannelRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncCreateChannel { + + public static void main(String[] args) throws Exception { + syncCreateChannel(); + } + + public static void syncCreateChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateChannelRequest request = + CreateChannelRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setChannel(Channel.newBuilder().build()) + .setChannelId("channelId1461735806") + .setValidateOnly(true) + .build(); + Channel response = eventarcClient.createChannelAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannel_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java new file mode 100644 index 000000000000..07b84db29317 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelLocationnameChannelString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannel_LocationnameChannelString_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncCreateChannelLocationnameChannelString { + + public static void main(String[] args) throws Exception { + syncCreateChannelLocationnameChannelString(); + } + + public static void syncCreateChannelLocationnameChannelString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + Channel response = eventarcClient.createChannelAsync(parent, channel, channelId).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannel_LocationnameChannelString_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java new file mode 100644 index 000000000000..61aba2068fb5 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannel/SyncCreateChannelStringChannelString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannel_StringChannelString_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncCreateChannelStringChannelString { + + public static void main(String[] args) throws Exception { + syncCreateChannelStringChannelString(); + } + + public static void syncCreateChannelStringChannelString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + Channel channel = Channel.newBuilder().build(); + String channelId = "channelId1461735806"; + Channel response = eventarcClient.createChannelAsync(parent, channel, channelId).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannel_StringChannelString_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java new file mode 100644 index 000000000000..cefe78bd01f1 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnection.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannelConnection_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.longrunning.Operation; + +public class AsyncCreateChannelConnection { + + public static void main(String[] args) throws Exception { + asyncCreateChannelConnection(); + } + + public static void asyncCreateChannelConnection() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateChannelConnectionRequest request = + CreateChannelConnectionRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setChannelConnection(ChannelConnection.newBuilder().build()) + .setChannelConnectionId("channelConnectionId-1246974660") + .build(); + ApiFuture future = + eventarcClient.createChannelConnectionCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannelConnection_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java new file mode 100644 index 000000000000..b4583454b4e4 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/AsyncCreateChannelConnectionLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannelConnection_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.OperationMetadata; + +public class AsyncCreateChannelConnectionLRO { + + public static void main(String[] args) throws Exception { + asyncCreateChannelConnectionLRO(); + } + + public static void asyncCreateChannelConnectionLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateChannelConnectionRequest request = + CreateChannelConnectionRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setChannelConnection(ChannelConnection.newBuilder().build()) + .setChannelConnectionId("channelConnectionId-1246974660") + .build(); + OperationFuture future = + eventarcClient.createChannelConnectionOperationCallable().futureCall(request); + // Do something. + ChannelConnection response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannelConnection_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java new file mode 100644 index 000000000000..a4c9d79af87d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnection.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannelConnection_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.CreateChannelConnectionRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncCreateChannelConnection { + + public static void main(String[] args) throws Exception { + syncCreateChannelConnection(); + } + + public static void syncCreateChannelConnection() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateChannelConnectionRequest request = + CreateChannelConnectionRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setChannelConnection(ChannelConnection.newBuilder().build()) + .setChannelConnectionId("channelConnectionId-1246974660") + .build(); + ChannelConnection response = eventarcClient.createChannelConnectionAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannelConnection_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java new file mode 100644 index 000000000000..268cceef225e --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionLocationnameChannelconnectionString.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannelConnection_LocationnameChannelconnectionString_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncCreateChannelConnectionLocationnameChannelconnectionString { + + public static void main(String[] args) throws Exception { + syncCreateChannelConnectionLocationnameChannelconnectionString(); + } + + public static void syncCreateChannelConnectionLocationnameChannelconnectionString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + ChannelConnection response = + eventarcClient + .createChannelConnectionAsync(parent, channelConnection, channelConnectionId) + .get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannelConnection_LocationnameChannelconnectionString_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java new file mode 100644 index 000000000000..badb6cdb2d49 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createchannelconnection/SyncCreateChannelConnectionStringChannelconnectionString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateChannelConnection_StringChannelconnectionString_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncCreateChannelConnectionStringChannelconnectionString { + + public static void main(String[] args) throws Exception { + syncCreateChannelConnectionStringChannelconnectionString(); + } + + public static void syncCreateChannelConnectionStringChannelconnectionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + ChannelConnection channelConnection = ChannelConnection.newBuilder().build(); + String channelConnectionId = "channelConnectionId-1246974660"; + ChannelConnection response = + eventarcClient + .createChannelConnectionAsync(parent, channelConnection, channelConnectionId) + .get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateChannelConnection_StringChannelconnectionString_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java new file mode 100644 index 000000000000..2b478302557d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTrigger.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateTrigger_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.longrunning.Operation; + +public class AsyncCreateTrigger { + + public static void main(String[] args) throws Exception { + asyncCreateTrigger(); + } + + public static void asyncCreateTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateTriggerRequest request = + CreateTriggerRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setTrigger(Trigger.newBuilder().build()) + .setTriggerId("triggerId-648752909") + .setValidateOnly(true) + .build(); + ApiFuture future = eventarcClient.createTriggerCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateTrigger_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java new file mode 100644 index 000000000000..2cde44c536ce --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/AsyncCreateTriggerLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateTrigger_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Trigger; + +public class AsyncCreateTriggerLRO { + + public static void main(String[] args) throws Exception { + asyncCreateTriggerLRO(); + } + + public static void asyncCreateTriggerLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateTriggerRequest request = + CreateTriggerRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setTrigger(Trigger.newBuilder().build()) + .setTriggerId("triggerId-648752909") + .setValidateOnly(true) + .build(); + OperationFuture future = + eventarcClient.createTriggerOperationCallable().futureCall(request); + // Do something. + Trigger response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateTrigger_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java new file mode 100644 index 000000000000..5ee7cb407094 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTrigger.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateTrigger_sync] +import com.google.cloud.eventarc.v1.CreateTriggerRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class SyncCreateTrigger { + + public static void main(String[] args) throws Exception { + syncCreateTrigger(); + } + + public static void syncCreateTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + CreateTriggerRequest request = + CreateTriggerRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setTrigger(Trigger.newBuilder().build()) + .setTriggerId("triggerId-648752909") + .setValidateOnly(true) + .build(); + Trigger response = eventarcClient.createTriggerAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateTrigger_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java new file mode 100644 index 000000000000..559aaecf0dc1 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerLocationnameTriggerString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateTrigger_LocationnameTriggerString_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class SyncCreateTriggerLocationnameTriggerString { + + public static void main(String[] args) throws Exception { + syncCreateTriggerLocationnameTriggerString(); + } + + public static void syncCreateTriggerLocationnameTriggerString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + Trigger response = eventarcClient.createTriggerAsync(parent, trigger, triggerId).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateTrigger_LocationnameTriggerString_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java new file mode 100644 index 000000000000..86431178c286 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/createtrigger/SyncCreateTriggerStringTriggerString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_CreateTrigger_StringTriggerString_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class SyncCreateTriggerStringTriggerString { + + public static void main(String[] args) throws Exception { + syncCreateTriggerStringTriggerString(); + } + + public static void syncCreateTriggerStringTriggerString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + Trigger trigger = Trigger.newBuilder().build(); + String triggerId = "triggerId-648752909"; + Trigger response = eventarcClient.createTriggerAsync(parent, trigger, triggerId).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_CreateTrigger_StringTriggerString_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java new file mode 100644 index 000000000000..c82cc94ec6d7 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannel.java @@ -0,0 +1,50 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannel_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.longrunning.Operation; + +public class AsyncDeleteChannel { + + public static void main(String[] args) throws Exception { + asyncDeleteChannel(); + } + + public static void asyncDeleteChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteChannelRequest request = + DeleteChannelRequest.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setValidateOnly(true) + .build(); + ApiFuture future = eventarcClient.deleteChannelCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannel_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java new file mode 100644 index 000000000000..892dd29058a5 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/AsyncDeleteChannelLRO.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannel_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.OperationMetadata; + +public class AsyncDeleteChannelLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteChannelLRO(); + } + + public static void asyncDeleteChannelLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteChannelRequest request = + DeleteChannelRequest.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setValidateOnly(true) + .build(); + OperationFuture future = + eventarcClient.deleteChannelOperationCallable().futureCall(request); + // Do something. + Channel response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannel_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java new file mode 100644 index 000000000000..cc576eb33650 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannel.java @@ -0,0 +1,47 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannel_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.DeleteChannelRequest; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncDeleteChannel { + + public static void main(String[] args) throws Exception { + syncDeleteChannel(); + } + + public static void syncDeleteChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteChannelRequest request = + DeleteChannelRequest.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setValidateOnly(true) + .build(); + Channel response = eventarcClient.deleteChannelAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannel_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java new file mode 100644 index 000000000000..23f7c3033f07 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelChannelname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannel_Channelname_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncDeleteChannelChannelname { + + public static void main(String[] args) throws Exception { + syncDeleteChannelChannelname(); + } + + public static void syncDeleteChannelChannelname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + Channel response = eventarcClient.deleteChannelAsync(name).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannel_Channelname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java new file mode 100644 index 000000000000..00853db136d7 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannel/SyncDeleteChannelString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannel_String_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncDeleteChannelString { + + public static void main(String[] args) throws Exception { + syncDeleteChannelString(); + } + + public static void syncDeleteChannelString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString(); + Channel response = eventarcClient.deleteChannelAsync(name).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannel_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java new file mode 100644 index 000000000000..30245363382f --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnection.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannelConnection_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.longrunning.Operation; + +public class AsyncDeleteChannelConnection { + + public static void main(String[] args) throws Exception { + asyncDeleteChannelConnection(); + } + + public static void asyncDeleteChannelConnection() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteChannelConnectionRequest request = + DeleteChannelConnectionRequest.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .build(); + ApiFuture future = + eventarcClient.deleteChannelConnectionCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannelConnection_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java new file mode 100644 index 000000000000..f2aa4cdb03b0 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/AsyncDeleteChannelConnectionLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannelConnection_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.OperationMetadata; + +public class AsyncDeleteChannelConnectionLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteChannelConnectionLRO(); + } + + public static void asyncDeleteChannelConnectionLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteChannelConnectionRequest request = + DeleteChannelConnectionRequest.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .build(); + OperationFuture future = + eventarcClient.deleteChannelConnectionOperationCallable().futureCall(request); + // Do something. + ChannelConnection response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannelConnection_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java new file mode 100644 index 000000000000..3d04faa5c943 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnection.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannelConnection_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncDeleteChannelConnection { + + public static void main(String[] args) throws Exception { + syncDeleteChannelConnection(); + } + + public static void syncDeleteChannelConnection() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteChannelConnectionRequest request = + DeleteChannelConnectionRequest.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .build(); + ChannelConnection response = eventarcClient.deleteChannelConnectionAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannelConnection_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java new file mode 100644 index 000000000000..90c0717dd0f4 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionChannelconnectionname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannelConnection_Channelconnectionname_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncDeleteChannelConnectionChannelconnectionname { + + public static void main(String[] args) throws Exception { + syncDeleteChannelConnectionChannelconnectionname(); + } + + public static void syncDeleteChannelConnectionChannelconnectionname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + ChannelConnection response = eventarcClient.deleteChannelConnectionAsync(name).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannelConnection_Channelconnectionname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java new file mode 100644 index 000000000000..6b93e3f3d738 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletechannelconnection/SyncDeleteChannelConnectionString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteChannelConnection_String_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncDeleteChannelConnectionString { + + public static void main(String[] args) throws Exception { + syncDeleteChannelConnectionString(); + } + + public static void syncDeleteChannelConnectionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]").toString(); + ChannelConnection response = eventarcClient.deleteChannelConnectionAsync(name).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteChannelConnection_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java new file mode 100644 index 000000000000..29916b56d6f5 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTrigger.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteTrigger_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.TriggerName; +import com.google.longrunning.Operation; + +public class AsyncDeleteTrigger { + + public static void main(String[] args) throws Exception { + asyncDeleteTrigger(); + } + + public static void asyncDeleteTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteTriggerRequest request = + DeleteTriggerRequest.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setEtag("etag3123477") + .setAllowMissing(true) + .setValidateOnly(true) + .build(); + ApiFuture future = eventarcClient.deleteTriggerCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteTrigger_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java new file mode 100644 index 000000000000..9897245a727d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/AsyncDeleteTriggerLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteTrigger_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class AsyncDeleteTriggerLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteTriggerLRO(); + } + + public static void asyncDeleteTriggerLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteTriggerRequest request = + DeleteTriggerRequest.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setEtag("etag3123477") + .setAllowMissing(true) + .setValidateOnly(true) + .build(); + OperationFuture future = + eventarcClient.deleteTriggerOperationCallable().futureCall(request); + // Do something. + Trigger response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteTrigger_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java new file mode 100644 index 000000000000..4508d579fae7 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTrigger.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteTrigger_sync] +import com.google.cloud.eventarc.v1.DeleteTriggerRequest; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class SyncDeleteTrigger { + + public static void main(String[] args) throws Exception { + syncDeleteTrigger(); + } + + public static void syncDeleteTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + DeleteTriggerRequest request = + DeleteTriggerRequest.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .setEtag("etag3123477") + .setAllowMissing(true) + .setValidateOnly(true) + .build(); + Trigger response = eventarcClient.deleteTriggerAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteTrigger_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java new file mode 100644 index 000000000000..887fee9310a1 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerStringBoolean.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteTrigger_StringBoolean_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class SyncDeleteTriggerStringBoolean { + + public static void main(String[] args) throws Exception { + syncDeleteTriggerStringBoolean(); + } + + public static void syncDeleteTriggerStringBoolean() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString(); + boolean allowMissing = true; + Trigger response = eventarcClient.deleteTriggerAsync(name, allowMissing).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteTrigger_StringBoolean_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java new file mode 100644 index 000000000000..e48588a23418 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/deletetrigger/SyncDeleteTriggerTriggernameBoolean.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_DeleteTrigger_TriggernameBoolean_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class SyncDeleteTriggerTriggernameBoolean { + + public static void main(String[] args) throws Exception { + syncDeleteTriggerTriggernameBoolean(); + } + + public static void syncDeleteTriggerTriggernameBoolean() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + boolean allowMissing = true; + Trigger response = eventarcClient.deleteTriggerAsync(name, allowMissing).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_DeleteTrigger_TriggernameBoolean_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java new file mode 100644 index 000000000000..850432a6f2b5 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/AsyncGetChannel.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannel_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetChannelRequest; + +public class AsyncGetChannel { + + public static void main(String[] args) throws Exception { + asyncGetChannel(); + } + + public static void asyncGetChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetChannelRequest request = + GetChannelRequest.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .build(); + ApiFuture future = eventarcClient.getChannelCallable().futureCall(request); + // Do something. + Channel response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannel_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java new file mode 100644 index 000000000000..add566e8168f --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannel.java @@ -0,0 +1,46 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannel_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetChannelRequest; + +public class SyncGetChannel { + + public static void main(String[] args) throws Exception { + syncGetChannel(); + } + + public static void syncGetChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetChannelRequest request = + GetChannelRequest.newBuilder() + .setName(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .build(); + Channel response = eventarcClient.getChannel(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannel_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java new file mode 100644 index 000000000000..cd73793fe33d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelChannelname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannel_Channelname_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncGetChannelChannelname { + + public static void main(String[] args) throws Exception { + syncGetChannelChannelname(); + } + + public static void syncGetChannelChannelname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ChannelName name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]"); + Channel response = eventarcClient.getChannel(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannel_Channelname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java new file mode 100644 index 000000000000..f6f47133fda1 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannel/SyncGetChannelString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannel_String_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncGetChannelString { + + public static void main(String[] args) throws Exception { + syncGetChannelString(); + } + + public static void syncGetChannelString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString(); + Channel response = eventarcClient.getChannel(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannel_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java new file mode 100644 index 000000000000..e7aa50bdbea3 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/AsyncGetChannelConnection.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannelConnection_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetChannelConnectionRequest; + +public class AsyncGetChannelConnection { + + public static void main(String[] args) throws Exception { + asyncGetChannelConnection(); + } + + public static void asyncGetChannelConnection() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetChannelConnectionRequest request = + GetChannelConnectionRequest.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .build(); + ApiFuture future = + eventarcClient.getChannelConnectionCallable().futureCall(request); + // Do something. + ChannelConnection response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannelConnection_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java new file mode 100644 index 000000000000..54709e43be3e --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnection.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannelConnection_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetChannelConnectionRequest; + +public class SyncGetChannelConnection { + + public static void main(String[] args) throws Exception { + syncGetChannelConnection(); + } + + public static void syncGetChannelConnection() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetChannelConnectionRequest request = + GetChannelConnectionRequest.newBuilder() + .setName( + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]") + .toString()) + .build(); + ChannelConnection response = eventarcClient.getChannelConnection(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannelConnection_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java new file mode 100644 index 000000000000..a927bff615d6 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionChannelconnectionname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannelConnection_Channelconnectionname_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncGetChannelConnectionChannelconnectionname { + + public static void main(String[] args) throws Exception { + syncGetChannelConnectionChannelconnectionname(); + } + + public static void syncGetChannelConnectionChannelconnectionname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ChannelConnectionName name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]"); + ChannelConnection response = eventarcClient.getChannelConnection(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannelConnection_Channelconnectionname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java new file mode 100644 index 000000000000..e289272662b6 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getchannelconnection/SyncGetChannelConnectionString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetChannelConnection_String_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.ChannelConnectionName; +import com.google.cloud.eventarc.v1.EventarcClient; + +public class SyncGetChannelConnectionString { + + public static void main(String[] args) throws Exception { + syncGetChannelConnectionString(); + } + + public static void syncGetChannelConnectionString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = + ChannelConnectionName.of("[PROJECT]", "[LOCATION]", "[CHANNEL_CONNECTION]").toString(); + ChannelConnection response = eventarcClient.getChannelConnection(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetChannelConnection_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java new file mode 100644 index 000000000000..cd1da8a90459 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/AsyncGetGoogleChannelConfig.java @@ -0,0 +1,50 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.GoogleChannelConfigName; + +public class AsyncGetGoogleChannelConfig { + + public static void main(String[] args) throws Exception { + asyncGetGoogleChannelConfig(); + } + + public static void asyncGetGoogleChannelConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetGoogleChannelConfigRequest request = + GetGoogleChannelConfigRequest.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + ApiFuture future = + eventarcClient.getGoogleChannelConfigCallable().futureCall(request); + // Do something. + GoogleChannelConfig response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java new file mode 100644 index 000000000000..6f7efe5d7209 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfig.java @@ -0,0 +1,46 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.GoogleChannelConfigName; + +public class SyncGetGoogleChannelConfig { + + public static void main(String[] args) throws Exception { + syncGetGoogleChannelConfig(); + } + + public static void syncGetGoogleChannelConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetGoogleChannelConfigRequest request = + GetGoogleChannelConfigRequest.newBuilder() + .setName(GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString()) + .build(); + GoogleChannelConfig response = eventarcClient.getGoogleChannelConfig(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java new file mode 100644 index 000000000000..cb60c7c9c0a3 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigGooglechannelconfigname.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_Googlechannelconfigname_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.GoogleChannelConfigName; + +public class SyncGetGoogleChannelConfigGooglechannelconfigname { + + public static void main(String[] args) throws Exception { + syncGetGoogleChannelConfigGooglechannelconfigname(); + } + + public static void syncGetGoogleChannelConfigGooglechannelconfigname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GoogleChannelConfigName name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]"); + GoogleChannelConfig response = eventarcClient.getGoogleChannelConfig(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_Googlechannelconfigname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java new file mode 100644 index 000000000000..83a8c30a5a5d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getgooglechannelconfig/SyncGetGoogleChannelConfigString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_String_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.GoogleChannelConfigName; + +public class SyncGetGoogleChannelConfigString { + + public static void main(String[] args) throws Exception { + syncGetGoogleChannelConfigString(); + } + + public static void syncGetGoogleChannelConfigString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = GoogleChannelConfigName.of("[PROJECT]", "[LOCATION]").toString(); + GoogleChannelConfig response = eventarcClient.getGoogleChannelConfig(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetGoogleChannelConfig_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java new file mode 100644 index 000000000000..557400c78620 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/AsyncGetIamPolicy.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetIamPolicy_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; + +public class AsyncGetIamPolicy { + + public static void main(String[] args) throws Exception { + asyncGetIamPolicy(); + } + + public static void asyncGetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + ApiFuture future = eventarcClient.getIamPolicyCallable().futureCall(request); + // Do something. + Policy response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetIamPolicy_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java new file mode 100644 index 000000000000..90454e341865 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getiampolicy/SyncGetIamPolicy.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetIamPolicy_sync] +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.iam.v1.GetIamPolicyRequest; +import com.google.iam.v1.GetPolicyOptions; +import com.google.iam.v1.Policy; + +public class SyncGetIamPolicy { + + public static void main(String[] args) throws Exception { + syncGetIamPolicy(); + } + + public static void syncGetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetIamPolicyRequest request = + GetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setOptions(GetPolicyOptions.newBuilder().build()) + .build(); + Policy response = eventarcClient.getIamPolicy(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetIamPolicy_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java new file mode 100644 index 000000000000..4e445f06a089 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/AsyncGetLocation.java @@ -0,0 +1,45 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetLocation_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.Location; + +public class AsyncGetLocation { + + public static void main(String[] args) throws Exception { + asyncGetLocation(); + } + + public static void asyncGetLocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + ApiFuture future = eventarcClient.getLocationCallable().futureCall(request); + // Do something. + Location response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetLocation_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java new file mode 100644 index 000000000000..01d5e17b95de --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getlocation/SyncGetLocation.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetLocation_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.location.GetLocationRequest; +import com.google.cloud.location.Location; + +public class SyncGetLocation { + + public static void main(String[] args) throws Exception { + syncGetLocation(); + } + + public static void syncGetLocation() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + Location response = eventarcClient.getLocation(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetLocation_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java new file mode 100644 index 000000000000..3b3a9a295403 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/AsyncGetProvider.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetProvider_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetProviderRequest; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.ProviderName; + +public class AsyncGetProvider { + + public static void main(String[] args) throws Exception { + asyncGetProvider(); + } + + public static void asyncGetProvider() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetProviderRequest request = + GetProviderRequest.newBuilder() + .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString()) + .build(); + ApiFuture future = eventarcClient.getProviderCallable().futureCall(request); + // Do something. + Provider response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetProvider_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java new file mode 100644 index 000000000000..df55dc3e1d16 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProvider.java @@ -0,0 +1,46 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetProvider_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetProviderRequest; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.ProviderName; + +public class SyncGetProvider { + + public static void main(String[] args) throws Exception { + syncGetProvider(); + } + + public static void syncGetProvider() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetProviderRequest request = + GetProviderRequest.newBuilder() + .setName(ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString()) + .build(); + Provider response = eventarcClient.getProvider(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetProvider_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java new file mode 100644 index 000000000000..6653953fae47 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderProvidername.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetProvider_Providername_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.ProviderName; + +public class SyncGetProviderProvidername { + + public static void main(String[] args) throws Exception { + syncGetProviderProvidername(); + } + + public static void syncGetProviderProvidername() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ProviderName name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]"); + Provider response = eventarcClient.getProvider(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetProvider_Providername_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java new file mode 100644 index 000000000000..9b10b49ff3e8 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/getprovider/SyncGetProviderString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetProvider_String_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Provider; +import com.google.cloud.eventarc.v1.ProviderName; + +public class SyncGetProviderString { + + public static void main(String[] args) throws Exception { + syncGetProviderString(); + } + + public static void syncGetProviderString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = ProviderName.of("[PROJECT]", "[LOCATION]", "[PROVIDER]").toString(); + Provider response = eventarcClient.getProvider(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetProvider_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java new file mode 100644 index 000000000000..39832a935164 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/AsyncGetTrigger.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetTrigger_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetTriggerRequest; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class AsyncGetTrigger { + + public static void main(String[] args) throws Exception { + asyncGetTrigger(); + } + + public static void asyncGetTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetTriggerRequest request = + GetTriggerRequest.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .build(); + ApiFuture future = eventarcClient.getTriggerCallable().futureCall(request); + // Do something. + Trigger response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetTrigger_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java new file mode 100644 index 000000000000..e2c61528d791 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTrigger.java @@ -0,0 +1,46 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetTrigger_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GetTriggerRequest; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class SyncGetTrigger { + + public static void main(String[] args) throws Exception { + syncGetTrigger(); + } + + public static void syncGetTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GetTriggerRequest request = + GetTriggerRequest.newBuilder() + .setName(TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString()) + .build(); + Trigger response = eventarcClient.getTrigger(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetTrigger_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java new file mode 100644 index 000000000000..89799c1ce37a --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerString.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetTrigger_String_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class SyncGetTriggerString { + + public static void main(String[] args) throws Exception { + syncGetTriggerString(); + } + + public static void syncGetTriggerString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]").toString(); + Trigger response = eventarcClient.getTrigger(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetTrigger_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java new file mode 100644 index 000000000000..70a8e433bd12 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/gettrigger/SyncGetTriggerTriggername.java @@ -0,0 +1,42 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_GetTrigger_Triggername_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.TriggerName; + +public class SyncGetTriggerTriggername { + + public static void main(String[] args) throws Exception { + syncGetTriggerTriggername(); + } + + public static void syncGetTriggerTriggername() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + TriggerName name = TriggerName.of("[PROJECT]", "[LOCATION]", "[TRIGGER]"); + Trigger response = eventarcClient.getTrigger(name); + } + } +} +// [END eventarc_v1_generated_Eventarc_GetTrigger_Triggername_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java new file mode 100644 index 000000000000..da97e38eb743 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnections.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannelConnections_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.LocationName; + +public class AsyncListChannelConnections { + + public static void main(String[] args) throws Exception { + asyncListChannelConnections(); + } + + public static void asyncListChannelConnections() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListChannelConnectionsRequest request = + ListChannelConnectionsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + eventarcClient.listChannelConnectionsPagedCallable().futureCall(request); + // Do something. + for (ChannelConnection element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannelConnections_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java new file mode 100644 index 000000000000..1b68882e1e93 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/AsyncListChannelConnectionsPaged.java @@ -0,0 +1,62 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannelConnections_Paged_async] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.ListChannelConnectionsResponse; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListChannelConnectionsPaged { + + public static void main(String[] args) throws Exception { + asyncListChannelConnectionsPaged(); + } + + public static void asyncListChannelConnectionsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListChannelConnectionsRequest request = + ListChannelConnectionsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListChannelConnectionsResponse response = + eventarcClient.listChannelConnectionsCallable().call(request); + for (ChannelConnection element : response.getChannelConnectionsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannelConnections_Paged_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java new file mode 100644 index 000000000000..44a6d63e766a --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnections.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannelConnections_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListChannelConnectionsRequest; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncListChannelConnections { + + public static void main(String[] args) throws Exception { + syncListChannelConnections(); + } + + public static void syncListChannelConnections() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListChannelConnectionsRequest request = + ListChannelConnectionsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (ChannelConnection element : + eventarcClient.listChannelConnections(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannelConnections_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java new file mode 100644 index 000000000000..456188e433c9 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannelConnections_Locationname_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncListChannelConnectionsLocationname { + + public static void main(String[] args) throws Exception { + syncListChannelConnectionsLocationname(); + } + + public static void syncListChannelConnectionsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (ChannelConnection element : eventarcClient.listChannelConnections(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannelConnections_Locationname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java new file mode 100644 index 000000000000..a71d6368c450 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannelconnections/SyncListChannelConnectionsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannelConnections_String_sync] +import com.google.cloud.eventarc.v1.ChannelConnection; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncListChannelConnectionsString { + + public static void main(String[] args) throws Exception { + syncListChannelConnectionsString(); + } + + public static void syncListChannelConnectionsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (ChannelConnection element : eventarcClient.listChannelConnections(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannelConnections_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java new file mode 100644 index 000000000000..e7c3a0af82ae --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannels.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannels_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.LocationName; + +public class AsyncListChannels { + + public static void main(String[] args) throws Exception { + asyncListChannels(); + } + + public static void asyncListChannels() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListChannelsRequest request = + ListChannelsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = eventarcClient.listChannelsPagedCallable().futureCall(request); + // Do something. + for (Channel element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannels_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java new file mode 100644 index 000000000000..01d4ec0a78c5 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/AsyncListChannelsPaged.java @@ -0,0 +1,62 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannels_Paged_async] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.ListChannelsResponse; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListChannelsPaged { + + public static void main(String[] args) throws Exception { + asyncListChannelsPaged(); + } + + public static void asyncListChannelsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListChannelsRequest request = + ListChannelsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListChannelsResponse response = eventarcClient.listChannelsCallable().call(request); + for (Channel element : response.getChannelsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannels_Paged_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java new file mode 100644 index 000000000000..b2b9860bb75c --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannels.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannels_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListChannelsRequest; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncListChannels { + + public static void main(String[] args) throws Exception { + syncListChannels(); + } + + public static void syncListChannels() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListChannelsRequest request = + ListChannelsRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .build(); + for (Channel element : eventarcClient.listChannels(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannels_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java new file mode 100644 index 000000000000..cfb8427a0c45 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannels_Locationname_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncListChannelsLocationname { + + public static void main(String[] args) throws Exception { + syncListChannelsLocationname(); + } + + public static void syncListChannelsLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Channel element : eventarcClient.listChannels(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannels_Locationname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java new file mode 100644 index 000000000000..4db758758323 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listchannels/SyncListChannelsString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListChannels_String_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; + +public class SyncListChannelsString { + + public static void main(String[] args) throws Exception { + syncListChannelsString(); + } + + public static void syncListChannelsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Channel element : eventarcClient.listChannels(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListChannels_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java new file mode 100644 index 000000000000..398e6a12123c --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocations.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListLocations_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.Location; + +public class AsyncListLocations { + + public static void main(String[] args) throws Exception { + asyncListLocations(); + } + + public static void asyncListLocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = eventarcClient.listLocationsPagedCallable().futureCall(request); + // Do something. + for (Location element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListLocations_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java new file mode 100644 index 000000000000..43feb3e4f1f9 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/AsyncListLocationsPaged.java @@ -0,0 +1,61 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListLocations_Paged_async] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.ListLocationsResponse; +import com.google.cloud.location.Location; +import com.google.common.base.Strings; + +public class AsyncListLocationsPaged { + + public static void main(String[] args) throws Exception { + asyncListLocationsPaged(); + } + + public static void asyncListLocationsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListLocationsResponse response = eventarcClient.listLocationsCallable().call(request); + for (Location element : response.getLocationsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListLocations_Paged_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java new file mode 100644 index 000000000000..2e74d1dfd282 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listlocations/SyncListLocations.java @@ -0,0 +1,50 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListLocations_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.location.ListLocationsRequest; +import com.google.cloud.location.Location; + +public class SyncListLocations { + + public static void main(String[] args) throws Exception { + syncListLocations(); + } + + public static void syncListLocations() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Location element : eventarcClient.listLocations(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListLocations_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java new file mode 100644 index 000000000000..c13e15f46aa6 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProviders.java @@ -0,0 +1,55 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListProviders_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Provider; + +public class AsyncListProviders { + + public static void main(String[] args) throws Exception { + asyncListProviders(); + } + + public static void asyncListProviders() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListProvidersRequest request = + ListProvidersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .setFilter("filter-1274492040") + .build(); + ApiFuture future = eventarcClient.listProvidersPagedCallable().futureCall(request); + // Do something. + for (Provider element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListProviders_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java new file mode 100644 index 000000000000..5d0423d2ffbc --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/AsyncListProvidersPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListProviders_Paged_async] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.ListProvidersResponse; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Provider; +import com.google.common.base.Strings; + +public class AsyncListProvidersPaged { + + public static void main(String[] args) throws Exception { + asyncListProvidersPaged(); + } + + public static void asyncListProvidersPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListProvidersRequest request = + ListProvidersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .setFilter("filter-1274492040") + .build(); + while (true) { + ListProvidersResponse response = eventarcClient.listProvidersCallable().call(request); + for (Provider element : response.getProvidersList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListProviders_Paged_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java new file mode 100644 index 000000000000..aa8bca010c20 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProviders.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListProviders_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListProvidersRequest; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Provider; + +public class SyncListProviders { + + public static void main(String[] args) throws Exception { + syncListProviders(); + } + + public static void syncListProviders() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListProvidersRequest request = + ListProvidersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .setFilter("filter-1274492040") + .build(); + for (Provider element : eventarcClient.listProviders(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListProviders_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java new file mode 100644 index 000000000000..3c7dae1d7675 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListProviders_Locationname_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Provider; + +public class SyncListProvidersLocationname { + + public static void main(String[] args) throws Exception { + syncListProvidersLocationname(); + } + + public static void syncListProvidersLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Provider element : eventarcClient.listProviders(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListProviders_Locationname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java new file mode 100644 index 000000000000..59d969780f7d --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listproviders/SyncListProvidersString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListProviders_String_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Provider; + +public class SyncListProvidersString { + + public static void main(String[] args) throws Exception { + syncListProvidersString(); + } + + public static void syncListProvidersString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Provider element : eventarcClient.listProviders(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListProviders_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java new file mode 100644 index 000000000000..45b00607b0bd --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggers.java @@ -0,0 +1,55 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListTriggers_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class AsyncListTriggers { + + public static void main(String[] args) throws Exception { + asyncListTriggers(); + } + + public static void asyncListTriggers() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListTriggersRequest request = + ListTriggersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .setFilter("filter-1274492040") + .build(); + ApiFuture future = eventarcClient.listTriggersPagedCallable().futureCall(request); + // Do something. + for (Trigger element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListTriggers_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java new file mode 100644 index 000000000000..5f7f0e2ad37f --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/AsyncListTriggersPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListTriggers_Paged_async] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.ListTriggersResponse; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.common.base.Strings; + +public class AsyncListTriggersPaged { + + public static void main(String[] args) throws Exception { + asyncListTriggersPaged(); + } + + public static void asyncListTriggersPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListTriggersRequest request = + ListTriggersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .setFilter("filter-1274492040") + .build(); + while (true) { + ListTriggersResponse response = eventarcClient.listTriggersCallable().call(request); + for (Trigger element : response.getTriggersList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListTriggers_Paged_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java new file mode 100644 index 000000000000..241fa3e58e0c --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggers.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListTriggers_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.ListTriggersRequest; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class SyncListTriggers { + + public static void main(String[] args) throws Exception { + syncListTriggers(); + } + + public static void syncListTriggers() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + ListTriggersRequest request = + ListTriggersRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setOrderBy("orderBy-1207110587") + .setFilter("filter-1274492040") + .build(); + for (Trigger element : eventarcClient.listTriggers(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListTriggers_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java new file mode 100644 index 000000000000..ff2b0fd3d88c --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersLocationname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListTriggers_Locationname_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class SyncListTriggersLocationname { + + public static void main(String[] args) throws Exception { + syncListTriggersLocationname(); + } + + public static void syncListTriggersLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Trigger element : eventarcClient.listTriggers(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListTriggers_Locationname_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java new file mode 100644 index 000000000000..da80feae99b2 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/listtriggers/SyncListTriggersString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_ListTriggers_String_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.LocationName; +import com.google.cloud.eventarc.v1.Trigger; + +public class SyncListTriggersString { + + public static void main(String[] args) throws Exception { + syncListTriggersString(); + } + + public static void syncListTriggersString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Trigger element : eventarcClient.listTriggers(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END eventarc_v1_generated_Eventarc_ListTriggers_String_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java new file mode 100644 index 000000000000..c8eee964c687 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/AsyncSetIamPolicy.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_SetIamPolicy_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.protobuf.FieldMask; + +public class AsyncSetIamPolicy { + + public static void main(String[] args) throws Exception { + asyncSetIamPolicy(); + } + + public static void asyncSetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = eventarcClient.setIamPolicyCallable().futureCall(request); + // Do something. + Policy response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_SetIamPolicy_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java new file mode 100644 index 000000000000..2134e52af120 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/setiampolicy/SyncSetIamPolicy.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_SetIamPolicy_sync] +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.iam.v1.Policy; +import com.google.iam.v1.SetIamPolicyRequest; +import com.google.protobuf.FieldMask; + +public class SyncSetIamPolicy { + + public static void main(String[] args) throws Exception { + syncSetIamPolicy(); + } + + public static void syncSetIamPolicy() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + SetIamPolicyRequest request = + SetIamPolicyRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .setPolicy(Policy.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + Policy response = eventarcClient.setIamPolicy(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_SetIamPolicy_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java new file mode 100644 index 000000000000..ceab79476e4f --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/AsyncTestIamPermissions.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_TestIamPermissions_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import java.util.ArrayList; + +public class AsyncTestIamPermissions { + + public static void main(String[] args) throws Exception { + asyncTestIamPermissions(); + } + + public static void asyncTestIamPermissions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .addAllPermissions(new ArrayList()) + .build(); + ApiFuture future = + eventarcClient.testIamPermissionsCallable().futureCall(request); + // Do something. + TestIamPermissionsResponse response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_TestIamPermissions_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java new file mode 100644 index 000000000000..8b8ee74a8054 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/testiampermissions/SyncTestIamPermissions.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_TestIamPermissions_sync] +import com.google.cloud.eventarc.v1.ChannelName; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.iam.v1.TestIamPermissionsRequest; +import com.google.iam.v1.TestIamPermissionsResponse; +import java.util.ArrayList; + +public class SyncTestIamPermissions { + + public static void main(String[] args) throws Exception { + syncTestIamPermissions(); + } + + public static void syncTestIamPermissions() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + TestIamPermissionsRequest request = + TestIamPermissionsRequest.newBuilder() + .setResource(ChannelName.of("[PROJECT]", "[LOCATION]", "[CHANNEL]").toString()) + .addAllPermissions(new ArrayList()) + .build(); + TestIamPermissionsResponse response = eventarcClient.testIamPermissions(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_TestIamPermissions_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java new file mode 100644 index 000000000000..0f7e79587f19 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateChannel_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateChannel { + + public static void main(String[] args) throws Exception { + asyncUpdateChannel(); + } + + public static void asyncUpdateChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateChannelRequest request = + UpdateChannelRequest.newBuilder() + .setChannel(Channel.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setValidateOnly(true) + .build(); + ApiFuture future = eventarcClient.updateChannelCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateChannel_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java new file mode 100644 index 000000000000..8b17f7c0f763 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/AsyncUpdateChannelLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateChannel_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateChannelLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateChannelLRO(); + } + + public static void asyncUpdateChannelLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateChannelRequest request = + UpdateChannelRequest.newBuilder() + .setChannel(Channel.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setValidateOnly(true) + .build(); + OperationFuture future = + eventarcClient.updateChannelOperationCallable().futureCall(request); + // Do something. + Channel response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateChannel_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java new file mode 100644 index 000000000000..9aa907c084ad --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannel.java @@ -0,0 +1,48 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateChannel_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.UpdateChannelRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateChannel { + + public static void main(String[] args) throws Exception { + syncUpdateChannel(); + } + + public static void syncUpdateChannel() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateChannelRequest request = + UpdateChannelRequest.newBuilder() + .setChannel(Channel.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setValidateOnly(true) + .build(); + Channel response = eventarcClient.updateChannelAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateChannel_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java new file mode 100644 index 000000000000..6ae56a1b025b --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatechannel/SyncUpdateChannelChannelFieldmask.java @@ -0,0 +1,43 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateChannel_ChannelFieldmask_sync] +import com.google.cloud.eventarc.v1.Channel; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.protobuf.FieldMask; + +public class SyncUpdateChannelChannelFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateChannelChannelFieldmask(); + } + + public static void syncUpdateChannelChannelFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + Channel channel = Channel.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + Channel response = eventarcClient.updateChannelAsync(channel, updateMask).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateChannel_ChannelFieldmask_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java new file mode 100644 index 000000000000..a58788074b37 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/AsyncUpdateGoogleChannelConfig.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateGoogleChannelConfig_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGoogleChannelConfig { + + public static void main(String[] args) throws Exception { + asyncUpdateGoogleChannelConfig(); + } + + public static void asyncUpdateGoogleChannelConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateGoogleChannelConfigRequest request = + UpdateGoogleChannelConfigRequest.newBuilder() + .setGoogleChannelConfig(GoogleChannelConfig.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + eventarcClient.updateGoogleChannelConfigCallable().futureCall(request); + // Do something. + GoogleChannelConfig response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateGoogleChannelConfig_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java new file mode 100644 index 000000000000..dc48d590ef12 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfig.java @@ -0,0 +1,47 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateGoogleChannelConfig_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGoogleChannelConfig { + + public static void main(String[] args) throws Exception { + syncUpdateGoogleChannelConfig(); + } + + public static void syncUpdateGoogleChannelConfig() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateGoogleChannelConfigRequest request = + UpdateGoogleChannelConfigRequest.newBuilder() + .setGoogleChannelConfig(GoogleChannelConfig.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + GoogleChannelConfig response = eventarcClient.updateGoogleChannelConfig(request); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateGoogleChannelConfig_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java new file mode 100644 index 000000000000..3165231786df --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updategooglechannelconfig/SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateGoogleChannelConfig_GooglechannelconfigFieldmask_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.GoogleChannelConfig; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGoogleChannelConfigGooglechannelconfigFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateGoogleChannelConfigGooglechannelconfigFieldmask(); + } + + public static void syncUpdateGoogleChannelConfigGooglechannelconfigFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + GoogleChannelConfig googleChannelConfig = GoogleChannelConfig.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + GoogleChannelConfig response = + eventarcClient.updateGoogleChannelConfig(googleChannelConfig, updateMask); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateGoogleChannelConfig_GooglechannelconfigFieldmask_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java new file mode 100644 index 000000000000..40d5e097d968 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTrigger.java @@ -0,0 +1,53 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateTrigger_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateTrigger { + + public static void main(String[] args) throws Exception { + asyncUpdateTrigger(); + } + + public static void asyncUpdateTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateTriggerRequest request = + UpdateTriggerRequest.newBuilder() + .setTrigger(Trigger.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setAllowMissing(true) + .setValidateOnly(true) + .build(); + ApiFuture future = eventarcClient.updateTriggerCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateTrigger_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java new file mode 100644 index 000000000000..e83f0cb1b8a1 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/AsyncUpdateTriggerLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateTrigger_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.OperationMetadata; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateTriggerLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateTriggerLRO(); + } + + public static void asyncUpdateTriggerLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateTriggerRequest request = + UpdateTriggerRequest.newBuilder() + .setTrigger(Trigger.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setAllowMissing(true) + .setValidateOnly(true) + .build(); + OperationFuture future = + eventarcClient.updateTriggerOperationCallable().futureCall(request); + // Do something. + Trigger response = future.get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateTrigger_LRO_async] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java new file mode 100644 index 000000000000..2f26b53af76b --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTrigger.java @@ -0,0 +1,49 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateTrigger_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.cloud.eventarc.v1.UpdateTriggerRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateTrigger { + + public static void main(String[] args) throws Exception { + syncUpdateTrigger(); + } + + public static void syncUpdateTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + UpdateTriggerRequest request = + UpdateTriggerRequest.newBuilder() + .setTrigger(Trigger.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setAllowMissing(true) + .setValidateOnly(true) + .build(); + Trigger response = eventarcClient.updateTriggerAsync(request).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateTrigger_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java new file mode 100644 index 000000000000..1ae4e724100a --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarc/updatetrigger/SyncUpdateTriggerTriggerFieldmaskBoolean.java @@ -0,0 +1,44 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_Eventarc_UpdateTrigger_TriggerFieldmaskBoolean_sync] +import com.google.cloud.eventarc.v1.EventarcClient; +import com.google.cloud.eventarc.v1.Trigger; +import com.google.protobuf.FieldMask; + +public class SyncUpdateTriggerTriggerFieldmaskBoolean { + + public static void main(String[] args) throws Exception { + syncUpdateTriggerTriggerFieldmaskBoolean(); + } + + public static void syncUpdateTriggerTriggerFieldmaskBoolean() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (EventarcClient eventarcClient = EventarcClient.create()) { + Trigger trigger = Trigger.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + boolean allowMissing = true; + Trigger response = eventarcClient.updateTriggerAsync(trigger, updateMask, allowMissing).get(); + } + } +} +// [END eventarc_v1_generated_Eventarc_UpdateTrigger_TriggerFieldmaskBoolean_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java new file mode 100644 index 000000000000..66e1de632ac1 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/eventarcsettings/gettrigger/SyncGetTrigger.java @@ -0,0 +1,45 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.samples; + +// [START eventarc_v1_generated_EventarcSettings_GetTrigger_sync] +import com.google.cloud.eventarc.v1.EventarcSettings; +import java.time.Duration; + +public class SyncGetTrigger { + + public static void main(String[] args) throws Exception { + syncGetTrigger(); + } + + public static void syncGetTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + EventarcSettings.Builder eventarcSettingsBuilder = EventarcSettings.newBuilder(); + eventarcSettingsBuilder + .getTriggerSettings() + .setRetrySettings( + eventarcSettingsBuilder.getTriggerSettings().getRetrySettings().toBuilder() + .setTotalTimeout(Duration.ofSeconds(30)) + .build()); + EventarcSettings eventarcSettings = eventarcSettingsBuilder.build(); + } +} +// [END eventarc_v1_generated_EventarcSettings_GetTrigger_sync] diff --git a/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java new file mode 100644 index 000000000000..237a5879e561 --- /dev/null +++ b/java-eventarc/v1/samples/snippets/generated/com/google/cloud/eventarc/v1/stub/eventarcstubsettings/gettrigger/SyncGetTrigger.java @@ -0,0 +1,45 @@ +/* + * Copyright 2022 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.eventarc.v1.stub.samples; + +// [START eventarc_v1_generated_EventarcStubSettings_GetTrigger_sync] +import com.google.cloud.eventarc.v1.stub.EventarcStubSettings; +import java.time.Duration; + +public class SyncGetTrigger { + + public static void main(String[] args) throws Exception { + syncGetTrigger(); + } + + public static void syncGetTrigger() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + EventarcStubSettings.Builder eventarcSettingsBuilder = EventarcStubSettings.newBuilder(); + eventarcSettingsBuilder + .getTriggerSettings() + .setRetrySettings( + eventarcSettingsBuilder.getTriggerSettings().getRetrySettings().toBuilder() + .setTotalTimeout(Duration.ofSeconds(30)) + .build()); + EventarcStubSettings eventarcSettings = eventarcSettingsBuilder.build(); + } +} +// [END eventarc_v1_generated_EventarcStubSettings_GetTrigger_sync] diff --git a/owl-bot-staging/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java b/owl-bot-staging/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java deleted file mode 100644 index 01fc6458f5db..000000000000 --- a/owl-bot-staging/java-eventarc/v1/grpc-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/EventarcGrpc.java +++ /dev/null @@ -1,1770 +0,0 @@ -package com.google.cloud.eventarc.v1; - -import static io.grpc.MethodDescriptor.generateFullMethodName; - -/** - *
- * Eventarc allows users to subscribe to various events that are provided by
- * Google Cloud services and forward them to supported destinations.
- * 
- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler", - comments = "Source: google/cloud/eventarc/v1/eventarc.proto") -@io.grpc.stub.annotations.GrpcGenerated -public final class EventarcGrpc { - - private EventarcGrpc() {} - - public static final String SERVICE_NAME = "google.cloud.eventarc.v1.Eventarc"; - - // Static method descriptors that strictly reflect the proto. - private static volatile io.grpc.MethodDescriptor getGetTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetTrigger", - requestType = com.google.cloud.eventarc.v1.GetTriggerRequest.class, - responseType = com.google.cloud.eventarc.v1.Trigger.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getGetTriggerMethod() { - io.grpc.MethodDescriptor getGetTriggerMethod; - if ((getGetTriggerMethod = EventarcGrpc.getGetTriggerMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getGetTriggerMethod = EventarcGrpc.getGetTriggerMethod) == null) { - EventarcGrpc.getGetTriggerMethod = getGetTriggerMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GetTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.Trigger.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetTrigger")) - .build(); - } - } - } - return getGetTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor getListTriggersMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListTriggers", - requestType = com.google.cloud.eventarc.v1.ListTriggersRequest.class, - responseType = com.google.cloud.eventarc.v1.ListTriggersResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getListTriggersMethod() { - io.grpc.MethodDescriptor getListTriggersMethod; - if ((getListTriggersMethod = EventarcGrpc.getListTriggersMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getListTriggersMethod = EventarcGrpc.getListTriggersMethod) == null) { - EventarcGrpc.getListTriggersMethod = getListTriggersMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListTriggers")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListTriggersRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListTriggersResponse.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListTriggers")) - .build(); - } - } - } - return getListTriggersMethod; - } - - private static volatile io.grpc.MethodDescriptor getCreateTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CreateTrigger", - requestType = com.google.cloud.eventarc.v1.CreateTriggerRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getCreateTriggerMethod() { - io.grpc.MethodDescriptor getCreateTriggerMethod; - if ((getCreateTriggerMethod = EventarcGrpc.getCreateTriggerMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getCreateTriggerMethod = EventarcGrpc.getCreateTriggerMethod) == null) { - EventarcGrpc.getCreateTriggerMethod = getCreateTriggerMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.CreateTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateTrigger")) - .build(); - } - } - } - return getCreateTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor getUpdateTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "UpdateTrigger", - requestType = com.google.cloud.eventarc.v1.UpdateTriggerRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getUpdateTriggerMethod() { - io.grpc.MethodDescriptor getUpdateTriggerMethod; - if ((getUpdateTriggerMethod = EventarcGrpc.getUpdateTriggerMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getUpdateTriggerMethod = EventarcGrpc.getUpdateTriggerMethod) == null) { - EventarcGrpc.getUpdateTriggerMethod = getUpdateTriggerMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.UpdateTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateTrigger")) - .build(); - } - } - } - return getUpdateTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor getDeleteTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "DeleteTrigger", - requestType = com.google.cloud.eventarc.v1.DeleteTriggerRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getDeleteTriggerMethod() { - io.grpc.MethodDescriptor getDeleteTriggerMethod; - if ((getDeleteTriggerMethod = EventarcGrpc.getDeleteTriggerMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getDeleteTriggerMethod = EventarcGrpc.getDeleteTriggerMethod) == null) { - EventarcGrpc.getDeleteTriggerMethod = getDeleteTriggerMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.DeleteTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteTrigger")) - .build(); - } - } - } - return getDeleteTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor getGetChannelMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetChannel", - requestType = com.google.cloud.eventarc.v1.GetChannelRequest.class, - responseType = com.google.cloud.eventarc.v1.Channel.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getGetChannelMethod() { - io.grpc.MethodDescriptor getGetChannelMethod; - if ((getGetChannelMethod = EventarcGrpc.getGetChannelMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getGetChannelMethod = EventarcGrpc.getGetChannelMethod) == null) { - EventarcGrpc.getGetChannelMethod = getGetChannelMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetChannel")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GetChannelRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.Channel.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetChannel")) - .build(); - } - } - } - return getGetChannelMethod; - } - - private static volatile io.grpc.MethodDescriptor getListChannelsMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListChannels", - requestType = com.google.cloud.eventarc.v1.ListChannelsRequest.class, - responseType = com.google.cloud.eventarc.v1.ListChannelsResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getListChannelsMethod() { - io.grpc.MethodDescriptor getListChannelsMethod; - if ((getListChannelsMethod = EventarcGrpc.getListChannelsMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getListChannelsMethod = EventarcGrpc.getListChannelsMethod) == null) { - EventarcGrpc.getListChannelsMethod = getListChannelsMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListChannels")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListChannelsRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListChannelsResponse.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListChannels")) - .build(); - } - } - } - return getListChannelsMethod; - } - - private static volatile io.grpc.MethodDescriptor getCreateChannelMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CreateChannel", - requestType = com.google.cloud.eventarc.v1.CreateChannelRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getCreateChannelMethod() { - io.grpc.MethodDescriptor getCreateChannelMethod; - if ((getCreateChannelMethod = EventarcGrpc.getCreateChannelMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getCreateChannelMethod = EventarcGrpc.getCreateChannelMethod) == null) { - EventarcGrpc.getCreateChannelMethod = getCreateChannelMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateChannel")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.CreateChannelRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateChannel")) - .build(); - } - } - } - return getCreateChannelMethod; - } - - private static volatile io.grpc.MethodDescriptor getUpdateChannelMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "UpdateChannel", - requestType = com.google.cloud.eventarc.v1.UpdateChannelRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getUpdateChannelMethod() { - io.grpc.MethodDescriptor getUpdateChannelMethod; - if ((getUpdateChannelMethod = EventarcGrpc.getUpdateChannelMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getUpdateChannelMethod = EventarcGrpc.getUpdateChannelMethod) == null) { - EventarcGrpc.getUpdateChannelMethod = getUpdateChannelMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateChannel")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.UpdateChannelRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateChannel")) - .build(); - } - } - } - return getUpdateChannelMethod; - } - - private static volatile io.grpc.MethodDescriptor getDeleteChannelMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "DeleteChannel", - requestType = com.google.cloud.eventarc.v1.DeleteChannelRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getDeleteChannelMethod() { - io.grpc.MethodDescriptor getDeleteChannelMethod; - if ((getDeleteChannelMethod = EventarcGrpc.getDeleteChannelMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getDeleteChannelMethod = EventarcGrpc.getDeleteChannelMethod) == null) { - EventarcGrpc.getDeleteChannelMethod = getDeleteChannelMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteChannel")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.DeleteChannelRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteChannel")) - .build(); - } - } - } - return getDeleteChannelMethod; - } - - private static volatile io.grpc.MethodDescriptor getGetProviderMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetProvider", - requestType = com.google.cloud.eventarc.v1.GetProviderRequest.class, - responseType = com.google.cloud.eventarc.v1.Provider.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getGetProviderMethod() { - io.grpc.MethodDescriptor getGetProviderMethod; - if ((getGetProviderMethod = EventarcGrpc.getGetProviderMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getGetProviderMethod = EventarcGrpc.getGetProviderMethod) == null) { - EventarcGrpc.getGetProviderMethod = getGetProviderMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetProvider")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GetProviderRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.Provider.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetProvider")) - .build(); - } - } - } - return getGetProviderMethod; - } - - private static volatile io.grpc.MethodDescriptor getListProvidersMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListProviders", - requestType = com.google.cloud.eventarc.v1.ListProvidersRequest.class, - responseType = com.google.cloud.eventarc.v1.ListProvidersResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getListProvidersMethod() { - io.grpc.MethodDescriptor getListProvidersMethod; - if ((getListProvidersMethod = EventarcGrpc.getListProvidersMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getListProvidersMethod = EventarcGrpc.getListProvidersMethod) == null) { - EventarcGrpc.getListProvidersMethod = getListProvidersMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListProviders")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListProvidersRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListProvidersResponse.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListProviders")) - .build(); - } - } - } - return getListProvidersMethod; - } - - private static volatile io.grpc.MethodDescriptor getGetChannelConnectionMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetChannelConnection", - requestType = com.google.cloud.eventarc.v1.GetChannelConnectionRequest.class, - responseType = com.google.cloud.eventarc.v1.ChannelConnection.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getGetChannelConnectionMethod() { - io.grpc.MethodDescriptor getGetChannelConnectionMethod; - if ((getGetChannelConnectionMethod = EventarcGrpc.getGetChannelConnectionMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getGetChannelConnectionMethod = EventarcGrpc.getGetChannelConnectionMethod) == null) { - EventarcGrpc.getGetChannelConnectionMethod = getGetChannelConnectionMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetChannelConnection")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GetChannelConnectionRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ChannelConnection.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetChannelConnection")) - .build(); - } - } - } - return getGetChannelConnectionMethod; - } - - private static volatile io.grpc.MethodDescriptor getListChannelConnectionsMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListChannelConnections", - requestType = com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.class, - responseType = com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getListChannelConnectionsMethod() { - io.grpc.MethodDescriptor getListChannelConnectionsMethod; - if ((getListChannelConnectionsMethod = EventarcGrpc.getListChannelConnectionsMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getListChannelConnectionsMethod = EventarcGrpc.getListChannelConnectionsMethod) == null) { - EventarcGrpc.getListChannelConnectionsMethod = getListChannelConnectionsMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListChannelConnections")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.ListChannelConnectionsResponse.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("ListChannelConnections")) - .build(); - } - } - } - return getListChannelConnectionsMethod; - } - - private static volatile io.grpc.MethodDescriptor getCreateChannelConnectionMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CreateChannelConnection", - requestType = com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getCreateChannelConnectionMethod() { - io.grpc.MethodDescriptor getCreateChannelConnectionMethod; - if ((getCreateChannelConnectionMethod = EventarcGrpc.getCreateChannelConnectionMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getCreateChannelConnectionMethod = EventarcGrpc.getCreateChannelConnectionMethod) == null) { - EventarcGrpc.getCreateChannelConnectionMethod = getCreateChannelConnectionMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateChannelConnection")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("CreateChannelConnection")) - .build(); - } - } - } - return getCreateChannelConnectionMethod; - } - - private static volatile io.grpc.MethodDescriptor getDeleteChannelConnectionMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "DeleteChannelConnection", - requestType = com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getDeleteChannelConnectionMethod() { - io.grpc.MethodDescriptor getDeleteChannelConnectionMethod; - if ((getDeleteChannelConnectionMethod = EventarcGrpc.getDeleteChannelConnectionMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getDeleteChannelConnectionMethod = EventarcGrpc.getDeleteChannelConnectionMethod) == null) { - EventarcGrpc.getDeleteChannelConnectionMethod = getDeleteChannelConnectionMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteChannelConnection")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("DeleteChannelConnection")) - .build(); - } - } - } - return getDeleteChannelConnectionMethod; - } - - private static volatile io.grpc.MethodDescriptor getGetGoogleChannelConfigMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetGoogleChannelConfig", - requestType = com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.class, - responseType = com.google.cloud.eventarc.v1.GoogleChannelConfig.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getGetGoogleChannelConfigMethod() { - io.grpc.MethodDescriptor getGetGoogleChannelConfigMethod; - if ((getGetGoogleChannelConfigMethod = EventarcGrpc.getGetGoogleChannelConfigMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getGetGoogleChannelConfigMethod = EventarcGrpc.getGetGoogleChannelConfigMethod) == null) { - EventarcGrpc.getGetGoogleChannelConfigMethod = getGetGoogleChannelConfigMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetGoogleChannelConfig")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("GetGoogleChannelConfig")) - .build(); - } - } - } - return getGetGoogleChannelConfigMethod; - } - - private static volatile io.grpc.MethodDescriptor getUpdateGoogleChannelConfigMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "UpdateGoogleChannelConfig", - requestType = com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.class, - responseType = com.google.cloud.eventarc.v1.GoogleChannelConfig.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor getUpdateGoogleChannelConfigMethod() { - io.grpc.MethodDescriptor getUpdateGoogleChannelConfigMethod; - if ((getUpdateGoogleChannelConfigMethod = EventarcGrpc.getUpdateGoogleChannelConfigMethod) == null) { - synchronized (EventarcGrpc.class) { - if ((getUpdateGoogleChannelConfigMethod = EventarcGrpc.getUpdateGoogleChannelConfigMethod) == null) { - EventarcGrpc.getUpdateGoogleChannelConfigMethod = getUpdateGoogleChannelConfigMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateGoogleChannelConfig")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloud.eventarc.v1.GoogleChannelConfig.getDefaultInstance())) - .setSchemaDescriptor(new EventarcMethodDescriptorSupplier("UpdateGoogleChannelConfig")) - .build(); - } - } - } - return getUpdateGoogleChannelConfigMethod; - } - - /** - * Creates a new async stub that supports all call types for the service - */ - public static EventarcStub newStub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public EventarcStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new EventarcStub(channel, callOptions); - } - }; - return EventarcStub.newStub(factory, channel); - } - - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static EventarcBlockingStub newBlockingStub( - io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public EventarcBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new EventarcBlockingStub(channel, callOptions); - } - }; - return EventarcBlockingStub.newStub(factory, channel); - } - - /** - * Creates a new ListenableFuture-style stub that supports unary calls on the service - */ - public static EventarcFutureStub newFutureStub( - io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public EventarcFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new EventarcFutureStub(channel, callOptions); - } - }; - return EventarcFutureStub.newStub(factory, channel); - } - - /** - *
-   * Eventarc allows users to subscribe to various events that are provided by
-   * Google Cloud services and forward them to supported destinations.
-   * 
- */ - public static abstract class EventarcImplBase implements io.grpc.BindableService { - - /** - *
-     * Get a single trigger.
-     * 
- */ - public void getTrigger(com.google.cloud.eventarc.v1.GetTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTriggerMethod(), responseObserver); - } - - /** - *
-     * List triggers.
-     * 
- */ - public void listTriggers(com.google.cloud.eventarc.v1.ListTriggersRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListTriggersMethod(), responseObserver); - } - - /** - *
-     * Create a new trigger in a particular project and location.
-     * 
- */ - public void createTrigger(com.google.cloud.eventarc.v1.CreateTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateTriggerMethod(), responseObserver); - } - - /** - *
-     * Update a single trigger.
-     * 
- */ - public void updateTrigger(com.google.cloud.eventarc.v1.UpdateTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUpdateTriggerMethod(), responseObserver); - } - - /** - *
-     * Delete a single trigger.
-     * 
- */ - public void deleteTrigger(com.google.cloud.eventarc.v1.DeleteTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getDeleteTriggerMethod(), responseObserver); - } - - /** - *
-     * Get a single Channel.
-     * 
- */ - public void getChannel(com.google.cloud.eventarc.v1.GetChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetChannelMethod(), responseObserver); - } - - /** - *
-     * List channels.
-     * 
- */ - public void listChannels(com.google.cloud.eventarc.v1.ListChannelsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListChannelsMethod(), responseObserver); - } - - /** - *
-     * Create a new channel in a particular project and location.
-     * 
- */ - public void createChannel(com.google.cloud.eventarc.v1.CreateChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateChannelMethod(), responseObserver); - } - - /** - *
-     * Update a single channel.
-     * 
- */ - public void updateChannel(com.google.cloud.eventarc.v1.UpdateChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUpdateChannelMethod(), responseObserver); - } - - /** - *
-     * Delete a single channel.
-     * 
- */ - public void deleteChannel(com.google.cloud.eventarc.v1.DeleteChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getDeleteChannelMethod(), responseObserver); - } - - /** - *
-     * Get a single Provider.
-     * 
- */ - public void getProvider(com.google.cloud.eventarc.v1.GetProviderRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetProviderMethod(), responseObserver); - } - - /** - *
-     * List providers.
-     * 
- */ - public void listProviders(com.google.cloud.eventarc.v1.ListProvidersRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListProvidersMethod(), responseObserver); - } - - /** - *
-     * Get a single ChannelConnection.
-     * 
- */ - public void getChannelConnection(com.google.cloud.eventarc.v1.GetChannelConnectionRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetChannelConnectionMethod(), responseObserver); - } - - /** - *
-     * List channel connections.
-     * 
- */ - public void listChannelConnections(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListChannelConnectionsMethod(), responseObserver); - } - - /** - *
-     * Create a new ChannelConnection in a particular project and location.
-     * 
- */ - public void createChannelConnection(com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateChannelConnectionMethod(), responseObserver); - } - - /** - *
-     * Delete a single ChannelConnection.
-     * 
- */ - public void deleteChannelConnection(com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getDeleteChannelConnectionMethod(), responseObserver); - } - - /** - *
-     * Get a GoogleChannelConfig
-     * 
- */ - public void getGoogleChannelConfig(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetGoogleChannelConfigMethod(), responseObserver); - } - - /** - *
-     * Update a single GoogleChannelConfig
-     * 
- */ - public void updateGoogleChannelConfig(com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUpdateGoogleChannelConfigMethod(), responseObserver); - } - - @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { - return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) - .addMethod( - getGetTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.GetTriggerRequest, - com.google.cloud.eventarc.v1.Trigger>( - this, METHODID_GET_TRIGGER))) - .addMethod( - getListTriggersMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.ListTriggersRequest, - com.google.cloud.eventarc.v1.ListTriggersResponse>( - this, METHODID_LIST_TRIGGERS))) - .addMethod( - getCreateTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.CreateTriggerRequest, - com.google.longrunning.Operation>( - this, METHODID_CREATE_TRIGGER))) - .addMethod( - getUpdateTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.UpdateTriggerRequest, - com.google.longrunning.Operation>( - this, METHODID_UPDATE_TRIGGER))) - .addMethod( - getDeleteTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.DeleteTriggerRequest, - com.google.longrunning.Operation>( - this, METHODID_DELETE_TRIGGER))) - .addMethod( - getGetChannelMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.GetChannelRequest, - com.google.cloud.eventarc.v1.Channel>( - this, METHODID_GET_CHANNEL))) - .addMethod( - getListChannelsMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.ListChannelsRequest, - com.google.cloud.eventarc.v1.ListChannelsResponse>( - this, METHODID_LIST_CHANNELS))) - .addMethod( - getCreateChannelMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.CreateChannelRequest, - com.google.longrunning.Operation>( - this, METHODID_CREATE_CHANNEL))) - .addMethod( - getUpdateChannelMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.UpdateChannelRequest, - com.google.longrunning.Operation>( - this, METHODID_UPDATE_CHANNEL))) - .addMethod( - getDeleteChannelMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.DeleteChannelRequest, - com.google.longrunning.Operation>( - this, METHODID_DELETE_CHANNEL))) - .addMethod( - getGetProviderMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.GetProviderRequest, - com.google.cloud.eventarc.v1.Provider>( - this, METHODID_GET_PROVIDER))) - .addMethod( - getListProvidersMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.ListProvidersRequest, - com.google.cloud.eventarc.v1.ListProvidersResponse>( - this, METHODID_LIST_PROVIDERS))) - .addMethod( - getGetChannelConnectionMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.GetChannelConnectionRequest, - com.google.cloud.eventarc.v1.ChannelConnection>( - this, METHODID_GET_CHANNEL_CONNECTION))) - .addMethod( - getListChannelConnectionsMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest, - com.google.cloud.eventarc.v1.ListChannelConnectionsResponse>( - this, METHODID_LIST_CHANNEL_CONNECTIONS))) - .addMethod( - getCreateChannelConnectionMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest, - com.google.longrunning.Operation>( - this, METHODID_CREATE_CHANNEL_CONNECTION))) - .addMethod( - getDeleteChannelConnectionMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest, - com.google.longrunning.Operation>( - this, METHODID_DELETE_CHANNEL_CONNECTION))) - .addMethod( - getGetGoogleChannelConfigMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest, - com.google.cloud.eventarc.v1.GoogleChannelConfig>( - this, METHODID_GET_GOOGLE_CHANNEL_CONFIG))) - .addMethod( - getUpdateGoogleChannelConfigMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest, - com.google.cloud.eventarc.v1.GoogleChannelConfig>( - this, METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG))) - .build(); - } - } - - /** - *
-   * Eventarc allows users to subscribe to various events that are provided by
-   * Google Cloud services and forward them to supported destinations.
-   * 
- */ - public static final class EventarcStub extends io.grpc.stub.AbstractAsyncStub { - private EventarcStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected EventarcStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new EventarcStub(channel, callOptions); - } - - /** - *
-     * Get a single trigger.
-     * 
- */ - public void getTrigger(com.google.cloud.eventarc.v1.GetTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetTriggerMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * List triggers.
-     * 
- */ - public void listTriggers(com.google.cloud.eventarc.v1.ListTriggersRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListTriggersMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Create a new trigger in a particular project and location.
-     * 
- */ - public void createTrigger(com.google.cloud.eventarc.v1.CreateTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateTriggerMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Update a single trigger.
-     * 
- */ - public void updateTrigger(com.google.cloud.eventarc.v1.UpdateTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateTriggerMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Delete a single trigger.
-     * 
- */ - public void deleteTrigger(com.google.cloud.eventarc.v1.DeleteTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteTriggerMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Get a single Channel.
-     * 
- */ - public void getChannel(com.google.cloud.eventarc.v1.GetChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetChannelMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * List channels.
-     * 
- */ - public void listChannels(com.google.cloud.eventarc.v1.ListChannelsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListChannelsMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Create a new channel in a particular project and location.
-     * 
- */ - public void createChannel(com.google.cloud.eventarc.v1.CreateChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateChannelMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Update a single channel.
-     * 
- */ - public void updateChannel(com.google.cloud.eventarc.v1.UpdateChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateChannelMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Delete a single channel.
-     * 
- */ - public void deleteChannel(com.google.cloud.eventarc.v1.DeleteChannelRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteChannelMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Get a single Provider.
-     * 
- */ - public void getProvider(com.google.cloud.eventarc.v1.GetProviderRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetProviderMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * List providers.
-     * 
- */ - public void listProviders(com.google.cloud.eventarc.v1.ListProvidersRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListProvidersMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Get a single ChannelConnection.
-     * 
- */ - public void getChannelConnection(com.google.cloud.eventarc.v1.GetChannelConnectionRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetChannelConnectionMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * List channel connections.
-     * 
- */ - public void listChannelConnections(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListChannelConnectionsMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Create a new ChannelConnection in a particular project and location.
-     * 
- */ - public void createChannelConnection(com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateChannelConnectionMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Delete a single ChannelConnection.
-     * 
- */ - public void deleteChannelConnection(com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteChannelConnectionMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Get a GoogleChannelConfig
-     * 
- */ - public void getGoogleChannelConfig(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetGoogleChannelConfigMethod(), getCallOptions()), request, responseObserver); - } - - /** - *
-     * Update a single GoogleChannelConfig
-     * 
- */ - public void updateGoogleChannelConfig(com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateGoogleChannelConfigMethod(), getCallOptions()), request, responseObserver); - } - } - - /** - *
-   * Eventarc allows users to subscribe to various events that are provided by
-   * Google Cloud services and forward them to supported destinations.
-   * 
- */ - public static final class EventarcBlockingStub extends io.grpc.stub.AbstractBlockingStub { - private EventarcBlockingStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected EventarcBlockingStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new EventarcBlockingStub(channel, callOptions); - } - - /** - *
-     * Get a single trigger.
-     * 
- */ - public com.google.cloud.eventarc.v1.Trigger getTrigger(com.google.cloud.eventarc.v1.GetTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetTriggerMethod(), getCallOptions(), request); - } - - /** - *
-     * List triggers.
-     * 
- */ - public com.google.cloud.eventarc.v1.ListTriggersResponse listTriggers(com.google.cloud.eventarc.v1.ListTriggersRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListTriggersMethod(), getCallOptions(), request); - } - - /** - *
-     * Create a new trigger in a particular project and location.
-     * 
- */ - public com.google.longrunning.Operation createTrigger(com.google.cloud.eventarc.v1.CreateTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateTriggerMethod(), getCallOptions(), request); - } - - /** - *
-     * Update a single trigger.
-     * 
- */ - public com.google.longrunning.Operation updateTrigger(com.google.cloud.eventarc.v1.UpdateTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateTriggerMethod(), getCallOptions(), request); - } - - /** - *
-     * Delete a single trigger.
-     * 
- */ - public com.google.longrunning.Operation deleteTrigger(com.google.cloud.eventarc.v1.DeleteTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteTriggerMethod(), getCallOptions(), request); - } - - /** - *
-     * Get a single Channel.
-     * 
- */ - public com.google.cloud.eventarc.v1.Channel getChannel(com.google.cloud.eventarc.v1.GetChannelRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetChannelMethod(), getCallOptions(), request); - } - - /** - *
-     * List channels.
-     * 
- */ - public com.google.cloud.eventarc.v1.ListChannelsResponse listChannels(com.google.cloud.eventarc.v1.ListChannelsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListChannelsMethod(), getCallOptions(), request); - } - - /** - *
-     * Create a new channel in a particular project and location.
-     * 
- */ - public com.google.longrunning.Operation createChannel(com.google.cloud.eventarc.v1.CreateChannelRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateChannelMethod(), getCallOptions(), request); - } - - /** - *
-     * Update a single channel.
-     * 
- */ - public com.google.longrunning.Operation updateChannel(com.google.cloud.eventarc.v1.UpdateChannelRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateChannelMethod(), getCallOptions(), request); - } - - /** - *
-     * Delete a single channel.
-     * 
- */ - public com.google.longrunning.Operation deleteChannel(com.google.cloud.eventarc.v1.DeleteChannelRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteChannelMethod(), getCallOptions(), request); - } - - /** - *
-     * Get a single Provider.
-     * 
- */ - public com.google.cloud.eventarc.v1.Provider getProvider(com.google.cloud.eventarc.v1.GetProviderRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetProviderMethod(), getCallOptions(), request); - } - - /** - *
-     * List providers.
-     * 
- */ - public com.google.cloud.eventarc.v1.ListProvidersResponse listProviders(com.google.cloud.eventarc.v1.ListProvidersRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListProvidersMethod(), getCallOptions(), request); - } - - /** - *
-     * Get a single ChannelConnection.
-     * 
- */ - public com.google.cloud.eventarc.v1.ChannelConnection getChannelConnection(com.google.cloud.eventarc.v1.GetChannelConnectionRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetChannelConnectionMethod(), getCallOptions(), request); - } - - /** - *
-     * List channel connections.
-     * 
- */ - public com.google.cloud.eventarc.v1.ListChannelConnectionsResponse listChannelConnections(com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListChannelConnectionsMethod(), getCallOptions(), request); - } - - /** - *
-     * Create a new ChannelConnection in a particular project and location.
-     * 
- */ - public com.google.longrunning.Operation createChannelConnection(com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateChannelConnectionMethod(), getCallOptions(), request); - } - - /** - *
-     * Delete a single ChannelConnection.
-     * 
- */ - public com.google.longrunning.Operation deleteChannelConnection(com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteChannelConnectionMethod(), getCallOptions(), request); - } - - /** - *
-     * Get a GoogleChannelConfig
-     * 
- */ - public com.google.cloud.eventarc.v1.GoogleChannelConfig getGoogleChannelConfig(com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetGoogleChannelConfigMethod(), getCallOptions(), request); - } - - /** - *
-     * Update a single GoogleChannelConfig
-     * 
- */ - public com.google.cloud.eventarc.v1.GoogleChannelConfig updateGoogleChannelConfig(com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateGoogleChannelConfigMethod(), getCallOptions(), request); - } - } - - /** - *
-   * Eventarc allows users to subscribe to various events that are provided by
-   * Google Cloud services and forward them to supported destinations.
-   * 
- */ - public static final class EventarcFutureStub extends io.grpc.stub.AbstractFutureStub { - private EventarcFutureStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected EventarcFutureStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new EventarcFutureStub(channel, callOptions); - } - - /** - *
-     * Get a single trigger.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture getTrigger( - com.google.cloud.eventarc.v1.GetTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetTriggerMethod(), getCallOptions()), request); - } - - /** - *
-     * List triggers.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listTriggers( - com.google.cloud.eventarc.v1.ListTriggersRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListTriggersMethod(), getCallOptions()), request); - } - - /** - *
-     * Create a new trigger in a particular project and location.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture createTrigger( - com.google.cloud.eventarc.v1.CreateTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateTriggerMethod(), getCallOptions()), request); - } - - /** - *
-     * Update a single trigger.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture updateTrigger( - com.google.cloud.eventarc.v1.UpdateTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateTriggerMethod(), getCallOptions()), request); - } - - /** - *
-     * Delete a single trigger.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture deleteTrigger( - com.google.cloud.eventarc.v1.DeleteTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteTriggerMethod(), getCallOptions()), request); - } - - /** - *
-     * Get a single Channel.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture getChannel( - com.google.cloud.eventarc.v1.GetChannelRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetChannelMethod(), getCallOptions()), request); - } - - /** - *
-     * List channels.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listChannels( - com.google.cloud.eventarc.v1.ListChannelsRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListChannelsMethod(), getCallOptions()), request); - } - - /** - *
-     * Create a new channel in a particular project and location.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture createChannel( - com.google.cloud.eventarc.v1.CreateChannelRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateChannelMethod(), getCallOptions()), request); - } - - /** - *
-     * Update a single channel.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture updateChannel( - com.google.cloud.eventarc.v1.UpdateChannelRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateChannelMethod(), getCallOptions()), request); - } - - /** - *
-     * Delete a single channel.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture deleteChannel( - com.google.cloud.eventarc.v1.DeleteChannelRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteChannelMethod(), getCallOptions()), request); - } - - /** - *
-     * Get a single Provider.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture getProvider( - com.google.cloud.eventarc.v1.GetProviderRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetProviderMethod(), getCallOptions()), request); - } - - /** - *
-     * List providers.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listProviders( - com.google.cloud.eventarc.v1.ListProvidersRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListProvidersMethod(), getCallOptions()), request); - } - - /** - *
-     * Get a single ChannelConnection.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture getChannelConnection( - com.google.cloud.eventarc.v1.GetChannelConnectionRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetChannelConnectionMethod(), getCallOptions()), request); - } - - /** - *
-     * List channel connections.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture listChannelConnections( - com.google.cloud.eventarc.v1.ListChannelConnectionsRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListChannelConnectionsMethod(), getCallOptions()), request); - } - - /** - *
-     * Create a new ChannelConnection in a particular project and location.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture createChannelConnection( - com.google.cloud.eventarc.v1.CreateChannelConnectionRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateChannelConnectionMethod(), getCallOptions()), request); - } - - /** - *
-     * Delete a single ChannelConnection.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture deleteChannelConnection( - com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteChannelConnectionMethod(), getCallOptions()), request); - } - - /** - *
-     * Get a GoogleChannelConfig
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture getGoogleChannelConfig( - com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetGoogleChannelConfigMethod(), getCallOptions()), request); - } - - /** - *
-     * Update a single GoogleChannelConfig
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture updateGoogleChannelConfig( - com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateGoogleChannelConfigMethod(), getCallOptions()), request); - } - } - - private static final int METHODID_GET_TRIGGER = 0; - private static final int METHODID_LIST_TRIGGERS = 1; - private static final int METHODID_CREATE_TRIGGER = 2; - private static final int METHODID_UPDATE_TRIGGER = 3; - private static final int METHODID_DELETE_TRIGGER = 4; - private static final int METHODID_GET_CHANNEL = 5; - private static final int METHODID_LIST_CHANNELS = 6; - private static final int METHODID_CREATE_CHANNEL = 7; - private static final int METHODID_UPDATE_CHANNEL = 8; - private static final int METHODID_DELETE_CHANNEL = 9; - private static final int METHODID_GET_PROVIDER = 10; - private static final int METHODID_LIST_PROVIDERS = 11; - private static final int METHODID_GET_CHANNEL_CONNECTION = 12; - private static final int METHODID_LIST_CHANNEL_CONNECTIONS = 13; - private static final int METHODID_CREATE_CHANNEL_CONNECTION = 14; - private static final int METHODID_DELETE_CHANNEL_CONNECTION = 15; - private static final int METHODID_GET_GOOGLE_CHANNEL_CONFIG = 16; - private static final int METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG = 17; - - private static final class MethodHandlers implements - io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { - private final EventarcImplBase serviceImpl; - private final int methodId; - - MethodHandlers(EventarcImplBase serviceImpl, int methodId) { - this.serviceImpl = serviceImpl; - this.methodId = methodId; - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - case METHODID_GET_TRIGGER: - serviceImpl.getTrigger((com.google.cloud.eventarc.v1.GetTriggerRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_TRIGGERS: - serviceImpl.listTriggers((com.google.cloud.eventarc.v1.ListTriggersRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_TRIGGER: - serviceImpl.createTrigger((com.google.cloud.eventarc.v1.CreateTriggerRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_UPDATE_TRIGGER: - serviceImpl.updateTrigger((com.google.cloud.eventarc.v1.UpdateTriggerRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_DELETE_TRIGGER: - serviceImpl.deleteTrigger((com.google.cloud.eventarc.v1.DeleteTriggerRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_CHANNEL: - serviceImpl.getChannel((com.google.cloud.eventarc.v1.GetChannelRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_CHANNELS: - serviceImpl.listChannels((com.google.cloud.eventarc.v1.ListChannelsRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_CHANNEL: - serviceImpl.createChannel((com.google.cloud.eventarc.v1.CreateChannelRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_UPDATE_CHANNEL: - serviceImpl.updateChannel((com.google.cloud.eventarc.v1.UpdateChannelRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_DELETE_CHANNEL: - serviceImpl.deleteChannel((com.google.cloud.eventarc.v1.DeleteChannelRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_PROVIDER: - serviceImpl.getProvider((com.google.cloud.eventarc.v1.GetProviderRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_PROVIDERS: - serviceImpl.listProviders((com.google.cloud.eventarc.v1.ListProvidersRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_CHANNEL_CONNECTION: - serviceImpl.getChannelConnection((com.google.cloud.eventarc.v1.GetChannelConnectionRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_CHANNEL_CONNECTIONS: - serviceImpl.listChannelConnections((com.google.cloud.eventarc.v1.ListChannelConnectionsRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_CHANNEL_CONNECTION: - serviceImpl.createChannelConnection((com.google.cloud.eventarc.v1.CreateChannelConnectionRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_DELETE_CHANNEL_CONNECTION: - serviceImpl.deleteChannelConnection((com.google.cloud.eventarc.v1.DeleteChannelConnectionRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_GOOGLE_CHANNEL_CONFIG: - serviceImpl.getGoogleChannelConfig((com.google.cloud.eventarc.v1.GetGoogleChannelConfigRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_UPDATE_GOOGLE_CHANNEL_CONFIG: - serviceImpl.updateGoogleChannelConfig((com.google.cloud.eventarc.v1.UpdateGoogleChannelConfigRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - default: - throw new AssertionError(); - } - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public io.grpc.stub.StreamObserver invoke( - io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - default: - throw new AssertionError(); - } - } - } - - private static abstract class EventarcBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { - EventarcBaseDescriptorSupplier() {} - - @java.lang.Override - public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return com.google.cloud.eventarc.v1.EventarcProto.getDescriptor(); - } - - @java.lang.Override - public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { - return getFileDescriptor().findServiceByName("Eventarc"); - } - } - - private static final class EventarcFileDescriptorSupplier - extends EventarcBaseDescriptorSupplier { - EventarcFileDescriptorSupplier() {} - } - - private static final class EventarcMethodDescriptorSupplier - extends EventarcBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { - private final String methodName; - - EventarcMethodDescriptorSupplier(String methodName) { - this.methodName = methodName; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { - return getServiceDescriptor().findMethodByName(methodName); - } - } - - private static volatile io.grpc.ServiceDescriptor serviceDescriptor; - - public static io.grpc.ServiceDescriptor getServiceDescriptor() { - io.grpc.ServiceDescriptor result = serviceDescriptor; - if (result == null) { - synchronized (EventarcGrpc.class) { - result = serviceDescriptor; - if (result == null) { - serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new EventarcFileDescriptorSupplier()) - .addMethod(getGetTriggerMethod()) - .addMethod(getListTriggersMethod()) - .addMethod(getCreateTriggerMethod()) - .addMethod(getUpdateTriggerMethod()) - .addMethod(getDeleteTriggerMethod()) - .addMethod(getGetChannelMethod()) - .addMethod(getListChannelsMethod()) - .addMethod(getCreateChannelMethod()) - .addMethod(getUpdateChannelMethod()) - .addMethod(getDeleteChannelMethod()) - .addMethod(getGetProviderMethod()) - .addMethod(getListProvidersMethod()) - .addMethod(getGetChannelConnectionMethod()) - .addMethod(getListChannelConnectionsMethod()) - .addMethod(getCreateChannelConnectionMethod()) - .addMethod(getDeleteChannelConnectionMethod()) - .addMethod(getGetGoogleChannelConfigMethod()) - .addMethod(getUpdateGoogleChannelConfigMethod()) - .build(); - } - } - } - return result; - } -} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java b/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java deleted file mode 100644 index 5d69b70a7336..000000000000 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelConnectionProto.java +++ /dev/null @@ -1,79 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/eventarc/v1/channel_connection.proto - -package com.google.cloud.eventarc.v1; - -public final class ChannelConnectionProto { - private ChannelConnectionProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); - } - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n1google/cloud/eventarc/v1/channel_conne" + - "ction.proto\022\030google.cloud.eventarc.v1\032\037g" + - "oogle/api/field_behavior.proto\032\031google/a" + - "pi/resource.proto\032\037google/protobuf/times" + - "tamp.proto\"\247\003\n\021ChannelConnection\022\021\n\004name" + - "\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 \001(\tB\003\340A\003\0228\n\007channel" + - "\030\005 \001(\tB\'\340A\002\372A!\n\037eventarc.googleapis.com/" + - "Channel\0224\n\013create_time\030\006 \001(\0132\032.google.pr" + - "otobuf.TimestampB\003\340A\003\0224\n\013update_time\030\007 \001" + - "(\0132\032.google.protobuf.TimestampB\003\340A\003\022\035\n\020a" + - "ctivation_token\030\010 \001(\tB\003\340A\004:\247\001\352A\243\001\n)event" + - "arc.googleapis.com/ChannelConnection\022Opr" + - "ojects/{project}/locations/{location}/ch" + - "annelConnections/{channel_connection}*\022c" + - "hannelConnections2\021channelConnectionB\316\001\n" + - "\034com.google.cloud.eventarc.v1B\026ChannelCo" + - "nnectionProtoP\001Z@google.golang.org/genpr" + - "oto/googleapis/cloud/eventarc/v1;eventar" + - "c\252\002\030Google.Cloud.Eventarc.V1\312\002\030Google\\Cl" + - "oud\\Eventarc\\V1\352\002\033Google::Cloud::Eventar" + - "c::V1b\006proto3" - }; - descriptor = com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.FieldBehaviorProto.getDescriptor(), - com.google.api.ResourceProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }); - internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_cloud_eventarc_v1_ChannelConnection_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ChannelConnection_descriptor, - new java.lang.String[] { "Name", "Uid", "Channel", "CreateTime", "UpdateTime", "ActivationToken", }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); - registry.add(com.google.api.ResourceProto.resource); - registry.add(com.google.api.ResourceProto.resourceReference); - com.google.protobuf.Descriptors.FileDescriptor - .internalUpdateFileDescriptor(descriptor, registry); - com.google.api.FieldBehaviorProto.getDescriptor(); - com.google.api.ResourceProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java b/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java deleted file mode 100644 index 8d3e4eecfdf6..000000000000 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/ChannelProto.java +++ /dev/null @@ -1,82 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/eventarc/v1/channel.proto - -package com.google.cloud.eventarc.v1; - -public final class ChannelProto { - private ChannelProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); - } - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Channel_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n&google/cloud/eventarc/v1/channel.proto" + - "\022\030google.cloud.eventarc.v1\032\037google/api/f" + - "ield_behavior.proto\032\031google/api/resource" + - ".proto\032\037google/protobuf/timestamp.proto\"" + - "\262\004\n\007Channel\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 " + - "\001(\tB\003\340A\003\0224\n\013create_time\030\005 \001(\0132\032.google.p" + - "rotobuf.TimestampB\003\340A\003\0224\n\013update_time\030\006 " + - "\001(\0132\032.google.protobuf.TimestampB\003\340A\003\022\020\n\010" + - "provider\030\007 \001(\t\022\033\n\014pubsub_topic\030\010 \001(\tB\003\340A" + - "\003H\000\022;\n\005state\030\t \001(\0162\'.google.cloud.eventa" + - "rc.v1.Channel.StateB\003\340A\003\022\035\n\020activation_t" + - "oken\030\n \001(\tB\003\340A\003\022B\n\017crypto_key_name\030\013 \001(\t" + - "B)\340A\001\372A#\n!cloudkms.googleapis.com/Crypto" + - "Key\"E\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n\007P" + - "ENDING\020\001\022\n\n\006ACTIVE\020\002\022\014\n\010INACTIVE\020\003:s\352Ap\n" + - "\037eventarc.googleapis.com/Channel\022:projec" + - "ts/{project}/locations/{location}/channe" + - "ls/{channel}*\010channels2\007channelB\013\n\ttrans" + - "portB\304\001\n\034com.google.cloud.eventarc.v1B\014C" + - "hannelProtoP\001Z@google.golang.org/genprot" + - "o/googleapis/cloud/eventarc/v1;eventarc\252" + - "\002\030Google.Cloud.Eventarc.V1\312\002\030Google\\Clou" + - "d\\Eventarc\\V1\352\002\033Google::Cloud::Eventarc:" + - ":V1b\006proto3" - }; - descriptor = com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.FieldBehaviorProto.getDescriptor(), - com.google.api.ResourceProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }); - internal_static_google_cloud_eventarc_v1_Channel_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_cloud_eventarc_v1_Channel_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_Channel_descriptor, - new java.lang.String[] { "Name", "Uid", "CreateTime", "UpdateTime", "Provider", "PubsubTopic", "State", "ActivationToken", "CryptoKeyName", "Transport", }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); - registry.add(com.google.api.ResourceProto.resource); - registry.add(com.google.api.ResourceProto.resourceReference); - com.google.protobuf.Descriptors.FileDescriptor - .internalUpdateFileDescriptor(descriptor, registry); - com.google.api.FieldBehaviorProto.getDescriptor(); - com.google.api.ResourceProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java b/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java deleted file mode 100644 index 4c8410841ade..000000000000 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/DiscoveryProto.java +++ /dev/null @@ -1,97 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/eventarc/v1/discovery.proto - -package com.google.cloud.eventarc.v1; - -public final class DiscoveryProto { - private DiscoveryProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); - } - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Provider_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Provider_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_EventType_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_EventType_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_FilteringAttribute_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_FilteringAttribute_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n(google/cloud/eventarc/v1/discovery.pro" + - "to\022\030google.cloud.eventarc.v1\032\037google/api" + - "/field_behavior.proto\032\031google/api/resour" + - "ce.proto\"\361\001\n\010Provider\022\021\n\004name\030\001 \001(\tB\003\340A\003" + - "\022\031\n\014display_name\030\002 \001(\tB\003\340A\003\022=\n\013event_typ" + - "es\030\003 \003(\0132#.google.cloud.eventarc.v1.Even" + - "tTypeB\003\340A\003:x\352Au\n eventarc.googleapis.com" + - "/Provider\022\202\323\344\223\002/\022-/v1/{parent=projects/*/locati" + - "ons/*}/providers\332A\006parent\022\301\001\n\024GetChannel" + - "Connection\0225.google.cloud.eventarc.v1.Ge" + - "tChannelConnectionRequest\032+.google.cloud" + - ".eventarc.v1.ChannelConnection\"E\202\323\344\223\0028\0226" + - "/v1/{name=projects/*/locations/*/channel" + - "Connections/*}\332A\004name\022\324\001\n\026ListChannelCon" + - "nections\0227.google.cloud.eventarc.v1.List" + - "ChannelConnectionsRequest\0328.google.cloud" + - ".eventarc.v1.ListChannelConnectionsRespo" + - "nse\"G\202\323\344\223\0028\0226/v1/{parent=projects/*/loca" + - "tions/*}/channelConnections\332A\006parent\022\242\002\n" + - "\027CreateChannelConnection\0228.google.cloud." + - "eventarc.v1.CreateChannelConnectionReque" + - "st\032\035.google.longrunning.Operation\"\255\001\202\323\344\223" + - "\002L\"6/v1/{parent=projects/*/locations/*}/" + - "channelConnections:\022channel_connection\332A" + - "/parent,channel_connection,channel_conne" + - "ction_id\312A&\n\021ChannelConnection\022\021Operatio" + - "nMetadata\022\342\001\n\027DeleteChannelConnection\0228." + - "google.cloud.eventarc.v1.DeleteChannelCo" + - "nnectionRequest\032\035.google.longrunning.Ope" + - "ration\"n\202\323\344\223\0028*6/v1/{name=projects/*/loc" + - "ations/*/channelConnections/*}\332A\004name\312A&" + - "\n\021ChannelConnection\022\021OperationMetadata\022\306" + - "\001\n\026GetGoogleChannelConfig\0227.google.cloud" + - ".eventarc.v1.GetGoogleChannelConfigReque" + - "st\032-.google.cloud.eventarc.v1.GoogleChan" + - "nelConfig\"D\202\323\344\223\0027\0225/v1/{name=projects/*/" + - "locations/*/googleChannelConfig}\332A\004name\022" + - "\227\002\n\031UpdateGoogleChannelConfig\022:.google.c" + - "loud.eventarc.v1.UpdateGoogleChannelConf" + - "igRequest\032-.google.cloud.eventarc.v1.Goo" + - "gleChannelConfig\"\216\001\202\323\344\223\002d2K/v1/{google_c" + - "hannel_config.name=projects/*/locations/" + - "*/googleChannelConfig}:\025google_channel_c" + - "onfig\332A!google_channel_config,update_mas" + - "k\032K\312A\027eventarc.googleapis.com\322A.https://" + - "www.googleapis.com/auth/cloud-platformB\305" + - "\001\n\034com.google.cloud.eventarc.v1B\rEventar" + - "cProtoP\001Z@google.golang.org/genproto/goo" + - "gleapis/cloud/eventarc/v1;eventarc\252\002\030Goo" + - "gle.Cloud.Eventarc.V1\312\002\030Google\\Cloud\\Eve" + - "ntarc\\V1\352\002\033Google::Cloud::Eventarc::V1b\006" + - "proto3" - }; - descriptor = com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.AnnotationsProto.getDescriptor(), - com.google.api.ClientProto.getDescriptor(), - com.google.api.FieldBehaviorProto.getDescriptor(), - com.google.api.ResourceProto.getDescriptor(), - com.google.cloud.eventarc.v1.ChannelProto.getDescriptor(), - com.google.cloud.eventarc.v1.ChannelConnectionProto.getDescriptor(), - com.google.cloud.eventarc.v1.DiscoveryProto.getDescriptor(), - com.google.cloud.eventarc.v1.GoogleChannelConfigProto.getDescriptor(), - com.google.cloud.eventarc.v1.TriggerProto.getDescriptor(), - com.google.longrunning.OperationsProto.getDescriptor(), - com.google.protobuf.FieldMaskProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }); - internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_cloud_eventarc_v1_GetTriggerRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_GetTriggerRequest_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_cloud_eventarc_v1_ListTriggersRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListTriggersRequest_descriptor, - new java.lang.String[] { "Parent", "PageSize", "PageToken", "OrderBy", "Filter", }); - internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_cloud_eventarc_v1_ListTriggersResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListTriggersResponse_descriptor, - new java.lang.String[] { "Triggers", "NextPageToken", "Unreachable", }); - internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_CreateTriggerRequest_descriptor, - new java.lang.String[] { "Parent", "Trigger", "TriggerId", "ValidateOnly", }); - internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_UpdateTriggerRequest_descriptor, - new java.lang.String[] { "Trigger", "UpdateMask", "AllowMissing", "ValidateOnly", }); - internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_DeleteTriggerRequest_descriptor, - new java.lang.String[] { "Name", "Etag", "AllowMissing", "ValidateOnly", }); - internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_google_cloud_eventarc_v1_GetChannelRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_GetChannelRequest_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor = - getDescriptor().getMessageTypes().get(7); - internal_static_google_cloud_eventarc_v1_ListChannelsRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListChannelsRequest_descriptor, - new java.lang.String[] { "Parent", "PageSize", "PageToken", "OrderBy", }); - internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor = - getDescriptor().getMessageTypes().get(8); - internal_static_google_cloud_eventarc_v1_ListChannelsResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListChannelsResponse_descriptor, - new java.lang.String[] { "Channels", "NextPageToken", "Unreachable", }); - internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_google_cloud_eventarc_v1_CreateChannelRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_CreateChannelRequest_descriptor, - new java.lang.String[] { "Parent", "Channel", "ChannelId", "ValidateOnly", }); - internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor = - getDescriptor().getMessageTypes().get(10); - internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_UpdateChannelRequest_descriptor, - new java.lang.String[] { "Channel", "UpdateMask", "ValidateOnly", }); - internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor = - getDescriptor().getMessageTypes().get(11); - internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_DeleteChannelRequest_descriptor, - new java.lang.String[] { "Name", "ValidateOnly", }); - internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor = - getDescriptor().getMessageTypes().get(12); - internal_static_google_cloud_eventarc_v1_GetProviderRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_GetProviderRequest_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor = - getDescriptor().getMessageTypes().get(13); - internal_static_google_cloud_eventarc_v1_ListProvidersRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListProvidersRequest_descriptor, - new java.lang.String[] { "Parent", "PageSize", "PageToken", "OrderBy", "Filter", }); - internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor = - getDescriptor().getMessageTypes().get(14); - internal_static_google_cloud_eventarc_v1_ListProvidersResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListProvidersResponse_descriptor, - new java.lang.String[] { "Providers", "NextPageToken", "Unreachable", }); - internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor = - getDescriptor().getMessageTypes().get(15); - internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_GetChannelConnectionRequest_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListChannelConnectionsRequest_descriptor, - new java.lang.String[] { "Parent", "PageSize", "PageToken", }); - internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor = - getDescriptor().getMessageTypes().get(17); - internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_ListChannelConnectionsResponse_descriptor, - new java.lang.String[] { "ChannelConnections", "NextPageToken", "Unreachable", }); - internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor = - getDescriptor().getMessageTypes().get(18); - internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_CreateChannelConnectionRequest_descriptor, - new java.lang.String[] { "Parent", "ChannelConnection", "ChannelConnectionId", }); - internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor = - getDescriptor().getMessageTypes().get(19); - internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_DeleteChannelConnectionRequest_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor = - getDescriptor().getMessageTypes().get(20); - internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_UpdateGoogleChannelConfigRequest_descriptor, - new java.lang.String[] { "GoogleChannelConfig", "UpdateMask", }); - internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor = - getDescriptor().getMessageTypes().get(21); - internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_GetGoogleChannelConfigRequest_descriptor, - new java.lang.String[] { "Name", }); - internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(22); - internal_static_google_cloud_eventarc_v1_OperationMetadata_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_OperationMetadata_descriptor, - new java.lang.String[] { "CreateTime", "EndTime", "Target", "Verb", "StatusMessage", "RequestedCancellation", "ApiVersion", }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.ClientProto.defaultHost); - registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); - registry.add(com.google.api.AnnotationsProto.http); - registry.add(com.google.api.ClientProto.methodSignature); - registry.add(com.google.api.ClientProto.oauthScopes); - registry.add(com.google.api.ResourceProto.resourceReference); - registry.add(com.google.longrunning.OperationsProto.operationInfo); - com.google.protobuf.Descriptors.FileDescriptor - .internalUpdateFileDescriptor(descriptor, registry); - com.google.api.AnnotationsProto.getDescriptor(); - com.google.api.ClientProto.getDescriptor(); - com.google.api.FieldBehaviorProto.getDescriptor(); - com.google.api.ResourceProto.getDescriptor(); - com.google.cloud.eventarc.v1.ChannelProto.getDescriptor(); - com.google.cloud.eventarc.v1.ChannelConnectionProto.getDescriptor(); - com.google.cloud.eventarc.v1.DiscoveryProto.getDescriptor(); - com.google.cloud.eventarc.v1.GoogleChannelConfigProto.getDescriptor(); - com.google.cloud.eventarc.v1.TriggerProto.getDescriptor(); - com.google.longrunning.OperationsProto.getDescriptor(); - com.google.protobuf.FieldMaskProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java b/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java deleted file mode 100644 index 97efa8ec1b29..000000000000 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/GoogleChannelConfigProto.java +++ /dev/null @@ -1,80 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/eventarc/v1/google_channel_config.proto - -package com.google.cloud.eventarc.v1; - -public final class GoogleChannelConfigProto { - private GoogleChannelConfigProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); - } - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n4google/cloud/eventarc/v1/google_channe" + - "l_config.proto\022\030google.cloud.eventarc.v1" + - "\032\037google/api/field_behavior.proto\032\031googl" + - "e/api/resource.proto\032\037google/protobuf/ti" + - "mestamp.proto\"\247\002\n\023GoogleChannelConfig\022\021\n" + - "\004name\030\001 \001(\tB\003\340A\002\0224\n\013update_time\030\006 \001(\0132\032." + - "google.protobuf.TimestampB\003\340A\003\022B\n\017crypto" + - "_key_name\030\007 \001(\tB)\340A\001\372A#\n!cloudkms.google" + - "apis.com/CryptoKey:\202\001\352A\177\n+eventarc.googl" + - "eapis.com/GoogleChannelConfig\022;projects/" + - "{project}/locations/{location}/googleCha" + - "nnelConfig2\023googleChannelConfigB\313\002\n\034com." + - "google.cloud.eventarc.v1B\030GoogleChannelC" + - "onfigProtoP\001Z@google.golang.org/genproto" + - "/googleapis/cloud/eventarc/v1;eventarc\252\002" + - "\030Google.Cloud.Eventarc.V1\312\002\030Google\\Cloud" + - "\\Eventarc\\V1\352\002\033Google::Cloud::Eventarc::" + - "V1\352Ax\n!cloudkms.googleapis.com/CryptoKey" + - "\022Sprojects/{project}/locations/{location" + - "}/keyRings/{key_ring}/cryptoKeys/{crypto" + - "_key}b\006proto3" - }; - descriptor = com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.FieldBehaviorProto.getDescriptor(), - com.google.api.ResourceProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }); - internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_eventarc_v1_GoogleChannelConfig_descriptor, - new java.lang.String[] { "Name", "UpdateTime", "CryptoKeyName", }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); - registry.add(com.google.api.ResourceProto.resource); - registry.add(com.google.api.ResourceProto.resourceDefinition); - registry.add(com.google.api.ResourceProto.resourceReference); - com.google.protobuf.Descriptors.FileDescriptor - .internalUpdateFileDescriptor(descriptor, registry); - com.google.api.FieldBehaviorProto.getDescriptor(); - com.google.api.ResourceProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java b/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java deleted file mode 100644 index 7016fc68fdd5..000000000000 --- a/owl-bot-staging/java-eventarc/v1/proto-google-cloud-eventarc-v1/src/main/java/com/google/cloud/eventarc/v1/TriggerProto.java +++ /dev/null @@ -1,218 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/cloud/eventarc/v1/trigger.proto - -package com.google.cloud.eventarc.v1; - -public final class TriggerProto { - private TriggerProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); - } - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Trigger_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Trigger_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Trigger_LabelsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Trigger_ConditionsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_EventFilter_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_EventFilter_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_StateCondition_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_StateCondition_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Destination_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Destination_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Transport_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Transport_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_CloudRun_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_CloudRun_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_GKE_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_GKE_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_eventarc_v1_Pubsub_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_eventarc_v1_Pubsub_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { - return descriptor; - } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; - static { - java.lang.String[] descriptorData = { - "\n&google/cloud/eventarc/v1/trigger.proto" + - "\022\030google.cloud.eventarc.v1\032\037google/api/f" + - "ield_behavior.proto\032\031google/api/resource" + - ".proto\032\037google/protobuf/timestamp.proto\032" + - "\025google/rpc/code.proto\"\334\006\n\007Trigger\022\021\n\004na" + - "me\030\001 \001(\tB\003\340A\002\022\020\n\003uid\030\002 \001(\tB\003\340A\003\0224\n\013creat" + - "e_time\030\005 \001(\0132\032.google.protobuf.Timestamp" + - "B\003\340A\003\0224\n\013update_time\030\006 \001(\0132\032.google.prot" + - "obuf.TimestampB\003\340A\003\022D\n\revent_filters\030\010 \003" + - "(\0132%.google.cloud.eventarc.v1.EventFilte" + - "rB\006\340A\006\340A\002\022B\n\017service_account\030\t \001(\tB)\340A\001\372" + - "A#\n!iam.googleapis.com/ServiceAccount\022?\n" + - "\013destination\030\n \001(\0132%.google.cloud.eventa" + - "rc.v1.DestinationB\003\340A\002\022;\n\ttransport\030\013 \001(" + - "\0132#.google.cloud.eventarc.v1.TransportB\003" + - "\340A\001\022B\n\006labels\030\014 \003(\0132-.google.cloud.event" + - "arc.v1.Trigger.LabelsEntryB\003\340A\001\022\024\n\007chann" + - "el\030\r \001(\tB\003\340A\001\022J\n\nconditions\030\017 \003(\01321.goog" + - "le.cloud.eventarc.v1.Trigger.ConditionsE" + - "ntryB\003\340A\003\022\021\n\004etag\030c \001(\tB\003\340A\003\032-\n\013LabelsEn" + - "try\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\032[\n\017C" + - "onditionsEntry\022\013\n\003key\030\001 \001(\t\0227\n\005value\030\002 \001" + - "(\0132(.google.cloud.eventarc.v1.StateCondi" + - "tion:\0028\001:s\352Ap\n\037eventarc.googleapis.com/T" + - "rigger\022:projects/{project}/locations/{lo" + - "cation}/triggers/{trigger}*\010triggers2\007tr" + - "igger\"P\n\013EventFilter\022\026\n\tattribute\030\001 \001(\tB" + - "\003\340A\002\022\022\n\005value\030\002 \001(\tB\003\340A\002\022\025\n\010operator\030\003 \001" + - "(\tB\003\340A\001\"A\n\016StateCondition\022\036\n\004code\030\001 \001(\0162" + - "\020.google.rpc.Code\022\017\n\007message\030\002 \001(\t\"\212\002\n\013D" + - "estination\0227\n\tcloud_run\030\001 \001(\0132\".google.c" + - "loud.eventarc.v1.CloudRunH\000\022J\n\016cloud_fun" + - "ction\030\002 \001(\tB0\372A-\n+cloudfunctions.googlea" + - "pis.com/CloudFunctionH\000\022,\n\003gke\030\003 \001(\0132\035.g" + - "oogle.cloud.eventarc.v1.GKEH\000\022:\n\010workflo" + - "w\030\004 \001(\tB&\372A#\n!workflows.googleapis.com/W" + - "orkflowH\000B\014\n\ndescriptor\"O\n\tTransport\0222\n\006" + - "pubsub\030\001 \001(\0132 .google.cloud.eventarc.v1." + - "PubsubH\000B\016\n\014intermediary\"g\n\010CloudRun\0223\n\007" + - "service\030\001 \001(\tB\"\340A\002\372A\034\n\032run.googleapis.co" + - "m/Service\022\021\n\004path\030\002 \001(\tB\003\340A\001\022\023\n\006region\030\003" + - " \001(\tB\003\340A\002\"s\n\003GKE\022\024\n\007cluster\030\001 \001(\tB\003\340A\002\022\025" + - "\n\010location\030\002 \001(\tB\003\340A\002\022\026\n\tnamespace\030\003 \001(\t" + - "B\003\340A\002\022\024\n\007service\030\004 \001(\tB\003\340A\002\022\021\n\004path\030\005 \001(" + - "\tB\003\340A\001\"7\n\006Pubsub\022\022\n\005topic\030\001 \001(\tB\003\340A\001\022\031\n\014" + - "subscription\030\002 \001(\tB\003\340A\003B\300\003\n\034com.google.c" + - "loud.eventarc.v1B\014TriggerProtoP\001Z@google" + - ".golang.org/genproto/googleapis/cloud/ev" + - "entarc/v1;eventarc\352Ak\n+cloudfunctions.go" + - "ogleapis.com/CloudFunction\022