Skip to content

Commit 20a2e53

Browse files
gsvicihnorton
authored andcommitted
Add README files under JNI SWIG related directories [ch8456]
1 parent ae269ee commit 20a2e53

File tree

4 files changed

+37
-0
lines changed

4 files changed

+37
-0
lines changed

src/main/c/README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# JNI Generated Code
2+
3+
This directory contains the C++ code that is used by the JNI native methods, under the `io.tiledb.java.libtiledb.tiledb` class.
4+
The code is separated into two directoriesn, namely custom and generated.
5+
6+
## ./generated
7+
The `tiledb_wrap.cxx` file under this directory contains the auto-generated JNI C++ code, using SWIG.
8+
9+
## ./custom
10+
The `tiledb_custom.cxx` file under this directory contains custom methods defined by the developer that are not
11+
auto-generated. Any custom method that needs to be added should be put in this file. Also, the signature of the
12+
new custom method should be also put in the `tiledb.i` file under the `TileDB-Java/swig` dir. For implementation details,
13+
all `*_nio` methods (e.g. `tiledb_query_set_subarray_nio`) are good examples.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Java API
2+
3+
Contains all the implementations of the TileDB-Java API.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# libtiledb
2+
Contains all the aut-generated data types and methods by SWIG.

swig/README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# SWIG
2+
3+
This directory contains the basic SWIG files.
4+
5+
### customCode
6+
Contains custom method implementations.
7+
8+
- NativeLibLoader.java: Helper methods for loading native libraries (e.g. `.so` files)
9+
- PointerUtils.java: Pointer conversion methods
10+
- Utils.java: Custom JNI methods
11+
12+
The rest of the files are auto-generated.
13+
14+
### tiledb.i
15+
The SWIG interface (`.i`) file. More info can be found at the official SWIG documentation: http://www.swig.org/tutorial.html
16+
17+
### tiledb_java_extensions.h
18+
Contains some extensions of the `tiledb.h` (https://github.com/TileDB-Inc/TileDB/blob/dev/tiledb/sm/c_api/tiledb.h) library that we use in Java. Most of these extensions are implementations of
19+
`dump()` methods that print the dumb to the `stdout` (e.g. `tiledb_fragment_info_dump_stdout`).

0 commit comments

Comments
 (0)