- 2.58.1 (latest)
- 2.58.0
- 2.57.0
- 2.56.0
- 2.55.0
- 2.54.0
- 2.53.3
- 2.52.3
- 2.50.0
- 2.49.0
- 2.48.2
- 2.47.0
- 2.46.0
- 2.45.0
- 2.44.1
- 2.43.2
- 2.42.0
- 2.41.0
- 2.40.1
- 2.39.0
- 2.38.0
- 2.37.0
- 2.36.1
- 2.34.0
- 2.33.0
- 2.32.1
- 2.30.1
- 2.29.1
- 2.28.0
- 2.27.1
- 2.24.0
- 2.23.0
- 2.22.6
- 2.21.0
- 2.20.2
- 2.19.0
- 2.18.0
- 2.17.2
- 2.16.0
- 2.15.1
- 2.14.0
- 2.13.1
- 2.12.0
- 2.11.3
- 2.10.0
- 2.9.3
- 2.8.1
- 2.7.1
- 2.6.1
- 2.5.1
- 2.4.5
- 2.3.0
- 2.2.3
- 2.1.10
public static final class Notification.Builder extends GeneratedMessageV3.Builder<Notification.Builder> implements NotificationOrBuilderA directive to publish Pub/Sub notifications upon changes to a bucket.
Protobuf type google.storage.v2.Notification
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > Notification.BuilderImplements
NotificationOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Type | Description |
| Descriptor |
Methods
addAllEventTypes(Iterable<String> values)
public Notification.Builder addAllEventTypes(Iterable<String> values)Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| values | Iterable<String>The eventTypes to add. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
addEventTypes(String value)
public Notification.Builder addEventTypes(String value)Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| value | StringThe eventTypes to add. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
addEventTypesBytes(ByteString value)
public Notification.Builder addEventTypesBytes(ByteString value)Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| value | ByteStringThe bytes of the eventTypes to add. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public Notification.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)| Name | Description |
| field | FieldDescriptor |
| value | Object |
| Type | Description |
| Notification.Builder |
build()
public Notification build()| Type | Description |
| Notification |
buildPartial()
public Notification buildPartial()| Type | Description |
| Notification |
clear()
public Notification.Builder clear()| Type | Description |
| Notification.Builder |
clearCustomAttributes()
public Notification.Builder clearCustomAttributes()| Type | Description |
| Notification.Builder |
clearEventTypes()
public Notification.Builder clearEventTypes()Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| Notification.Builder | This builder for chaining. |
clearField(Descriptors.FieldDescriptor field)
public Notification.Builder clearField(Descriptors.FieldDescriptor field)| Name | Description |
| field | FieldDescriptor |
| Type | Description |
| Notification.Builder |
clearName()
public Notification.Builder clearName() Required. The resource name of this notification.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notification}
The {project} portion may be _ for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| Notification.Builder | This builder for chaining. |
clearObjectNamePrefix()
public Notification.Builder clearObjectNamePrefix()Optional. If present, only apply this notification config to object names that begin with this prefix.
string object_name_prefix = 5 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| Notification.Builder | This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public Notification.Builder clearOneof(Descriptors.OneofDescriptor oneof)| Name | Description |
| oneof | OneofDescriptor |
| Type | Description |
| Notification.Builder |
clearPayloadFormat()
public Notification.Builder clearPayloadFormat()Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| Notification.Builder | This builder for chaining. |
clearTopic()
public Notification.Builder clearTopic()Required. The Pub/Sub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'
string topic = 2 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| Notification.Builder | This builder for chaining. |
clone()
public Notification.Builder clone()| Type | Description |
| Notification.Builder |
containsCustomAttributes(String key)
public boolean containsCustomAttributes(String key)Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| key | String |
| Type | Description |
| boolean |
getCustomAttributes()
public Map<String,String> getCustomAttributes()Use #getCustomAttributesMap() instead.
| Type | Description |
| Map<String,String> |
getCustomAttributesCount()
public int getCustomAttributesCount()Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| int |
getCustomAttributesMap()
public Map<String,String> getCustomAttributesMap()Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| Map<String,String> |
getCustomAttributesOrDefault(String key, String defaultValue)
public String getCustomAttributesOrDefault(String key, String defaultValue)Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| key | String |
| defaultValue | String |
| Type | Description |
| String |
getCustomAttributesOrThrow(String key)
public String getCustomAttributesOrThrow(String key)Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| key | String |
| Type | Description |
| String |
getDefaultInstanceForType()
public Notification getDefaultInstanceForType()| Type | Description |
| Notification |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Type | Description |
| Descriptor |
getEventTypes(int index)
public String getEventTypes(int index)Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| index | intThe index of the element to return. |
| Type | Description |
| String | The eventTypes at the given index. |
getEventTypesBytes(int index)
public ByteString getEventTypesBytes(int index)Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| index | intThe index of the value to return. |
| Type | Description |
| ByteString | The bytes of the eventTypes at the given index. |
getEventTypesCount()
public int getEventTypesCount()Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| int | The count of eventTypes. |
getEventTypesList()
public ProtocolStringList getEventTypesList()Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| ProtocolStringList | A list containing the eventTypes. |
getMutableCustomAttributes()
public Map<String,String> getMutableCustomAttributes()Use alternate mutation accessors instead.
| Type | Description |
| Map<String,String> |
getName()
public String getName() Required. The resource name of this notification.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notification}
The {project} portion may be _ for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| String | The name. |
getNameBytes()
public ByteString getNameBytes() Required. The resource name of this notification.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notification}
The {project} portion may be _ for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| ByteString | The bytes for name. |
getObjectNamePrefix()
public String getObjectNamePrefix()Optional. If present, only apply this notification config to object names that begin with this prefix.
string object_name_prefix = 5 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| String | The objectNamePrefix. |
getObjectNamePrefixBytes()
public ByteString getObjectNamePrefixBytes()Optional. If present, only apply this notification config to object names that begin with this prefix.
string object_name_prefix = 5 [(.google.api.field_behavior) = OPTIONAL];
| Type | Description |
| ByteString | The bytes for objectNamePrefix. |
getPayloadFormat()
public String getPayloadFormat()Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| String | The payloadFormat. |
getPayloadFormatBytes()
public ByteString getPayloadFormatBytes()Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| ByteString | The bytes for payloadFormat. |
getTopic()
public String getTopic()Required. The Pub/Sub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'
string topic = 2 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| String | The topic. |
getTopicBytes()
public ByteString getTopicBytes()Required. The Pub/Sub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'
string topic = 2 [(.google.api.field_behavior) = REQUIRED];
| Type | Description |
| ByteString | The bytes for topic. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()| Type | Description |
| FieldAccessorTable |
internalGetMapField(int number)
protected MapField internalGetMapField(int number)| Name | Description |
| number | int |
| Type | Description |
| MapField |
internalGetMutableMapField(int number)
protected MapField internalGetMutableMapField(int number)| Name | Description |
| number | int |
| Type | Description |
| MapField |
isInitialized()
public final boolean isInitialized()| Type | Description |
| boolean |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public Notification.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Name | Description |
| input | CodedInputStream |
| extensionRegistry | ExtensionRegistryLite |
| Type | Description |
| Notification.Builder |
| Type | Description |
| IOException |
mergeFrom(Message other)
public Notification.Builder mergeFrom(Message other)| Name | Description |
| other | Message |
| Type | Description |
| Notification.Builder |
mergeFrom(Notification other)
public Notification.Builder mergeFrom(Notification other)| Name | Description |
| other | Notification |
| Type | Description |
| Notification.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final Notification.Builder mergeUnknownFields(UnknownFieldSet unknownFields)| Name | Description |
| unknownFields | UnknownFieldSet |
| Type | Description |
| Notification.Builder |
putAllCustomAttributes(Map<String,String> values)
public Notification.Builder putAllCustomAttributes(Map<String,String> values)Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| values | Map<String,String> |
| Type | Description |
| Notification.Builder |
putCustomAttributes(String key, String value)
public Notification.Builder putCustomAttributes(String key, String value)Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| key | String |
| value | String |
| Type | Description |
| Notification.Builder |
removeCustomAttributes(String key)
public Notification.Builder removeCustomAttributes(String key)Optional. An optional list of additional attributes to attach to each Pub/Sub message published for this notification subscription.
map<string, string> custom_attributes = 4 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| key | String |
| Type | Description |
| Notification.Builder |
setEventTypes(int index, String value)
public Notification.Builder setEventTypes(int index, String value)Optional. If present, only send notifications about listed event types. If empty, sent notifications for all event types.
repeated string event_types = 3 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| index | intThe index to set the value at. |
| value | StringThe eventTypes to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setField(Descriptors.FieldDescriptor field, Object value)
public Notification.Builder setField(Descriptors.FieldDescriptor field, Object value)| Name | Description |
| field | FieldDescriptor |
| value | Object |
| Type | Description |
| Notification.Builder |
setName(String value)
public Notification.Builder setName(String value) Required. The resource name of this notification.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notification}
The {project} portion may be _ for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
| Name | Description |
| value | StringThe name to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setNameBytes(ByteString value)
public Notification.Builder setNameBytes(ByteString value) Required. The resource name of this notification.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notification}
The {project} portion may be _ for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
| Name | Description |
| value | ByteStringThe bytes for name to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setObjectNamePrefix(String value)
public Notification.Builder setObjectNamePrefix(String value)Optional. If present, only apply this notification config to object names that begin with this prefix.
string object_name_prefix = 5 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| value | StringThe objectNamePrefix to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setObjectNamePrefixBytes(ByteString value)
public Notification.Builder setObjectNamePrefixBytes(ByteString value)Optional. If present, only apply this notification config to object names that begin with this prefix.
string object_name_prefix = 5 [(.google.api.field_behavior) = OPTIONAL];
| Name | Description |
| value | ByteStringThe bytes for objectNamePrefix to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setPayloadFormat(String value)
public Notification.Builder setPayloadFormat(String value)Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
| Name | Description |
| value | StringThe payloadFormat to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setPayloadFormatBytes(ByteString value)
public Notification.Builder setPayloadFormatBytes(ByteString value)Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
| Name | Description |
| value | ByteStringThe bytes for payloadFormat to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public Notification.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)| Name | Description |
| field | FieldDescriptor |
| index | int |
| value | Object |
| Type | Description |
| Notification.Builder |
setTopic(String value)
public Notification.Builder setTopic(String value)Required. The Pub/Sub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'
string topic = 2 [(.google.api.field_behavior) = REQUIRED];
| Name | Description |
| value | StringThe topic to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setTopicBytes(ByteString value)
public Notification.Builder setTopicBytes(ByteString value)Required. The Pub/Sub topic to which this subscription publishes. Formatted as: '//pubsub.googleapis.com/projects/{project-identifier}/topics/{my-topic}'
string topic = 2 [(.google.api.field_behavior) = REQUIRED];
| Name | Description |
| value | ByteStringThe bytes for topic to set. |
| Type | Description |
| Notification.Builder | This builder for chaining. |
setUnknownFields(UnknownFieldSet unknownFields)
public final Notification.Builder setUnknownFields(UnknownFieldSet unknownFields)| Name | Description |
| unknownFields | UnknownFieldSet |
| Type | Description |
| Notification.Builder |