Package com.google.cloud.functions.v1
Class EventTrigger.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<EventTrigger.Builder>
com.google.cloud.functions.v1.EventTrigger.Builder
- All Implemented Interfaces:
EventTriggerOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- EventTrigger
public static final class EventTrigger.Builder
extends com.google.protobuf.GeneratedMessage.Builder<EventTrigger.Builder>
implements EventTriggerOrBuilder
Describes EventTrigger, used to request events be sent from another service.Protobuf type
google.cloud.functions.v1.EventTrigger-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Required.Specifies policy for failed executions.Required.The hostname of the service that should be observed.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorRequired.com.google.protobuf.ByteStringRequired.Specifies policy for failed executions.Specifies policy for failed executions.Specifies policy for failed executions.Required.com.google.protobuf.ByteStringRequired.The hostname of the service that should be observed.com.google.protobuf.ByteStringThe hostname of the service that should be observed.booleanSpecifies policy for failed executions.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFailurePolicy(FailurePolicy value) Specifies policy for failed executions.mergeFrom(EventTrigger other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setEventType(String value) Required.setEventTypeBytes(com.google.protobuf.ByteString value) Required.setFailurePolicy(FailurePolicy value) Specifies policy for failed executions.setFailurePolicy(FailurePolicy.Builder builderForValue) Specifies policy for failed executions.setResource(String value) Required.setResourceBytes(com.google.protobuf.ByteString value) Required.setService(String value) The hostname of the service that should be observed.setServiceBytes(com.google.protobuf.ByteString value) The hostname of the service that should be observed.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<EventTrigger.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<EventTrigger.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<EventTrigger.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<EventTrigger.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<EventTrigger.Builder>
-
mergeFrom
public EventTrigger.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<EventTrigger.Builder>- Throws:
IOException
-
getEventType
Required. The type of event to observe. For example: `providers/cloud.storage/eventTypes/object.change` and `providers/cloud.pubsub/eventTypes/topic.publish`. Event types match pattern `providers/*/eventTypes/*.*`. The pattern contains: 1. namespace: For example, `cloud.storage` and `google.firebase.analytics`. 2. resource type: The type of resource on which event occurs. For example, the Google Cloud Storage API includes the type `object`. 3. action: The action that generates the event. For example, action for a Google Cloud Storage Object is 'change'. These parts are lower case.
string event_type = 1;- Specified by:
getEventTypein interfaceEventTriggerOrBuilder- Returns:
- The eventType.
-
getEventTypeBytes
public com.google.protobuf.ByteString getEventTypeBytes()Required. The type of event to observe. For example: `providers/cloud.storage/eventTypes/object.change` and `providers/cloud.pubsub/eventTypes/topic.publish`. Event types match pattern `providers/*/eventTypes/*.*`. The pattern contains: 1. namespace: For example, `cloud.storage` and `google.firebase.analytics`. 2. resource type: The type of resource on which event occurs. For example, the Google Cloud Storage API includes the type `object`. 3. action: The action that generates the event. For example, action for a Google Cloud Storage Object is 'change'. These parts are lower case.
string event_type = 1;- Specified by:
getEventTypeBytesin interfaceEventTriggerOrBuilder- Returns:
- The bytes for eventType.
-
setEventType
Required. The type of event to observe. For example: `providers/cloud.storage/eventTypes/object.change` and `providers/cloud.pubsub/eventTypes/topic.publish`. Event types match pattern `providers/*/eventTypes/*.*`. The pattern contains: 1. namespace: For example, `cloud.storage` and `google.firebase.analytics`. 2. resource type: The type of resource on which event occurs. For example, the Google Cloud Storage API includes the type `object`. 3. action: The action that generates the event. For example, action for a Google Cloud Storage Object is 'change'. These parts are lower case.
string event_type = 1;- Parameters:
value- The eventType to set.- Returns:
- This builder for chaining.
-
clearEventType
Required. The type of event to observe. For example: `providers/cloud.storage/eventTypes/object.change` and `providers/cloud.pubsub/eventTypes/topic.publish`. Event types match pattern `providers/*/eventTypes/*.*`. The pattern contains: 1. namespace: For example, `cloud.storage` and `google.firebase.analytics`. 2. resource type: The type of resource on which event occurs. For example, the Google Cloud Storage API includes the type `object`. 3. action: The action that generates the event. For example, action for a Google Cloud Storage Object is 'change'. These parts are lower case.
string event_type = 1;- Returns:
- This builder for chaining.
-
setEventTypeBytes
Required. The type of event to observe. For example: `providers/cloud.storage/eventTypes/object.change` and `providers/cloud.pubsub/eventTypes/topic.publish`. Event types match pattern `providers/*/eventTypes/*.*`. The pattern contains: 1. namespace: For example, `cloud.storage` and `google.firebase.analytics`. 2. resource type: The type of resource on which event occurs. For example, the Google Cloud Storage API includes the type `object`. 3. action: The action that generates the event. For example, action for a Google Cloud Storage Object is 'change'. These parts are lower case.
string event_type = 1;- Parameters:
value- The bytes for eventType to set.- Returns:
- This builder for chaining.
-
getResource
Required. The resource(s) from which to observe events, for example, `projects/_/buckets/myBucket`. Not all syntactically correct values are accepted by all services. For example: 1. The authorization model must support it. Google Cloud Functions only allows EventTriggers to be deployed that observe resources in the same project as the `CloudFunction`. 2. The resource type must match the pattern expected for an `event_type`. For example, an `EventTrigger` that has an `event_type` of "google.pubsub.topic.publish" should have a resource that matches Google Cloud Pub/Sub topics. Additionally, some services may support short names when creating an `EventTrigger`. These will always be returned in the normalized "long" format. See each *service's* documentation for supported formats.
string resource = 2;- Specified by:
getResourcein interfaceEventTriggerOrBuilder- Returns:
- The resource.
-
getResourceBytes
public com.google.protobuf.ByteString getResourceBytes()Required. The resource(s) from which to observe events, for example, `projects/_/buckets/myBucket`. Not all syntactically correct values are accepted by all services. For example: 1. The authorization model must support it. Google Cloud Functions only allows EventTriggers to be deployed that observe resources in the same project as the `CloudFunction`. 2. The resource type must match the pattern expected for an `event_type`. For example, an `EventTrigger` that has an `event_type` of "google.pubsub.topic.publish" should have a resource that matches Google Cloud Pub/Sub topics. Additionally, some services may support short names when creating an `EventTrigger`. These will always be returned in the normalized "long" format. See each *service's* documentation for supported formats.
string resource = 2;- Specified by:
getResourceBytesin interfaceEventTriggerOrBuilder- Returns:
- The bytes for resource.
-
setResource
Required. The resource(s) from which to observe events, for example, `projects/_/buckets/myBucket`. Not all syntactically correct values are accepted by all services. For example: 1. The authorization model must support it. Google Cloud Functions only allows EventTriggers to be deployed that observe resources in the same project as the `CloudFunction`. 2. The resource type must match the pattern expected for an `event_type`. For example, an `EventTrigger` that has an `event_type` of "google.pubsub.topic.publish" should have a resource that matches Google Cloud Pub/Sub topics. Additionally, some services may support short names when creating an `EventTrigger`. These will always be returned in the normalized "long" format. See each *service's* documentation for supported formats.
string resource = 2;- Parameters:
value- The resource to set.- Returns:
- This builder for chaining.
-
clearResource
Required. The resource(s) from which to observe events, for example, `projects/_/buckets/myBucket`. Not all syntactically correct values are accepted by all services. For example: 1. The authorization model must support it. Google Cloud Functions only allows EventTriggers to be deployed that observe resources in the same project as the `CloudFunction`. 2. The resource type must match the pattern expected for an `event_type`. For example, an `EventTrigger` that has an `event_type` of "google.pubsub.topic.publish" should have a resource that matches Google Cloud Pub/Sub topics. Additionally, some services may support short names when creating an `EventTrigger`. These will always be returned in the normalized "long" format. See each *service's* documentation for supported formats.
string resource = 2;- Returns:
- This builder for chaining.
-
setResourceBytes
Required. The resource(s) from which to observe events, for example, `projects/_/buckets/myBucket`. Not all syntactically correct values are accepted by all services. For example: 1. The authorization model must support it. Google Cloud Functions only allows EventTriggers to be deployed that observe resources in the same project as the `CloudFunction`. 2. The resource type must match the pattern expected for an `event_type`. For example, an `EventTrigger` that has an `event_type` of "google.pubsub.topic.publish" should have a resource that matches Google Cloud Pub/Sub topics. Additionally, some services may support short names when creating an `EventTrigger`. These will always be returned in the normalized "long" format. See each *service's* documentation for supported formats.
string resource = 2;- Parameters:
value- The bytes for resource to set.- Returns:
- This builder for chaining.
-
getService
The hostname of the service that should be observed. If no string is provided, the default service implementing the API will be used. For example, `storage.googleapis.com` is the default for all event types in the `google.storage` namespace.
string service = 3;- Specified by:
getServicein interfaceEventTriggerOrBuilder- Returns:
- The service.
-
getServiceBytes
public com.google.protobuf.ByteString getServiceBytes()The hostname of the service that should be observed. If no string is provided, the default service implementing the API will be used. For example, `storage.googleapis.com` is the default for all event types in the `google.storage` namespace.
string service = 3;- Specified by:
getServiceBytesin interfaceEventTriggerOrBuilder- Returns:
- The bytes for service.
-
setService
The hostname of the service that should be observed. If no string is provided, the default service implementing the API will be used. For example, `storage.googleapis.com` is the default for all event types in the `google.storage` namespace.
string service = 3;- Parameters:
value- The service to set.- Returns:
- This builder for chaining.
-
clearService
The hostname of the service that should be observed. If no string is provided, the default service implementing the API will be used. For example, `storage.googleapis.com` is the default for all event types in the `google.storage` namespace.
string service = 3;- Returns:
- This builder for chaining.
-
setServiceBytes
The hostname of the service that should be observed. If no string is provided, the default service implementing the API will be used. For example, `storage.googleapis.com` is the default for all event types in the `google.storage` namespace.
string service = 3;- Parameters:
value- The bytes for service to set.- Returns:
- This builder for chaining.
-
hasFailurePolicy
public boolean hasFailurePolicy()Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5;- Specified by:
hasFailurePolicyin interfaceEventTriggerOrBuilder- Returns:
- Whether the failurePolicy field is set.
-
getFailurePolicy
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5;- Specified by:
getFailurePolicyin interfaceEventTriggerOrBuilder- Returns:
- The failurePolicy.
-
setFailurePolicy
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5; -
setFailurePolicy
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5; -
mergeFailurePolicy
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5; -
clearFailurePolicy
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5; -
getFailurePolicyBuilder
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5; -
getFailurePolicyOrBuilder
Specifies policy for failed executions.
.google.cloud.functions.v1.FailurePolicy failure_policy = 5;- Specified by:
getFailurePolicyOrBuilderin interfaceEventTriggerOrBuilder
-