Proposing Units Converter API Design in ICU

36 views
Skip to first unread message

Younies Mahmoud

unread,
Jan 23, 2025, 9:14:08 AMJan 23
to icu-d...@unicode.org
Dear ICU Committee,

I'd like to introduce a proposed design for a Units Converter API in ICU. This API aims to provide convenient and flexible unit conversion functionality within ICU.

The API utilizes a fluent pattern for essential options and a builder pattern for optional settings. The initial focus is on CompoundUnitsConverter, with plans to expand to Complex and LocaleAware converters in the future.

Attached is a design document that details the API and includes usage examples for Compound, Complex, and LocaleAware converters. It also outlines the design for the CompoundUnitsConverter in both ICU4C and ICU4J.

I welcome your feedback and suggestions on this proposal. Please let me know if you have any questions.

Link to the design doc: https://bit.ly/icu-units-converter 

Sincerely,
--
Younies Mahmoud
💻 Software Engineer at Google | 🌐 Unicode & Internationalization Engineer
✉️ Personal: younies...@gmail.com
🔗 GitHub

Younies Mahmoud

unread,
Jan 29, 2025, 5:29:48 PMJan 29
to icu-d...@unicode.org
Dear ICU Committee,

I have edited the design document and added two more options.

However, given the limited time, we won't be able to submit this proposal for ICU 77.  We can instead consider it for ICU 78 and discuss it on Thursday, February 20, 2025.

Have a nice day.
Reply all
Reply to author
Forward
0 new messages