How to access a hash type BDB by pure java - berkeley-db

I use bdb 4.7(not java edition) to create a hash type db, but I need to access it by pure java and I don't want to use JNI.
I looked up some keywords in this discussion
But it can not solve my problem, I only need to read the bdb.
Thanks in advance.

A bit late, but for others who are seeking to use BDB in their java applications:
1) go to http://www.oracle.com/technetwork/database/database-technologies/berkeleydb/downloads/index.html
2) download and extract the java .tar.gz/.zip
3) add the .jar to your classpath
Hope this helps

Related

Qt: how to make help system?

I need to provide some help system for my application. The app mostly works on the computers without any Qt installed. I would like to have some way (tool etc) to create the professionally looking help system. I mean I need to provide the regular help system like most applications have. It should look like regular CHM file (with index, search etc.).
I tried to use QtAssistance class, created .adb file but if I run assistance utility, it doesn't know -profile key so I even cannot check if I did this file properly.
I'm a little bit confused because I could see QtAssistant and QHelp classes and I don't know which one is more suitable for my purpose.
Thanks a lot
If you do not care for using Microsofts chm-files, then go ahead and use the QtHelp API - if you are using Qt versions 4.4 or newer. The QAssistant API has been superseded by QtHelp starting with version 4.4, so don't start with old or deprecated interfaces. The QAssistant help files will still be readable from a QtHelp based implementation.
If you do need to read chm files, then a chmlib-based approach with a customized QWebBrowser would be suitable, but I don't think that's what you are looking for.

SQLite for Scala

Try googling for "scala" and "sqlite". You don't come up with much. How are people interfacing with SQLite using Scala?
I didn't like the Java wrappers, so I wrote a new one in Scala. Very alpha. But maybe useful:
http://github.com/srhea/scalaqlite
Since Scala runs on the JVM, it's possible to use Java libraries from Scala. So one option is to use a Java library. There are some listed on the SqliteWrappers page on the SQLite wiki.

SSIS PGP encryption

I have a SSIS package that writes the output to Flat file.
Now I need to PGP encrypt the output file and further decrypt in other packages. I am curious if anyone knows of how to do this, or better yet a website with helpful hints on how to do it.
Thanks
Assuming you want to do the en/de-cryption within SSIS, the simplest method will probably to explore the command line version of whichever encryption software you are using, and execute it using an Execute Process task.
If you haven't yet selected encryption software, obvious choices include PGP (commercial) and GnuPG (open source).
The other option would be to write .Net code to carry out en/de-cryption in a Script Task - this would require a .dll from PGP or GnuPG. Various generic .Net examples (not specific to SSIS) are available - like this one - but I can't comment on their completeness or quality.
This SQLServerCentral thread may have some useful pointers.
For stable, well-supported and updated PGP-compatible SSIS task check our BizCrypto product.
Check the third-party commercial CozyRoc SSIS+ library. It includes OpenPGP Task and many other useful extensions.

Anyone know of a good free patch creator?

Does anyone know of a good patching program that is free? You know, one that can take a directory with your old program in it and compare it to a directory with your new version, and spit out a patch that is only the difference between the two?
Also, I am looking for something that can patch the entire directory, not just one exe.
EDIT:
Thanks for the answers, but I am looking for an end user patch for product updates. Nothing to do with the source.
There is Binary patch and diff, which is free, Windows port available.
I've never used this but it is free. It might be worth a try:
Patch Maker 1.2.
A list of tools here reveals a few marked as "free".
Dispatcher: will use an updater GUI as well. They have a quick demo video on their site.
The best tool I've seen for this purpose is Visual Patch 3.5 . It provides the same functionality that you've mentioned. Although it needs to be purchased since it's not free software.
If you are using Subversion, SmartSVN can create a patch for directories (recursive and all) for the files changed since the last commit. I understand this is only a partial answer and it's not CLI, but it's a really good tool if you deal with an SVN repo here.
SmartSVN patch http://cdn.beerpla.net.lg1x3.simplecdn.net/for_www/screenshots/smartsvn-patch.gif

OS-independent API to monitor file system?

I would like to experiment with ideas about distributed file synchronization/replication. To make it efficient when the user is working, I would like to implement some kind of daemon to monitor changes in some directory (e.g. /home/user/dirToBeMonitored or c:\docs and setts\user\dirToBeMonitored). So, I could be able to know which filename was added/changed/deleted at every time (or within a reasonable interval).
Is this possible with any high-medium level language?. Do you know some API (and in which language?) to do this?
Thanks.
The APIs are totally different for Windows, Linux, Mac OS X, and any other Unix you can name, it seems. I don't know of any cross-platform library that handles this in a consistent way.
A bonified answer, albeit one that requires a largish library dependency (well-worth it IMO)!
QT provides the QFileSystemwatcher class, which uses the native mechanism of the underlying platform.
Even better, you can use the QT language bindings for Python or Ruby. Here is a simple PyQT4 application which uses QFileSystemWatcher.
Notes
A good reference on on creating deployable PyQT4 apps, especially on OSX but should work for Windows also.
Same solution previously posted here.
Other cross-platform toolkits may also do the trick (for example Gnome's GIO has GFileMonitor, although it is UNIX only and doesn't support OSX's FSEvents mechanism afaik).
In Linux it is called inotify.
And on OS X it's called fsevents. It's an OS-level API, so it's easiest to access from C or C++. It should be accessible from nearly any language, although bindings for your preferred language may not have been written yet.

Resources