gh-249 Remove MDB_UNSIGNEDKEY, let CursorIterable call mdb_cmp by at055612 · Pull Request #250 · lmdbjava/lmdbjava

@at055612

There are now essentially three ways of configuring comparators
when creating a Dbi.

**null comparator**
LMDB will use its own comparator & CursorIterable will call down
to mdb_cmp for comparisons between the current cursor key and the
range start/stop key.

**provided comparator**
LMDB will use its own comparator & CursorIterable will use the
provided comparator for comparisons between the current cursor
key and the range start/stop key.

**provided comparator with nativeCb==true**
LMDB will call back to java for all comparator duties.
CursorIterable will use the same provided comparator for
comparisons between the current cursor key and the range
start/stop key.

The methods `getSignedComparator()` and `getUnsignedComparator()`
have been made public so users of this library can access them.

added 2 commits

March 6, 2025 17:27

github-advanced-security[bot]

github-advanced-security[bot]

@at055612

github-advanced-security[bot]

@at055612

github-advanced-security[bot]

@at055612

Refactor DbiBuilder and Dbi ctor to use DbiFlagSet.

@at055612

Replace Env#copy(File, CopyFlags...) with copy(File, CopyFlagSet).
As there is only one flag this should not be a breaking change.

Deprecate Env#txn(Txn, TxnFlags...) as there is now
Env#txn(Txn)
Env#txn(Txn, TxnFlags)
Env#txn(Txn, TxnFlagSet)

@at055612

github-advanced-security[bot]

@at055612

Also improve javadoc and refactor some tests to use DbiBuilder.

Some tests are failing.

github-advanced-security[bot]

@at055612

github-advanced-security[bot]

@at055612

@at055612

github-advanced-security[bot]

@at055612

@at055612

github-advanced-security[bot]

@at055612

github-advanced-security[bot]

@at055612

@at055612