add Logout and javaDoc