public static function make($settings, $metricsToKeep)
    {
        return new ReportsPurger(
            $settings['delete_reports_older_than'],
            $settings['delete_reports_keep_basic_metrics'] == 1,
            self::getReportPeriodsToKeep($settings),
            $settings['delete_reports_keep_segment_reports'] == 1,
            $metricsToKeep,
            $settings['delete_logs_max_rows_per_query']
        );
    }
public static function make($settings, $metricsToKeep)
    {
        return new ReportsPurger(
            $settings['delete_reports_older_than'],
            $settings['delete_reports_keep_basic_metrics'] == 1,
            self::getReportPeriodsToKeep($settings),
            $settings['delete_reports_keep_segment_reports'] == 1,
            $metricsToKeep,
            $settings['delete_logs_max_rows_per_query']
        );
    }
public static function make ( $ settings , $ metricsToKeep ) { return new ReportsPurger ( $ settings [ 'delete_reports_older_than' ] , $ settings [ 'delete_reports_keep_basic_metrics' ] == 1 , self :: getReportPeriodsToKeep ( $ settings ) , $ settings [ 'delete_reports_keep_segment_reports' ] == 1 , $ metricsToKeep , $ settings [ 'delete_logs_max_rows_per_query' ] ) ; }
Utility function. Creates a new instance of ReportsPurger with the supplied array
of settings.

$settings must contain the following keys:
-'delete_reports_older_than': The number of months after which reports/metrics are
considered old.
-'delete_reports_keep_basic_metrics': 1 if basic metrics should be kept, 0 if otherwise.
-'delete_reports_keep_day_reports': 1 if daily reports should be kept, 0 if otherwise.
-'delete_reports_keep_week_reports': 1 if weekly reports should be kept, 0 if otherwise.
-'delete_reports_keep_month_reports': 1 if monthly reports should be kept, 0 if otherwise.
-'delete_reports_keep_year_reports': 1 if yearly reports should be kept, 0 if otherwise.
-'delete_reports_keep_range_reports': 1 if range reports should be kept, 0 if otherwise.
-'delete_reports_keep_segment_reports': 1 if reports for segments should be kept, 0 if otherwise.
-'delete_logs_max_rows_per_query': Maximum number of rows to delete in one DELETE query.
Utility function . Creates a new instance of ReportsPurger with the supplied array of settings .