summaryrefslogtreecommitdiffstats
path: root/src/pinyin.h
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2012-03-05 16:04:25 +0800
committerPeng Wu <alexepico@gmail.com>2012-03-05 16:04:53 +0800
commitda7323a57cb89ca385676b9566f5b70e4a42e1a3 (patch)
tree68ab6f84aac99a9fcd608e15f1daed8d3f56e137 /src/pinyin.h
parent536b587a1a5c2aa273026890cec64881e58e5cc5 (diff)
downloadlibpinyin-da7323a57cb89ca385676b9566f5b70e4a42e1a3.tar.gz
libpinyin-da7323a57cb89ca385676b9566f5b70e4a42e1a3.tar.xz
libpinyin-da7323a57cb89ca385676b9566f5b70e4a42e1a3.zip
add pinyin_guess_sentence_with_prefix
Diffstat (limited to 'src/pinyin.h')
-rw-r--r--src/pinyin.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/pinyin.h b/src/pinyin.h
index da2e820..fcd10eb 100644
--- a/src/pinyin.h
+++ b/src/pinyin.h
@@ -143,6 +143,18 @@ void pinyin_free_instance(pinyin_instance_t * instance);
bool pinyin_guess_sentence(pinyin_instance_t * instance);
/**
+ * pinyin_guess_sentence_with_prefix:
+ * @instance: the pinyin instance.
+ * @prefix: the prefix before the sentence.
+ * @returns: whether the sentence are guessed successfully.
+ *
+ * Guess a sentence from the saved pinyin keys with a prefix.
+ *
+ */
+bool pinyin_guess_sentence_with_prefix(pinyin_instance_t * instance,
+ const char * prefix);
+
+/**
* pinyin_phrase_segment:
* @instance: the pinyin instance.
* @sentence: the utf-8 sentence to be segmented.