public final class NotificationConfig extends GeneratedMessageV3 implements NotificationConfigOrBuilder
A directive to publish Pub/Sub notifications upon changes to a bucket.
Protobuf type google.storage.v2.NotificationConfig
Static Fields
CUSTOM_ATTRIBUTES_FIELD_NUMBER
public static final int CUSTOM_ATTRIBUTES_FIELD_NUMBER
Field Value
ETAG_FIELD_NUMBER
public static final int ETAG_FIELD_NUMBER
Field Value
EVENT_TYPES_FIELD_NUMBER
public static final int EVENT_TYPES_FIELD_NUMBER
Field Value
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER
Field Value
OBJECT_NAME_PREFIX_FIELD_NUMBER
public static final int OBJECT_NAME_PREFIX_FIELD_NUMBER
Field Value
public static final int PAYLOAD_FORMAT_FIELD_NUMBER
Field Value
TOPIC_FIELD_NUMBER
public static final int TOPIC_FIELD_NUMBER
Field Value
Static Methods
getDefaultInstance()
public static NotificationConfig getDefaultInstance()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
newBuilder()
public static NotificationConfig.Builder newBuilder()
Returns
newBuilder(NotificationConfig prototype)
public static NotificationConfig.Builder newBuilder(NotificationConfig prototype)
Parameter
Returns
public static NotificationConfig parseDelimitedFrom(InputStream input)
Parameter
Returns
Exceptions
public static NotificationConfig parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(byte[] data)
public static NotificationConfig parseFrom(byte[] data)
Parameter
Name | Description |
data | byte[]
|
Returns
Exceptions
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static NotificationConfig parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteString data)
public static NotificationConfig parseFrom(ByteString data)
Parameter
Returns
Exceptions
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static NotificationConfig parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static NotificationConfig parseFrom(CodedInputStream input)
Parameter
Returns
Exceptions
public static NotificationConfig parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
public static NotificationConfig parseFrom(InputStream input)
Parameter
Returns
Exceptions
public static NotificationConfig parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parseFrom(ByteBuffer data)
public static NotificationConfig parseFrom(ByteBuffer data)
Parameter
Returns
Exceptions
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static NotificationConfig parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Exceptions
parser()
public static Parser<NotificationConfig> parser()
Returns
Methods
containsCustomAttributes(String key)
public boolean containsCustomAttributes(String key)
A list of additional attributes to attach to each Pub/Sub
message published for this NotificationConfig.
map<string, string> custom_attributes = 4;
Parameter
Returns
equals(Object obj)
public boolean equals(Object obj)
Parameter
Returns
Overrides
getCustomAttributes()
public Map<String,String> getCustomAttributes()
Returns
getCustomAttributesCount()
public int getCustomAttributesCount()
A list of additional attributes to attach to each Pub/Sub
message published for this NotificationConfig.
map<string, string> custom_attributes = 4;
Returns
getCustomAttributesMap()
public Map<String,String> getCustomAttributesMap()
A list of additional attributes to attach to each Pub/Sub
message published for this NotificationConfig.
map<string, string> custom_attributes = 4;
Returns
getCustomAttributesOrDefault(String key, String defaultValue)
public String getCustomAttributesOrDefault(String key, String defaultValue)
A list of additional attributes to attach to each Pub/Sub
message published for this NotificationConfig.
map<string, string> custom_attributes = 4;
Parameters
Returns
getCustomAttributesOrThrow(String key)
public String getCustomAttributesOrThrow(String key)
A list of additional attributes to attach to each Pub/Sub
message published for this NotificationConfig.
map<string, string> custom_attributes = 4;
Parameter
Returns
getDefaultInstanceForType()
public NotificationConfig getDefaultInstanceForType()
Returns
getEtag()
The etag of the NotificationConfig.
If included in the metadata of GetNotificationConfigRequest, the operation
will only be performed if the etag matches that of the NotificationConfig.
string etag = 7;
Returns
Type | Description |
String | The etag.
|
getEtagBytes()
public ByteString getEtagBytes()
The etag of the NotificationConfig.
If included in the metadata of GetNotificationConfigRequest, the operation
will only be performed if the etag matches that of the NotificationConfig.
string etag = 7;
Returns
getEventTypes(int index)
public String getEventTypes(int index)
If present, only send notifications about listed event types. If
empty, sent notifications for all event types.
repeated string event_types = 3;
Parameter
Name | Description |
index | int
The index of the element to return.
|
Returns
Type | Description |
String | The eventTypes at the given index.
|
getEventTypesBytes(int index)
public ByteString getEventTypesBytes(int index)
If present, only send notifications about listed event types. If
empty, sent notifications for all event types.
repeated string event_types = 3;
Parameter
Name | Description |
index | int
The index of the value to return.
|
Returns
Type | Description |
ByteString | The bytes of the eventTypes at the given index.
|
getEventTypesCount()
public int getEventTypesCount()
If present, only send notifications about listed event types. If
empty, sent notifications for all event types.
repeated string event_types = 3;
Returns
Type | Description |
int | The count of eventTypes.
|
getEventTypesList()
public ProtocolStringList getEventTypesList()
If present, only send notifications about listed event types. If
empty, sent notifications for all event types.
repeated string event_types = 3;
Returns
getName()
Required. The resource name of this NotificationConfig.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notificationConfig}
The {project}
portion may be _
for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
String | The name.
|
getNameBytes()
public ByteString getNameBytes()
Required. The resource name of this NotificationConfig.
Format:
projects/{project}/buckets/{bucket}/notificationConfigs/{notificationConfig}
The {project}
portion may be _
for globally unique buckets.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Returns
getObjectNamePrefix()
public String getObjectNamePrefix()
If present, only apply this NotificationConfig to object names that
begin with this prefix.
string object_name_prefix = 5;
Returns
Type | Description |
String | The objectNamePrefix.
|
getObjectNamePrefixBytes()
public ByteString getObjectNamePrefixBytes()
If present, only apply this NotificationConfig to object names that
begin with this prefix.
string object_name_prefix = 5;
Returns
Type | Description |
ByteString | The bytes for objectNamePrefix.
|
getParserForType()
public Parser<NotificationConfig> getParserForType()
Returns
Overrides
public String getPayloadFormat()
Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
String | The payloadFormat.
|
public ByteString getPayloadFormatBytes()
Required. The desired content of the Payload.
string payload_format = 6 [(.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
ByteString | The bytes for payloadFormat.
|
getSerializedSize()
public int getSerializedSize()
Returns
Overrides
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];
Returns
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];
Returns
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Returns
Overrides
hashCode()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
newBuilderForType()
public NotificationConfig.Builder newBuilderForType()
Returns
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected NotificationConfig.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
Returns
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
Returns
Overrides
toBuilder()
public NotificationConfig.Builder toBuilder()
Returns
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Parameter
Overrides
Exceptions