#include <mw/iwnn/iwnnCTR.h> s16 NjxAddWord( IWNN_CLASS* iwnn, // Parsing information class const IWNN_WORD_INFO* word, // Word registration information structure u8 type, // Dictionary type u8 connect // Associative learning flag );
Name | Description | |
---|---|---|
IN / OUT | IWNN_CLASS* iwnn | Parsing information class An error results if NULL is specified. |
IN | const IWNN_WORD_INFO* word | Word registration information dictionary. Specifies word information to be registered. An error results if an erroneous value is set in IWNN_WORD_INFO or NULL is specified. |
IN | u8 type | Dictionary type to register to. 0: Add to user dictionary 1: Add to learning dictionary 2: Add to pseudo-dictionary |
IN | u8 connect | Associative learning flag. This flag can only be enabled when a learning dictionary is specified for the dictionary type. 0: Do not perform associative learning with the word last registered. 1: Perform associative learning with the word last registered. |
s16 | Negative value: Error (including cases where candidates with the same reading string and candidate string exist) Other: Normal exit |
Error Code | Description of Error |
NJ_ERR_PARAM_ENVIRONMENT_NULL |
A NULL pointer was specified for iwnn |
NJ_ERR_PARAM_DIC_NULL |
NULL was specified for iwnn->dicSet |
NJ_ERR_NO_RULE_DIC |
A rule dictionary was not specified in iwnn->dicSet |
NJ_ERR_DIC_TYPE_INVALID |
An undefined value was set for type |
NJ_ERR_WORD_INFO_NULL |
NULL was specified for word |
NJ_ERR_USER_READING_INVALID |
■ A reading string longer than NJ_MAX_LEN was specified for word registration in the learning dictionary■ A reading string longer than NJ_MAX_USER_LEN was specified for word registration in the user dictionary |
NJ_ERR_USER_CANDIDATE_INVALID |
■ A candidate string longer than NJ_MAX_RESULT_LEN was specified for word registration in the learning dictionary ■ A candidate string longer than NJ_MAX_USER_CANDIDATE_LEN was specified for word registration in the user dictionary |
NJ_ERR_PARTS_OF_SPEECH_GROUP_INVALID |
An undefined value was set for the word part-of-speech group |
NJ_ERR_DIC_NOT_FOUND |
The dictionary specified by type does not exist in the dictionary set specified in iwnn->dicSet |
NJ_ERR_USER_DIC_FULL |
The user dictionary already contains the maximum number of registered words allowed |
NJ_ERR_DIC_BROKEN |
■ Additional locations of learning information and user dictionary information could not be obtained from the learning dictionary specified in iwnn->dicSet ■ The number of words to register is larger than the maximum number of registered words given in the learning dictionary and user dictionary headers specified in iwnn->dicSet ■ The data in the learning dictionary and user dictionary queue specified in iwnn->dicSet is corrupted |
NJ_ERR_SAME_WORD |
The word to add to the user dictionary has already been added |
NJ_ERR_PROTECTION_ERR |
Operations have been performed on memory secured by using a learning dictionary function |
NJ_ERR_INVALID_FLAG |
A value greater than one was specified for connect |
CONFIDENTIAL