ICU4X
International Components for Unicode
Loading...
Searching...
No Matches
LineBreakStrictness.d.hpp
Go to the documentation of this file.
1#ifndef icu4x_LineBreakStrictness_D_HPP
2#define icu4x_LineBreakStrictness_D_HPP
3
4#include <stdio.h>
5#include <stdint.h>
6#include <stddef.h>
7#include <stdbool.h>
8#include <memory>
9#include <functional>
10#include <optional>
11#include <cstdlib>
13
14
15namespace icu4x {
16namespace capi {
17 enum LineBreakStrictness {
18 LineBreakStrictness_Loose = 0,
19 LineBreakStrictness_Normal = 1,
20 LineBreakStrictness_Strict = 2,
21 LineBreakStrictness_Anywhere = 3,
22 };
23
24 typedef struct LineBreakStrictness_option {union { LineBreakStrictness ok; }; bool is_ok; } LineBreakStrictness_option;
25} // namespace capi
26} // namespace
27
28namespace icu4x {
33public:
34 enum Value {
35 Loose = 0,
36 Normal = 1,
37 Strict = 2,
39 };
40
42 // Implicit conversions between enum and ::Value
43 constexpr LineBreakStrictness(Value v) : value(v) {}
44 constexpr operator Value() const { return value; }
45 // Prevent usage as boolean value
46 explicit operator bool() const = delete;
47
48 inline icu4x::capi::LineBreakStrictness AsFFI() const;
49 inline static icu4x::LineBreakStrictness FromFFI(icu4x::capi::LineBreakStrictness c_enum);
50private:
51 Value value;
52};
53
54} // namespace
55#endif // icu4x_LineBreakStrictness_D_HPP
Definition LineBreakStrictness.d.hpp:32
Value
Definition LineBreakStrictness.d.hpp:34
@ Strict
Definition LineBreakStrictness.d.hpp:37
@ Loose
Definition LineBreakStrictness.d.hpp:35
@ Anywhere
Definition LineBreakStrictness.d.hpp:38
@ Normal
Definition LineBreakStrictness.d.hpp:36
constexpr LineBreakStrictness(Value v)
Definition LineBreakStrictness.d.hpp:43
Definition Bidi.d.hpp:14