Class: ControlDBFsAdapter

ControlDBFsAdapter()

new ControlDBFsAdapter()

A control persistence adapter which persists using node fs module

Source:

Methods

deleteDatabase(dbname, callback)

deleteDatabase() - delete the database file, will throw an error if the file can't be deleted

Parameters:
Name Type Description
dbname string

the filename of the database to delete

callback function

the callback to handle the result

Source:

loadDatabase(dbname, callback)

loadDatabase() - Load data from file, will throw an error if the file does not exist

Parameters:
Name Type Description
dbname string

the filename of the database to load

callback function

the callback to handle the result

Source:

saveDatabase(dbname, callback)

saveDatabase() - save data to file, will throw an error if the file can't be saved might want to expand this to avoid dataloss on partial save

Parameters:
Name Type Description
dbname string

the filename of the database to load

callback function

the callback to handle the result

Source: