İlk temizlik tamamlandı bir önceki projeden
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace App\Services\TpCreator\DocumentProcessors;
|
||||
|
||||
use Exception;
|
||||
|
||||
class TpDocumentProcessorFactory
|
||||
{
|
||||
public static function make(string $type, string $path): AbstractTpDocumentProcessor
|
||||
{
|
||||
// Path based detection logic first (as in blade/service)
|
||||
if (strpos($path, "NDT_Clearance") !== false) {
|
||||
return new NdtClearanceTpProcessor();
|
||||
}
|
||||
|
||||
switch ($type) {
|
||||
case 'qa':
|
||||
return new QaTpProcessor();
|
||||
case 'wdb':
|
||||
return new WdbTpProcessor();
|
||||
case 'drawings':
|
||||
return new DrawingsTpProcessor();
|
||||
case 'document-procedure':
|
||||
return new DocumentProcedureTpProcessor();
|
||||
default:
|
||||
return new GenericTpProcessor();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user