Java调用C代码时传入以及返回基本数据类型

Java代码示例:

package zfw;  
  
/** 
 * 别问我为什么有些分隔注释写在C代码里面,有些写在Java里面,如果你问了,恭喜你,小小彩蛋一个 
 * 我发现... 
 * 1.如果native方法有返回值的话,会先执行完java线程中的代码,再执行C中的printf打印 
 * 2.如果native方法没有返回值的话,如果native方法中有printf语句,则会把所有调用了 
 *   printf打印的地方先全部打印出来,再执行java的代码 
 * 当然,项目中的开发最终这些printf语句一般是不过引入的,方便开发时调试,所以知道下这个小 
 * tips也好。 
 * @author zfw 
 * 
 */  
public class JniTest {  
  
    // 1.1 返回基本数据类型系列  
    public native static int getInt();  
    public native static long getLong();  
    public native static float getFloat();  
    public native static double getDouble();  
    public native static String getString();  
  
    // 1.2 返回基本数据类型一维数组系列  
    public native static int[] getIntArray();  
    public native static long[] getLongArray();  
    public native static float[] getFloatArray();  
    public native static double[] getDoubleArray();  
    public native static String[] getStringArray();  
  
    // 1.3 返回基本数组类型二维数组系列  
    public native static int[][] get2DIntArray();  
    public native static long[][] get2DLongArray();  
    public native static float[][] get2DFloatArray();  
    public native static double[][] get2DDoubleArray();  
    public native static String[][] get2DStringArray();  
  
    // 2.1 传入基本数据类型参数系列  
    public native static void transferInt(int param);  
    public native static void transferLong(long param);  
    public native static void transferFloat(float param);  
    public native static void transferDouble(double param);  
    public native static void transferString(String param);  
  
    // 2.2 传入基本数据类型数组参数系列  
    public native static void transferIntArray(int[] param);  
    public native static void transferLongArray(long[] param);  
    public native static void transferFloatArray(float[] param);  
    public native static void transferDoubleArray(double[] param);  
    public native static void transferStringArray(String[] param);  
  
    // 2.3 传入基本数据类型二维数组参数系列  
    public native static void transfer2DIntArray(int[][] param);  
    public native static void transfer2DLongArray(long[][] param);  
    public native static void transfer2DFloatArray(float[][] param);  
    public native static void transfer2DDoubleArray(double[][] param);  
    public native static void transfer2DStringArray(String[][] param);  
      
    // 2.4 传入的是bitmap类型或者自定义类对象呢?  
  
    public static void main(String[] args) {  
          
        System.out.println("-------------1.1 返回基本数据类型系列--------------");  
        int a0 = getInt();  
        System.out.println("getInt():" + a0);  
        long b0 = getLong();  
        System.out.println("getLong():" + b0);  
        float c0 = getFloat();  
        System.out.println("getFloat():" + c0);  
        double d0 = getDouble();  
        System.out.println("getDouble():" + d0);  
        String e0 = getString();  
        System.out.println("getString():" + e0);  
          
        System.out.println("------------1.2 返回基本数据类型一维 数组系列-------------");  
        int[] a1 = getIntArray();  
        System.out.print("getIntArray():");  
        new Printor(a1);  
        long[] b1 = getLongArray();  
        System.out.print("getLongArray():");  
        new Printor(b1);  
        float[] c1 = getFloatArray();  
        System.out.print("getFloatArray():");  
        new Printor(c1);  
        double[] d1 = getDoubleArray();  
        System.out.print("getDoubleArray():");  
        new Printor(d1);  
        String[] e1 = getStringArray();  
        System.out.print("getStringArray():");  
        new Printor(e1);  
          
        System.out.println("------------1.3 返回基本数据类型二维数组系列-------------");  
        int[][] a2 = get2DIntArray();  
        System.out.print("get2DIntArray():");  
        new Printor(a2);  
        long[][] b2 = get2DLongArray();  
        System.out.print("get2DLongArray():");  
        new Printor(b2);  
        float[][] c2 = get2DFloatArray();  
        System.out.print("get2DFloatArray():");  
        new Printor(c2);  
        double[][] d2 = get2DDoubleArray();  
        System.out.print("get2DDoubleArray():");  
        new Printor(d2);  
        String[][] e2 = get2DStringArray();  
        System.out.print("get2DStringArray():");  
        new Printor(e2);  
          
        // 2.1 传入基本数据类型参数系列  
        transferInt(10);  
        transferLong(214721222L);  
        transferFloat(11.22f);  
        transferDouble(10.1234567);  
        transferString("transfer a String type for jni.");  
          
        // 2.2 传入基本数据类型数组参数系列  
        transferIntArray(new int[] { 1, 2, 3 });  
        transferLongArray(new long[] { 214721222L, 214721223L, 214721224 });  
        transferFloatArray(new float[] { 0.1f, 0.2f, 0.3f });  
        transferDoubleArray(new double[] { 0.1234567, 1.1234567, 2.1234567 });  
        transferStringArray(new String[] { "hello", "java", "and", "jni" });  
      
        // 2.3 传入基本数据类型二维数组参数系列  
        transfer2DIntArray(new int[][]{{1,2},{3,4},{5,6}});  
        transfer2DLongArray(new long[][]{{214721222L, 214721223L},{214721224L, 214721225L},{214721226L, 214721227L}});  
        transfer2DFloatArray(new float[][]{{1.1f,2.2f},{3.3f,4.4f},{5.5f,6.6f}});  
        transfer2DDoubleArray(new double[][]{{1.1234567,2.1234567},{3.1234567,4.1234567},{5.1234567,6.1234567}});  
        transfer2DStringArray(new String[][]{{"hello","zfw"},{"lear","jni"},{"i love","java"}});  
      
          
    }  
  
    static {  
        System.loadLibrary("Project1");  
    }  
  
}  

C代码示例:

#include <stdio.h>  
#include "zfw_JniTest.h"  
#include <stdlib.h>  
  
// 1.1 返回基本数据类型系列  
JNIEXPORT jint JNICALL Java_zfw_JniTest_getInt  
(JNIEnv *env, jclass jcls) {  
    int result = 5;  
    return result;  
}  
  
JNIEXPORT jlong JNICALL Java_zfw_JniTest_getLong  
(JNIEnv *env, jclass jcls) {  
    unsigned long result = 2147483650;  
    return result;  
}  
  
JNIEXPORT jfloat JNICALL Java_zfw_JniTest_getFloat  
(JNIEnv *env, jclass jcls) {  
    float result = 10.123f;  
    return result;  
}  
  
JNIEXPORT jdouble JNICALL Java_zfw_JniTest_getDouble  
(JNIEnv *env, jclass jcls) {  
    double result = 110.5678910;  
    return result;  
}  
  
JNIEXPORT jstring JNICALL Java_zfw_JniTest_getString  
(JNIEnv *env, jclass jcls) {  
    jstring result = (*env)->NewStringUTF(env, "I am String type.");  
    return result;  
}  
// 1.2 返回基本数据类型数组系列  
JNIEXPORT jintArray JNICALL Java_zfw_JniTest_getIntArray  
(JNIEnv *env, jclass jcls) {  
    int size = 5;  
    // 创建指定大小的数组  
    jintArray jint_arr = (*env)->NewIntArray(env, size);  
    jint *elems = (*env)->GetIntArrayElements(env, jint_arr, NULL);  
    int i = 0;  
    for (; i < size; i++) {  
        elems[i] = i;  
    }  
    (*env)->ReleaseIntArrayElements(env, jint_arr, elems, 0);  
    return jint_arr;  
}  
  
  
JNIEXPORT jlongArray JNICALL Java_zfw_JniTest_getLongArray  
(JNIEnv *env, jclass jcls) {  
    int size = 5;  
    jlongArray jlong_arr = (*env)->NewLongArray(env, size);  
    jlong *elems = (*env)->GetLongArrayElements(env, jlong_arr, NULL);  
    int i = 0;  
    for (; i < size; i++) {  
        elems[i] = 2147483650 + i;  
    }  
    (*env)->ReleaseLongArrayElements(env, jlong_arr, elems, 0);  
    return jlong_arr;  
}  
  
JNIEXPORT jfloatArray JNICALL Java_zfw_JniTest_getFloatArray  
(JNIEnv *env, jclass jcls) {  
    int size = 5;  
    jfloatArray jfloat_arr = (*env)->NewFloatArray(env, size);  
    jfloat *elems = (*env)->GetFloatArrayElements(env, jfloat_arr, NULL);  
    int i = 0;  
    for (; i < size; i++) {  
        elems[i] = (float)(i / 100.0);  
    }  
    (*env)->ReleaseFloatArrayElements(env, jfloat_arr, elems, 0);  
    return jfloat_arr;  
}  
  
JNIEXPORT jdoubleArray JNICALL Java_zfw_JniTest_getDoubleArray  
(JNIEnv *env, jclass jcls) {  
    int size = 5;  
    jdoubleArray jdouble_arr = (*env)->NewDoubleArray(env, size);  
    jdouble *elems = (*env)->GetDoubleArrayElements(env, jdouble_arr, NULL);  
    int i = 0;  
    for (; i < size; i++) {  
        elems[i] = i+0.1234567;  
    }  
    (*env)->ReleaseDoubleArrayElements(env, jdouble_arr, elems, 0);  
    return jdouble_arr;  
}  
  
JNIEXPORT jobjectArray JNICALL Java_zfw_JniTest_getStringArray  
(JNIEnv *env, jclass jcls) {  
    jobjectArray result;  
    jsize len = 5;  
    int index;  
    char* data[5] = { "Jni", "return", "String", "array", "type" };  
    result = (*env)->NewObjectArray(  
        env, len, (*env)->FindClass(env, "java/lang/String"), 0);  
    for(index = 0; index < 5; index++) {  
        (*env)->SetObjectArrayElement(  
            env, result, index, (*env)->NewStringUTF(env, data[index]));  
    }  
    return result;  
}  
// 1.3 返回基本数组类型二维数组系列  
JNIEXPORT jobjectArray JNICALL Java_zfw_JniTest_get2DIntArray  
(JNIEnv *env, jclass jcls) {  
      
    jobjectArray ret;  
    int row = 3;  
    int column = 2;  
    jsize len = row * column;  
    ret = (*env)->NewObjectArray(  
        env, len, (*env)->FindClass(env, "[I"), 0);  
    int i;  
    int j;  
    for (i = 0; i < row; i++) {  
        jintArray intArr = (*env)->NewIntArray(env, column);  
        jint *elems = (*env)->GetIntArrayElements(env, intArr, NULL);  
        for (j = 0; j < column; j++) {  
            elems[j] = i+j;  
        }  
        (*env)->ReleaseIntArrayElements(env, intArr, elems, 0);  
        (*env)->SetObjectArrayElement(env, ret, i, intArr);  
        (*env)->DeleteLocalRef(env, intArr);  
    }  
    return ret;  
}  
JNIEXPORT jobjectArray JNICALL Java_zfw_JniTest_get2DLongArray  
(JNIEnv *env, jclass jcls) {  
    jobjectArray ret;  
    int row = 3;  
    int column = 2;  
    jsize len = row * column;  
    ret = (*env)->NewObjectArray(  
        env, len, (*env)->FindClass(env, "[J"), 0);  
    int i;  
    int j;  
    for (i = 0; i < row; i++) {  
        jlongArray longArr = (*env)->NewLongArray(env, column);  
        jlong *elems = (*env)->GetLongArrayElements(env, longArr, NULL);  
        for (j = 0; j < column; j++) {  
            elems[j] = i + j + 2147483650;  
        }  
        (*env)->ReleaseLongArrayElements(env, longArr, elems, 0);  
        (*env)->SetObjectArrayElement(env, ret, i, longArr);  
        (*env)->DeleteLocalRef(env, longArr);  
    }  
    return ret;  
}  
JNIEXPORT jobjectArray JNICALL Java_zfw_JniTest_get2DFloatArray  
(JNIEnv *env, jclass jcls) {  
    jobjectArray ret;  
    int row = 3;  
    int column = 2;  
    jsize len = row * column;  
    ret = (*env)->NewObjectArray(  
        env, len, (*env)->FindClass(env, "[F"), 0);  
    int i;  
    int j;  
    for (i = 0; i < row; i++) {  
        jfloatArray floatArr = (*env)->NewFloatArray(env, column);  
        jfloat *elems = (*env)->GetFloatArrayElements(env, floatArr, NULL);  
        for (j = 0; j < column; j++) {  
            elems[j] = (float)((i+j) / 100.0);  
        }  
        (*env)->ReleaseFloatArrayElements(env, floatArr, elems, 0);  
        (*env)->SetObjectArrayElement(env, ret, i, floatArr);  
        (*env)->DeleteLocalRef(env, floatArr);  
    }  
    return ret;  
}  
JNIEXPORT jobjectArray JNICALL Java_zfw_JniTest_get2DDoubleArray  
(JNIEnv *env, jclass jcls) {  
    jobjectArray ret;  
    int row = 3;  
    int column = 2;  
    jsize len = row * column;  
    ret = (*env)->NewObjectArray(  
        env, len, (*env)->FindClass(env, "[D"), 0);  
    int i;  
    int j;  
    for (i = 0; i < row; i++) {  
        jdoubleArray doubleArr = (*env)->NewDoubleArray(env, column);  
        jdouble *elems = (*env)->GetDoubleArrayElements(env, doubleArr, NULL);  
        for (j = 0; j < column; j++) {  
            elems[j] = i+j+ 0.1234567;;  
        }  
        (*env)->ReleaseDoubleArrayElements(env, doubleArr, elems, 0);  
        (*env)->SetObjectArrayElement(env, ret, i, doubleArr);  
        (*env)->DeleteLocalRef(env, doubleArr);  
    }  
    return ret;  
}  
  
