diff options
Diffstat (limited to 'org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language/src/main/java/org/eclipse/viatra/solver/language/naming/ProblemQualifiedNameProvider.java')
-rw-r--r-- | org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language/src/main/java/org/eclipse/viatra/solver/language/naming/ProblemQualifiedNameProvider.java | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language/src/main/java/org/eclipse/viatra/solver/language/naming/ProblemQualifiedNameProvider.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language/src/main/java/org/eclipse/viatra/solver/language/naming/ProblemQualifiedNameProvider.java new file mode 100644 index 00000000..81365724 --- /dev/null +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language/src/main/java/org/eclipse/viatra/solver/language/naming/ProblemQualifiedNameProvider.java | |||
@@ -0,0 +1,15 @@ | |||
1 | package org.eclipse.viatra.solver.language.naming; | ||
2 | |||
3 | import org.eclipse.viatra.solver.language.model.problem.Node; | ||
4 | import org.eclipse.xtext.naming.DefaultDeclarativeQualifiedNameProvider; | ||
5 | import org.eclipse.xtext.naming.QualifiedName; | ||
6 | |||
7 | public class ProblemQualifiedNameProvider extends DefaultDeclarativeQualifiedNameProvider { | ||
8 | public QualifiedName qualifiedName(Node node) { | ||
9 | String name = node.getName(); | ||
10 | if (name == null || name.isEmpty()) { | ||
11 | return null; | ||
12 | } | ||
13 | return getConverter().toQualifiedName(name); | ||
14 | } | ||
15 | } | ||