Open jowilco opened 5 months ago
Comment on June 6 is no longer valid - we're now ready for review.
@macchiati @eggrobin @markusicu - Please can you review?
No good reason. I think the code might predate the formal recognition as properties.
On Wed, Nov 27, 2024, 07:01 Robin Leroy @.***> wrote:
@.**** commented on this pull request.
In unicodetools/src/main/java/org/unicode/xml/AttributeResolver.java https://github.com/unicode-org/unicodetools/pull/859#discussion_r1860820160 :
- case Script:
- return map_script.get(codepoint).getShortName();
- case Script_Extensions:
- StringBuilder extensionBuilder = new StringBuilder();
- String[] extensions = map_script_extensions.get(codepoint).split("\|", 0);
- for (String extension : extensions) {
- extensionBuilder.append(
- UcdPropertyValues.Script_Values.valueOf(extension)
- .getShortName());
- extensionBuilder.append(" ");
- }
- return extensionBuilder.toString().trim();
- default:
- throw new RuntimeException("Missing Catalog case");
- }
- case Enumerated:
This (and the associated pile of UnicodeMaps) seems like it is going to be a bit annoying to maintain as we add properties. Is there a reason why you are not doing something like
final UnicodeProperty property = indexUnicodeProperties.getProperty(prop);final List
valueAliases = property.getValueAliases(property.getValue(codepoint));return valueAliases.size() == 1 ? valueAliases.get(0) : valueAliases.get(1); for most of them (special-casing Decomposition_Type etc. as needed)?
— Reply to this email directly, view it on GitHub https://github.com/unicode-org/unicodetools/pull/859#pullrequestreview-2465280738, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACJLEMDD3JBHAYCDTBHLLX32CXNFDAVCNFSM6AAAAABI5USRGKVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDINRVGI4DANZTHA . You are receiving this because you were mentioned.Message ID: @.***>
PR to make it easy to see what changes have been made to support UCDXML.