<?php mt_rand(): int
<?php public function virtualBooleanCached(): Attribute { return Attribute::get(function () { return (bool) mt_rand(0, 1); })->shouldCache(); }
<?php public function virtualBoolean(): Attribute { return Attribute::get(function () { return (bool) mt_rand(0, 1); }); }
<?php { return new Attribute( function () { return Date::now()->addSeconds(mt_rand(0, 10000)); } ); }
<?php { return (new Attribute( function () { return Date::now()->addSeconds(mt_rand(0, 10000)); } ))->withoutObjectCaching(); }
<?php public function virtualDateTimeWithoutCaching(): Attribute { return Attribute::get(function () { return Date::now()->addSeconds(mt_rand(0, 10000)); })->withoutObjectCaching(); } }