fix flags support, add method SetFlags to Logger interface