# NetApp V1 API - Class Google::Cloud::NetApp::V1::BackupPolicy (v2.11.0)

2.11.0 (latest) 2.10.0 2.9.0 2.8.0 2.7.0 2.6.1 2.5.0 2.4.0 2.3.0 2.2.0 2.1.0 2.0.2 1.6.0 1.5.0 1.4.0 1.3.0 1.2.0 1.1.1 1.0.0 0.6.0 0.5.2 0.4.2 0.3.0 0.2.0 0.1.0 Reference documentation and code samples for the NetApp V1 API class Google::Cloud::NetApp::V1::BackupPolicy.

Backup Policy.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #assigned_volume_count

    def assigned_volume_count() -> ::Integer

**Returns**

- (::Integer) --- Output only. The total number of volumes assigned by this backup policy.

### #create_time

    def create_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-netapp-v1/latest/Google-Protobuf-Timestamp)) --- Output only. The time when the backup policy was created.

### #daily_backup_limit

    def daily_backup_limit() -> ::Integer

**Returns**

- (::Integer) --- Number of daily backups to keep. Note that the minimum daily backup limit is 2.

### #daily_backup_limit=

    def daily_backup_limit=(value) -> ::Integer

**Parameter**

- **value** (::Integer) --- Number of daily backups to keep. Note that the minimum daily backup limit is 2.
**Returns**

- (::Integer) --- Number of daily backups to keep. Note that the minimum daily backup limit is 2.

### #description

    def description() -> ::String

**Returns**

- (::String) --- Description of the backup policy.

### #description=

    def description=(value) -> ::String

**Parameter**

- **value** (::String) --- Description of the backup policy.
**Returns**

- (::String) --- Description of the backup policy.

### #enabled

    def enabled() -> ::Boolean

**Returns**

- (::Boolean) --- 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.

### #enabled=

    def enabled=(value) -> ::Boolean

**Parameter**

- **value** (::Boolean) --- 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.
**Returns**

- (::Boolean) --- 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.

### #labels

    def labels() -> ::Google::Protobuf::Map{::String => ::String}

**Returns**

- (::Google::Protobuf::Map{::String =\> ::String}) --- Resource labels to represent user provided metadata.

### #labels=

    def labels=(value) -> ::Google::Protobuf::Map{::String => ::String}

**Parameter**

- **value** (::Google::Protobuf::Map{::String =\> ::String}) --- Resource labels to represent user provided metadata.
**Returns**

- (::Google::Protobuf::Map{::String =\> ::String}) --- Resource labels to represent user provided metadata.

### #monthly_backup_limit

    def monthly_backup_limit() -> ::Integer

**Returns**

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

### #monthly_backup_limit=

    def monthly_backup_limit=(value) -> ::Integer

**Parameter**

- **value** (::Integer) --- Number of monthly backups to keep. Note that the sum of daily, weekly and monthly backups should be greater than 1.
**Returns**

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

### #name

    def name() -> ::String

**Returns**

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

### #name=

    def name=(value) -> ::String

**Parameter**

- **value** (::String) --- Identifier. The resource name of the backup policy. Format: `projects/{project_id}/locations/{location}/backupPolicies/{backup_policy_id}`.
**Returns**

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

### #state

    def state() -> ::Google::Cloud::NetApp::V1::BackupPolicy::State

**Returns**

- ([::Google::Cloud::NetApp::V1::BackupPolicy::State](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-netapp-v1/latest/Google-Cloud-NetApp-V1-BackupPolicy-State)) --- Output only. The backup policy state.

### #weekly_backup_limit

    def weekly_backup_limit() -> ::Integer

**Returns**

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

### #weekly_backup_limit=

    def weekly_backup_limit=(value) -> ::Integer

**Parameter**

- **value** (::Integer) --- Number of weekly backups to keep. Note that the sum of daily, weekly and monthly backups should be greater than 1.
**Returns**

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