Automattic\WooCommerce\Internal\BatchProcessing

BatchProcessingController::get_process_details()privateWC 1.0

Get the current state for a given enqueued processor.

Метод класса: BatchProcessingController{}

Хуков нет.

Возвращает

Массив. Current state for the processor, or a "blank" state if none exists yet.

Использование

// private - только в коде основоного (родительского) класса
$result = $this->get_process_details( $batch_processor ): array;
$batch_processor(BatchProcessorInterface) (обязательный)
Batch processor instance.

Код BatchProcessingController::get_process_details() WC 8.7.0

private function get_process_details( BatchProcessorInterface $batch_processor ): array {
	return get_option(
		$this->get_processor_state_option_name( $batch_processor ),
		array(
			'total_time_spent'   => 0,
			'current_batch_size' => $batch_processor->get_default_batch_size(),
			'last_error'         => null,
		)
	);
}