tor-browser

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

PropertyValueNameToEnumMapper.d.hpp (11874B)


      1 #ifndef icu4x_PropertyValueNameToEnumMapper_D_HPP
      2 #define icu4x_PropertyValueNameToEnumMapper_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 DataProvider; }
     16 class DataProvider;
     17 namespace capi { struct PropertyValueNameToEnumMapper; }
     18 class PropertyValueNameToEnumMapper;
     19 class DataError;
     20 }
     21 
     22 
     23 namespace icu4x {
     24 namespace capi {
     25    struct PropertyValueNameToEnumMapper;
     26 } // namespace capi
     27 } // namespace
     28 
     29 namespace icu4x {
     30 /**
     31 * A type capable of looking up a property value from a string name.
     32 *
     33 * See the [Rust documentation for `PropertyParser`](https://docs.rs/icu/latest/icu/properties/struct.PropertyParser.html) for more information.
     34 *
     35 * See the [Rust documentation for `PropertyParserBorrowed`](https://docs.rs/icu/latest/icu/properties/struct.PropertyParserBorrowed.html) for more information.
     36 *
     37 * See the [Rust documentation for `new`](https://docs.rs/icu/latest/icu/properties/struct.PropertyParser.html#method.new) for more information.
     38 */
     39 class PropertyValueNameToEnumMapper {
     40 public:
     41 
     42  /**
     43   * Get the property value matching the given name, using strict matching
     44   *
     45   * Returns -1 if the name is unknown for this property
     46   *
     47   * See the [Rust documentation for `get_strict`](https://docs.rs/icu/latest/icu/properties/struct.PropertyParserBorrowed.html#method.get_strict) for more information.
     48   */
     49  inline int16_t get_strict(std::string_view name) const;
     50 
     51  /**
     52   * Get the property value matching the given name, using loose matching
     53   *
     54   * Returns -1 if the name is unknown for this property
     55   *
     56   * See the [Rust documentation for `get_loose`](https://docs.rs/icu/latest/icu/properties/struct.PropertyParserBorrowed.html#method.get_loose) for more information.
     57   */
     58  inline int16_t get_loose(std::string_view name) const;
     59 
     60  /**
     61   * Create a name-to-enum mapper for the `General_Category` property, using compiled data.
     62   *
     63   * See the [Rust documentation for `GeneralCategory`](https://docs.rs/icu/latest/icu/properties/props/enum.GeneralCategory.html) for more information.
     64   */
     65  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_general_category();
     66 
     67  /**
     68   * Create a name-to-enum mapper for the `General_Category` property, using a particular data source.
     69   *
     70   * See the [Rust documentation for `GeneralCategory`](https://docs.rs/icu/latest/icu/properties/props/enum.GeneralCategory.html) for more information.
     71   */
     72  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_general_category_with_provider(const icu4x::DataProvider& provider);
     73 
     74  /**
     75   * Create a name-to-enum mapper for the `Hangul_Syllable_Type` property, using compiled data.
     76   *
     77   * See the [Rust documentation for `HangulSyllableType`](https://docs.rs/icu/latest/icu/properties/props/struct.HangulSyllableType.html) for more information.
     78   */
     79  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_hangul_syllable_type();
     80 
     81  /**
     82   * Create a name-to-enum mapper for the `Hangul_Syllable_Type` property, using a particular data source.
     83   *
     84   * See the [Rust documentation for `HangulSyllableType`](https://docs.rs/icu/latest/icu/properties/props/struct.HangulSyllableType.html) for more information.
     85   */
     86  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_hangul_syllable_type_with_provider(const icu4x::DataProvider& provider);
     87 
     88  /**
     89   * Create a name-to-enum mapper for the `East_Asian_Width` property, using compiled data.
     90   *
     91   * See the [Rust documentation for `EastAsianWidth`](https://docs.rs/icu/latest/icu/properties/props/struct.EastAsianWidth.html) for more information.
     92   */
     93  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_east_asian_width();
     94 
     95  /**
     96   * Create a name-to-enum mapper for the `East_Asian_Width` property, using a particular data source.
     97   *
     98   * See the [Rust documentation for `EastAsianWidth`](https://docs.rs/icu/latest/icu/properties/props/struct.EastAsianWidth.html) for more information.
     99   */
    100  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_east_asian_width_with_provider(const icu4x::DataProvider& provider);
    101 
    102  /**
    103   * Create a name-to-enum mapper for the `Bidi_Class` property, using compiled data.
    104   *
    105   * See the [Rust documentation for `BidiClass`](https://docs.rs/icu/latest/icu/properties/props/struct.BidiClass.html) for more information.
    106   */
    107  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_bidi_class();
    108 
    109  /**
    110   * Create a name-to-enum mapper for the `Bidi_Class` property, using a particular data source.
    111   *
    112   * See the [Rust documentation for `BidiClass`](https://docs.rs/icu/latest/icu/properties/props/struct.BidiClass.html) for more information.
    113   */
    114  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_bidi_class_with_provider(const icu4x::DataProvider& provider);
    115 
    116  /**
    117   * Create a name-to-enum mapper for the `Indic_Syllabic_Category` property, using compiled data.
    118   *
    119   * See the [Rust documentation for `IndicSyllabicCategory`](https://docs.rs/icu/latest/icu/properties/props/struct.IndicSyllabicCategory.html) for more information.
    120   */
    121  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_indic_syllabic_category();
    122 
    123  /**
    124   * Create a name-to-enum mapper for the `Indic_Syllabic_Category` property, using a particular data source.
    125   *
    126   * See the [Rust documentation for `IndicSyllabicCategory`](https://docs.rs/icu/latest/icu/properties/props/struct.IndicSyllabicCategory.html) for more information.
    127   */
    128  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_indic_syllabic_category_with_provider(const icu4x::DataProvider& provider);
    129 
    130  /**
    131   * Create a name-to-enum mapper for the `Line_Break` property, using compiled data.
    132   *
    133   * See the [Rust documentation for `LineBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.LineBreak.html) for more information.
    134   */
    135  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_line_break();
    136 
    137  /**
    138   * Create a name-to-enum mapper for the `Line_Break` property, using a particular data source.
    139   *
    140   * See the [Rust documentation for `LineBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.LineBreak.html) for more information.
    141   */
    142  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_line_break_with_provider(const icu4x::DataProvider& provider);
    143 
    144  /**
    145   * Create a name-to-enum mapper for the `Grapheme_Cluster_Break` property, using compiled data.
    146   *
    147   * See the [Rust documentation for `GraphemeClusterBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.GraphemeClusterBreak.html) for more information.
    148   */
    149  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_grapheme_cluster_break();
    150 
    151  /**
    152   * Create a name-to-enum mapper for the `Grapheme_Cluster_Break` property, using a particular data source.
    153   *
    154   * See the [Rust documentation for `GraphemeClusterBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.GraphemeClusterBreak.html) for more information.
    155   */
    156  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_grapheme_cluster_break_with_provider(const icu4x::DataProvider& provider);
    157 
    158  /**
    159   * Create a name-to-enum mapper for the `Word_Break` property, using compiled data.
    160   *
    161   * See the [Rust documentation for `WordBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.WordBreak.html) for more information.
    162   */
    163  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_word_break();
    164 
    165  /**
    166   * Create a name-to-enum mapper for the `Word_Break` property, using a particular data source.
    167   *
    168   * See the [Rust documentation for `WordBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.WordBreak.html) for more information.
    169   */
    170  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_word_break_with_provider(const icu4x::DataProvider& provider);
    171 
    172  /**
    173   * Create a name-to-enum mapper for the `Sentence_Break` property, using compiled data.
    174   *
    175   * See the [Rust documentation for `SentenceBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.SentenceBreak.html) for more information.
    176   */
    177  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_sentence_break();
    178 
    179  /**
    180   * Create a name-to-enum mapper for the `Sentence_Break` property, using a particular data source.
    181   *
    182   * See the [Rust documentation for `SentenceBreak`](https://docs.rs/icu/latest/icu/properties/props/struct.SentenceBreak.html) for more information.
    183   */
    184  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_sentence_break_with_provider(const icu4x::DataProvider& provider);
    185 
    186  /**
    187   * Create a name-to-enum mapper for the `Script` property, using compiled data.
    188   *
    189   * See the [Rust documentation for `Script`](https://docs.rs/icu/latest/icu/properties/props/struct.Script.html) for more information.
    190   */
    191  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_script();
    192 
    193  /**
    194   * Create a name-to-enum mapper for the `Script` property, using a particular data source.
    195   *
    196   * See the [Rust documentation for `Script`](https://docs.rs/icu/latest/icu/properties/props/struct.Script.html) for more information.
    197   */
    198  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_script_with_provider(const icu4x::DataProvider& provider);
    199 
    200  /**
    201   * Create a name-to-enum mapper for the `Vertical_Orientation` property, using compiled data.
    202   *
    203   * See the [Rust documentation for `VerticalOrientation`](https://docs.rs/icu/latest/icu/properties/props/struct.VerticalOrientation.html) for more information.
    204   */
    205  inline static std::unique_ptr<icu4x::PropertyValueNameToEnumMapper> create_vertical_orientation();
    206 
    207  /**
    208   * Create a name-to-enum mapper for the `Vertical_Orientation` property, using a particular data source.
    209   *
    210   * See the [Rust documentation for `VerticalOrientation`](https://docs.rs/icu/latest/icu/properties/props/struct.VerticalOrientation.html) for more information.
    211   */
    212  inline static diplomat::result<std::unique_ptr<icu4x::PropertyValueNameToEnumMapper>, icu4x::DataError> create_vertical_orientation_with_provider(const icu4x::DataProvider& provider);
    213 
    214  inline const icu4x::capi::PropertyValueNameToEnumMapper* AsFFI() const;
    215  inline icu4x::capi::PropertyValueNameToEnumMapper* AsFFI();
    216  inline static const icu4x::PropertyValueNameToEnumMapper* FromFFI(const icu4x::capi::PropertyValueNameToEnumMapper* ptr);
    217  inline static icu4x::PropertyValueNameToEnumMapper* FromFFI(icu4x::capi::PropertyValueNameToEnumMapper* ptr);
    218  inline static void operator delete(void* ptr);
    219 private:
    220  PropertyValueNameToEnumMapper() = delete;
    221  PropertyValueNameToEnumMapper(const icu4x::PropertyValueNameToEnumMapper&) = delete;
    222  PropertyValueNameToEnumMapper(icu4x::PropertyValueNameToEnumMapper&&) noexcept = delete;
    223  PropertyValueNameToEnumMapper operator=(const icu4x::PropertyValueNameToEnumMapper&) = delete;
    224  PropertyValueNameToEnumMapper operator=(icu4x::PropertyValueNameToEnumMapper&&) noexcept = delete;
    225  static void operator delete[](void*, size_t) = delete;
    226 };
    227 
    228 } // namespace
    229 #endif // icu4x_PropertyValueNameToEnumMapper_D_HPP