1.0.1 • Published 6 years ago
awdb_nodejs v1.0.1
Installation
npm i awdb_nodejsV6 Support
Module is fully compatible with IPv6. There are no differences in API between IPv4 and IPv6.
const lookup = await aw.open('/path/to/****.awdb');
const location = lookup.get('2001:4860:0:1001::3004:ef68');Options
aw.open(filepath, options)_
filepath:<string>Path to the binary awdb file.options:<Object>cache:<Object>Cache options. Under the bonnet module uses tiny-lru cache.max:<number>Max cache items to keep in memory. Default:6000.
watchForUpdates:<boolean>Supports reloading the reader when changes occur to the database that is loaded. Default:false.watchForUpdatesNonPersistent:<boolean>Controlls wether the watcher should be persistent or not. If it is persistent, a node process will be blocked in watching state if the watcher is the only thing still running in the program. Default:false.watchForUpdatesHook:<Function>Hook function that is fired on database update. Default:null.
License
MIT