Commit Graph

15 Commits

Author SHA1 Message Date
Don Anderson
7c5de72ebd Fixed bugs in packing/unpacking bytearrays: we must be aware of 'U' format;
when length is provided in format, use it; do padding.

Fixed signed checking for getInt/Long/Short.

Fixed bugs in packing strings: embedded nulls; use length when provided.
Logic copied from packing.py.

Added special case encoding for 8256 (to match Python and C).
2015-07-13 13:54:09 -04:00
Don Anderson
b8971b6ffe Merge branch 'develop' into java-examples 2015-01-09 10:19:17 -05:00
Don Anderson
c8bad02860 Various fixes related to java examples. Refs #1526.
Don't turn on cursor RAW flag for a JSON dump cursor.

Fixed unpacking a fixed length string: unpack cur position was not being updated.

Fixed packing a fixed length string: String array bounds check was firing.

Fixed unpacking short/int: range check was incorrect.

Added methods to put/get record numbers (e.g. getKeyRecord) in Cursor and AsyncOp.

Remove stray println.
2015-01-09 09:54:21 -05:00
Keith Bostic
1f9098871a Copyright notices: add MongoDB, update to 2015. 2015-01-04 14:07:56 -05:00
Don Anderson
b7c182b26c Renamed WiredTigerDeadlockException to be WiredTigerRollbackException. 2014-10-23 10:33:19 -04:00
Don Anderson
f2dd007eda Added new Java exception classes for WT_DEADLOCK and WT_PANIC errors.
refs #1011.
2014-10-10 13:45:41 -04:00
Don Anderson
dff61d2713 WiredTigerException now extends RuntimeException, making it easier to
write Java programs using WiredTiger.  refs #1011.
2014-10-10 13:37:25 -04:00
Don Anderson
2bf916541f Support async operations in Java. refs #933.
- Created a real async handler for java allowing callbacks
  into java code.  Code to be registered must implement the
  new AsyncCallback interface.
- Renamed classes/methods to Java-ish names.
- Fixes to support 'this' removal for AsyncOp.
- Java's cursor ops, like 'insert' set up the value unpackers
  after insert completes.  For AsyncOp, we take a different
  approach, and invalidate the unpacker when the op completes,
  letting the value be fetched when needed.
- Added new test AsyncTest that tests doing different numbers of
  async ops with different parameters, and also with different types
  of keys/values.
2014-05-11 15:09:40 -04:00
Keith Bostic
5b509b7220 Update copyright notices for 2014.
Move lang/java and lang/python into the public domain.
2014-01-07 10:30:12 -05:00
Alex Gorrod
12ea0e5961 Fix copyright notices in Java source code. 2013-02-19 18:40:27 +11:00
Alex Gorrod
39150c640e Update Java Cursor API naming to reflect ByteArray semantics.
Also update documentation, to use Doxygen and @copydoc where possible.
Not yet tied into s_docs.
2013-02-19 17:06:41 +11:00
Alex Gorrod
52d37a140b Update Java cursors to use packing code. Also enhance JUnit usage. 2013-02-13 19:14:40 +11:00
Alex Gorrod
19fed99760 Update Java structure packing implementation.
Add a first JUnit test case, and associated autoconf files.
2013-02-12 21:00:49 +11:00
Alex Gorrod
12c649b0f4 Add a Java implementation of packed formats.
Also add a test case and update the layout of the Java build.
2013-02-08 14:15:19 +11:00
Alex Gorrod
20cf269c8c Move generated Java files into a subdirectory. 2013-01-24 13:49:35 +11:00