Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Christian Willms
hfc
Commits
97b5f8c0
Commit
97b5f8c0
authored
Jun 13, 2018
by
Bernd Kiefer
Browse files
Fix long xsd name error
parent
b07d7615
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/de/dfki/lt/hfc/types/XsdString.java
View file @
97b5f8c0
...
...
@@ -36,7 +36,12 @@ public final class XsdString extends XsdAnySimpleType {
// to the "internal" form, removing backslashes that escape other
// backslashes or double quotes
String
ext
=
null
;
if
(!
val
.
endsWith
(
"^^<xsd:string>"
))
{
this
.
languageTag
=
null
;
if
(
val
.
endsWith
(
"^^"
+
SHORT_NAME
))
{
ext
=
val
.
substring
(
1
,
val
.
length
()
-
SHORT_NAME
.
length
()
-
3
);
}
else
if
(
val
.
endsWith
(
"^^"
+
LONG_NAME
))
{
ext
=
val
.
substring
(
1
,
val
.
length
()
-
LONG_NAME
.
length
()
-
3
);
}
else
{
// no suffix "^^<xsd:string>"
int
index
=
val
.
lastIndexOf
(
'@'
);
final
int
length
=
val
.
length
();
...
...
@@ -48,7 +53,6 @@ public final class XsdString extends XsdAnySimpleType {
}
else
{
this
.
value
=
val
;
}
this
.
languageTag
=
null
;
}
else
{
// there is a language tag
...
...
@@ -56,10 +60,7 @@ public final class XsdString extends XsdAnySimpleType {
this
.
languageTag
=
val
.
substring
(
index
+
1
,
length
);;
}
}
else
{
ext
=
val
.
substring
(
1
,
val
.
length
()
-
15
);
this
.
languageTag
=
null
;
}
if
(
ext
!=
null
)
{
this
.
value
=
Utils
.
externalToString
(
ext
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment