Class BackupPolicy (0.15.0)

public final class BackupPolicy extends GeneratedMessageV3 implements BackupPolicyOrBuilder

Backup Policy.

Protobuf type google.cloud.netapp.v1.BackupPolicy

Static Fields

ASSIGNED_VOLUME_COUNT_FIELD_NUMBER

public static final int ASSIGNED_VOLUME_COUNT_FIELD_NUMBER
Field Value
TypeDescription
int

CREATE_TIME_FIELD_NUMBER

public static final int CREATE_TIME_FIELD_NUMBER
Field Value
TypeDescription
int

DAILY_BACKUP_LIMIT_FIELD_NUMBER

public static final int DAILY_BACKUP_LIMIT_FIELD_NUMBER
Field Value
TypeDescription
int

DESCRIPTION_FIELD_NUMBER

public static final int DESCRIPTION_FIELD_NUMBER
Field Value
TypeDescription
int

ENABLED_FIELD_NUMBER

public static final int ENABLED_FIELD_NUMBER
Field Value
TypeDescription
int

LABELS_FIELD_NUMBER

public static final int LABELS_FIELD_NUMBER
Field Value
TypeDescription
int

MONTHLY_BACKUP_LIMIT_FIELD_NUMBER

public static final int MONTHLY_BACKUP_LIMIT_FIELD_NUMBER
Field Value
TypeDescription
int

NAME_FIELD_NUMBER

public static final int NAME_FIELD_NUMBER
Field Value
TypeDescription
int

STATE_FIELD_NUMBER

public static final int STATE_FIELD_NUMBER
Field Value
TypeDescription
int

WEEKLY_BACKUP_LIMIT_FIELD_NUMBER

public static final int WEEKLY_BACKUP_LIMIT_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static BackupPolicy getDefaultInstance()
Returns
TypeDescription
BackupPolicy

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static BackupPolicy.Builder newBuilder()
Returns
TypeDescription
BackupPolicy.Builder

newBuilder(BackupPolicy prototype)

public static BackupPolicy.Builder newBuilder(BackupPolicy prototype)
Parameter
NameDescription
prototypeBackupPolicy
Returns
TypeDescription
BackupPolicy.Builder

parseDelimitedFrom(InputStream input)

public static BackupPolicy parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static BackupPolicy parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static BackupPolicy parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static BackupPolicy parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static BackupPolicy parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static BackupPolicy parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static BackupPolicy parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static BackupPolicy parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static BackupPolicy parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static BackupPolicy parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static BackupPolicy parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static BackupPolicy parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
BackupPolicy
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<BackupPolicy> parser()
Returns
TypeDescription
Parser<BackupPolicy>

Methods

containsLabels(String key)

public boolean containsLabels(String key)

Resource labels to represent user provided metadata.

map<string, string> labels = 9;

Parameter
NameDescription
keyString
Returns
TypeDescription
boolean

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getAssignedVolumeCount()

public int getAssignedVolumeCount()

Output only. The total number of volumes assigned by this backup policy.

optional int32 assigned_volume_count = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

The assignedVolumeCount.

getCreateTime()

public Timestamp getCreateTime()

Output only. The time when the backup policy was created.

.google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
Timestamp

The createTime.

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The time when the backup policy was created.

.google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
TimestampOrBuilder

getDailyBackupLimit()

public int getDailyBackupLimit()

Number of daily backups to keep. Note that the minimum daily backup limit is 2.

optional int32 daily_backup_limit = 2;

Returns
TypeDescription
int

The dailyBackupLimit.

getDefaultInstanceForType()

public BackupPolicy getDefaultInstanceForType()
Returns
TypeDescription
BackupPolicy

getDescription()

public String getDescription()

Description of the backup policy.

optional string description = 5;

Returns
TypeDescription
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

Description of the backup policy.

optional string description = 5;

Returns
TypeDescription
ByteString

The bytes for description.

getEnabled()

public boolean getEnabled()

If enabled, make backups automatically according to the schedules. This will be applied to all volumes that have this policy attached and enforced on volume level. If not specified, default is true.

optional bool enabled = 6;

Returns
TypeDescription
boolean

The enabled.

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
TypeDescription
Map<String,String>

