1234567891011121314151617181920 |
- <?php
- namespace App\Libraries\BIM;
- use App\Libraries\BIM\BlackHole\BlackHole;
- use App\Libraries\BIM\Contacts\BIMContact;
- use App\Libraries\BIM\Glendale\Glendale;
- class BIMFactory
- {
- public static function make(string $driver = null): BIMContact
- {
- $driver = $driver ? $driver : config("bim.default");
- return match ($driver) {
- BIMDriverEnum::BLACK_HOLE->value => new BlackHole(),
- BIMDriverEnum::GLENDALE->value => new Glendale(),
- };
- }
- }
|