src/Model/Environment.php
public function addBackupPolicy(Policy $policy)
    {
        $backups = isset($this->data['backups']) ? $this->data['backups'] : [];
        $backups['schedule'][] = [
            'interval' => $policy->getInterval(),
            'count' => $policy->getCount(),
        ];
        if (!isset($backups['manual_count'])) {
            $backups['manual_count'] = 3;
        }

        return $this->update(['backups' => $backups]);
    }
public function addBackupPolicy(Policy $policy)
    {
        $backups = isset($this->data['backups']) ? $this->data['backups'] : [];
        $backups['schedule'][] = [
            'interval' => $policy->getInterval(),
            'count' => $policy->getCount(),
        ];
        if (!isset($backups['manual_count'])) {
            $backups['manual_count'] = 3;
        }

        return $this->update(['backups' => $backups]);
    }
public function addBackupPolicy ( Policy $ policy ) { $ backups = isset ( $ this -> data [ 'backups' ] ) ? $ this -> data [ 'backups' ] : [ ] ; $ backups [ 'schedule' ] [ ] = [ 'interval' => $ policy -> getInterval ( ) , 'count' => $ policy -> getCount ( ) , ] ; if ( ! isset ( $ backups [ 'manual_count' ] ) ) { $ backups [ 'manual_count' ] = 3 ; } return $ this -> update ( [ 'backups' => $ backups ] ) ; }
Add a scheduled backup policy.

@param \Platformsh\Client\Model\Backups\Policy $policy

@return \Platformsh\Client\Model\Result
Add a scheduled backup policy .