trait Batchable

Properties

string|null $batchId

The batch ID (if applicable).

Methods

Batch|null
batch()

Get the batch instance for the job, if applicable.

bool
batching()

Determine if the batch is still active and processing.

withBatchId(string $batchId)

Set the batch ID on the job.

array
withFakeBatch(string $id = '', string $name = '', int $totalJobs = 0, int $pendingJobs = 0, int $failedJobs = 0, array $failedJobIds = [], array $options = [], CarbonImmutable|null $createdAt = null, CarbonImmutable|null $cancelledAt = null, CarbonImmutable|null $finishedAt = null)

Indicate that the job should use a fake batch.

Details

at line 27
Batch|null batch()

Get the batch instance for the job, if applicable.

Return Value

Batch|null

at line 43
bool batching()

Determine if the batch is still active and processing.

Return Value

bool

at line 53
Batchable withBatchId(string $batchId)

Set the batch ID on the job.

Parameters

string $batchId

Return Value

Batchable

at line 65
array withFakeBatch(string $id = '', string $name = '', int $totalJobs = 0, int $pendingJobs = 0, int $failedJobs = 0, array $failedJobIds = [], array $options = [], CarbonImmutable|null $createdAt = null, CarbonImmutable|null $cancelledAt = null, CarbonImmutable|null $finishedAt = null)

Indicate that the job should use a fake batch.

Parameters

string $id
string $name
int $totalJobs
int $pendingJobs
int $failedJobs
array $failedJobIds
array $options
CarbonImmutable|null $createdAt
CarbonImmutable|null $cancelledAt
CarbonImmutable|null $finishedAt

Return Value

array