| 1 | /* |
| 2 | Copyright(C) 2012-2016 Brazil |
| 3 | Copyright(C) 2018 Kouhei Sutou <[email protected]> |
| 4 | |
| 5 | This library is free software; you can redistribute it and/or |
| 6 | modify it under the terms of the GNU Lesser General Public |
| 7 | License as published by the Free Software Foundation; either |
| 8 | version 2.1 of the License, or (at your option) any later version. |
| 9 | |
| 10 | This library is distributed in the hope that it will be useful, |
| 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 | Lesser General Public License for more details. |
| 14 | |
| 15 | You should have received a copy of the GNU Lesser General Public |
| 16 | License along with this library; if not, write to the Free Software |
| 17 | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
| 18 | */ |
| 19 | |
| 20 | #pragma once |
| 21 | |
| 22 | #include "grn.h" |
| 23 | #include "grn_ctx.h" |
| 24 | #include "grn_db.h" |
| 25 | #include "grn_nfkc.h" |
| 26 | #include "grn_string.h" |
| 27 | |
| 28 | #ifdef __cplusplus |
| 29 | extern "C" { |
| 30 | #endif |
| 31 | |
| 32 | #define GRN_NORMALIZER_AUTO_NAME "NormalizerAuto" |
| 33 | |
| 34 | grn_rc grn_normalizer_init(void); |
| 35 | grn_rc grn_normalizer_fin(void); |
| 36 | |
| 37 | grn_rc grn_normalizer_normalize(grn_ctx *ctx, |
| 38 | grn_obj *normalizer, |
| 39 | grn_obj *string); |
| 40 | |
| 41 | grn_rc grn_nfkc_normalize(grn_ctx *ctx, |
| 42 | grn_obj *string, |
| 43 | grn_nfkc_normalize_options *options); |
| 44 | |
| 45 | grn_rc grn_db_init_builtin_normalizers(grn_ctx *ctx); |
| 46 | |
| 47 | #ifdef __cplusplus |
| 48 | } |
| 49 | #endif |