diff --git a/app/Services/StringMatcher.php b/app/Services/ContentMatcher.php similarity index 96% rename from app/Services/StringMatcher.php rename to app/Services/ContentMatcher.php index 0db51d4..0968eee 100644 --- a/app/Services/StringMatcher.php +++ b/app/Services/ContentMatcher.php @@ -4,7 +4,7 @@ use App\Domain\Rule\MatchMode; -final class StringMatcher +final class ContentMatcher { public static function match(string $input, string $pattern, MatchMode $mode): bool { diff --git a/app/Services/Pacs/DicomStudyMapper.php b/app/Services/Pacs/DicomStudyMapper.php index b4b967b..14958cd 100644 --- a/app/Services/Pacs/DicomStudyMapper.php +++ b/app/Services/Pacs/DicomStudyMapper.php @@ -3,7 +3,7 @@ namespace App\Services\Pacs; use App\Domain\Rule\MatchMode; -use App\Services\StringMatcher; +use App\Services\ContentMatcher; use Illuminate\Support\Facades\Cache; use Illuminate\Support\Facades\DB; @@ -36,7 +36,7 @@ public static function map(?string $input): array $input = strtolower($input); foreach (self::$rules as $pattern) { - if (StringMatcher::match($input, $pattern->name, MatchMode::from($pattern->match_mode))) { + if (ContentMatcher::match($input, $pattern->name, MatchMode::from($pattern->match_mode))) { return [$pattern->institute_id, $pattern->facility_id]; } }