JNIEXPORT jobjectArray JNICALL Java_zfw_JniTest_get2DStringArray  
(JNIEnv *env, jclass jcls) {  
    jobjectArray ret = NULL;  
    const jsize row = 3;  
    const jsize column = 2;  
    char* data[3][2] = {   
        {"hello", "zfw"},  
        {"learn", "jni"},  
        {"i love", "java"}  
    };  
    jsize i;  
    jsize j;  
    jobjectArray *obj = malloc(sizeof(jobjectArray)*row*column);  
    for (i = 0; i < row; i++) {  
        jobjectArray objArr = (*env)->NewObjectArray(  
            env, column, (*env)->FindClass(env, "java/lang/String"), 0);  
        for (j = 0; j < column; j++) {  
            (*env)->SetObjectArrayElement(  
                env, objArr, j, (*env)->NewStringUTF(env, data[i][j]));  
        }  
        obj[i] = objArr;  
    }  
    for (i = 0; i < row; i++) {  
        jobjectArray objArr = obj[i];  
        if (ret == NULL) {  
            ret = (*env)->NewObjectArray(env, row, (*env)->GetObjectClass(env, objArr), 0);  
        }  
        (*env)->SetObjectArrayElement(env, ret, i, objArr);  
    }  
    free(obj);  
    obj = NULL;  
    return ret;  
}  
//2.1 传入基本数据类型参数系列  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferInt  
(JNIEnv *env, jclass jcls, jint param) {  
    printf("------------2.1 传入基本数据类型参数系列-------------\n");  
    printf("transferInt():");  
    printf("%d\n", param);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferLong  
(JNIEnv *env, jclass jcls, jlong param) {  
    printf("transferLong():");  
    printf("%ld\n", param);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferFloat  
(JNIEnv *env, jclass jcls, jfloat param) {  
    printf("transferFloat():");  
    printf("%0.2f\n", param);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferDouble  
(JNIEnv *env, jclass jcls, jdouble param) {  
    printf("transferDouble():");  
    printf("%lf\n", param);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferString  
(JNIEnv *env, jclass jcls, jstring param) {  
    printf("transferString():");  
    char* str = (*env)->GetStringUTFChars(env, param, NULL);  
    printf("%s\n", str);  
}  
// 2.2 传入基本数据类型数组参数系列  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferIntArray  
(JNIEnv *env, jclass jcls, jintArray arr) {  
    printf("----------2.2 传入基本数据类型数组参数系列------------\n");  
    printf("transferIntArray():");  
    jint *elems = (*env)->GetIntArrayElements(env, arr, NULL);  
    int len = (*env)->GetArrayLength(env, arr);  
    int index;  
    for (index = 0; index < len; index++) {  
        if (index != len - 1) {  
            printf("%d | ", elems[index]);  
        }  
        else {  
            printf("%d\n", elems[index]);  
        }  
    }  
    (*env)->ReleaseIntArrayElements(env, arr, elems, JNI_COMMIT);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferLongArray  
(JNIEnv *env, jclass jcls, jlongArray arr) {  
    printf("transferLongArray():");  
    jlong *elems = (*env)->GetLongArrayElements(env, arr, NULL);  
    int len = (*env)->GetArrayLength(env, arr);  
    int index;  
    for (index = 0; index < len; index++) {  
        if (index != len - 1) {  
            printf("%ld | ", elems[index]);  
        }  
        else {  
            printf("%ld\n", elems[index]);  
        }  
    }  
    (*env)->ReleaseLongArrayElements(env, arr, elems, JNI_COMMIT);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferFloatArray  
(JNIEnv *env, jclass jcls, jfloatArray arr) {  
    printf("transferFloatArray():");  
    jfloat *elems = (*env)->GetFloatArrayElements(env, arr, NULL);  
    int len = (*env)->GetArrayLength(env, arr);  
    int index;  
    for (index = 0; index < len; index++) {  
        if (index != len - 1) {  
            printf("%f | ", elems[index]);  
        }  
        else {  
            printf("%f\n", elems[index]);  
        }  
    }  
    (*env)->ReleaseFloatArrayElements(env, arr, elems, JNI_COMMIT);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferDoubleArray  
(JNIEnv *env, jclass jcls, jdoubleArray arr) {  
    printf("transferDoubleArray():");  
    jdouble *elems = (*env)->GetDoubleArrayElements(env, arr, NULL);  
    int len = (*env)->GetArrayLength(env, arr);  
    int index;  
    for (index = 0; index < len; index++) {  
        if (index != len - 1) {  
            printf("%lf | ", elems[index]);  
        }  
        else {  
            printf("%lf\n", elems[index]);  
        }  
    }  
    (*env)->ReleaseDoubleArrayElements(env, arr, elems, JNI_COMMIT);  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transferStringArray  
(JNIEnv *env, jclass jcls, jobjectArray arr) {  
    printf("transferStringArray():");  
    int len = (*env)->GetArrayLength(env, arr);  
    int index;  
    for (index = 0; index < len; index++) {  
        jstring str = (*env)->GetObjectArrayElement(env, arr, index);  
        if (index != len - 1) {  
            printf("%s | ", (*env)->GetStringUTFChars(env, str, NULL));  
        }  
        else {  
            printf("%s\n", (*env)->GetStringUTFChars(env, str, NULL));  
        }  
    }  
}  
  
// 2.3 传入基本数据类型二维数组参数系列  
JNIEXPORT void JNICALL Java_zfw_JniTest_transfer2DIntArray  
(JNIEnv *env, jclass jcls, jobjectArray arr) {  
    printf("----------2.3 传入基本数据类型二维数组参数系列------------\n");  
    printf("transfer2DIntArray(): ");  
    int size = (*env)->GetArrayLength(env, arr);  
    int i, j;  
    for (i = 0; i < size; i++) {  
        jarray elem_arr = (*env)->GetObjectArrayElement(env, arr, i);  
        int elem_arr_size = (*env)->GetArrayLength(env, elem_arr);  
        jint *elem = (*env)->GetIntArrayElements(env, elem_arr, JNI_FALSE);  
        for (j = 0; j < elem_arr_size; j++) {  
            if (j != elem_arr_size - 1) {  
                printf("%d , ", elem[j]);  
            }  
            else {  
                printf("%d", elem[j]);  
            }  
        }  
        printf(" | ");  
        (*env)->ReleaseIntArrayElements(env, elem_arr, elem, 0);  
    }  
    printf("\n");  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transfer2DLongArray  
(JNIEnv *env, jclass jcls, jobjectArray arr) {  
    printf("transfer2DLongArray(): ");  
    int size = (*env)->GetArrayLength(env, arr);  
    int i, j;  
    for (i = 0; i < size; i++) {  
        jarray elem_arr = (*env)->GetObjectArrayElement(env, arr, i);  
        int elem_arr_size = (*env)->GetArrayLength(env, elem_arr);  
        jlong *elem = (*env)->GetLongArrayElements(env, elem_arr, JNI_FALSE);  
        for (j = 0; j < elem_arr_size; j++) {  
            if (j != elem_arr_size - 1) {  
                printf("%ld , ", elem[j]);  
            }  
            else {  
                printf("%ld", elem[j]);  
            }  
        }  
        printf(" | ");  
        (*env)->ReleaseLongArrayElements(env, elem_arr, elem, 0);  
    }  
    printf("\n");  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transfer2DFloatArray  
(JNIEnv *env, jclass jcls, jobjectArray arr) {  
    printf("transfer2DFloatArray(): ");  
    int size = (*env)->GetArrayLength(env, arr);  
    int i, j;  
    for (i = 0; i < size; i++) {  
        jarray elem_arr = (*env)->GetObjectArrayElement(env, arr, i);  
        int elem_arr_size = (*env)->GetArrayLength(env, elem_arr);  
        jfloat *elem = (*env)->GetFloatArrayElements(env, elem_arr, JNI_FALSE);  
        for (j = 0; j < elem_arr_size; j++) {  
            if (j != elem_arr_size - 1) {  
                printf("%.1f , ", elem[j]);  
            }  
            else {  
                printf("%.1f", elem[j]);  
            }  
        }  
        printf(" | ");  
        (*env)->ReleaseFloatArrayElements(env, elem_arr, elem, 0);  
    }  
    printf("\n");  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transfer2DDoubleArray  
(JNIEnv *env, jclass jcls, jobjectArray arr) {  
    printf("transfer2DDoubleArray(): ");  
    int size = (*env)->GetArrayLength(env, arr);  
    int i, j;  
    for (i = 0; i < size; i++) {  
        jarray elem_arr = (*env)->GetObjectArrayElement(env, arr, i);  
        int elem_arr_size = (*env)->GetArrayLength(env, elem_arr);  
        jdouble *elem = (*env)->GetDoubleArrayElements(env, elem_arr, JNI_FALSE);  
        for (j = 0; j < elem_arr_size; j++) {  
            if (j != elem_arr_size - 1) {  
                printf("%lf , ", elem[j]);  
            }  
            else {  
                printf("%lf", elem[j]);  
            }  
        }  
        printf(" | ");  
        (*env)->ReleaseDoubleArrayElements(env, elem_arr, elem, 0);  
    }  
    printf("\n");  
}  
JNIEXPORT void JNICALL Java_zfw_JniTest_transfer2DStringArray  
(JNIEnv *env, jclass jcls, jobjectArray arr) {  
    printf("transfer2DStringArray(): ");  
    int size = (*env)->GetArrayLength(env, arr);  
    int i, j;  
    for (i = 0; i < size; i++) {  
        jobjectArray elem_arr = (*env)->GetObjectArrayElement(env, arr, i);  
        int elem_arr_size = (*env)->GetArrayLength(env, elem_arr);  
        for (j = 0; j < elem_arr_size; j++) {  
            jstring str = (*env)->GetObjectArrayElement(env, elem_arr, j);  
            if (j != elem_arr_size - 1) {  
                printf("%s , ", (*env)->GetStringUTFChars(env, str, NULL));  
            } else {  
                printf("%s", (*env)->GetStringUTFChars(env, str, NULL));  
            }  
        }  
        printf(" | ");  
    }  
    printf("\n");  
}  
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 214,377评论 6 496
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 91,390评论 3 389
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 159,967评论 0 349
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 57,344评论 1 288
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 66,441评论 6 386
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 50,492评论 1 292
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 39,497评论 3 412
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 38,274评论 0 269
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 44,732评论 1 307
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 37,008评论 2 328
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 39,184评论 1 342
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 34,837评论 4 337
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 40,520评论 3 322
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 31,156评论 0 21
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 32,407评论 1 268
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 47,056评论 2 365
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 44,074评论 2 352

推荐阅读更多精彩内容