Skip to content

Commit 3e7a6fd

Browse files
authored
UnitParser: adding overloads for getting a UnitInfo using a type/name and abbreviation (angularsen#1585)
Adding the following (public) methods to the `UnitParser` - `UnitInfo GetUnitFromAbbreviation(string quantityName, string unitAbbreviation, IFormatProvider? formatProvider)` - `UnitInfo GetUnitFromAbbreviation(Type quantityType, string unitAbbreviation, IFormatProvider? formatProvider)` - `bool TryGetUnitFromAbbreviation(string quantityName, string? unitAbbreviation, IFormatProvider? formatProvider, [NotNullWhen(true)] out UnitInfo? unitInfo)` - `bool TryGetUnitFromAbbreviation(Type quantityType, string? unitAbbreviation, IFormatProvider? formatProvider, [NotNullWhen(true)] out UnitInfo? unitInfo)`
1 parent 0da4a5a commit 3e7a6fd

2 files changed

Lines changed: 466 additions & 255 deletions

File tree

0 commit comments

Comments
 (0)