diff --git a/bindings/java/README.txt b/bindings/java/README.txt index 0f7e7e07945be48ed315636cae120fc9cfa89a99..6cfae9b04f7a238c97e930349b01fccf08381c01 100644 --- a/bindings/java/README.txt +++ b/bindings/java/README.txt @@ -13,30 +13,38 @@ To use the Java bindings, you must have the Sleuth Kit datamodel JAR file compiled and have compiled the associated dynamic library from the C/C++ code. - -Building The Jar File - -You will need: -* The sqlitejdbc Jar file: - http://www.xerial.org/maven/repository/artifact/org/xerial/sqlite-jdbc/ (newest version is at the BOTTOM) +Requirements: * Java JDK * Ant -Place the JAR file in the 'lib' folder. -Build with the default ant target (by running 'ant') +Building the Dynamic Library (for JNI) +The win32 Visual Studio solution has a tsk_jni project that will +build the JNI dll. To use this project, you will need to have +JDK_HOME environment variable set to the root directory of JDK. -Building the Dynamic Library (for JNI) +On non-windows environments, it should just build as part of running +./configure and make. If the needed Java components are not found, +it will not be built. -To build the .dll build the win32 visual studio project. You will -need to have a version of JDK for the .dll to build. You will need -to set the JDK_HOME environment variable If it is not already set. + + +Building The Jar File + +Build with the default ant target (by running 'ant'). This will +download the required libraries (using ivy) and place the jar file +in the dist folder along with the needed dll and library files. Using the Jar file and Library Make sure the Jar file is in your CLASSPATH. The dynamic library will also need to be available when the program is run. Typically -that means that it must be in the path. +that means that it must be in the path. Refer to the javadocs for +details on using the API + +------------ +Brian Carrier +Nov 11, 2011 diff --git a/bindings/java/src/org/sleuthkit/datamodel/package.html b/bindings/java/src/org/sleuthkit/datamodel/package.html index dc473a414add2717fe6f41dc9918f6656da39333..81f415752f6be58326ad9ca867b4f2b3b3dfecec 100644 --- a/bindings/java/src/org/sleuthkit/datamodel/package.html +++ b/bindings/java/src/org/sleuthkit/datamodel/package.html @@ -18,6 +18,9 @@ <h3><b>Data Mapping</b></h3> <p>Use TskData to map integer and enum values back to their meaning. For example, the file system type will be returned as an integer and TskData maps it to NTFS or FAT.</p> <h3><b>JNI</b></h3> -<p>The bulk of the analysis occurs in the C/C++ code. JNI is used to run the C/C++ code from Java. The JNI methods are all located in the SleuthkitJNI class as static methods. It returns handles that refer to data structures in the C/C++ land. You should never have to directly call these methods. This class and its methods are used by the other data model classes.</p> +<p>The bulk of the analysis occurs in the C/C++ code. JNI is used to run the C/C++ code from Java. The JNI methods are all located in the SleuthkitJNI java class as static methods. It returns handles that refer to data structures in the C/C++ land. You should never have to directly call these static Java methods. This class and its methods are used by the other Java data model classes.</p> + +<h3>Error Handling</h3> +<p>The C/C++ code uses return codes and such for error handling. The C/C++ JNI code turns any errors into a TskException that gets thrown into the Java code. The Datamodel Java code will not catch these exceptions and instead they will be passed up to the other Java code that called the datamodel code. </p> </body>