1 /* Copyright (c) 2013 - The libcangjie authors. 2 * 3 * This file is part of libcangjie. 4 * 5 * libcangjie is free software: you can redistribute it and/or modify 6 * it under the terms of the GNU Lesser General Public License as published by 7 * the Free Software Foundation, either version 3 of the License, or 8 * (at your option) any later version. 9 * 10 * libcangjie 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 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with libcangjie. If not, see <http://www.gnu.org/licenses/>. 17 */ 18 19 #ifndef CANGJIEERRORS_H__ 20 #define CANGJIEERRORS_H__ 21 #define CANGJIE_OK 0 /* Successful result */ 22 #define CANGJIE_NOCHARS 1 /* Nothing wrong, but no corresponding CangjieChar returned */ 23 #define CANGJIE_DBOPEN 2 /* Could not open the database */ 24 #define CANGJIE_DBERROR 3 /* Something happened when querying the database */ 25 #define CANGJIE_NOMEM 4 /* Memory allocation failure */ 26 #define CANGJIE_INVALID 5 /* Invalid input was passed to the library */ 27 28 #endif 29