Example #1
0
static void NativeCollation_setText(JNIEnv* env, jclass, jint address, jstring source0) {
    ScopedJavaUnicodeString source(env, source0);
    UErrorCode status = U_ZERO_ERROR;
    ucol_setText(toCollationElements(address),
            source.unicodeString().getBuffer(), source.unicodeString().length(), &status);
    icu4jni_error(env, status);
}
Example #2
0
//static void NativeCollation_setOffset(JNIEnv* env, jclass, jint address, jint offset) {
JNIEXPORT void JNICALL
Java_com_ibm_icu4jni_text_NativeCollation_setOffset(JNIEnv* env, jclass,
		jint address, jint offset) {
	UErrorCode status = U_ZERO_ERROR;
	ucol_setOffset(toCollationElements(address), offset, &status);
	icu4jni_error(env, status);
}
Example #3
0
//static jint NativeCollation_previous(JNIEnv* env, jclass, jint address) {
JNIEXPORT jint JNICALL
Java_com_ibm_icu4jni_text_NativeCollation_previous(JNIEnv* env, jclass,
		jint address) {
	UErrorCode status = U_ZERO_ERROR;
	jint result = ucol_previous(toCollationElements(address), &status);
	icu4jni_error(env, status);
	return result;
}
static void NativeCollation_setText(JNIEnv* env, jclass, jlong address, jstring javaSource) {
    ScopedStringChars source(env, javaSource);
    if (source.get() == NULL) {
        return;
    }
    UErrorCode status = U_ZERO_ERROR;
    ucol_setText(toCollationElements(address), source.get(), source.size(), &status);
    maybeThrowIcuException(env, "ucol_setText", status);
}
Example #5
0
//static jint NativeCollation_getMaxExpansion(JNIEnv*, jclass, jint address, jint order) {
JNIEXPORT jint JNICALL
Java_com_ibm_icu4jni_text_NativeCollation_getMaxExpansion(JNIEnv*, jclass,
		jint address, jint order) {
	return ucol_getMaxExpansion(toCollationElements(address), order);
}
Example #6
0
//static void NativeCollation_closeElements(JNIEnv*, jclass, jint address) {
JNIEXPORT void JNICALL
Java_com_ibm_icu4jni_text_NativeCollation_closeElements(JNIEnv*, jclass,
		jint address) {
	ucol_closeElements(toCollationElements(address));
}
Example #7
0
//static jint NativeCollation_getOffset(JNIEnv*, jclass, jint address) {
JNIEXPORT jint JNICALL
Java_com_ibm_icu4jni_text_NativeCollation_getOffset(JNIEnv*, jclass,
		jint address) {
	return ucol_getOffset(toCollationElements(address));
}
static jint NativeCollation_getOffset(JNIEnv*, jclass, jlong address) {
    return ucol_getOffset(toCollationElements(address));
}
static jint NativeCollation_getMaxExpansion(JNIEnv*, jclass, jlong address, jint order) {
    return ucol_getMaxExpansion(toCollationElements(address), order);
}
static void NativeCollation_closeElements(JNIEnv*, jclass, jlong address) {
    ucol_closeElements(toCollationElements(address));
}
static void NativeCollation_setOffset(JNIEnv* env, jclass, jlong address, jint offset) {
    UErrorCode status = U_ZERO_ERROR;
    ucol_setOffset(toCollationElements(address), offset, &status);
    maybeThrowIcuException(env, "ucol_setOffset", status);
}
static jint NativeCollation_previous(JNIEnv* env, jclass, jlong address) {
    UErrorCode status = U_ZERO_ERROR;
    jint result = ucol_previous(toCollationElements(address), &status);
    maybeThrowIcuException(env, "ucol_previous", status);
    return result;
}
Example #13
0
static void NativeCollation_setOffset(JNIEnv* env, jclass, jint address, jint offset) {
    UErrorCode status = U_ZERO_ERROR;
    ucol_setOffset(toCollationElements(address), offset, &status);
    icu4jni_error(env, status);
}
Example #14
0
static void NativeCollation_reset(JNIEnv*, jclass, jint address) {
    ucol_reset(toCollationElements(address));
}
Example #15
0
static jint NativeCollation_previous(JNIEnv* env, jclass, jint address) {
    UErrorCode status = U_ZERO_ERROR;
    jint result = ucol_previous(toCollationElements(address), &status);
    icu4jni_error(env, status);
    return result;
}