Supported Versions: PHP 5 >= 5.1.0, PHP 7, PHP 8
Checks if the object or class has a property
<?php property_exists(object|string $object_or_class, string $property): bool
<?php public function __construct($event)
{
$this->event = $event;
$this->tries = property_exists($event, 'tries') ? $event->tries : null;
$this->timeout = property_exists($event, 'timeout') ? $event->timeout : null;
$this->backoff = property_exists($event, 'backoff') ? $event->backoff : null;
$this->afterCommit = property_exists($event, 'afterCommit') ? $event->afterCommit : null;
<?php {
$this->event = $event;
$this->tries = property_exists($event, 'tries') ? $event->tries : null;
$this->timeout = property_exists($event, 'timeout') ? $event->timeout : null;
$this->backoff = property_exists($event, 'backoff') ? $event->backoff : null;
$this->afterCommit = property_exists($event, 'afterCommit') ? $event->afterCommit : null;
$this->maxExceptions = property_exists($event, 'maxExceptions') ? $event->maxExceptions : null;
<?php $this->event = $event;
$this->tries = property_exists($event, 'tries') ? $event->tries : null;
$this->timeout = property_exists($event, 'timeout') ? $event->timeout : null;
$this->backoff = property_exists($event, 'backoff') ? $event->backoff : null;
$this->afterCommit = property_exists($event, 'afterCommit') ? $event->afterCommit : null;
$this->maxExceptions = property_exists($event, 'maxExceptions') ? $event->maxExceptions : null;
}
<?php $this->tries = property_exists($event, 'tries') ? $event->tries : null;
$this->timeout = property_exists($event, 'timeout') ? $event->timeout : null;
$this->backoff = property_exists($event, 'backoff') ? $event->backoff : null;
$this->afterCommit = property_exists($event, 'afterCommit') ? $event->afterCommit : null;
$this->maxExceptions = property_exists($event, 'maxExceptions') ? $event->maxExceptions : null;
}
<?php $this->timeout = property_exists($event, 'timeout') ? $event->timeout : null;
$this->backoff = property_exists($event, 'backoff') ? $event->backoff : null;
$this->afterCommit = property_exists($event, 'afterCommit') ? $event->afterCommit : null;
$this->maxExceptions = property_exists($event, 'maxExceptions') ? $event->maxExceptions : null;
}
<?php if (method_exists($event, 'uniqueId')) {
$this->uniqueId .= $event->uniqueId();
} elseif (property_exists($event, 'uniqueId')) {
$this->uniqueId .= $event->uniqueId;
}
<?php if (method_exists($event, 'uniqueFor')) {
$this->uniqueFor = $event->uniqueFor();
} elseif (property_exists($event, 'uniqueFor')) {
$this->uniqueFor = $event->uniqueFor;
}
<?php {
$instance = new $model;
$chunkSize = property_exists($instance, 'prunableChunkSize')
? $instance->prunableChunkSize
: $this->option('chunk');
<?php public function newBroadcastableModelEvent($event)
{
return tap($this->newBroadcastableEvent($event), function ($event) {
$event->connection = property_exists($this, 'broadcastConnection')
? $this->broadcastConnection
: $this->broadcastConnection();
<?php ? $this->broadcastConnection
: $this->broadcastConnection();
$event->queue = property_exists($this, 'broadcastQueue')
? $this->broadcastQueue
: $this->broadcastQueue();
<?php ? $this->broadcastQueue
: $this->broadcastQueue();
$event->afterCommit = property_exists($this, 'broadcastAfterCommit')
? $this->broadcastAfterCommit
: $this->broadcastAfterCommit();
});
<?php if ($listener instanceof ShouldQueueAfterCommit) {
$job->afterCommit = true;
} else {
$job->afterCommit = property_exists($listener, 'afterCommit') ? $listener->afterCommit : null;
}
$job->backoff = method_exists($listener, 'backoff') ? $listener->backoff(...$data) : ($listener->backoff ?? null);
<?php if (property_exists($provider, 'bindings')) {
foreach ($provider->bindings as $key => $value) {
$this->bind($key, $value);
}
<?php }
}
if (property_exists($provider, 'singletons')) {
foreach ($provider->singletons as $key => $value) {
$key = is_int($key) ? $value : $key;
<?php $this->setUpHasRun = false;
if (property_exists($this, 'serverVariables')) {
$this->serverVariables = [];
}