mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 21:59:07 +00:00
LibUnicode: Download and parse IDNA data
This commit is contained in:
parent
cfd0a60863
commit
7d9fe44039
Notes:
sideshowbarker
2024-07-16 23:08:48 +09:00
Author: https://github.com/skyrising
Commit: 7d9fe44039
Pull-request: https://github.com/SerenityOS/serenity/pull/19414
Reviewed-by: https://github.com/AtkinsSJ
Reviewed-by: https://github.com/nico
Reviewed-by: https://github.com/shannonbooth
Reviewed-by: https://github.com/trflynn89
6 changed files with 324 additions and 30 deletions
34
Userland/Libraries/LibUnicode/IDNA.h
Normal file
34
Userland/Libraries/LibUnicode/IDNA.h
Normal file
|
@ -0,0 +1,34 @@
|
|||
/*
|
||||
* Copyright (c) 2023, Simon Wanner <simon@skyrising.xyz>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <AK/Utf32View.h>
|
||||
|
||||
namespace Unicode::IDNA {
|
||||
|
||||
enum class MappingStatus : u8 {
|
||||
Valid,
|
||||
Ignored,
|
||||
Mapped,
|
||||
Deviation,
|
||||
Disallowed,
|
||||
DisallowedStd3Valid,
|
||||
DisallowedStd3Mapped,
|
||||
};
|
||||
|
||||
enum class IDNA2008Status : u8 {
|
||||
NV8,
|
||||
XV8,
|
||||
};
|
||||
|
||||
struct Mapping {
|
||||
MappingStatus status;
|
||||
IDNA2008Status idna_2008_status;
|
||||
Utf32View mapped_to;
|
||||
};
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue