package org.simantics.modeling.scl.issue;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Objects;
@Override
public SCLIssueProvider getSCLIssueProvider() {
- return new SCLExpressionIssueProvider();
+ if (Boolean.getBoolean("org.simantics.scl.issues"))
+ return new SCLExpressionIssueProvider();
+ else
+ return new DummyIssueProvider();
}
}
+ public static class DummyIssueProvider implements SCLIssueProvider {
+ @Override
+ public void listenIssues(Runnable callback) {
+
+ }
+
+ @Override
+ public List<SCLIssuesTableEntry> getIssues() {
+ return Collections.emptyList();
+ }
+
+ @Override
+ public void dispose() {
+
+ }
+ }
+
private static final Logger LOGGER = LoggerFactory.getLogger(SCLExpressionIssueProvider.class);
private boolean disposed = false;
private ComponentSyncListenerAdapter listener;