Skip to content
Snippets Groups Projects
Commit 0fb31bfa authored by Martti Käärik's avatar Martti Käärik
Browse files

Keyword escape support for GRIdentifier rule.

parent 900da81f
Branches
Tags
No related merge requests found
......@@ -34,6 +34,16 @@ public class TDLValueConverterService extends EString2XtextConverter {
public IValueConverter<String> TDLtxQIdentifier() {
return this.QIdentifier();
}
@ValueConverter(rule = "org.etsi.mts.tdl.TDLtx.GRIdentifier")
public IValueConverter<String> GRIdentifier() {
return this.QIdentifier();
}
@ValueConverter(rule = "GRIdentifier")
public IValueConverter<String> TDLtxGRIdentifier() {
return this.GRIdentifier();
}
}
class IdentifierValueConverter extends AbstractValueConverter<String> {
......@@ -55,13 +65,12 @@ class IdentifierValueConverter extends AbstractValueConverter<String> {
}
class QIdentifierValueConverter extends IdentifierValueConverter {
public QIdentifierValueConverter(IValueConverter<String> iValueConverter) {
super(iValueConverter);
}
@Override
public String toValue(String string, INode node) throws ValueConverterException {
String[] parts = string.split("\\.");
......@@ -70,7 +79,7 @@ class QIdentifierValueConverter extends IdentifierValueConverter {
}
return String.join(".", parts);
}
@Override
public String toString(String value) throws ValueConverterException {
String[] parts = value.split("\\.");
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment