frontend spec by workspace instead

This commit is contained in:
2026-03-24 13:42:15 +00:00
parent f627914c9f
commit 9170104a12
17 changed files with 93 additions and 89 deletions
@@ -8,7 +8,7 @@ import java.util.Optional;
public class FrontendRegistryService {
private static final FrontendSpec[] FRONTEND_SPECS = {
PBSDefinitions.PBS,
PBSDefinitions.PBS,
};
private static final Map<String, FrontendSpec> FRONTENDS = new HashMap<>();
@@ -17,7 +17,8 @@ public class FrontendRegistryService {
for (final var frontendSpec : FRONTEND_SPECS) {
FRONTENDS.put(frontendSpec.getLanguageId(), frontendSpec);
}
if (FRONTENDS.size() != FRONTEND_SPECS.length) throw new IllegalStateException("Duplicate frontend specs found");
if (FRONTENDS.size() != FRONTEND_SPECS.length)
throw new IllegalStateException("Duplicate frontend specs found");
}
public static FrontendSpec getDefaultFrontendSpec() {
@@ -27,4 +28,4 @@ public class FrontendRegistryService {
public static Optional<FrontendSpec> getFrontendSpec(final String languageId) {
return Optional.ofNullable(FRONTENDS.get(languageId));
}
}
}