def _checkIfDatabaseIsEmpty(self, successHandler=None, failHandler=None):
def failCallback(error):<EOL><INDENT>errorMessage = str(error)<EOL>if isinstance(error, Failure):<EOL><INDENT>errorMessage = error.getErrorMessage()<EOL><DEDENT>if failHandler is not None:<EOL><INDENT>reactor.callInThread(failHandler, errorMessage)<EOL><DEDENT><DEDENT>def selectCallback(transaction, successHandler):<EOL><INDENT>querySelect ="<STR_LIT>""<STR_LIT>""<STR_LIT>""<STR_LIT>""<STR_LIT:;>"<EOL>try:<EOL><INDENT>transaction.execute(<EOL>querySelect,<EOL>(self.application.config["<STR_LIT>"]["<STR_LIT:name>"],)<EOL>)<EOL>tables = transaction.fetchall()<EOL><DEDENT>except Exception as e:<EOL><INDENT>failCallback(e)<EOL>return<EOL><DEDENT>if successHandler is not None:<EOL><INDENT>reactor.callInThread(successHandler, len(tables) == <NUM_LIT:0>)<EOL><DEDENT><DEDENT>interaction = self.runInteraction(selectCallback, successHandler)<EOL>interaction.addErrback(failCallback)<EOL>
Check if database contains any tables.

:param successHandler: <function(<bool>)> method called if interrogation was successful where the first argument
                        is a boolean flag specifying if the database is empty or not
:param failHandler: <function(<str>)> method called if interrogation failed where the first argument is the
                        error message
:return: <void>