getLabelsCount()

public int getLabelsCount()

Resource labels to represent user provided metadata.

map<string, string> labels = 9;

Returns
TypeDescription
int

getLabelsMap()

public Map<String,String> getLabelsMap()

Resource labels to represent user provided metadata.

map<string, string> labels = 9;

Returns
TypeDescription
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

Resource labels to represent user provided metadata.

map<string, string> labels = 9;

Parameters
NameDescription
keyString
defaultValueString
Returns
TypeDescription
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

Resource labels to represent user provided metadata.

map<string, string> labels = 9;

Parameter
NameDescription
keyString
Returns
TypeDescription
String

getMonthlyBackupLimit()

public int getMonthlyBackupLimit()

Number of monthly backups to keep. Note that the sum of daily, weekly and monthly backups should be greater than 1.

optional int32 monthly_backup_limit = 4;

Returns
TypeDescription
int

The monthlyBackupLimit.

getName()

public String getName()

Identifier. The resource name of the backup policy. Format: projects/{project_id}/locations/{location}/backupPolicies/{backup_policy_id}.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Identifier. The resource name of the backup policy. Format: projects/{project_id}/locations/{location}/backupPolicies/{backup_policy_id}.

string name = 1 [(.google.api.field_behavior) = IDENTIFIER];

Returns
TypeDescription
ByteString

The bytes for name.

getParserForType()

public Parser<BackupPolicy> getParserForType()
Returns
TypeDescription
Parser<BackupPolicy>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getState()

public BackupPolicy.State getState()

Output only. The backup policy state.

.google.cloud.netapp.v1.BackupPolicy.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
BackupPolicy.State

The state.

getStateValue()

public int getStateValue()

Output only. The backup policy state.

.google.cloud.netapp.v1.BackupPolicy.State state = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
int

The enum numeric value on the wire for state.

getWeeklyBackupLimit()

public int getWeeklyBackupLimit()

Number of weekly backups to keep. Note that the sum of daily, weekly and monthly backups should be greater than 1.

optional int32 weekly_backup_limit = 3;

Returns
TypeDescription
int

The weeklyBackupLimit.

hasAssignedVolumeCount()

public boolean hasAssignedVolumeCount()

Output only. The total number of volumes assigned by this backup policy.

optional int32 assigned_volume_count = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the assignedVolumeCount field is set.

hasCreateTime()

public boolean hasCreateTime()

Output only. The time when the backup policy was created.

.google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
boolean

Whether the createTime field is set.

hasDailyBackupLimit()

public boolean hasDailyBackupLimit()

Number of daily backups to keep. Note that the minimum daily backup limit is 2.

optional int32 daily_backup_limit = 2;

Returns
TypeDescription
boolean

Whether the dailyBackupLimit field is set.

hasDescription()

public boolean hasDescription()

Description of the backup policy.

optional string description = 5;

Returns
TypeDescription
boolean

Whether the description field is set.

hasEnabled()

public boolean hasEnabled()

If enabled, make backups automatically according to the schedules. This will be applied to all volumes that have this policy attached and enforced on volume level. If not specified, default is true.

optional bool enabled = 6;

Returns
TypeDescription
boolean

Whether the enabled field is set.

hasMonthlyBackupLimit()

public boolean hasMonthlyBackupLimit()

Number of monthly backups to keep. Note that the sum of daily, weekly and monthly backups should be greater than 1.

optional int32 monthly_backup_limit = 4;

Returns
TypeDescription
boolean

Whether the monthlyBackupLimit field is set.

hasWeeklyBackupLimit()

public boolean hasWeeklyBackupLimit()

Number of weekly backups to keep. Note that the sum of daily, weekly and monthly backups should be greater than 1.

optional int32 weekly_backup_limit = 3;

Returns
TypeDescription
boolean

Whether the weeklyBackupLimit field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
NameDescription
numberint
Returns
TypeDescription
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public BackupPolicy.Builder newBuilderForType()
Returns
TypeDescription
BackupPolicy.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected BackupPolicy.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
BackupPolicy.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public BackupPolicy.Builder toBuilder()
Returns
TypeDescription
BackupPolicy.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException