Added preliminary functionality to retrieve product information. Also
moved much of the code from Core into a new class called ModuleThread,
which supports running each of the module queries on separate threads
(and all related issues). I had to wrap InputStream in an
InterruptableInputStream since there was a vulnerability where the
module could make the core hang by having it wait on input that it
expects. Thus, whenever any waiting happens on IO, it can be
interrupted.

I changed the prototype of Database. For remote modules, we may end up
having multiple product information queries being done at a time, in
which case we can have key-value arrays for multiple products (and so we
may need another method with two-dimensional input). But for now, the
current Database interface is sufficient to implement all the features
necessary to the core/modules.
Merge branch 'master' of github.com:rafiss/transparent.