tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

CodePointMapData8.d.hpp (13707B)


      1 #ifndef icu4x_CodePointMapData8_D_HPP
      2 #define icu4x_CodePointMapData8_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>
     12 #include "../diplomat_runtime.hpp"
     13 
     14 namespace icu4x {
     15 namespace capi { struct CodePointMapData8; }
     16 class CodePointMapData8;
     17 namespace capi { struct CodePointRangeIterator; }
     18 class CodePointRangeIterator;
     19 namespace capi { struct CodePointSetData; }
     20 class CodePointSetData;
     21 namespace capi { struct DataProvider; }
     22 class DataProvider;
     23 struct GeneralCategoryGroup;
     24 class DataError;
     25 }
     26 
     27 
     28 namespace icu4x {
     29 namespace capi {
     30    struct CodePointMapData8;
     31 } // namespace capi
     32 } // namespace
     33 
     34 namespace icu4x {
     35 /**
     36 * An ICU4X Unicode Map Property object, capable of querying whether a code point (key) to obtain the Unicode property value, for a specific Unicode property.
     37 *
     38 * For properties whose values fit into 8 bits.
     39 *
     40 * See the [Rust documentation for `properties`](https://docs.rs/icu/latest/icu/properties/index.html) for more information.
     41 *
     42 * See the [Rust documentation for `CodePointMapData`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapData.html) for more information.
     43 *
     44 * See the [Rust documentation for `CodePointMapDataBorrowed`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapDataBorrowed.html) for more information.
     45 */
     46 class CodePointMapData8 {
     47 public:
     48 
     49  /**
     50   * Gets the value for a code point.
     51   *
     52   * See the [Rust documentation for `get`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapDataBorrowed.html#method.get) for more information.
     53   */
     54  inline uint8_t operator[](char32_t cp) const;
     55 
     56  /**
     57   * Produces an iterator over ranges of code points that map to `value`
     58   *
     59   * See the [Rust documentation for `iter_ranges_for_value`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapDataBorrowed.html#method.iter_ranges_for_value) for more information.
     60   */
     61  inline std::unique_ptr<icu4x::CodePointRangeIterator> iter_ranges_for_value(uint8_t value) const;
     62 
     63  /**
     64   * Produces an iterator over ranges of code points that do not map to `value`
     65   *
     66   * See the [Rust documentation for `iter_ranges_for_value_complemented`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapDataBorrowed.html#method.iter_ranges_for_value_complemented) for more information.
     67   */
     68  inline std::unique_ptr<icu4x::CodePointRangeIterator> iter_ranges_for_value_complemented(uint8_t value) const;
     69 
     70  /**
     71   * Given a mask value (the nth bit marks property value = n), produce an iterator over ranges of code points
     72   * whose property values are contained in the mask.
     73   *
     74   * The main mask property supported is that for General_Category, which can be obtained via `general_category_to_mask()` or
     75   * by using `GeneralCategoryNameToMaskMapper`
     76   *
     77   * Should only be used on maps for properties with values less than 32 (like Generak_Category),
     78   * other maps will have unpredictable results
     79   *
     80   * See the [Rust documentation for `iter_ranges_for_group`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapDataBorrowed.html#method.iter_ranges_for_group) for more information.
     81   */
     82  inline std::unique_ptr<icu4x::CodePointRangeIterator> iter_ranges_for_group(icu4x::GeneralCategoryGroup group) const;
     83 
     84  /**
     85   * Gets a [`CodePointSetData`] representing all entries in this map that map to the given value
     86   *
     87   * See the [Rust documentation for `get_set_for_value`](https://docs.rs/icu/latest/icu/properties/struct.CodePointMapDataBorrowed.html#method.get_set_for_value) for more information.
     88   */
     89  inline std::unique_ptr<icu4x::CodePointSetData> get_set_for_value(uint8_t value) const;
     90 
     91  /**
     92   * Create a map for the `General_Category` property, using compiled data.
     93   *
     94   * See the [Rust documentation for `GeneralCategory`](https://docs.rs/icu/latest/icu/properties/props/enum.GeneralCategory.html) for more information.
     95   */
     96  inline static std::unique_ptr<icu4x::CodePointMapData8> create_general_category();
     97 
     98  /**
     99   * Create a map for the `General_Category` property, using a particular data source
    100   *
    101   * See the [Rust documentation for `GeneralCategory`](https://docs.rs/icu/latest/icu/properties/props/enum.GeneralCategory.html) for more information.
    102   */
    103  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_general_category_with_provider(const icu4x::DataProvider& provider);
    104 
    105  /**
    106   * Create a map for the `Bidi_Class` property, using compiled data.
    107   *
    108   * See the [Rust documentation for `BidiClass`](https://docs.rs/icu/latest/icu/properties/props/struct.BidiClass.html) for more information.
    109   */
    110  inline static std::unique_ptr<icu4x::CodePointMapData8> create_bidi_class();
    111 
    112  /**
    113   * Create a map for the `Bidi_Class` property, using a particular data source.
    114   *
    115   * See the [Rust documentation for `BidiClass`](https://docs.rs/icu/latest/icu/properties/props/struct.BidiClass.html) for more information.
    116   */
    117  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_bidi_class_with_provider(const icu4x::DataProvider& provider);
    118 
    119  /**
    120   * Create a map for the `East_Asian_Width` property, using compiled data.
    121   *
    122   * See the [Rust documentation for `EastAsianWidth`](https://docs.rs/icu/latest/icu/properties/props/struct.EastAsianWidth.html) for more information.
    123   */
    124  inline static std::unique_ptr<icu4x::CodePointMapData8> create_east_asian_width();
    125 
    126  /**
    127   * Create a map for the `East_Asian_Width` property, using a particular data source.
    128   *
    129   * See the [Rust documentation for `EastAsianWidth`](https://docs.rs/icu/latest/icu/properties/props/struct.EastAsianWidth.html) for more information.
    130   */
    131  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_east_asian_width_with_provider(const icu4x::DataProvider& provider);
    132 
    133  /**
    134   * Create a map for the `Hangul_Syllable_Type` property, using compiled data.
    135   *
    136   * See the [Rust documentation for `HangulSyllableType`](https://docs.rs/icu/latest/icu/properties/props/struct.HangulSyllableType.html) for more information.
    137   */
    138  inline static std::unique_ptr<icu4x::CodePointMapData8> create_hangul_syllable_type();
    139 
    140  /**
    141   * Create a map for the `Hangul_Syllable_Type` property, using a particular data source.
    142   *
    143   * See the [Rust documentation for `HangulSyllableType`](https://docs.rs/icu/latest/icu/properties/props/struct.HangulSyllableType.html) for more information.
    144   */
    145  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_hangul_syllable_type_with_provider(const icu4x::DataProvider& provider);
    146 
    147  /**
    148   * Create a map for the `Indic_Syllabic_Property` property, using compiled data.
    149   *
    150   * See the [Rust documentation for `IndicSyllabicCategory`](https://docs.rs/icu/latest/icu/properties/props/struct.IndicSyllabicCategory.html) for more information.
    151   */
    152  inline static std::unique_ptr<icu4x::CodePointMapData8> create_indic_syllabic_category();
    153 
    154  /**
    155   * Create a map for the `Indic_Syllabic_Property` property, using a particular data source.
    156   *
    157   * See the [Rust documentation for `IndicSyllabicCategory`](https://docs.rs/icu/latest/icu/properties/props/struct.IndicSyllabicCategory.html) for more information.
    158   */
    159  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_indic_syllabic_category_with_provider(const icu4x::DataProvider& provider);
    160 
    161  /**
    162   * Create a map for the `Line_Break` property, using compiled data.
    163   *
    164   * See the [Rust documentation for `LineBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.LineBreak.html) for more information.
    165   */
    166  inline static std::unique_ptr<icu4x::CodePointMapData8> create_line_break();
    167 
    168  /**
    169   * Create a map for the `Line_Break` property, using a particular data source.
    170   *
    171   * See the [Rust documentation for `LineBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.LineBreak.html) for more information.
    172   */
    173  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_line_break_with_provider(const icu4x::DataProvider& provider);
    174 
    175  /**
    176   * Create a map for the `Grapheme_Cluster_Break` property, using compiled data.
    177   *
    178   * See the [Rust documentation for `GraphemeClusterBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.GraphemeClusterBreak.html) for more information.
    179   */
    180  inline static std::unique_ptr<icu4x::CodePointMapData8> create_grapheme_cluster_break();
    181 
    182  /**
    183   * Create a map for the `Grapheme_Cluster_Break` property, using a particular data source.
    184   *
    185   * See the [Rust documentation for `GraphemeClusterBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.GraphemeClusterBreak.html) for more information.
    186   */
    187  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_grapheme_cluster_break_with_provider(const icu4x::DataProvider& provider);
    188 
    189  /**
    190   * Create a map for the `Word_Break` property, using compiled data.
    191   *
    192   * See the [Rust documentation for `WordBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.WordBreak.html) for more information.
    193   */
    194  inline static std::unique_ptr<icu4x::CodePointMapData8> create_word_break();
    195 
    196  /**
    197   * Create a map for the `Word_Break` property, using a particular data source.
    198   *
    199   * See the [Rust documentation for `WordBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.WordBreak.html) for more information.
    200   */
    201  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_word_break_with_provider(const icu4x::DataProvider& provider);
    202 
    203  /**
    204   * Create a map for the `Sentence_Break` property, using compiled data.
    205   *
    206   * See the [Rust documentation for `SentenceBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.SentenceBreak.html) for more information.
    207   */
    208  inline static std::unique_ptr<icu4x::CodePointMapData8> create_sentence_break();
    209 
    210  /**
    211   * Create a map for the `Sentence_Break` property, using a particular data source.
    212   *
    213   * See the [Rust documentation for `SentenceBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.SentenceBreak.html) for more information.
    214   */
    215  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_sentence_break_with_provider(const icu4x::DataProvider& provider);
    216 
    217  /**
    218   * Create a map for the `Joining_Type` property, using compiled data.
    219   *
    220   * See the [Rust documentation for `JoiningType`](https://docs.rs/icu/latest/icu/properties/props/struct.JoiningType.html) for more information.
    221   */
    222  inline static std::unique_ptr<icu4x::CodePointMapData8> create_joining_type();
    223 
    224  /**
    225   * Create a map for the `Joining_Type` property, using a particular data source.
    226   *
    227   * See the [Rust documentation for `JoiningType`](https://docs.rs/icu/latest/icu/properties/props/struct.JoiningType.html) for more information.
    228   */
    229  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_joining_type_with_provider(const icu4x::DataProvider& provider);
    230 
    231  /**
    232   * Create a map for the `Canonical_Combining_Class` property, using compiled data.
    233   *
    234   * See the [Rust documentation for `CanonicalCombiningClass`](https://docs.rs/icu/latest/icu/properties/props/struct.CanonicalCombiningClass.html) for more information.
    235   */
    236  inline static std::unique_ptr<icu4x::CodePointMapData8> create_canonical_combining_class();
    237 
    238  /**
    239   * Create a map for the `Canonical_Combining_Class` property, using a particular data source.
    240   *
    241   * See the [Rust documentation for `CanonicalCombiningClass`](https://docs.rs/icu/latest/icu/properties/props/struct.CanonicalCombiningClass.html) for more information.
    242   */
    243  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_canonical_combining_class_with_provider(const icu4x::DataProvider& provider);
    244 
    245  /**
    246   * Create a map for the `Vertical_Orientation` property, using compiled data.
    247   *
    248   * See the [Rust documentation for `VerticalOrientation`](https://docs.rs/icu/latest/icu/properties/props/struct.VerticalOrientation.html) for more information.
    249   */
    250  inline static std::unique_ptr<icu4x::CodePointMapData8> create_vertical_orientation();
    251 
    252  /**
    253   * Create a map for the `Vertical_Orientation` property, using a particular data source.
    254   *
    255   * See the [Rust documentation for `VerticalOrientation`](https://docs.rs/icu/latest/icu/properties/props/struct.VerticalOrientation.html) for more information.
    256   */
    257  inline static diplomat::result<std::unique_ptr<icu4x::CodePointMapData8>, icu4x::DataError> create_vertical_orientation_with_provider(const icu4x::DataProvider& provider);
    258 
    259  inline const icu4x::capi::CodePointMapData8* AsFFI() const;
    260  inline icu4x::capi::CodePointMapData8* AsFFI();
    261  inline static const icu4x::CodePointMapData8* FromFFI(const icu4x::capi::CodePointMapData8* ptr);
    262  inline static icu4x::CodePointMapData8* FromFFI(icu4x::capi::CodePointMapData8* ptr);
    263  inline static void operator delete(void* ptr);
    264 private:
    265  CodePointMapData8() = delete;
    266  CodePointMapData8(const icu4x::CodePointMapData8&) = delete;
    267  CodePointMapData8(icu4x::CodePointMapData8&&) noexcept = delete;
    268  CodePointMapData8 operator=(const icu4x::CodePointMapData8&) = delete;
    269  CodePointMapData8 operator=(icu4x::CodePointMapData8&&) noexcept = delete;
    270  static void operator delete[](void*, size_t) = delete;
    271 };
    272 
    273 } // namespace
    274 #endif // icu4x_CodePointMapData8_D_HPP