mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:07:44 +00:00
LibUnicode: Add some data related to currency codes
This data is published under ISO-4217 as an XML file. Since we can't parse XML files yet, and the data isn't very large, it was translated to C++ manually here.
This commit is contained in:
parent
3ae4ff109f
commit
e6334cb856
4 changed files with 229 additions and 0 deletions
21
Userland/Libraries/LibUnicode/CurrencyCode.h
Normal file
21
Userland/Libraries/LibUnicode/CurrencyCode.h
Normal file
|
@ -0,0 +1,21 @@
|
|||
/*
|
||||
* Copyright (c) 2021, Tim Flynn <trflynn89@pm.me>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <AK/HashMap.h>
|
||||
#include <AK/Optional.h>
|
||||
#include <AK/StringView.h>
|
||||
|
||||
namespace Unicode {
|
||||
|
||||
struct CurrencyCode {
|
||||
Optional<int> minor_unit {};
|
||||
};
|
||||
|
||||
Optional<CurrencyCode> get_currency_code(StringView currency);
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue