added logTable method