src/Model/Backups/BackupConfig.php
public static function fromData(array $data)
    {
        $policies = [];
        foreach (isset($data['schedule']) ? $data['schedule'] : [] as $policyData) {
            $policies[] = new Policy($policyData['interval'], $policyData['count']);
        }

        return new static($policies, isset($data['manual_count']) ? $data['manual_count'] : 1);
    }
public static function fromData(array $data)
    {
        $policies = [];
        foreach (isset($data['schedule']) ? $data['schedule'] : [] as $policyData) {
            $policies[] = new Policy($policyData['interval'], $policyData['count']);
        }

        return new static($policies, isset($data['manual_count']) ? $data['manual_count'] : 1);
    }
public static function fromData ( array $ data ) { $ policies = [ ] ; foreach ( isset ( $ data [ 'schedule' ] ) ? $ data [ 'schedule' ] : [ ] as $ policyData ) { $ policies [ ] = new Policy ( $ policyData [ 'interval' ] , $ policyData [ 'count' ] ) ; } return new static ( $ policies , isset ( $ data [ 'manual_count' ] ) ? $ data [ 'manual_count' ] : 1 ) ; }
Instantiates a backup configuration object from config data.

@param array $data

@return static
Instantiates a backup configuration object from config data .