Send feedback
Class Contact (2.17.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version 2.17.0keyboard_arrow_down
public final class Contact extends GeneratedMessageV3 implements ContactOrBuilder
A contact that will receive notifications from Google Cloud.
Protobuf type google.cloud.essentialcontacts.v1.Contact
Static Fields
public static final int EMAIL_FIELD_NUMBER
Field Value
Type
Description
int
public static final int LANGUAGE_TAG_FIELD_NUMBER
Field Value
Type
Description
int
public static final int NAME_FIELD_NUMBER
Field Value
Type
Description
int
public static final int NOTIFICATION_CATEGORY_SUBSCRIPTIONS_FIELD_NUMBER
Field Value
Type
Description
int
public static final int VALIDATE_TIME_FIELD_NUMBER
Field Value
Type
Description
int
public static final int VALIDATION_STATE_FIELD_NUMBER
Field Value
Type
Description
int
Static Methods
public static Contact getDefaultInstance ()
public static final Descriptors . Descriptor getDescriptor ()
public static Contact . Builder newBuilder ()
public static Contact . Builder newBuilder ( Contact prototype )
Parameter
Name
Description
prototype
Contact
public static Contact parseDelimitedFrom ( InputStream input )
public static Contact parseDelimitedFrom ( InputStream input , ExtensionRegistryLite extensionRegistry )
public static Contact parseFrom ( byte [] data )
Parameter
Name
Description
data
byte []
public static Contact parseFrom ( byte [] data , ExtensionRegistryLite extensionRegistry )
public static Contact parseFrom ( ByteString data )
public static Contact parseFrom ( ByteString data , ExtensionRegistryLite extensionRegistry )
public static Contact parseFrom ( CodedInputStream input )
public static Contact parseFrom ( CodedInputStream input , ExtensionRegistryLite extensionRegistry )
public static Contact parseFrom ( InputStream input )
public static Contact parseFrom ( InputStream input , ExtensionRegistryLite extensionRegistry )
public static Contact parseFrom ( ByteBuffer data )
public static Contact parseFrom ( ByteBuffer data , ExtensionRegistryLite extensionRegistry )
public static Parser<Contact> parser ()
Methods
public boolean equals ( Object obj )
Parameter
Name
Description
obj
Object
Overrides
public Contact getDefaultInstanceForType ()
Required. The email address to send notifications to. This does not need to
be a Google account.
string email = 2;
Returns
Type
Description
String
The email.
public ByteString getEmailBytes ()
Required. The email address to send notifications to. This does not need to
be a Google account.
string email = 2;
Returns
Type
Description
ByteString
The bytes for email.
public String getLanguageTag ()
The preferred language for notifications, as a ISO 639-1 language code. See
Supported
languages
for a list of supported languages.
string language_tag = 4;
Returns
Type
Description
String
The languageTag.
public ByteString getLanguageTagBytes ()
The preferred language for notifications, as a ISO 639-1 language code. See
Supported
languages
for a list of supported languages.
string language_tag = 4;
Returns
Type
Description
ByteString
The bytes for languageTag.
The identifier for the contact.
Format: {resource_type}/{resource_id}/contacts/{contact_id}
string name = 1;
Returns
Type
Description
String
The name.
public ByteString getNameBytes ()
The identifier for the contact.
Format: {resource_type}/{resource_id}/contacts/{contact_id}
string name = 1;
Returns
Type
Description
ByteString
The bytes for name.
public NotificationCategory getNotificationCategorySubscriptions ( int index )
The categories of notifications that the contact will receive
communications for.
repeated .google.cloud.essentialcontacts.v1.NotificationCategory notification_category_subscriptions = 3;
Parameter
Name
Description
index
int
The index of the element to return.
Returns
Type
Description
NotificationCategory
The notificationCategorySubscriptions at the given index.
public int getNotificationCategorySubscriptionsCount ()
The categories of notifications that the contact will receive
communications for.
repeated .google.cloud.essentialcontacts.v1.NotificationCategory notification_category_subscriptions = 3;
Returns
Type
Description
int
The count of notificationCategorySubscriptions.
public List<NotificationCategory> getNotificationCategorySubscriptionsList ()
The categories of notifications that the contact will receive
communications for.
repeated .google.cloud.essentialcontacts.v1.NotificationCategory notification_category_subscriptions = 3;
public int getNotificationCategorySubscriptionsValue ( int index )
The categories of notifications that the contact will receive
communications for.
repeated .google.cloud.essentialcontacts.v1.NotificationCategory notification_category_subscriptions = 3;
Parameter
Name
Description
index
int
The index of the value to return.
Returns
Type
Description
int
The enum numeric value on the wire of notificationCategorySubscriptions at the given
index.
public List<Integer> getNotificationCategorySubscriptionsValueList ()
The categories of notifications that the contact will receive
communications for.
repeated .google.cloud.essentialcontacts.v1.NotificationCategory notification_category_subscriptions = 3;
Returns
Type
Description
List <Integer >
A list containing the enum numeric values on the wire for
notificationCategorySubscriptions.
public Parser<Contact> getParserForType ()
Overrides
public int getSerializedSize ()
Returns
Type
Description
int
Overrides
public final UnknownFieldSet getUnknownFields ()
Overrides
public Timestamp getValidateTime ()
The last time the validation_state was updated, either manually or
automatically. A contact is considered stale if its validation state was
updated more than 1 year ago.
.google.protobuf.Timestamp validate_time = 9;
Returns
Type
Description
Timestamp
The validateTime.
public TimestampOrBuilder getValidateTimeOrBuilder ()
The last time the validation_state was updated, either manually or
automatically. A contact is considered stale if its validation state was
updated more than 1 year ago.
.google.protobuf.Timestamp validate_time = 9;
public ValidationState getValidationState ()
The validity of the contact. A contact is considered valid if it is the
correct recipient for notifications for a particular resource.
.google.cloud.essentialcontacts.v1.ValidationState validation_state = 8;
public int getValidationStateValue ()
The validity of the contact. A contact is considered valid if it is the
correct recipient for notifications for a particular resource.
.google.cloud.essentialcontacts.v1.ValidationState validation_state = 8;
Returns
Type
Description
int
The enum numeric value on the wire for validationState.
public boolean hasValidateTime ()
The last time the validation_state was updated, either manually or
automatically. A contact is considered stale if its validation state was
updated more than 1 year ago.
.google.protobuf.Timestamp validate_time = 9;
Returns
Type
Description
boolean
Whether the validateTime field is set.
Returns
Type
Description
int
Overrides
protected GeneratedMessageV3 . FieldAccessorTable internalGetFieldAccessorTable ()
Overrides
public final boolean isInitialized ()
Overrides
public Contact . Builder newBuilderForType ()
protected Contact . Builder newBuilderForType ( GeneratedMessageV3 . BuilderParent parent )
Overrides
protected Object newInstance ( GeneratedMessageV3 . UnusedPrivateParameter unused )
Returns
Type
Description
Object
Overrides
public Contact . Builder toBuilder ()
public void writeTo ( CodedOutputStream output )
Overrides
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-05-15 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-15 UTC."],[],[]]