Task
in package
implements
JsonSerializable
FinalYes
This is a task processing task
Tags
Table of Contents
Interfaces
- JsonSerializable
Constants
- STATUS_CANCELLED = 5
- STATUS_FAILED = 4
- STATUS_RUNNING = 2
- STATUS_SCHEDULED = 1
- STATUS_SUCCESSFUL = 3
- STATUS_UNKNOWN = 0
Properties
- $appId : string
- $completionExpectedAt : DateTime|null
- $customId : string|null
- $endedAt : int|null
- $errorMessage : string|null
- $id : int|null
- $input : array<string|int, mixed>
- $lastUpdated : int
- $output : array<string|int, mixed>|null
- $progress : float|null
- $scheduledAt : int|null
- $startedAt : int|null
- $status : int
- $taskTypeId : string
- $userId : string|null
- $webhookMethod : string|null
- $webhookUri : string|null
Methods
- __construct() : mixed
- getAppId() : string
- getCompletionExpectedAt() : DateTime|null
- getCustomId() : null|string
- getEndedAt() : int|null
- getErrorMessage() : string|null
- getId() : int|null
- getInput() : array<string|int, array<int, (numeric)|string>|(numeric)|string>
- getLastUpdated() : int
- getOutput() : array<string|int, array<int, (numeric)|string>|(numeric)|string>|null
- getProgress() : float|null
- getScheduledAt() : int|null
- getStartedAt() : int|null
- getStatus() : int
- getTaskTypeId() : string
- getUserId() : string|null
- getWebhookMethod() : null|string
- getWebhookUri() : null|string
- jsonSerialize() : array<string|int, mixed>
- setCompletionExpectedAt() : void
- setEndedAt() : void
- setErrorMessage() : void
- setId() : void
- setInput() : void
- setLastUpdated() : void
- setOutput() : void
- setProgress() : void
- setScheduledAt() : void
- setStartedAt() : void
- setStatus() : void
- setWebhookMethod() : void
- setWebhookUri() : void
- statusToString() : "STATUS_CANCELLED"|"STATUS_FAILED"|"STATUS_SUCCESSFUL"|"STATUS_RUNNING"|"STATUS_SCHEDULED"|"STATUS_UNKNOWN"
Constants
STATUS_CANCELLED
public
mixed
STATUS_CANCELLED
= 5
Tags
STATUS_FAILED
public
mixed
STATUS_FAILED
= 4
Tags
STATUS_RUNNING
public
mixed
STATUS_RUNNING
= 2
Tags
STATUS_SCHEDULED
public
mixed
STATUS_SCHEDULED
= 1
Tags
STATUS_SUCCESSFUL
public
mixed
STATUS_SUCCESSFUL
= 3
Tags
STATUS_UNKNOWN
public
mixed
STATUS_UNKNOWN
= 0
Tags
Properties
$appId read-only
protected
string
$appId
$completionExpectedAt
protected
DateTime|null
$completionExpectedAt
= null
$customId read-only
protected
string|null
$customId
= ''
$endedAt
protected
int|null
$endedAt
= null
$errorMessage
protected
string|null
$errorMessage
= null
$id
protected
int|null
$id
= null
$input
protected
array<string|int, mixed>
$input
$lastUpdated
protected
int
$lastUpdated
$output
protected
array<string|int, mixed>|null
$output
= null
$progress
protected
float|null
$progress
= null
$scheduledAt
protected
int|null
$scheduledAt
= null
$startedAt
protected
int|null
$startedAt
= null
$status
protected
int
$status
= self::STATUS_UNKNOWN
Tags
$taskTypeId read-only
protected
string
$taskTypeId
$userId read-only
protected
string|null
$userId
$webhookMethod
protected
string|null
$webhookMethod
= null
$webhookUri
protected
string|null
$webhookUri
= null
Methods
__construct()
public
final __construct(string $taskTypeId, array<string, array<int, (numeric)|string>|(numeric)|string> $input, string $appId, string|null $userId[, null|string $customId = '' ]) : mixed
Parameters
- $taskTypeId : string
- $input : array<string, array<int, (numeric)|string>|(numeric)|string>
- $appId : string
- $userId : string|null
- $customId : null|string = ''
-
An arbitrary customId for this task. max length: 255 chars
Tags
getAppId()
public
final getAppId() : string
Tags
Return values
stringgetCompletionExpectedAt()
public
final getCompletionExpectedAt() : DateTime|null
Tags
Return values
DateTime|nullgetCustomId()
public
final getCustomId() : null|string
Tags
Return values
null|stringgetEndedAt()
public
final getEndedAt() : int|null
Tags
Return values
int|nullgetErrorMessage()
public
final getErrorMessage() : string|null
Tags
Return values
string|nullgetId()
public
final getId() : int|null
Tags
Return values
int|nullgetInput()
public
final getInput() : array<string|int, array<int, (numeric)|string>|(numeric)|string>
Tags
Return values
array<string|int, array<int, (numeric)|string>|(numeric)|string>getLastUpdated()
public
final getLastUpdated() : int
Tags
Return values
intgetOutput()
public
final getOutput() : array<string|int, array<int, (numeric)|string>|(numeric)|string>|null
Tags
Return values
array<string|int, array<int, (numeric)|string>|(numeric)|string>|nullgetProgress()
public
final getProgress() : float|null
Tags
Return values
float|nullgetScheduledAt()
public
final getScheduledAt() : int|null
Tags
Return values
int|nullgetStartedAt()
public
final getStartedAt() : int|null
Tags
Return values
int|nullgetStatus()
public
final getStatus() : int
Tags
Return values
intgetTaskTypeId()
public
final getTaskTypeId() : string
Tags
Return values
stringgetUserId()
public
final getUserId() : string|null
Tags
Return values
string|nullgetWebhookMethod()
public
final getWebhookMethod() : null|string
Tags
Return values
null|stringgetWebhookUri()
public
final getWebhookUri() : null|string
Tags
Return values
null|stringjsonSerialize()
public
final jsonSerialize() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>setCompletionExpectedAt()
public
final setCompletionExpectedAt(DateTime|null $at) : void
Parameters
- $at : DateTime|null
Tags
setEndedAt()
public
final setEndedAt(int|null $endedAt) : void
Parameters
- $endedAt : int|null
Tags
setErrorMessage()
public
final setErrorMessage(string|null $error) : void
Parameters
- $error : string|null
Tags
setId()
public
final setId(int|null $id) : void
Parameters
- $id : int|null
Tags
setInput()
public
final setInput(array<string|int, mixed> $input) : void
Parameters
- $input : array<string|int, mixed>
Tags
setLastUpdated()
public
final setLastUpdated(int $lastUpdated) : void
Parameters
- $lastUpdated : int
Tags
setOutput()
public
final setOutput(null|array<string|int, array<int, (numeric)|string>|(numeric)|string> $output) : void
Parameters
- $output : null|array<string|int, array<int, (numeric)|string>|(numeric)|string>
Tags
setProgress()
public
final setProgress(float|null $progress) : void
Parameters
- $progress : float|null
Tags
setScheduledAt()
public
final setScheduledAt(int|null $scheduledAt) : void
Parameters
- $scheduledAt : int|null
Tags
setStartedAt()
public
final setStartedAt(int|null $startedAt) : void
Parameters
- $startedAt : int|null
Tags
setStatus()
public
final setStatus(int $status) : void
Parameters
- $status : int
Tags
setWebhookMethod()
public
final setWebhookMethod(string|null $webhookMethod) : void
Parameters
- $webhookMethod : string|null
Tags
setWebhookUri()
public
final setWebhookUri(string|null $webhookUri) : void
Parameters
- $webhookUri : string|null
Tags
statusToString()
public
final static statusToString(int $status) : "STATUS_CANCELLED"|"STATUS_FAILED"|"STATUS_SUCCESSFUL"|"STATUS_RUNNING"|"STATUS_SCHEDULED"|"STATUS_UNKNOWN"
Parameters
- $status : int