node-postgres/lib/index.js

18 lines
524 B
JavaScript
Raw Normal View History

var EventEmitter = require('events').EventEmitter;
var Client = require(__dirname+'/client');
var defaults = require(__dirname + '/defaults');
var pool = require(__dirname + "/client-pool").init(Client);
module.exports = {
Client: Client,
Connection: require(__dirname + '/connection'),
connect: pool.connect,
end: pool.end,
defaults: defaults
}
2011-05-02 13:32:30 +08:00
//lazy require native module...the c++ may not have been compiled
module.exports.__defineGetter__("native", function() {
2011-03-16 12:08:37 +08:00
return require(__dirname + '/native');
})