mirror of
https://gitlab.com/oeffi/public-transport-enabler.git
synced 2025-07-14 00:30:31 +00:00
parse ambiguous type in brackets
git-svn-id: https://public-transport-enabler.googlecode.com/svn/trunk@566 0924bc21-9374-b0fa-ee44-9ff1593b38f0
This commit is contained in:
parent
eeee8303a2
commit
ab24e4284b
2 changed files with 26 additions and 10 deletions
|
@ -220,7 +220,7 @@ public final class ParserUtils
|
|||
}
|
||||
}
|
||||
|
||||
private static final Pattern P_ENTITY = Pattern.compile("&(?:#(x[\\da-f]+|\\d+)|(amp|quot|apos));");
|
||||
private static final Pattern P_ENTITY = Pattern.compile("&(?:#(x[\\da-f]+|\\d+)|(amp|quot|apos|szlig));");
|
||||
|
||||
public static String resolveEntities(final CharSequence str)
|
||||
{
|
||||
|
@ -250,6 +250,8 @@ public final class ParserUtils
|
|||
c = '"';
|
||||
else if (namedEntity.equals("apos"))
|
||||
c = '\'';
|
||||
else if (namedEntity.equals("szlig"))
|
||||
c = 'ß';
|
||||
else
|
||||
throw new IllegalStateException("unknown entity: " + namedEntity);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue