REDROOM
PHP 8.3.31
Path:
Logout
Edit File
Size: 1.68 KB
Close
/home/getspomw/royalsquad.us/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/HasFactory.php
Text
Base64
<?php namespace Illuminate\Database\Eloquent\Factories; use Illuminate\Database\Eloquent\Attributes\UseFactory; /** * @template TFactory of \Illuminate\Database\Eloquent\Factories\Factory */ trait HasFactory { /** * Get a new factory instance for the model. * * @param (callable(array<string, mixed>, static|null): array<string, mixed>)|array<string, mixed>|int|null $count * @param (callable(array<string, mixed>, static|null): array<string, mixed>)|array<string, mixed> $state * @return TFactory */ public static function factory($count = null, $state = []) { $factory = static::newFactory() ?? Factory::factoryForModel(static::class); return $factory ->count(is_numeric($count) ? $count : null) ->state(is_callable($count) || is_array($count) ? $count : $state); } /** * Create a new factory instance for the model. * * @return TFactory|null */ protected static function newFactory() { if (isset(static::$factory)) { return static::$factory::new(); } return static::getUseFactoryAttribute() ?? null; } /** * Get the factory from the UseFactory class attribute. * * @return TFactory|null */ protected static function getUseFactoryAttribute() { $attributes = (new \ReflectionClass(static::class)) ->getAttributes(UseFactory::class); if ($attributes !== []) { $useFactory = $attributes[0]->newInstance(); $factory = new $useFactory->factoryClass; $factory->guessModelNamesUsing(fn () => static::class); return $factory; } } }
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 7
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
BelongsToManyRelationship.php
2.03 KB
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
BelongsToRelationship.php
2.68 KB
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
CrossJoinSequence.php
541 B
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Factory.php
28.85 KB
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
HasFactory.php
1.68 KB
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Relationship.php
2.10 KB
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Sequence.php
1.11 KB
lrw-rw-rw-
2025-09-17 06:53:01
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).